aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/programs/Xserver/hw/nxagent/Args.c
diff options
context:
space:
mode:
authorMike Gabriel <mike.gabriel@das-netzwerkteam.de>2015-10-07 20:51:12 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2015-12-30 00:05:53 +0100
commit0297567cd501b6fc012c41ff4a1ae27304ff6a10 (patch)
tree5beb83ca372493fa7cde5d0b7b581c27a53726eb /nx-X11/programs/Xserver/hw/nxagent/Args.c
parentf40792c436c2e0678f46478002830367b683f20c (diff)
downloadnx-libs-0297567cd501b6fc012c41ff4a1ae27304ff6a10.tar.gz
nx-libs-0297567cd501b6fc012c41ff4a1ae27304ff6a10.tar.bz2
nx-libs-0297567cd501b6fc012c41ff4a1ae27304ff6a10.zip
Provide support for re-enabling Xinerama on session resumptions.
By design, when resuming a session, Xinerama can only be re-enabled by NX option parsing. Thus, this change introduces a "xinerama" NX option that can be loaded via an options file into NX agent when resuming a session. The new xinerame NX session option also allows switching on Xinerama at session startup via an option file. When implementing the new NX Xinerama support into clients (like TheQVD, X2Go Client, etc., this new xinerama NX option should be used for activating Xinerama in the NX / QVD / X2Go session.
Diffstat (limited to 'nx-X11/programs/Xserver/hw/nxagent/Args.c')
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Args.c31
1 files changed, 31 insertions, 0 deletions
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.c b/nx-X11/programs/Xserver/hw/nxagent/Args.c
index 5c5a1e8f8..309f08d0e 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Args.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Args.c
@@ -42,6 +42,7 @@ is" without express or implied warranty.
#include "screenint.h"
#include "input.h"
#include "misc.h"
+#include "globals.h"
#include "scrnintstr.h"
#include "dixstruct.h"
#include "servermd.h"
@@ -1202,6 +1203,36 @@ static void nxagentParseOptions(char *name, char *value)
return;
}
+ else if (!strcmp(name, "xinerama"))
+ {
+#ifdef PANORAMIX
+ if (!PanoramiXExtensionDisabledHack)
+ {
+ if (!strcmp(value, "1"))
+ {
+ nxagentChangeOption(Xinerama, 1);
+ }
+ else if (!strcmp(value, "0"))
+ {
+ nxagentChangeOption(Xinerama, 0);
+ }
+ else
+ {
+ fprintf(stderr, "Warning: Ignoring bad value '%s' for option 'xinerama'.\n",
+ validateString(value));
+ }
+ }
+ else
+ {
+ nxagentChangeOption(Xinerama, 0);
+ fprintf(stderr, "Warning: Xinerama extension has been disabled via -disablexineramaextension cmdline switch.\n");
+ }
+#else
+ nxagentChangeOption(Xinerama, 0);
+ fprintf(stderr, "Warning: No Xinerama support compiled into nxagent.\n")
+#endif /* of PANORAMIX */
+ return;
+ }
else if (!strcmp(name, "resize"))
{
if (nxagentOption(DesktopResize) == 0 || strcmp(value, "0") == 0)