Added screen saver synchronization option to win32 launcher dialog.
This commit is contained in:
parent
ddfc05244b
commit
b840c61f6c
|
@ -75,6 +75,8 @@ CGlobalOptions::init(HWND hwnd)
|
||||||
setItemChecked(child, false);
|
setItemChecked(child, false);
|
||||||
child = getItem(hwnd, IDC_GLOBAL_HEARTBEAT_TIME);
|
child = getItem(hwnd, IDC_GLOBAL_HEARTBEAT_TIME);
|
||||||
setWindowText(child, buffer);
|
setWindowText(child, buffer);
|
||||||
|
child = getItem(hwnd, IDC_GLOBAL_SCREENSAVER_SYNC);
|
||||||
|
setItemChecked(child, true);
|
||||||
|
|
||||||
// get the global options
|
// get the global options
|
||||||
const CConfig::CScreenOptions* options = m_config->getOptions("");
|
const CConfig::CScreenOptions* options = m_config->getOptions("");
|
||||||
|
@ -110,6 +112,10 @@ CGlobalOptions::init(HWND hwnd)
|
||||||
setWindowText(child, buffer);
|
setWindowText(child, buffer);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (id == kOptionScreenSaverSync) {
|
||||||
|
child = getItem(hwnd, IDC_GLOBAL_SCREENSAVER_SYNC);
|
||||||
|
setItemChecked(child, (value != 0));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -173,6 +179,7 @@ CGlobalOptions::save(HWND hwnd)
|
||||||
m_config->removeOption("", kOptionScreenSwitchDelay);
|
m_config->removeOption("", kOptionScreenSwitchDelay);
|
||||||
m_config->removeOption("", kOptionScreenSwitchTwoTap);
|
m_config->removeOption("", kOptionScreenSwitchTwoTap);
|
||||||
m_config->removeOption("", kOptionHeartbeat);
|
m_config->removeOption("", kOptionHeartbeat);
|
||||||
|
m_config->removeOption("", kOptionScreenSaverSync);
|
||||||
|
|
||||||
// add requested options
|
// add requested options
|
||||||
child = getItem(hwnd, IDC_GLOBAL_DELAY_CHECK);
|
child = getItem(hwnd, IDC_GLOBAL_DELAY_CHECK);
|
||||||
|
@ -187,6 +194,10 @@ CGlobalOptions::save(HWND hwnd)
|
||||||
if (isItemChecked(child)) {
|
if (isItemChecked(child)) {
|
||||||
m_config->addOption("", kOptionHeartbeat, newHeartbeatTime);
|
m_config->addOption("", kOptionHeartbeat, newHeartbeatTime);
|
||||||
}
|
}
|
||||||
|
child = getItem(hwnd, IDC_GLOBAL_SCREENSAVER_SYNC);
|
||||||
|
if (!isItemChecked(child)) {
|
||||||
|
m_config->addOption("", kOptionScreenSaverSync, 0);
|
||||||
|
}
|
||||||
|
|
||||||
// save last values
|
// save last values
|
||||||
m_delayTime = newDelayTime;
|
m_delayTime = newDelayTime;
|
||||||
|
|
|
@ -170,7 +170,7 @@ BEGIN
|
||||||
IDC_STATIC,7,43,181,17
|
IDC_STATIC,7,43,181,17
|
||||||
END
|
END
|
||||||
|
|
||||||
IDD_GLOBAL_OPTIONS DIALOG DISCARDABLE 0, 0, 207, 196
|
IDD_GLOBAL_OPTIONS DIALOG DISCARDABLE 0, 0, 207, 233
|
||||||
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
STYLE DS_MODALFRAME | WS_POPUP | WS_CAPTION | WS_SYSMENU
|
||||||
CAPTION "Options"
|
CAPTION "Options"
|
||||||
FONT 8, "MS Sans Serif"
|
FONT 8, "MS Sans Serif"
|
||||||
|
@ -198,8 +198,12 @@ BEGIN
|
||||||
EDITTEXT IDC_GLOBAL_HEARTBEAT_TIME,112,152,45,12,ES_AUTOHSCROLL |
|
EDITTEXT IDC_GLOBAL_HEARTBEAT_TIME,112,152,45,12,ES_AUTOHSCROLL |
|
||||||
ES_NUMBER
|
ES_NUMBER
|
||||||
LTEXT "ms",IDC_STATIC,159,154,10,8
|
LTEXT "ms",IDC_STATIC,159,154,10,8
|
||||||
DEFPUSHBUTTON "OK",IDOK,94,175,50,14
|
LTEXT "Synergy can synchronize screen savers across all screens.",
|
||||||
PUSHBUTTON "Cancel",IDCANCEL,150,175,50,14
|
IDC_STATIC,7,176,193,8
|
||||||
|
CONTROL "Synchronize screen savers",IDC_GLOBAL_SCREENSAVER_SYNC,
|
||||||
|
"Button",BS_AUTOCHECKBOX | WS_TABSTOP,7,192,101,10
|
||||||
|
DEFPUSHBUTTON "OK",IDOK,94,212,50,14
|
||||||
|
PUSHBUTTON "Cancel",IDCANCEL,150,212,50,14
|
||||||
END
|
END
|
||||||
|
|
||||||
IDD_ADVANCED_OPTIONS DIALOG DISCARDABLE 0, 0, 230, 133
|
IDD_ADVANCED_OPTIONS DIALOG DISCARDABLE 0, 0, 230, 133
|
||||||
|
@ -267,7 +271,7 @@ BEGIN
|
||||||
LEFTMARGIN, 7
|
LEFTMARGIN, 7
|
||||||
RIGHTMARGIN, 200
|
RIGHTMARGIN, 200
|
||||||
TOPMARGIN, 7
|
TOPMARGIN, 7
|
||||||
BOTTOMMARGIN, 189
|
BOTTOMMARGIN, 226
|
||||||
END
|
END
|
||||||
|
|
||||||
IDD_ADVANCED_OPTIONS, DIALOG
|
IDD_ADVANCED_OPTIONS, DIALOG
|
||||||
|
|
|
@ -97,6 +97,7 @@
|
||||||
#define IDC_ADD_MOD_META 1046
|
#define IDC_ADD_MOD_META 1046
|
||||||
#define IDC_GLOBAL_HEARTBEAT_TIME 1046
|
#define IDC_GLOBAL_HEARTBEAT_TIME 1046
|
||||||
#define IDC_ADD_MOD_SUPER 1047
|
#define IDC_ADD_MOD_SUPER 1047
|
||||||
|
#define IDC_GLOBAL_SCREENSAVER_SYNC 1047
|
||||||
#define IDC_ADVANCED_DEFAULTS 1049
|
#define IDC_ADVANCED_DEFAULTS 1049
|
||||||
|
|
||||||
// Next default values for new objects
|
// Next default values for new objects
|
||||||
|
|
Loading…
Reference in New Issue