Added half-duplex option for scroll lock key.
This commit is contained in:
parent
dc499149f4
commit
3c3c31008e
|
@ -829,6 +829,10 @@ addDlgProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
index->second != 0));
|
index->second != 0));
|
||||||
child = getItem(hwnd, IDC_ADD_HD_NUM_CHECK);
|
child = getItem(hwnd, IDC_ADD_HD_NUM_CHECK);
|
||||||
index = info->m_options.find(kOptionHalfDuplexNumLock);
|
index = info->m_options.find(kOptionHalfDuplexNumLock);
|
||||||
|
setItemChecked(child, (index != info->m_options.end() &&
|
||||||
|
index->second != 0));
|
||||||
|
child = getItem(hwnd, IDC_ADD_HD_SCROLL_CHECK);
|
||||||
|
index = info->m_options.find(kOptionHalfDuplexScrollLock);
|
||||||
setItemChecked(child, (index != info->m_options.end() &&
|
setItemChecked(child, (index != info->m_options.end() &&
|
||||||
index->second != 0));
|
index->second != 0));
|
||||||
|
|
||||||
|
@ -940,9 +944,15 @@ addDlgProc(HWND hwnd, UINT message, WPARAM wParam, LPARAM lParam)
|
||||||
else {
|
else {
|
||||||
info->m_options.erase(kOptionHalfDuplexNumLock);
|
info->m_options.erase(kOptionHalfDuplexNumLock);
|
||||||
}
|
}
|
||||||
|
child = getItem(hwnd, IDC_ADD_HD_SCROLL_CHECK);
|
||||||
|
if (isItemChecked(child)) {
|
||||||
|
info->m_options[kOptionHalfDuplexScrollLock] = 1;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
info->m_options.erase(kOptionHalfDuplexScrollLock);
|
||||||
|
}
|
||||||
|
|
||||||
// save modifier options
|
// save modifier options
|
||||||
child = getItem(hwnd, IDC_ADD_HD_CAPS_CHECK);
|
|
||||||
for (UInt32 i = 0; i < sizeof(s_modifiers) /
|
for (UInt32 i = 0; i < sizeof(s_modifiers) /
|
||||||
sizeof(s_modifiers[0]); ++i) {
|
sizeof(s_modifiers[0]); ++i) {
|
||||||
child = getItem(hwnd, s_modifiers[i].m_ctrlID);
|
child = getItem(hwnd, s_modifiers[i].m_ctrlID);
|
||||||
|
|
|
@ -116,13 +116,15 @@ BEGIN
|
||||||
LTEXT "&Aliases:",IDC_STATIC,7,25,25,8
|
LTEXT "&Aliases:",IDC_STATIC,7,25,25,8
|
||||||
EDITTEXT IDC_ADD_ALIASES_EDIT,79,26,106,40,ES_MULTILINE |
|
EDITTEXT IDC_ADD_ALIASES_EDIT,79,26,106,40,ES_MULTILINE |
|
||||||
ES_AUTOVSCROLL | ES_AUTOHSCROLL | ES_WANTRETURN
|
ES_AUTOVSCROLL | ES_AUTOHSCROLL | ES_WANTRETURN
|
||||||
GROUPBOX "Options",IDC_STATIC,7,72,178,64
|
GROUPBOX "Half-Duplex",IDC_STATIC,7,72,178,64
|
||||||
LTEXT "If your Caps Lock or Num Lock keys behave strangely on this client screen then try turning the half-duplex options on and reconnect the client.",
|
LTEXT "If your Caps, Num, or Scroll Lock keys behave strangely on this screen then turn on the half-duplex options and restart the server.",
|
||||||
IDC_STATIC,13,82,165,25
|
IDC_STATIC,13,82,165,25
|
||||||
CONTROL "Half-duplex &Caps Lock",IDC_ADD_HD_CAPS_CHECK,"Button",
|
CONTROL "&Caps Lock",IDC_ADD_HD_CAPS_CHECK,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,13,110,165,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,13,110,81,10
|
||||||
CONTROL "Half-duplex &Num Lock",IDC_ADD_HD_NUM_CHECK,"Button",
|
CONTROL "&Num Lock",IDC_ADD_HD_NUM_CHECK,"Button",
|
||||||
BS_AUTOCHECKBOX | WS_TABSTOP,13,122,165,10
|
BS_AUTOCHECKBOX | WS_TABSTOP,13,122,81,10
|
||||||
|
CONTROL "Sc&roll Lock",IDC_ADD_HD_SCROLL_CHECK,"Button",
|
||||||
|
BS_AUTOCHECKBOX | WS_TABSTOP,98,110,81,10
|
||||||
GROUPBOX "Modifiers",IDC_STATIC,7,139,178,65
|
GROUPBOX "Modifiers",IDC_STATIC,7,139,178,65
|
||||||
LTEXT "Shift",IDC_STATIC,13,155,15,8
|
LTEXT "Shift",IDC_STATIC,13,155,15,8
|
||||||
COMBOBOX IDC_ADD_MOD_SHIFT,37,152,48,60,CBS_DROPDOWNLIST |
|
COMBOBOX IDC_ADD_MOD_SHIFT,37,152,48,60,CBS_DROPDOWNLIST |
|
||||||
|
|
|
@ -87,6 +87,7 @@
|
||||||
#define IDC_ADD_HD_NUM_CHECK 1038
|
#define IDC_ADD_HD_NUM_CHECK 1038
|
||||||
#define IDC_ADVANCED_NAME_EDIT 1038
|
#define IDC_ADVANCED_NAME_EDIT 1038
|
||||||
#define IDC_ADVANCED_PORT_EDIT 1039
|
#define IDC_ADVANCED_PORT_EDIT 1039
|
||||||
|
#define IDC_ADD_HD_SCROLL_CHECK 1039
|
||||||
#define IDC_MAIN_DEBUG 1040
|
#define IDC_MAIN_DEBUG 1040
|
||||||
#define IDC_GLOBAL_DELAY_CHECK 1041
|
#define IDC_GLOBAL_DELAY_CHECK 1041
|
||||||
#define IDC_GLOBAL_DELAY_TIME 1042
|
#define IDC_GLOBAL_DELAY_TIME 1042
|
||||||
|
|
|
@ -99,6 +99,14 @@ A screen can have the following options:
|
||||||
This is identical to <span class="code">halfDuplexCapsLock</span>
|
This is identical to <span class="code">halfDuplexCapsLock</span>
|
||||||
except it applies to the Num Lock key.
|
except it applies to the Num Lock key.
|
||||||
</p>
|
</p>
|
||||||
|
<li><span class="code">halfDuplexScrollLock = {true|false}</span>
|
||||||
|
<p>
|
||||||
|
This is identical to <span class="code">halfDuplexCapsLock</span>
|
||||||
|
except it applies to the Scroll Lock key. Note that synergy uses
|
||||||
|
Scroll Lock to keep the cursor on the current screen. That is,
|
||||||
|
when Scroll Lock is toggled on, the cursor is locked to the screen
|
||||||
|
that it's currently on. Use it to prevent accidental switching.
|
||||||
|
</p>
|
||||||
<li><span class="code">xtestIsXineramaUnaware = {true|false}</span>
|
<li><span class="code">xtestIsXineramaUnaware = {true|false}</span>
|
||||||
<p>
|
<p>
|
||||||
This option works around a bug in the XTest extension
|
This option works around a bug in the XTest extension
|
||||||
|
|
25
doc/faq.html
25
doc/faq.html
|
@ -15,7 +15,7 @@
|
||||||
<li><a href="#faq4">What does "Cannot initialize hook library" mean?</a>
|
<li><a href="#faq4">What does "Cannot initialize hook library" mean?</a>
|
||||||
<li><a href="#faq5">What security/encryption does synergy provide?</a>
|
<li><a href="#faq5">What security/encryption does synergy provide?</a>
|
||||||
<li><a href="#faq6">What should I call my screens in the configuration?</a>
|
<li><a href="#faq6">What should I call my screens in the configuration?</a>
|
||||||
<li><a href="#faq7">Why do my Caps-Lock and Num-Lock keys act funny?</a>
|
<li><a href="#faq7">Why do my Caps-Lock, Num-Lock, Scroll-Lock keys act funny?</a>
|
||||||
<li><a href="#faq8">Can synergy share the display in addition to the mouse and keyboard?</a>
|
<li><a href="#faq8">Can synergy share the display in addition to the mouse and keyboard?</a>
|
||||||
<li><a href="#faq9">Can synergy do drag and drop between computers?</a>
|
<li><a href="#faq9">Can synergy do drag and drop between computers?</a>
|
||||||
<li><a href="#faq10">Do AltGr or Mode-Switch or ISO_Level3_Shift work?</a>
|
<li><a href="#faq10">Do AltGr or Mode-Switch or ISO_Level3_Shift work?</a>
|
||||||
|
@ -125,28 +125,29 @@
|
||||||
then use <span class="code">xyz.local</span> as the screen name.
|
then use <span class="code">xyz.local</span> as the screen name.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<li><a name="faq7"></a><span class="fakelink">Why do my Caps-Lock and Num-Lock keys act funny?</span>
|
<li><a name="faq7"></a><span class="fakelink">Why do my Caps-Lock, Num-Lock, Scroll-Lock keys act funny?</span>
|
||||||
<p>
|
<p>
|
||||||
Some systems treat the Caps-Lock and Num-Lock keys differently
|
Some systems treat the Caps-Lock, Num-Lock, and Scroll-Lock keys
|
||||||
than all the others. Whereas most keys report going down when
|
differently than all the others. Whereas most keys report going down
|
||||||
physically pressed and going up when physically released, on
|
when physically pressed and going up when physically released, on
|
||||||
these systems the Caps-Lock and Num-Lock keys report going down
|
these systems the keys report going down when being activated and
|
||||||
when being activated and going up when being deactivated. That
|
going up when being deactivated. That is, when you press and release,
|
||||||
is, when you press and release, say, Caps-Lock to activate it, it
|
say, Caps-Lock to activate it, it only reports going down, and when
|
||||||
only reports going down, and when you press and release to
|
you press and release to deactivate it, it only reports going up.
|
||||||
deactivate it, it only reports going up. This confuses synergy.
|
This confuses synergy.
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p>
|
||||||
You can solve the problem by changing your configuration file.
|
You can solve the problem by changing your configuration file.
|
||||||
In the screens section, following each screen that has the
|
In the screens section, following each screen that has the
|
||||||
problem, add either or both of these lines as appropriate:
|
problem, add any or all of these lines as appropriate:
|
||||||
</p>
|
</p>
|
||||||
<pre>
|
<pre>
|
||||||
halfDuplexCapsLock = true
|
halfDuplexCapsLock = true
|
||||||
halfDuplexNumLock = true
|
halfDuplexNumLock = true
|
||||||
|
halfDuplexScrollLock = true
|
||||||
</pre>
|
</pre>
|
||||||
<p>
|
<p>
|
||||||
Then restart synergy on the server.
|
Then restart synergy on the server or reload the configuration.
|
||||||
</p>
|
</p>
|
||||||
|
|
||||||
<li><a name="faq8"></a><span class="fakelink">Can synergy share the display in addition to the mouse and keyboard?</span>
|
<li><a name="faq8"></a><span class="fakelink">Can synergy share the display in addition to the mouse and keyboard?</span>
|
||||||
|
|
|
@ -599,6 +599,9 @@ CConfig::getOptionName(OptionID id)
|
||||||
if (id == kOptionHalfDuplexNumLock) {
|
if (id == kOptionHalfDuplexNumLock) {
|
||||||
return "halfDuplexNumLock";
|
return "halfDuplexNumLock";
|
||||||
}
|
}
|
||||||
|
if (id == kOptionHalfDuplexScrollLock) {
|
||||||
|
return "halfDuplexScrollLock";
|
||||||
|
}
|
||||||
if (id == kOptionModifierMapForShift) {
|
if (id == kOptionModifierMapForShift) {
|
||||||
return "shift";
|
return "shift";
|
||||||
}
|
}
|
||||||
|
@ -640,6 +643,7 @@ CConfig::getOptionValue(OptionID id, OptionValue value)
|
||||||
{
|
{
|
||||||
if (id == kOptionHalfDuplexCapsLock ||
|
if (id == kOptionHalfDuplexCapsLock ||
|
||||||
id == kOptionHalfDuplexNumLock ||
|
id == kOptionHalfDuplexNumLock ||
|
||||||
|
id == kOptionHalfDuplexScrollLock ||
|
||||||
id == kOptionScreenSaverSync ||
|
id == kOptionScreenSaverSync ||
|
||||||
id == kOptionXTestXineramaUnaware ||
|
id == kOptionXTestXineramaUnaware ||
|
||||||
id == kOptionRelativeMouseMoves) {
|
id == kOptionRelativeMouseMoves) {
|
||||||
|
@ -850,6 +854,10 @@ CConfig::readSectionScreens(std::istream& s)
|
||||||
addOption(screen, kOptionHalfDuplexNumLock,
|
addOption(screen, kOptionHalfDuplexNumLock,
|
||||||
parseBoolean(value));
|
parseBoolean(value));
|
||||||
}
|
}
|
||||||
|
else if (name == "halfDuplexScrollLock") {
|
||||||
|
addOption(screen, kOptionHalfDuplexScrollLock,
|
||||||
|
parseBoolean(value));
|
||||||
|
}
|
||||||
else if (name == "shift") {
|
else if (name == "shift") {
|
||||||
addOption(screen, kOptionModifierMapForShift,
|
addOption(screen, kOptionModifierMapForShift,
|
||||||
parseModifierKey(value));
|
parseModifierKey(value));
|
||||||
|
|
|
@ -285,6 +285,16 @@ CScreen::setOptions(const COptionsList& options)
|
||||||
m_screen->setHalfDuplexMask(m_halfDuplex);
|
m_screen->setHalfDuplexMask(m_halfDuplex);
|
||||||
LOG((CLOG_DEBUG1 "half-duplex num-lock %s", ((m_halfDuplex & KeyModifierNumLock) != 0) ? "on" : "off"));
|
LOG((CLOG_DEBUG1 "half-duplex num-lock %s", ((m_halfDuplex & KeyModifierNumLock) != 0) ? "on" : "off"));
|
||||||
}
|
}
|
||||||
|
else if (options[i] == kOptionHalfDuplexScrollLock) {
|
||||||
|
if (options[i + 1] != 0) {
|
||||||
|
m_halfDuplex |= KeyModifierScrollLock;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
m_halfDuplex &= ~KeyModifierScrollLock;
|
||||||
|
}
|
||||||
|
m_screen->setHalfDuplexMask(m_halfDuplex);
|
||||||
|
LOG((CLOG_DEBUG1 "half-duplex scroll-lock %s", ((m_halfDuplex & KeyModifierScrollLock) != 0) ? "on" : "off"));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// update screen saver synchronization
|
// update screen saver synchronization
|
||||||
|
|
Loading…
Reference in New Issue