add sound driver selection and logging toggle
This commit is contained in:
@@ -54,8 +54,10 @@ BOOL ChangeGameSettings::OnInitDialog()
|
||||
ini.ReadFile();
|
||||
|
||||
CString sValue;
|
||||
ini.GetValue( "Options", "VideoRenderers", sValue );
|
||||
|
||||
|
||||
|
||||
sValue = "";
|
||||
ini.GetValue( "Options", "VideoRenderers", sValue );
|
||||
if( sValue.CompareNoCase("opengl")==0 )
|
||||
CheckDlgButton( IDC_RADIO_OPENGL, BST_CHECKED );
|
||||
else if( sValue.CompareNoCase("d3d")==0 )
|
||||
@@ -63,6 +65,27 @@ BOOL ChangeGameSettings::OnInitDialog()
|
||||
else
|
||||
CheckDlgButton( IDC_RADIO_DEFAULT, BST_CHECKED );
|
||||
|
||||
|
||||
sValue = "";
|
||||
ini.GetValue( "Options", "SoundDrivers", sValue );
|
||||
if( sValue.CompareNoCase("null")==0 )
|
||||
CheckDlgButton( IDC_RADIO_SOUND_NULL, BST_CHECKED );
|
||||
else
|
||||
CheckDlgButton( IDC_RADIO_SOUND_DEFAULT, BST_CHECKED );
|
||||
|
||||
|
||||
bool bValue;
|
||||
|
||||
|
||||
bValue = false;
|
||||
ini.GetValue( "Options", "LogToDisk", bValue );
|
||||
CheckDlgButton( IDC_CHECK_LOG_TO_DISK, bValue ? BST_CHECKED : BST_UNCHECKED );
|
||||
|
||||
|
||||
bValue = false;
|
||||
ini.GetValue( "Options", "ShowLogWindow", bValue );
|
||||
CheckDlgButton( IDC_CHECK_SHOW_LOG_WINDOW, bValue ? BST_CHECKED : BST_UNCHECKED );
|
||||
|
||||
|
||||
return TRUE; // return TRUE unless you set the focus to a control
|
||||
// EXCEPTION: OCX Property Pages should return FALSE
|
||||
@@ -75,6 +98,7 @@ void ChangeGameSettings::OnOK()
|
||||
ini.SetPath( "Data\\StepMania.ini" );
|
||||
ini.ReadFile();
|
||||
|
||||
|
||||
if( BST_CHECKED == IsDlgButtonChecked(IDC_RADIO_OPENGL) )
|
||||
ini.SetValue( "Options", "VideoRenderers", "opengl" );
|
||||
else if( BST_CHECKED == IsDlgButtonChecked(IDC_RADIO_DIRECT3D) )
|
||||
@@ -82,6 +106,17 @@ void ChangeGameSettings::OnOK()
|
||||
else
|
||||
ini.SetValue( "Options", "VideoRenderers", "" );
|
||||
|
||||
|
||||
if( BST_CHECKED == IsDlgButtonChecked(IDC_RADIO_SOUND_NULL) )
|
||||
ini.SetValue( "Options", "SoundDrivers", "null" );
|
||||
else
|
||||
ini.SetValue( "Options", "SoundDrivers", "" );
|
||||
|
||||
|
||||
ini.SetValue( "Options", "LogToDisk", BST_CHECKED == IsDlgButtonChecked(IDC_CHECK_LOG_TO_DISK) );
|
||||
ini.SetValue( "Options", "ShowLogWindow", BST_CHECKED == IsDlgButtonChecked(IDC_CHECK_SHOW_LOG_WINDOW) );
|
||||
|
||||
|
||||
ini.WriteFile();
|
||||
|
||||
CDialog::OnOK();
|
||||
|
||||
@@ -63,6 +63,10 @@
|
||||
#define IDC_RADIO_DEFAULT 1048
|
||||
#define IDC_RADIO_OPENGL 1049
|
||||
#define IDC_RADIO_DIRECT3D 1050
|
||||
#define IDC_RADIO_SOUND_DEFAULT 1051
|
||||
#define IDC_RADIO_SOUND_NULL 1052
|
||||
#define IDC_CHECK_LOG_TO_DISK 1053
|
||||
#define IDC_CHECK_SHOW_LOG_WINDOW 1054
|
||||
|
||||
// Next default values for new objects
|
||||
//
|
||||
@@ -70,7 +74,7 @@
|
||||
#ifndef APSTUDIO_READONLY_SYMBOLS
|
||||
#define _APS_NEXT_RESOURCE_VALUE 149
|
||||
#define _APS_NEXT_COMMAND_VALUE 32771
|
||||
#define _APS_NEXT_CONTROL_VALUE 1049
|
||||
#define _APS_NEXT_CONTROL_VALUE 1054
|
||||
#define _APS_NEXT_SYMED_VALUE 104
|
||||
#endif
|
||||
#endif
|
||||
|
||||
@@ -18,21 +18,21 @@ Class3=CSMPackageInstallDlg
|
||||
Class4=CSmpackageExportDlg
|
||||
Resource3=IDD_INSTALL
|
||||
Class5=EnterName
|
||||
Resource4=IDD_CONVERT_THEME
|
||||
Resource4=IDD_ENTER_COMMENT
|
||||
Class6=EditInsallations
|
||||
Resource5=IDD_SHOW_COMMENT
|
||||
Class7=MainMenuDlg
|
||||
Resource6=IDD_UNINSTALL_OLD_PACKAGES
|
||||
Resource6=IDD_EDIT_INSTALLATIONS
|
||||
Class8=ConvertThemeDlg
|
||||
Resource7=IDD_ENTER_COMMENT
|
||||
Resource7=IDD_CONVERT_THEME
|
||||
Class9=EditMetricsDlg
|
||||
Resource8=IDD_EDIT_INSTALLATIONS
|
||||
Resource9=IDD_EXPORTER
|
||||
Resource8=IDD_EXPORTER
|
||||
Resource9=IDD_UNINSTALL_OLD_PACKAGES
|
||||
Class10=EnterComment
|
||||
Resource10=IDD_EDIT_METRICS
|
||||
Resource10=IDD_MENU
|
||||
Class11=ShowComment
|
||||
Resource11=IDD_DIALOG_NAME
|
||||
Resource12=IDD_MENU
|
||||
Resource11=IDD_EDIT_METRICS
|
||||
Resource12=IDD_DIALOG_NAME
|
||||
Class12=ChangeGameSettings
|
||||
Resource13=IDD_CHANGE_GAME_SETTINGS
|
||||
|
||||
@@ -287,14 +287,20 @@ Control6=IDC_STATIC,static,1342308352
|
||||
[DLG:IDD_CHANGE_GAME_SETTINGS]
|
||||
Type=1
|
||||
Class=ChangeGameSettings
|
||||
ControlCount=7
|
||||
ControlCount=13
|
||||
Control1=IDOK,button,1342242817
|
||||
Control2=IDCANCEL,button,1342242816
|
||||
Control3=IDC_STATIC,button,1342177287
|
||||
Control4=IDC_RADIO_DEFAULT,button,1342177289
|
||||
Control4=IDC_RADIO_DEFAULT,button,1342308361
|
||||
Control5=IDC_RADIO_OPENGL,button,1342177289
|
||||
Control6=IDC_RADIO_DIRECT3D,button,1342177289
|
||||
Control7=IDC_STATIC,static,1342308352
|
||||
Control8=IDC_STATIC,button,1342177287
|
||||
Control9=IDC_RADIO_SOUND_DEFAULT,button,1342308361
|
||||
Control10=IDC_RADIO_SOUND_NULL,button,1342177289
|
||||
Control11=IDC_STATIC,button,1342177287
|
||||
Control12=IDC_CHECK_LOG_TO_DISK,button,1342242819
|
||||
Control13=IDC_CHECK_SHOW_LOG_WINDOW,button,1342242819
|
||||
|
||||
[CLS:ChangeGameSettings]
|
||||
Type=0
|
||||
|
||||
@@ -155,12 +155,12 @@ BEGIN
|
||||
IDC_STATIC,18,144,196,17
|
||||
END
|
||||
|
||||
IDD_MENU DIALOG DISCARDABLE 0, 0, 332, 281
|
||||
IDD_MENU DIALOG DISCARDABLE 0, 0, 332, 293
|
||||
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
||||
CAPTION "StepMania Tools Main Menu"
|
||||
FONT 8, "MS Sans Serif"
|
||||
BEGIN
|
||||
DEFPUSHBUTTON "Exit",IDOK,275,260,50,14
|
||||
DEFPUSHBUTTON "Exit",IDOK,275,272,50,14
|
||||
CONTROL 140,IDC_STATIC,"Static",SS_BITMAP,0,0,332,38
|
||||
PUSHBUTTON "Export Packages",IDC_EXPORT_PACKAGES,20,120,70,15
|
||||
LTEXT "Choose this option to create .smzip files that you can share with other StepMania and DWI users. A .smzip package can contain songs, courses, themes, background animations, and more.",
|
||||
@@ -174,10 +174,10 @@ BEGIN
|
||||
GROUPBOX "Installations",IDC_STATIC,5,45,320,50
|
||||
LTEXT "Using this feature, you can:\n - Catch redundant and misnamed theme elements\n - Convert a SM 3.0 theme for use in SM 4.0\n - Edit theme metrics using a user-friendly interface",
|
||||
IDC_STATIC,103,168,215,35
|
||||
GROUPBOX "Game Settings",IDC_STATIC,6,215,320,40
|
||||
PUSHBUTTON "Change Settings",IDC_CHANGE_API,20,230,70,15
|
||||
LTEXT "Using this feature, you can:\n - Change the graphics API that StepMania will use.",
|
||||
IDC_STATIC,104,228,215,19
|
||||
GROUPBOX "Game Settings",IDC_STATIC,6,215,320,49
|
||||
PUSHBUTTON "Change Settings",IDC_CHANGE_API,20,234,70,15
|
||||
LTEXT "Using this feature, you can:\n - Change the graphics API that StepMania will use.\n - Change the sound API that StepMania will use.",
|
||||
IDC_STATIC,104,228,215,29
|
||||
END
|
||||
|
||||
IDD_CONVERT_THEME DIALOG DISCARDABLE 0, 0, 332, 258
|
||||
@@ -274,22 +274,32 @@ BEGIN
|
||||
LTEXT "Delete old packages?",IDC_STATIC,105,119,67,12
|
||||
END
|
||||
|
||||
IDD_CHANGE_GAME_SETTINGS DIALOG DISCARDABLE 0, 0, 167, 146
|
||||
IDD_CHANGE_GAME_SETTINGS DIALOG DISCARDABLE 0, 0, 162, 262
|
||||
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
||||
CAPTION "Change Game Settings"
|
||||
FONT 8, "MS Sans Serif"
|
||||
BEGIN
|
||||
DEFPUSHBUTTON "OK",IDOK,49,124,50,14
|
||||
PUSHBUTTON "Cancel",IDCANCEL,109,124,50,14
|
||||
GROUPBOX "Graphics API",IDC_STATIC,7,7,152,71
|
||||
DEFPUSHBUTTON "OK",IDOK,49,240,50,14
|
||||
PUSHBUTTON "Cancel",IDCANCEL,104,240,50,14
|
||||
GROUPBOX "Graphics API",IDC_STATIC,7,7,147,71
|
||||
CONTROL "Default (recommended)",IDC_RADIO_DEFAULT,"Button",
|
||||
BS_AUTORADIOBUTTON,25,24,105,12
|
||||
CONTROL "Force OpenGL",IDC_RADIO_OPENGL,"Button",
|
||||
BS_AUTORADIOBUTTON,25,40,105,12
|
||||
CONTROL "Force Direct3D",IDC_RADIO_DIRECT3D,"Button",
|
||||
BS_AUTORADIOBUTTON | WS_GROUP,25,24,105,12
|
||||
CONTROL "OpenGL",IDC_RADIO_OPENGL,"Button",BS_AUTORADIOBUTTON,25,
|
||||
40,105,12
|
||||
CONTROL "Direct3D",IDC_RADIO_DIRECT3D,"Button",
|
||||
BS_AUTORADIOBUTTON,25,56,105,12
|
||||
LTEXT "Tip: Change these only if you experience problems when using the default settings.",
|
||||
IDC_STATIC,7,88,152,27
|
||||
IDC_STATIC,7,205,147,27
|
||||
GROUPBOX "Sound API",IDC_STATIC,7,83,147,53
|
||||
CONTROL "Default (recommended)",IDC_RADIO_SOUND_DEFAULT,"Button",
|
||||
BS_AUTORADIOBUTTON | WS_GROUP,25,99,105,12
|
||||
CONTROL "Null (no sound)",IDC_RADIO_SOUND_NULL,"Button",
|
||||
BS_AUTORADIOBUTTON,25,115,105,12
|
||||
GROUPBOX "Logging",IDC_STATIC,7,143,147,53
|
||||
CONTROL "Log to Disk",IDC_CHECK_LOG_TO_DISK,"Button",
|
||||
BS_AUTOCHECKBOX | WS_TABSTOP,26,160,106,10
|
||||
CONTROL "Show Log Window",IDC_CHECK_SHOW_LOG_WINDOW,"Button",
|
||||
BS_AUTOCHECKBOX | WS_TABSTOP,26,176,106,10
|
||||
END
|
||||
|
||||
|
||||
@@ -379,7 +389,7 @@ BEGIN
|
||||
LEFTMARGIN, 7
|
||||
RIGHTMARGIN, 325
|
||||
TOPMARGIN, 7
|
||||
BOTTOMMARGIN, 274
|
||||
BOTTOMMARGIN, 286
|
||||
END
|
||||
|
||||
IDD_CONVERT_THEME, DIALOG
|
||||
@@ -425,9 +435,9 @@ BEGIN
|
||||
IDD_CHANGE_GAME_SETTINGS, DIALOG
|
||||
BEGIN
|
||||
LEFTMARGIN, 7
|
||||
RIGHTMARGIN, 159
|
||||
RIGHTMARGIN, 154
|
||||
TOPMARGIN, 7
|
||||
BOTTOMMARGIN, 138
|
||||
BOTTOMMARGIN, 254
|
||||
END
|
||||
END
|
||||
#endif // APSTUDIO_INVOKED
|
||||
|
||||
Reference in New Issue
Block a user