diff options
author | Pierre Ossman <ossman@cendio.se> | 2016-03-29 14:15:38 +0200 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2016-03-29 14:15:38 +0200 |
commit | f862c2e8f4a783b74b3b813c95101e4e4427893b (patch) | |
tree | d6daeddeb1892dfa5a08b7959c7f31bef6cd77e8 /vncviewer/OptionsDialog.cxx | |
parent | a37314575a85ed0a265fd3cf171d2ebc5613e3b9 (diff) | |
download | tigervnc-f862c2e8f4a783b74b3b813c95101e4e4427893b.tar.gz tigervnc-f862c2e8f4a783b74b3b813c95101e4e4427893b.zip |
Add option to set primary selection for cut text
Previously the incoming clipboard was unconditionally set to both
the PRIMARY and CLIPBOARD selection. This isn't always what the
user want, so make it configurable.
Diffstat (limited to 'vncviewer/OptionsDialog.cxx')
-rw-r--r-- | vncviewer/OptionsDialog.cxx | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/vncviewer/OptionsDialog.cxx b/vncviewer/OptionsDialog.cxx index f112a529..55a366f1 100644 --- a/vncviewer/OptionsDialog.cxx +++ b/vncviewer/OptionsDialog.cxx @@ -263,6 +263,9 @@ void OptionsDialog::loadOptions(void) viewOnlyCheckbox->value(viewOnly); acceptClipboardCheckbox->value(acceptClipboard); +#if !defined(WIN32) && !defined(__APPLE__) + setPrimaryCheckbox->value(setPrimary); +#endif sendClipboardCheckbox->value(sendClipboard); #if !defined(WIN32) && !defined(__APPLE__) sendPrimaryCheckbox->value(sendPrimary); @@ -373,6 +376,9 @@ void OptionsDialog::storeOptions(void) /* Input */ viewOnly.setParam(viewOnlyCheckbox->value()); acceptClipboard.setParam(acceptClipboardCheckbox->value()); +#if !defined(WIN32) && !defined(__APPLE__) + setPrimary.setParam(setPrimaryCheckbox->value()); +#endif sendClipboard.setParam(sendClipboardCheckbox->value()); #if !defined(WIN32) && !defined(__APPLE__) sendPrimary.setParam(sendPrimaryCheckbox->value()); @@ -696,6 +702,14 @@ void OptionsDialog::createInputPage(int tx, int ty, int tw, int th) _("Accept clipboard from server"))); ty += CHECK_HEIGHT + TIGHT_MARGIN; +#if !defined(WIN32) && !defined(__APPLE__) + setPrimaryCheckbox = new Fl_Check_Button(LBLRIGHT(tx + INDENT, ty, + CHECK_MIN_WIDTH, + CHECK_HEIGHT, + _("Also set primary selection"))); + ty += CHECK_HEIGHT + TIGHT_MARGIN; +#endif + sendClipboardCheckbox = new Fl_Check_Button(LBLRIGHT(tx, ty, CHECK_MIN_WIDTH, CHECK_HEIGHT, |