From 9e3371021541dbb7d8428b419c2e77156b166f1a Mon Sep 17 00:00:00 2001 From: Reinhard Tartler Date: Mon, 10 Oct 2011 17:58:30 +0200 Subject: Imported nxagent-3.1.0-2.tar.gz Summary: Imported nxagent-3.1.0-2.tar.gz Keywords: Imported nxagent-3.1.0-2.tar.gz into Git repository --- nx-X11/programs/Xserver/hw/nxagent/Render.h | 108 ++++++++++++++++++++++++++++ 1 file changed, 108 insertions(+) create mode 100644 nx-X11/programs/Xserver/hw/nxagent/Render.h (limited to 'nx-X11/programs/Xserver/hw/nxagent/Render.h') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.h b/nx-X11/programs/Xserver/hw/nxagent/Render.h new file mode 100644 index 000000000..240dc3901 --- /dev/null +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.h @@ -0,0 +1,108 @@ +/**************************************************************************/ +/* */ +/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* */ +/* NXAGENT, NX protocol compression and NX extensions to this software */ +/* are copyright of NoMachine. Redistribution and use of the present */ +/* software is allowed according to terms specified in the file LICENSE */ +/* which comes in the source distribution. */ +/* */ +/* Check http://www.nomachine.com/licensing.html for applicability. */ +/* */ +/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* */ +/* All rights reserved. */ +/* */ +/**************************************************************************/ + +#ifndef __Render_H__ +#define __Render_H__ + +#include "screenint.h" +#include "picture.h" +#include "renderproto.h" + +#include "NXglyphstr.h" + +#include "Agent.h" + +extern int nxagentRenderEnable; +extern int nxagentRenderVersionMajor; +extern int nxagentRenderVersionMinor; + +extern int nxagentPicturePrivateIndex; + +extern BoxPtr nxagentGlyphsExtents; +extern BoxPtr nxagentTrapezoidExtents; + +/* + * Structure imported from Xrender.h. We don't + * include Xrender.h at this point because of + * clashes of definition. + */ + +/* + * Xlib Pixmap and Atom types are 8 bytes long + * on 64-bit archs, whilst they are 4 bytes long + * on 32-bit ones. At this point, Pixmap and Atom + * are not Xlib types but Xserver ones: here they + * are always 4 bytes long. So that we use XlibID + * symbols defined below to fill the structure with + * fields having the right size. + */ + +typedef struct { + int repeat; + Picture alpha_map; + int alpha_x_origin; + int alpha_y_origin; + int clip_x_origin; + int clip_y_origin; + XlibPixmap clip_mask; + Bool graphics_exposures; + int subwindow_mode; + int poly_edge; + int poly_mode; + XlibAtom dither; + Bool component_alpha; +} XRenderPictureAttributes_; + +typedef struct +{ + Picture picture; + + XRenderPictureAttributes_ lastServerValues; + +} nxagentPrivPictureRec; + +typedef nxagentPrivPictureRec *nxagentPrivPicturePtr; + +#define nxagentPicturePriv(pPicture) \ + ((nxagentPrivPicturePtr) ((pPicture) -> devPrivates[nxagentPicturePrivateIndex].ptr)) + +#define nxagentPicture(pPicture) (nxagentPicturePriv(pPicture) -> picture) + +#define nxagentSetPictureRemoteValue(pPicture, pvalue, value) \ +do \ +{ \ + nxagentPicturePriv(pPicture) -> lastServerValues.pvalue = value; \ +} \ +while (0) + +#define nxagentCheckPictureRemoteValue(pPicture, pvalue, value) \ + (nxagentPicturePriv(pPicture) -> lastServerValues.pvalue == value) + +void nxagentRenderExtensionInit(void); +Bool nxagentPictureInit(ScreenPtr, PictFormatPtr, int); + +int nxagentRenderRealizeCursor(ScreenPtr pScreen, CursorPtr pCursor); + +void nxagentAddGlyphs(GlyphSetPtr glyphSet, Glyph *gids, xGlyphInfo *gi, + int nglyphs, CARD8 *images, int sizeImages); + +void nxagentReconnectPicture(pointer p0, XID x1, void *p2); +void nxagentDisconnectPicture(pointer p0, XID x1, void* p2); + +void nxagentReconnectGlyphSet(void* p0, XID x1, void *p2); + +#endif /* __Render_H__ */ -- cgit v1.2.3 From e9132da09462b3d2607a97e2f580cbd3144819eb Mon Sep 17 00:00:00 2001 From: Reinhard Tartler Date: Mon, 10 Oct 2011 17:58:57 +0200 Subject: Imported nxagent-3.4.0-11.tar.gz Summary: Imported nxagent-3.4.0-11.tar.gz Keywords: Imported nxagent-3.4.0-11.tar.gz into Git repository --- nx-X11/programs/Xserver/hw/nxagent/Agent.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Args.c | 8 +- nx-X11/programs/Xserver/hw/nxagent/Args.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Atoms.c | 32 +- nx-X11/programs/Xserver/hw/nxagent/Atoms.h | 6 +- nx-X11/programs/Xserver/hw/nxagent/Binder.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Binder.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/CHANGELOG | 200 +++++ nx-X11/programs/Xserver/hw/nxagent/Client.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Client.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Clipboard.c | 28 +- nx-X11/programs/Xserver/hw/nxagent/Clipboard.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Colormap.c | 21 +- nx-X11/programs/Xserver/hw/nxagent/Colormap.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Composite.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Composite.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Cursor.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Cursor.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Dialog.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Dialog.h | 6 +- nx-X11/programs/Xserver/hw/nxagent/Display.c | 40 +- nx-X11/programs/Xserver/hw/nxagent/Display.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Drawable.c | 98 ++- nx-X11/programs/Xserver/hw/nxagent/Drawable.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Error.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Error.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Events.c | 924 ++++++++++++++++++--- nx-X11/programs/Xserver/hw/nxagent/Events.h | 9 +- nx-X11/programs/Xserver/hw/nxagent/Extensions.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Extensions.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Font.c | 18 +- nx-X11/programs/Xserver/hw/nxagent/Font.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/GC.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/GCOps.c | 91 +- nx-X11/programs/Xserver/hw/nxagent/GCOps.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/GCs.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Handlers.c | 30 +- nx-X11/programs/Xserver/hw/nxagent/Handlers.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Holder.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Holder.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Icons.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Image.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Image.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Imakefile | 3 +- nx-X11/programs/Xserver/hw/nxagent/Init.c | 8 +- nx-X11/programs/Xserver/hw/nxagent/Init.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Keyboard.c | 5 +- nx-X11/programs/Xserver/hw/nxagent/Keyboard.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Keystroke.c | 121 ++- nx-X11/programs/Xserver/hw/nxagent/Keystroke.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/LICENSE | 2 +- nx-X11/programs/Xserver/hw/nxagent/Literals.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Millis.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Millis.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c | 4 +- .../Xserver/hw/nxagent/NXdispatch.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c | 4 +- .../Xserver/hw/nxagent/NXdixfonts.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXevents.c | 4 +- .../Xserver/hw/nxagent/NXevents.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXextension.c | 4 +- .../Xserver/hw/nxagent/NXextension.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXglyph.c | 4 +- .../Xserver/hw/nxagent/NXglyph.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c | 4 +- .../Xserver/hw/nxagent/NXglyphcurs.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h | 4 +- .../Xserver/hw/nxagent/NXglyphstr.h.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c | 4 +- .../Xserver/hw/nxagent/NXmiglyph.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXpicture.c | 4 +- .../Xserver/hw/nxagent/NXpicture.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h | 4 +- .../Xserver/hw/nxagent/NXpicturestr.h.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXproperty.c | 4 +- .../Xserver/hw/nxagent/NXproperty.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXrandr.c | 4 +- .../Xserver/hw/nxagent/NXrandr.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXrender.c | 4 +- .../Xserver/hw/nxagent/NXrender.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXwindow.c | 4 +- .../Xserver/hw/nxagent/NXwindow.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Options.c | 15 +- nx-X11/programs/Xserver/hw/nxagent/Options.h | 9 +- nx-X11/programs/Xserver/hw/nxagent/Pixels.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Pixels.h | 22 +- nx-X11/programs/Xserver/hw/nxagent/Pixmap.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Pointer.c | 38 +- nx-X11/programs/Xserver/hw/nxagent/Pointer.h | 13 +- nx-X11/programs/Xserver/hw/nxagent/Reconnect.c | 16 +- nx-X11/programs/Xserver/hw/nxagent/Reconnect.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Render.c | 285 ++++++- nx-X11/programs/Xserver/hw/nxagent/Render.h | 6 +- nx-X11/programs/Xserver/hw/nxagent/Rootless.c | 111 ++- nx-X11/programs/Xserver/hw/nxagent/Rootless.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Screen.c | 424 +++------- nx-X11/programs/Xserver/hw/nxagent/Screen.h | 15 +- nx-X11/programs/Xserver/hw/nxagent/Splash.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Splash.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Split.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Split.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/TestExt.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Trap.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Trap.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Utils.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Visual.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Visual.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Window.c | 313 +++---- nx-X11/programs/Xserver/hw/nxagent/Windows.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c | 4 +- .../Xserver/hw/nxagent/X/NXdamage.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c | 26 +- .../Xserver/hw/nxagent/X/NXdispatch.c.NX.original | 26 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c | 4 +- .../Xserver/hw/nxagent/X/NXdixfonts.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c | 110 ++- .../Xserver/hw/nxagent/X/NXevents.c.NX.original | 110 ++- nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c | 4 +- .../Xserver/hw/nxagent/X/NXextension.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c | 4 +- .../Xserver/hw/nxagent/X/NXglxext.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c | 4 +- .../Xserver/hw/nxagent/X/NXglyph.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c | 4 +- .../Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h | 4 +- .../Xserver/hw/nxagent/X/NXglyphstr.h.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c | 4 +- .../Xserver/hw/nxagent/X/NXmiexpose.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c | 4 +- .../Xserver/hw/nxagent/X/NXmiglyph.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c | 4 +- .../Xserver/hw/nxagent/X/NXmitrap.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c | 4 +- .../Xserver/hw/nxagent/X/NXmiwindow.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c | 51 +- .../Xserver/hw/nxagent/X/NXpicture.c.NX.original | 51 +- .../programs/Xserver/hw/nxagent/X/NXpicturestr.h | 4 +- .../hw/nxagent/X/NXpicturestr.h.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c | 4 +- .../Xserver/hw/nxagent/X/NXproperty.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c | 4 +- .../Xserver/hw/nxagent/X/NXrandr.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c | 62 +- .../Xserver/hw/nxagent/X/NXrender.c.NX.original | 62 +- nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c | 4 +- .../Xserver/hw/nxagent/X/NXresource.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c | 4 +- .../Xserver/hw/nxagent/X/NXshm.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c | 4 +- .../Xserver/hw/nxagent/X/NXwindow.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c | 4 +- .../Xserver/hw/nxagent/X/NXxvdisp.c.NX.original | 4 +- nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm | 4 +- nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm | 4 +- nx-X11/programs/Xserver/hw/nxagent/os2Stub.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/screensaver | 4 +- 161 files changed, 2837 insertions(+), 1066 deletions(-) (limited to 'nx-X11/programs/Xserver/hw/nxagent/Render.h') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Agent.h b/nx-X11/programs/Xserver/hw/nxagent/Agent.h index f976fd768..3f2c93fdb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Agent.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Agent.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.c b/nx-X11/programs/Xserver/hw/nxagent/Args.c index 5d344729c..c2e58bd58 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Args.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Args.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -1208,7 +1208,7 @@ static void nxagentParseOptions(char *name, char *value) { nxagentChangeOption(ClientOs, ClientOsSolaris); } - else if (strcmp(value, "mac") == 0) + else if (strcmp(value, "macosx") == 0) { nxagentChangeOption(ClientOs, ClientOsMac); } @@ -1512,7 +1512,7 @@ N/A int splitMode = 0; int splitSize = 0; - unsigned int packMethod = PACK_NONE; + unsigned int packMethod = PACK_NONE; unsigned int packQuality = 9; int dataLevel = 0; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.h b/nx-X11/programs/Xserver/hw/nxagent/Args.h index 43d7ec779..92650a4a0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Args.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Args.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c index ac26646ae..171df95a9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -66,19 +66,21 @@ Atom nxagentAtoms[NXAGENT_NUMBER_OF_ATOMS]; static char *nxagentAtomNames[NXAGENT_NUMBER_OF_ATOMS + 1] = { - "NX_IDENTITY", /* 0 */ - "WM_PROTOCOLS", /* 1 */ - "WM_DELETE_WINDOW", /* 2 */ - "WM_NX_READY", /* 3 */ - "MCOPGLOBALS", /* 4 */ - "NX_CUT_BUFFER_SERVER", /* 5 */ - "TARGETS", /* 6 */ - "TEXT", /* 7 */ - "NX_AGENT_SIGNATURE", /* 8 */ - "NXDARWIN", /* 9 */ - "CLIPBOARD", /* 10 */ - "TIMESTAMP", /* 11 */ - "UTF8_STRING", /* 12 */ + "NX_IDENTITY", /* 0 */ + "WM_PROTOCOLS", /* 1 */ + "WM_DELETE_WINDOW", /* 2 */ + "WM_NX_READY", /* 3 */ + "MCOPGLOBALS", /* 4 */ + "NX_CUT_BUFFER_SERVER", /* 5 */ + "TARGETS", /* 6 */ + "TEXT", /* 7 */ + "NX_AGENT_SIGNATURE", /* 8 */ + "NXDARWIN", /* 9 */ + "CLIPBOARD", /* 10 */ + "TIMESTAMP", /* 11 */ + "UTF8_STRING", /* 12 */ + "_NET_WM_STATE", /* 13 */ + "_NET_WM_STATE_FULLSCREEN", /* 14 */ NULL, NULL }; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h index 17b2d8f57..f49f2751e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -22,7 +22,7 @@ #include "../../include/window.h" #include "screenint.h" -#define NXAGENT_NUMBER_OF_ATOMS 14 +#define NXAGENT_NUMBER_OF_ATOMS 16 extern Atom nxagentAtoms[NXAGENT_NUMBER_OF_ATOMS]; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.c b/nx-X11/programs/Xserver/hw/nxagent/Binder.c index cfea2cc77..34433bd2b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Binder.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.h b/nx-X11/programs/Xserver/hw/nxagent/Binder.h index 928db74fb..e0da3e357 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Binder.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG index 1f7f0df55..3f0a6abcd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG +++ b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG @@ -1,5 +1,205 @@ ChangeLog: +nxagent-3.4.0-11 + +- Corrected switching between viewport mode and resize mode. + +- Fixed TR04H02340. Keycode is correctly translated in shadow sessions + also if the remote X display is using evdev. + +nxagent-3.4.0-10 + +- Handled XGrabKeyboard() return value. + +- Fixed TR10D01512. NumLock and CapsLock keys are now synchronized + between local and remote. + +nxagent-3.4.0-9 + +- Fixed TR06H02362. No icon was swown in the task bar. + +- Fixed keyboard grab in fullscreen mode. + +- Fixed compiler warnings. + +nxagent-3.4.0-8 + +- Grab the keyboard in fullscreen mode on EnterNotify only if mode is + 'NotifyNormal'. + +- Yield control in the dispatch loop in case we stop the smart sche- + duler timer while waiting for a reply from the remote display. + +nxagent-3.4.0-7 + +- Fixed TR08D01478. The communication with the compiz window manager + by means of the _NET_WM_PING property was not handled properly. + +- Fixed a type mismatch in XKB events on 64 bit platforms. + +- Moved grab/ungrab keyboard from focus in/out event to enter/leave + notify event. + +- Removed nxagentIconWindow because it's not longer used. + +nxagent-3.4.0-6 + +- Fixed TR09F02102. Problem was with pointer buttons map. + +- Fixed TR02H02327. Some KeyRelease events was discarded. + +- Fixed up Num and Caps locks. + +- Fixed TR03H02335. Emulated right mouse button for Mac clients. + +- Added utilities to print info about internal and remote windows. + +- Fixed TR01F01995. Solved a picture resource leak by destroying remo- + te pictures only when their reference counter returns to zero. + +- Fixed TR04H02337. Errors occurred because pictures with no drawable + were handled badly. + +- Implemented handling nxagent's private for gradient pictures and so- + lid fill picture. + +- Fixed BadMatch condition check in function ProcRenderComposite. + +- Fixed nxagentComposite() to handle situations with source picture + drawable pointing to NULL. + +- Implemented render acceleration for requests: CreateSolidFill, + CreateLinearGradient, CreateRadialGradient, CreateConicalGradient. + +- Fixed TR03G02196. Dialogs are shown to the fore when the NX session + is in fullscreen mode. + +- Changed mechanism to switch to fullscreen mode. Now the override + redirect attribute is no longer used and _NET_WM_STATE_FULLSCREEN + hint is sent to the WM. + +nxagent-3.4.0-5 + +- Updated copyright to year 2010. + +nxagent-3.4.0-4 + +- Fixed TR07F02090. Now XDMCP sessions start without problems. + +- Fixed TR08G02259. Corrected window border granularity of rootless + session at reconnection on 64 bit platforms. + +- Fixed TR11G02290. Forcing null timeout with queued events only if + display connection is up. This prevents the flood of session log. + +- Fixed TR10G02287. Now QueryTree's loop is aborted in case of failure + and session log isn't filled anymore with repeated warning messages. + +- Fixed TR01G02154. Corrected window placement when switching between + fullscreen and windowed mode. + +- Fixed TR09G02276. Now the agent does not receive unwanted characters + while interacting with the local window manager. + +- Implemented FR02G02174. Added ability to do large screen pans in + viewport mode through key combination Ctrl+Alt+Shift+Arrow. + +- Corrected parsing of the 'client' option when the client OS is Mac. + +nxagent-3.4.0-3 + +- Fixed TR09G02271. The array containing the font name fields was not + correctly initialized for non-standard font names. + +nxagent-3.4.0-2 + +- Updated copyright to year 2009. + +nxagent-3.4.0-1 + +- Opened the 3.4.0 branch based on nxagent-3.3.0-19. + +- Changed the printed version number. + +nxagent-3.3.0-19 + +- Fixed TR09G02266. A proper error message is printed in the session + log if the shadowing initialization fails because of a mismatch in + the visual class. + +- Added a workaround for X servers that doesn't return 1 among the + available depths. + +nxagent-3.3.0-18 + +- The area to restore from the backing store is limited by the screen + size instead of the visible screen. + +nxagent-3.3.0-17 + +- Fixed TR12F02150. The agent could crash when copying text from VNC + viewer. Fixed by aborting the procedure in case the retrieved pro- + perty has not a valid format. + +nxagent-3.3.0-16 + +- Fixed TR07G02247. Don't try to call XSetWindowColormap() if the + window has no colormap, e.g. if its class is InputOnly. + +nxagent-3.3.0-15 + +- Fixed TR04G02210. Region is cut to the visible screen before re- + storing areas from the backing store. + +- Fixed TR07G02246. Box is shrinked if bounds can't stay in a short + signed integer. + +nxagent-3.3.0-14 + +- Fixed TR03G02206. waitpid() call was missing for the "Fonts replace- + ment" dialog type. + +- Fixed TR03G02195. Added a properties structure compatible with 32 + and 64 bit platform types. + +nxagent-3.3.0-13 + +- Handle the window unmap immediately. Don't add it to the configure + queue. + +nxagent-3.3.0-12 + +- Fixed TR03G02200. Timestamps could be in the future in KeyRelease + events sent to the X clients. + +- Added debug logging of input devices state Logging can be enabled + or disabled via the Ctrl+Alt+x shortcut. State info is dumped every + 5 seconds. + +- Added Ctrl+Alt+y shortcut used to deactivate input devices grab for + debug purposes. + +nxagent-3.3.0-11 + +- Changed the message logging the screen size changes, in order to + show the fullscreen state. + +- Handle the window unmapping in the nxagentConfigureWindow queue. + +nxagent-3.3.0-10 + +- Fixed TR12F02146. Compare the drawable and the bitmap data before + realizing the image update, in order to delay the data clean up that + caused the memcmp() failure. + +- Fixed TR01G02156. Reduce the exposing area by subtracting the ex- + posed region. + +- Fixed a compile warning in Drawable.c. + +- Added detailed logs in the nxagentSynchronizeRegion() function if + the data memory allocation fails. + nxagent-3.3.0-9 - Added /usr/NX/share/base to alternate font paths. This would fix diff --git a/nx-X11/programs/Xserver/hw/nxagent/Client.c b/nx-X11/programs/Xserver/hw/nxagent/Client.c index 7e86a03d2..acfaab7c0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Client.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Client.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Client.h b/nx-X11/programs/Xserver/hw/nxagent/Client.h index 5f9fa1ebb..45f87fc66 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Client.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Client.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c index a575cabe5..eb830234d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -680,6 +680,30 @@ void nxagentCollectPropertyEvent(int resource) return; } + + if (resultFormat != 8 && resultFormat != 16 && resultFormat != 32) + { + + #ifdef DEBUG + fprintf (stderr, "nxagentCollectPropertyEvent: WARNING! Invalid property " + "value.\n"); + #endif + + if (lastClientClientPtr != NULL) + { + nxagentSendSelectionNotify(None); + } + + lastClientWindowPtr = NULL; + lastClientStage = SelectionStageNone; + + if (pszReturnData != NULL) + { + XFree(pszReturnData); + } + + return; + } switch (lastClientStage) { diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h index 912260b8b..2750ddfd2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c index 75758679f..259aa3b24 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -291,9 +291,20 @@ void nxagentSetInstalledColormapWindows(ScreenPtr pScreen) pCmap = (ColormapPtr)LookupIDByType(pScreen->defColormap, RT_COLORMAP); - XSetWindowColormap(nxagentDisplay, - nxagentDefaultWindows[pScreen->myNum], - nxagentColormap(pCmap)); + if (pCmap != NULL) + { + XSetWindowColormap(nxagentDisplay, + nxagentDefaultWindows[pScreen->myNum], + nxagentColormap(pCmap)); + } + #ifdef WARNING + else + { + fprintf(stderr, "nxagentSetInstalledColormapWindows: WARNING! " + "Window at [%p] has no colormap with class [%d].\n", + pWin, pWin -> drawable.class); + } + #endif } #endif /* DUMB_WINDOW_MANAGERS */ } diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.h b/nx-X11/programs/Xserver/hw/nxagent/Colormap.h index b0cb2dc5e..8321e8038 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Composite.c b/nx-X11/programs/Xserver/hw/nxagent/Composite.c index 9bdbac1b1..b0640ff11 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Composite.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Composite.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Composite.h b/nx-X11/programs/Xserver/hw/nxagent/Composite.h index 5ec1e9888..fb1d6d8e9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Composite.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Composite.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Cursor.c b/nx-X11/programs/Xserver/hw/nxagent/Cursor.c index 3ca29fa5e..141ba3a64 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Cursor.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Cursor.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Cursor.h b/nx-X11/programs/Xserver/hw/nxagent/Cursor.h index ea1bb30f3..11e407efd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Cursor.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Cursor.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Dialog.c b/nx-X11/programs/Xserver/hw/nxagent/Dialog.c index c1db78344..2f807b1dc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Dialog.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Dialog.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Dialog.h b/nx-X11/programs/Xserver/hw/nxagent/Dialog.h index 135cd2df3..aa845c7c2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Dialog.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Dialog.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -42,7 +42,7 @@ extern int nxagentKillDialogPid; extern int nxagentSuspendDialogPid; extern int nxagentRootlessDialogPid; extern int nxagentPulldownDialogPid; -extern int nxagentFontsReplacement; +extern int nxagentFontsReplacementDialogPid; extern int nxagentEnableRandRModeDialogPid; extern int nxagentDisableRandRModeDialogPid; extern int nxagentEnableDeferModePid; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.c b/nx-X11/programs/Xserver/hw/nxagent/Display.c index 9f257e508..1a57788e6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -453,6 +453,21 @@ static void nxagentSigchldHandler(int signal) } } + if (pid == 0 && nxagentFontsReplacementDialogPid) + { + pid = waitpid(nxagentFontsReplacementDialogPid, &status, options); + + if (pid == -1 && errno == ECHILD) + { + #ifdef WARNING + fprintf(stderr, "nxagentSigchldHandler: Got ECHILD waiting for child %d (Fonts replacement).\n", + nxagentFontsReplacementDialogPid); + #endif + + pid = nxagentFontsReplacementDialogPid = 0; + } + } + if (pid == 0 && nxagentEnableRandRModeDialogPid) { pid = waitpid(nxagentEnableRandRModeDialogPid, &status, options); @@ -1609,19 +1624,30 @@ void nxagentInitPixmapFormats() nxagentNumPixmapFormats = 0; - nxagentPixmapFormats = xalloc(nxagentNumDepths * sizeof(XPixmapFormatValues)); +/* +XXX: Some X server doesn't list 1 among available depths... +*/ + + nxagentPixmapFormats = xalloc((nxagentNumDepths + 1) * sizeof(XPixmapFormatValues)); for (i = 1; i <= MAXDEPTH; i++) { depth = 0; - for (j = 0; j < nxagentNumDepths; j++) + if (i == 1) + { + depth = 1; + } + else { - if (nxagentDepths[j] == i) + for (j = 0; j < nxagentNumDepths; j++) { - depth = i; + if (nxagentDepths[j] == i) + { + depth = i; - break; + break; + } } } diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.h b/nx-X11/programs/Xserver/hw/nxagent/Display.h index d18785b60..35b7857ad 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Drawable.c b/nx-X11/programs/Xserver/hw/nxagent/Drawable.c index 2c1b07fa5..75057097a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Drawable.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Drawable.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -32,6 +32,7 @@ #include "Handlers.h" #include "Pixels.h" #include "Reconnect.h" +#include "GCOps.h" #include "NXlib.h" @@ -418,13 +419,14 @@ int nxagentSynchronizeRegion(DrawablePtr pDrawable, RegionPtr pRegion, unsigned if (useStoredBitmap != 0) { #ifdef TEST - fprintf(stderr, "nxagentSynchronizeRegion: Drawable [%s] at [%p] has a synchronization bitmap " + fprintf(stderr, "nxagentSynchronizeRegion: Drawable [%s] at [%p] has a synchronization bitmap at [%p] " "[%d,%d,%d,%d] with [%ld] rects.\n", nxagentDrawableType(pDrawable), - (void *) pDrawable, nxagentCorruptedRegion((DrawablePtr) nxagentDrawableBitmap(pDrawable)) -> extents.x1, - nxagentCorruptedRegion((DrawablePtr) nxagentDrawableBitmap(pDrawable)) -> extents.y1, - nxagentCorruptedRegion((DrawablePtr) nxagentDrawableBitmap(pDrawable)) -> extents.x2, - nxagentCorruptedRegion((DrawablePtr) nxagentDrawableBitmap(pDrawable)) -> extents.y2, - REGION_NUM_RECTS(nxagentCorruptedRegion((DrawablePtr) nxagentDrawableBitmap(pDrawable)))); + (void *) pDrawable, (void *) nxagentDrawableBitmap(pDrawable), + nxagentCorruptedRegion((DrawablePtr) nxagentDrawableBitmap(pDrawable)) -> extents.x1, + nxagentCorruptedRegion((DrawablePtr) nxagentDrawableBitmap(pDrawable)) -> extents.y1, + nxagentCorruptedRegion((DrawablePtr) nxagentDrawableBitmap(pDrawable)) -> extents.x2, + nxagentCorruptedRegion((DrawablePtr) nxagentDrawableBitmap(pDrawable)) -> extents.y2, + REGION_NUM_RECTS(nxagentCorruptedRegion((DrawablePtr) nxagentDrawableBitmap(pDrawable)))); #endif clipRegion = nxagentCreateRegion(pDrawable, NULL, 0, 0, pDrawable -> width, pDrawable -> height); @@ -581,8 +583,7 @@ int nxagentSynchronizeRegion(DrawablePtr pDrawable, RegionPtr pRegion, unsigned #ifdef TEST fprintf(stderr, "nxagentSynchronizeRegion: Going to synchronize [%ld] rects of [%s] at [%p].\n", - REGION_NUM_RECTS(clipRegion), (pDrawable -> type == DRAWABLE_PIXMAP ? "Pixmap" : "Window"), - (void *) pDrawable); + REGION_NUM_RECTS(clipRegion), nxagentDrawableType(pDrawable), (void *) pDrawable); fprintf(stderr, "nxagentSynchronizeRegion: Extents geometry [%d,%d,%d,%d].\n", clipRegion -> extents.x1, clipRegion -> extents.y1, clipRegion -> extents.x2, clipRegion -> extents.y2); @@ -615,7 +616,22 @@ int nxagentSynchronizeRegion(DrawablePtr pDrawable, RegionPtr pRegion, unsigned if (data == NULL) { #ifdef WARNING + fprintf(stderr, "nxagentSynchronizeRegion: WARNING! Failed to allocate memory for synchronization.\n"); + + /* + * Print detailed informations if the + * image length is zero. + */ + + if (length == 0) + { + fprintf(stderr, "nxagentSynchronizeRegion: Drawable [%s] at [%p] with region geometry [%ld][%d,%d,%d,%d].\n", + nxagentDrawableType(pDrawable), (void *) pDrawable, REGION_NUM_RECTS(clipRegion), + clipRegion -> extents.x1, clipRegion -> extents.y1, + clipRegion -> extents.x2, clipRegion -> extents.y2); + } + #endif goto nxagentSynchronizeRegionFree; @@ -670,10 +686,14 @@ int nxagentSynchronizeRegion(DrawablePtr pDrawable, RegionPtr pRegion, unsigned if (nxagentDrawableStatus(pDrawable) == Synchronized) { #ifdef WARNING + if (pDrawable -> type == DRAWABLE_WINDOW && pSrcDrawable != pDrawable) + { fprintf(stderr, "nxagentSynchronizeRegion: WARNING! Trying to synchronize " "the clean drawable type [%d] at [%p] with source at [%p].\n", pDrawable -> type, (void *) pDrawable, (void *) pSrcDrawable); + } + #endif goto nxagentSynchronizeRegionStop; @@ -748,9 +768,6 @@ int nxagentSynchronizeRegion(DrawablePtr pDrawable, RegionPtr pRegion, unsigned nxagentGetImage(pSrcDrawable, x, y, w, h, format, AllPlanes, data); - nxagentRealizeImage(pDrawable, pGC, pDrawable -> depth, - x, y, w, h, leftPad, format, data); - /* * Going to unmark the synchronized * region. @@ -805,6 +822,13 @@ int nxagentSynchronizeRegion(DrawablePtr pDrawable, RegionPtr pRegion, unsigned nxagentUnmarkCorruptedRegion(pDrawable, &tileRegion); } + #ifdef TEST + else + { + fprintf(stderr, "nxagentSynchronizeRegion: Tile [%d,%d,%d,%d] on drawable [%p] doesn't match.\n", + x, y, x + w, y + h, (void *) pDrawable); + } + #endif } else { @@ -835,6 +859,14 @@ int nxagentSynchronizeRegion(DrawablePtr pDrawable, RegionPtr pRegion, unsigned } } + /* + * Realize the image after comparing the + * source data with the bitmap data. + */ + + nxagentRealizeImage(pDrawable, pGC, pDrawable -> depth, + x, y, w, h, leftPad, format, data); + REGION_UNINIT(pDrawable -> pScreen, &tileRegion); #if !defined(COLLECTED_UPDATES) @@ -2555,16 +2587,13 @@ void nxagentCreateDrawableBitmap(DrawablePtr pDrawable) GCPtr pGC = NULL; RegionPtr pClipRegion = NullRegion; - char *data = NULL; - int x, y; int w, h; - int length, format; int saveTrap; #ifdef TEST - fprintf(stderr, "nxagentCreateDrawableBitmap: Creating synchronization bitmap for drawable at [%p].\n", - (void *) pDrawable); + fprintf(stderr, "nxagentCreateDrawableBitmap: Creating synchronization bitmap for [%s] at [%p].\n", + nxagentDrawableType(pDrawable), (void *) pDrawable); #endif /* @@ -2652,24 +2681,8 @@ void nxagentCreateDrawableBitmap(DrawablePtr pDrawable) w = pClipRegion -> extents.x2 - pClipRegion -> extents.x1; h = pClipRegion -> extents.y2 - pClipRegion -> extents.y1; - data = nxagentAllocateImageData(w, h, pDrawable -> depth, &length, &format); - - if (data == NULL) - { - #ifdef WARNING - fprintf(stderr, "nxagentCreateDrawableBitmap: Cannot allocate memory for the bitmap data.\n"); - #endif - - nxagentDestroyPixmap(pBitmap); + nxagentCopyArea(pDrawable, (DrawablePtr) pBitmap, pGC, x, y, w, h, x, y); - goto nxagentCreateDrawableBitmapEnd; - } - - nxagentGetImage(pDrawable, x, y, w, h, format, AllPlanes, data); - - nxagentPutImage((DrawablePtr) pBitmap, pGC, pBitmap -> drawable.depth, x, y, w, h, - 0, format, data); - REGION_UNION(pDrawable -> pScreen, nxagentCorruptedRegion((DrawablePtr) pBitmap), nxagentCorruptedRegion((DrawablePtr) pBitmap), pClipRegion); @@ -2711,11 +2724,6 @@ nxagentCreateDrawableBitmapEnd: nxagentFreeRegion(pDrawable, pClipRegion); } - if (data != NULL) - { - xfree(data); - } - if (pGC != NULL) { FreeScratchGC(pGC); @@ -3091,6 +3099,16 @@ void nxagentSendBackgroundExpose(WindowPtr pWin, PixmapPtr pBackground, RegionPt REGION_INTERSECT(pWin -> pScreen, &expose, &expose, &pWin -> clipList); + /* + * Reduce the overall region to expose. + */ + + REGION_TRANSLATE(pWin -> pScreen, &expose, -pWin -> drawable.x, -pWin -> drawable.y); + + REGION_SUBTRACT(pWin -> pScreen, pExpose, pExpose, &expose); + + REGION_TRANSLATE(pWin -> pScreen, &expose, pWin -> drawable.x, pWin -> drawable.y); + miWindowExposures(pWin, &expose, &expose); nxagentSendBackgroundExposeEnd: diff --git a/nx-X11/programs/Xserver/hw/nxagent/Drawable.h b/nx-X11/programs/Xserver/hw/nxagent/Drawable.h index 62af0685d..146610efb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Drawable.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Drawable.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Error.c b/nx-X11/programs/Xserver/hw/nxagent/Error.c index e60845dd3..963cfa287 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Error.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Error.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Error.h b/nx-X11/programs/Xserver/hw/nxagent/Error.h index 78e15592b..2d6083d4e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Error.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Error.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.c b/nx-X11/programs/Xserver/hw/nxagent/Events.c index 3c1458cb7..1576962fb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -76,7 +76,9 @@ #include "input.h" #endif +#define Time XlibXID #include "XKBlib.h" +#undef Time #define GC XlibGC #define Font XlibFont @@ -203,6 +205,8 @@ CARD32 nxagentLastEventTime = 0; CARD32 nxagentLastKeyPressTime = 0; Time nxagentLastServerTime = 0; +int nxagentPointerAndKeyboardGrabbed = 0; + /* * Used for storing windows that need to * receive expose events from the agent. @@ -218,6 +222,16 @@ static void nxagentForwardRemoteExpose(void); static int nxagentClipAndSendExpose(WindowPtr pWin, pointer ptr); +/* + * This is from NXproperty.c. + */ + +int GetWindowProperty(WindowPtr pWin, Atom property, long longOffset, + long longLength, Bool delete, Atom type, + Atom *actualType, int *format, unsigned + long *nItems, unsigned long *bytesAfter, + unsigned char **propData); + /* * Associate a resource to a drawable and * store the region affected by the split @@ -274,6 +288,280 @@ void ProcessInputEvents() mieqProcessInputEvents(); } +#ifdef DEBUG_TREE + +/* + * Print ID and name of window. + */ + +void nxagentRemoteWindowID(Window window, Bool newline) +{ +#ifdef NO_I18N + char *winName; +#else + XTextProperty tp; +#endif + + fprintf(stderr, "0x%lx", window); + + if (!window) + { + fprintf(stderr, " (none) "); + } + else + { + if (window == DefaultRootWindow(nxagentDisplay)) + { + fprintf(stderr, " (the root window) "); + } + +#ifdef NO_I18N + + if (!XFetchName(nxagentDisplay, window, &winName)) + { + fprintf(stderr, " (has no name) "); + } + else if (winName) + { + fprintf(stderr, " \"%s\" ", winName); + XFree(winName); + } + +#else + + if (XGetWMName(nxagentDisplay, window, &tp) != 0) + { + fprintf(stderr, " (has no name) "); + } + else if (tp.nitems > 0) + { + int count = 0; + int i, ret; + char **list = NULL; + + fprintf(stderr, " \""); + + ret = XmbTextPropertyToTextList(nxagentDisplay, &tp, &list, &count); + + if ((ret == Success || ret > 0) && list != NULL) + { + for (i = 0; i < count; i++) + { + fprintf(stderr, "%s", list[i]); + } + + XFreeStringList(list); + } + else + { + fprintf(stderr, "%s", tp.value); + } + + fprintf(stderr, "\" "); + } + +#endif + + else + { + fprintf(stderr, " (has no name) "); + } + } + + if (newline == TRUE) + { + fprintf(stderr, "\n"); + } + + return; +} + +/* + * Print info about remote window. + */ + +void nxagentRemoteWindowInfo(Window win, int indent, Bool newLine) +{ + XWindowAttributes attributes; + int i; + + if (XGetWindowAttributes(nxagentDisplay, win, &attributes) == 0) + { + return; + } + + for (i = 0; i < indent; i++) + { + fprintf(stderr, " "); + } + + fprintf(stderr, "x=%d y=%d width=%d height=%d class=%s map_state=%s " + "override_redirect=%s\n", attributes.x, attributes.y, + attributes.width, attributes.height, (attributes.class == 0) ? + "InputOutput" : "InputOnly", (attributes.map_state == 0) ? + "IsUnmapped" : (attributes.map_state == 1 ? + "IsUnviewable" : "IsViewable"), + (attributes.override_redirect == 0) ? + "No" : "Yes" ); + + if (newLine == TRUE) + { + fprintf(stderr, "\n"); + } +} + +/* + * Walk remote windows tree. + */ + +void nxagentRemoteWindowsTree(Window window, int level) +{ + int i, j; + Window rootWin, parentWin; + unsigned int numChildren; + Window *childList; + + if (!XQueryTree(nxagentDisplay, window, &rootWin, &parentWin, &childList, + &numChildren)) + { + fprintf(stderr, "nxagentRemoteWindowsTree - XQueryTree failed.\n"); + + return; + } + + if (level == 0) + { + fprintf(stderr, "\n"); + + fprintf(stderr, " Root Window ID: "); + nxagentRemoteWindowID(rootWin, TRUE); + + fprintf(stderr, " Parent window ID: "); + nxagentRemoteWindowID(parentWin, TRUE); + } + + if (level == 0 || numChildren > 0) + { + fprintf(stderr, " "); + + for (j = 0; j < level; j++) + { + fprintf(stderr, " "); + } + + fprintf(stderr, "%d child%s%s\n", numChildren, (numChildren == 1) ? "" : + "ren", (numChildren == 1) ? ":" : "."); + } + + for (i = (int) numChildren - 1; i >= 0; i--) + { + fprintf(stderr, " "); + + for (j = 0; j < level; j++) + { + fprintf(stderr, " "); + } + + nxagentRemoteWindowID(childList[i], TRUE); + + nxagentRemoteWindowInfo(childList[i], (level * 5) + 6, TRUE); + + nxagentRemoteWindowsTree(childList[i], level + 1); + } + + if (childList) + { + XFree((char *) childList); + } +} + +/* + * Print info about internal window. + */ + +void nxagentInternalWindowInfo(WindowPtr pWin, int indent, Bool newLine) +{ + int i; + int result; + unsigned long ulReturnItems; + unsigned long ulReturnBytesLeft; + Atom atomReturnType; + int iReturnFormat; + unsigned char *pszReturnData = NULL; + + fprintf(stderr, "Window ID=[0x%lx] Remote ID=[0x%lx] ", pWin -> drawable.id, + nxagentWindow(pWin)); + + result = GetWindowProperty(pWin, MakeAtom("WM_NAME", 7, False) , 0, + sizeof(CARD32), False, AnyPropertyType, + &atomReturnType, &iReturnFormat, + &ulReturnItems, &ulReturnBytesLeft, + &pszReturnData); + + fprintf(stderr, "Name: "); + + if (result == Success && pszReturnData != NULL) + { + pszReturnData[ulReturnItems] = '\0'; + + fprintf(stderr, "\"%s\"\n", (char *) pszReturnData); + } + else + { + fprintf(stderr, "%s\n", "( has no name )"); + } + + for (i = 0; i < indent; i++) + { + fprintf(stderr, " "); + } + + fprintf(stderr, "x=%d y=%d width=%d height=%d class=%s map_state=%s " + "override_redirect=%s", pWin -> drawable.x, pWin -> drawable.y, + pWin -> drawable.width, pWin -> drawable.height, + (pWin -> drawable.class == 0) ? "InputOutput" : + "InputOnly", (pWin -> mapped == 0) ? + "IsUnmapped" : (pWin -> mapped == 1 ? + "IsUnviewable" : "IsViewable"), + (pWin -> overrideRedirect == 0) ? + "No" : "Yes"); + + if (newLine == TRUE) + { + fprintf(stderr, "\n"); + } +} + +/* + * Walk internal windows tree. + */ + +void nxagentInternalWindowsTree(WindowPtr pWin, int indent) +{ + WindowPtr pChild; + int i; + + while (pWin) + { + pChild = pWin -> firstChild; + + for (i = 0; i < indent; i++) + { + fprintf(stderr, " "); + } + + nxagentInternalWindowInfo(pWin, indent, TRUE); + + fprintf(stderr, "\n"); + + nxagentInternalWindowsTree(pChild, indent + 4); + + pWin = pWin -> nextSib; + } +} + +#endif /* DEBUG_TREE */ + void nxagentSwitchResizeMode(ScreenPtr pScreen) { XSizeHints sizeHints; @@ -290,8 +578,14 @@ void nxagentSwitchResizeMode(ScreenPtr pScreen) nxagentLaunchDialog(DIALOG_DISABLE_DESKTOP_RESIZE_MODE); - sizeHints.max_width = nxagentOption(RootWidth); - sizeHints.max_height = nxagentOption(RootHeight); + if (nxagentOption(Fullscreen) == 0) + { + sizeHints.max_width = nxagentOption(RootWidth); + sizeHints.max_height = nxagentOption(RootHeight); + + XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], + &sizeHints); + } } else { @@ -299,7 +593,8 @@ void nxagentSwitchResizeMode(ScreenPtr pScreen) nxagentLaunchDialog(DIALOG_ENABLE_DESKTOP_RESIZE_MODE); - nxagentRRSetScreenConfig(pScreen, nxagentOption(Width), nxagentOption(Height)); + nxagentRRSetScreenConfig(pScreen, nxagentOption(Width), + nxagentOption(Height)); if (nxagentOption(ClientOs) == ClientOsWinnt) { @@ -308,10 +603,10 @@ void nxagentSwitchResizeMode(ScreenPtr pScreen) sizeHints.max_width = WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); sizeHints.max_height = HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); - } - XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], - &sizeHints); + XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], + &sizeHints); + } } void nxagentShadowSwitchResizeMode(ScreenPtr pScreen) @@ -655,6 +950,22 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) { break; } + + #ifdef DEBUG_TREE + + case doDebugTree: + { + fprintf(stderr, "\n ========== nxagentRemoteWindowsTree ==========\n"); + nxagentRemoteWindowsTree(nxagentWindow(WindowTable[0]), 0); + + fprintf(stderr, "\n========== nxagentInternalWindowsTree ==========\n"); + nxagentInternalWindowsTree(WindowTable[0], 0); + + break; + } + + #endif /* DEBUG_TREE */ + case doCloseSession: { closeSession = TRUE; @@ -679,6 +990,30 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) break; } + case doViewportMoveUp: + { + nxagentMoveViewport(pScreen, 0, -nxagentOption(Height)); + + break; + } + case doViewportMoveDown: + { + nxagentMoveViewport(pScreen, 0, nxagentOption(Height)); + + break; + } + case doViewportMoveLeft: + { + nxagentMoveViewport(pScreen, -nxagentOption(Width), 0); + + break; + } + case doViewportMoveRight: + { + nxagentMoveViewport(pScreen, nxagentOption(Width), 0); + + break; + } case doViewportUp: { nxagentMoveViewport(pScreen, 0, -nextinc(viewportInc)); @@ -755,6 +1090,8 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) if (nxagentOption(ViewOnly) == 0 && nxagentOption(Shadow) == 1 && result == doNothing) { + X.xkey.keycode = nxagentConvertKeycode(X.xkey.keycode); + NXShadowEvent(nxagentDisplay, X); } @@ -763,6 +1100,27 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) case KeyRelease: { enum HandleEventResult result; + int sendKey = 0; + +/* +FIXME: If we don't flush the queue here, it could happen + that the inputInfo structure will not be up to date + when we perform the following check on down keys. +*/ + ProcessInputEvents(); + +/* +FIXME: Don't enqueue the KeyRelease event if the key was + not already pressed. This workaround avoids a fake + KeyPress is enqueued by the XKEYBOARD extension. + Another solution would be to let the events are + enqueued and to remove the KeyPress afterwards. +*/ + if (BitIsOn(inputInfo.keyboard -> key -> down, + nxagentConvertKeycode(X.xkey.keycode))) + { + sendKey = 1; + } #ifdef TEST fprintf(stderr, "nxagentDispatchEvents: Going to handle new KeyRelease event.\n"); @@ -803,7 +1161,12 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) nxagentLastEventTime = GetTimeInMillis(); - if (!(nxagentCheckSpecialKeystroke(&X.xkey, &result))) + if (x.u.keyButtonPointer.time > nxagentLastEventTime) + { + x.u.keyButtonPointer.time = nxagentLastEventTime; + } + + if (!(nxagentCheckSpecialKeystroke(&X.xkey, &result)) && sendKey == 1) { mieqEnqueue(&x); @@ -811,6 +1174,8 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) if (nxagentOption(ViewOnly) == 0 && nxagentOption(Shadow)) { + X.xkey.keycode = nxagentConvertKeycode(X.xkey.keycode); + NXShadowEvent(nxagentDisplay, X); } } @@ -828,6 +1193,23 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) nxagentInputEvent = 1; + if (nxagentOption(ClientOs) == ClientOsMac && (X.xbutton.state & ControlMask) == ControlMask) + { + x.u.u.type = ButtonPress; + x.u.u.detail = inputInfo.pointer -> button -> map[3]; + x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); + + mieqEnqueue(&x); + + x.u.u.type = ButtonRelease; + x.u.u.detail = inputInfo.pointer -> button -> map[3]; + x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); + + mieqEnqueue(&x); + + break; + } + if (nxagentOption(Fullscreen)) { if (nxagentMagicPixelZone(X.xbutton.x, X.xbutton.y)) @@ -874,7 +1256,7 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) X.xbutton.subwindow == None)) { x.u.u.type = ButtonPress; - x.u.u.detail = X.xbutton.button; + x.u.u.detail = inputInfo.pointer -> button -> map[nxagentReversePointerMap[X.xbutton.button - 1]]; x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); if (nxagentOption(Rootless)) @@ -931,6 +1313,11 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) nxagentInputEvent = 1; + if (nxagentOption(ClientOs) == ClientOsMac && (X.xbutton.state & ControlMask) == ControlMask) + { + break; + } + if (viewportCursor) { /* @@ -947,7 +1334,7 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) if (minimize != True) { x.u.u.type = ButtonRelease; - x.u.u.detail = X.xbutton.button; + x.u.u.detail = inputInfo.pointer -> button -> map[nxagentReversePointerMap[X.xbutton.button - 1]]; x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); if (nxagentOption(Rootless)) @@ -1301,10 +1688,11 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) nxagentScreenTrap = 0; } - if (nxagentOption(Fullscreen)) + if (nxagentOption(Fullscreen) == 1) { - if (X.xcrossing.window == nxagentFullscreenWindow && - X.xcrossing.detail != NotifyInferior) + if (X.xcrossing.window == nxagentDefaultWindows[0] && + X.xcrossing.detail != NotifyInferior && + X.xcrossing.mode == NotifyNormal) { nxagentGrabPointerAndKeyboard(&X); } @@ -1356,14 +1744,11 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) nxagentLastEnteredWindow = NULL; } - if (nxagentOption(Fullscreen)) + if (X.xcrossing.window == nxagentDefaultWindows[0] && + X.xcrossing.detail != NotifyInferior && + X.xcrossing.mode == NotifyNormal) { - if (X.xcrossing.window == nxagentFullscreenWindow && - X.xcrossing.detail != NotifyInferior && - X.xcrossing.mode == NotifyNormal) - { - nxagentUngrabPointerAndKeyboard(&X); - } + nxagentUngrabPointerAndKeyboard(&X); } if (X.xcrossing.detail != NotifyInferior) @@ -1617,7 +2002,7 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) } if (nxagentUseNXTrans == 1 && nxagentOption(Rootless) == 0 && - nxagentOption(Nested) == 0 && X.xmap.window != nxagentIconWindow) + nxagentOption(Nested) == 0) { nxagentVisibility = VisibilityFullyObscured; } @@ -1658,12 +2043,6 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) if (nxagentOption(Fullscreen) == 1) { - if (X.xmap.window == nxagentIconWindow) - { - pScreen = nxagentScreen(X.xmap.window); - nxagentMaximizeToFullScreen(pScreen); - } - nxagentVisibility = VisibilityUnobscured; nxagentVisibilityStop = False; nxagentVisibilityTimeout = GetTimeInMillis() + 2000; @@ -1673,10 +2052,17 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) } case MappingNotify: { + XMappingEvent *mappingEvent = (XMappingEvent *) &X; + #ifdef DEBUG fprintf(stderr, "nxagentDispatchEvents: WARNING! Going to handle new MappingNotify event.\n"); #endif + if (mappingEvent -> request == MappingPointer) + { + nxagentInitPointerMap(); + } + break; } default: @@ -1750,14 +2136,8 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) if (nxagentWMIsRunning) { - if (nxagentOption(Fullscreen)) - { - nxagentMinimizeFromFullScreen(pScreen); - } - else - { - XIconifyWindow(nxagentDisplay, nxagentDefaultWindows[0], DefaultScreen(nxagentDisplay)); - } + XIconifyWindow(nxagentDisplay, nxagentDefaultWindows[0], + DefaultScreen(nxagentDisplay)); } } @@ -1916,8 +2296,16 @@ int nxagentHandleKeyPress(XEvent *X, enum HandleEventResult *result) return 1; } - nxagentLastEventTime = nxagentLastKeyPressTime = GetTimeInMillis(); + if (X -> xkey.keycode == 66) + { + nxagentXkbState.Caps = (~nxagentXkbState.Caps & 1); + } + else if (X -> xkey.keycode == 77) + { + nxagentXkbState.Num = (~nxagentXkbState.Num & 1); + } + nxagentLastEventTime = nxagentLastKeyPressTime = GetTimeInMillis(); x.u.u.type = KeyPress; x.u.u.detail = nxagentConvertKeycode(X -> xkey.keycode); @@ -2227,7 +2615,6 @@ int nxagentHandleGraphicsExposeEvent(XEvent *X) int nxagentHandleClientMessageEvent(XEvent *X, enum HandleEventResult *result) { - ScreenPtr pScreen; WindowPtr pWin; xEvent x; @@ -2343,19 +2730,8 @@ int nxagentHandleClientMessageEvent(XEvent *X, enum HandleEventResult *result) fprintf(stderr, "Events: WM_DELETE_WINDOW arrived Atom = %ld.\n", wmAtom); #endif - if (X -> xclient.window == nxagentIconWindow) - { - pScreen = nxagentScreen(X -> xmap.window); - - XMapRaised(nxagentDisplay, nxagentFullscreenWindow); - - XIconifyWindow(nxagentDisplay, nxagentIconWindow, - DefaultScreen(nxagentDisplay)); - - } - - if (X -> xclient.window == (nxagentOption(Fullscreen) ? - nxagentIconWindow : nxagentDefaultWindows[0])) + if (X -> xclient.window == nxagentDefaultWindows[0] || + nxagentWMIsRunning == 0) { *result = doCloseSession; } @@ -2952,85 +3328,110 @@ int nxagentHandleConfigureNotify(XEvent* X) if (X -> xconfigure.window == nxagentDefaultWindows[pScreen -> myNum]) { - if (nxagentOption(Fullscreen) == 0) + if (nxagentOption(DesktopResize) == 1) { - if (nxagentOption(DesktopResize) == 1) + if (nxagentOption(Width) != X -> xconfigure.width || + nxagentOption(Height) != X -> xconfigure.height) { - if (nxagentOption(Width) != X -> xconfigure.width || - nxagentOption(Height) != X -> xconfigure.height) - { - Bool newEvents = False; + Bool newEvents = False; - doRandR = True; + doRandR = True; - NXFlushDisplay(nxagentDisplay, NXFlushLink); + NXFlushDisplay(nxagentDisplay, NXFlushLink); - do - { - newEvents = False; + do + { + newEvents = False; - timeout.tv_sec = 0; - timeout.tv_usec = 500 * 1000; + timeout.tv_sec = 0; + timeout.tv_usec = 500 * 1000; - nxagentWaitEvents(nxagentDisplay, &timeout); + nxagentWaitEvents(nxagentDisplay, &timeout); - /* - * This should also flush - * the NX link for us. - */ + /* + * This should also flush + * the NX link for us. + */ - XSync(nxagentDisplay, 0); + XSync(nxagentDisplay, 0); - while (XCheckTypedWindowEvent(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], - ConfigureNotify, X)) - { - newEvents = True; - } + while (XCheckTypedWindowEvent(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], + ConfigureNotify, X)) + { + newEvents = True; + } - } while (newEvents); - } + } while (newEvents); } + } - if (nxagentWMIsRunning == 0 || X -> xconfigure.send_event) - { - nxagentChangeOption(X, X -> xconfigure.x); - nxagentChangeOption(Y, X -> xconfigure.y); - } + if (nxagentWMIsRunning == 0 || X -> xconfigure.send_event) + { + nxagentChangeOption(X, X -> xconfigure.x); + nxagentChangeOption(Y, X -> xconfigure.y); + } - if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1 && - (nxagentOption(Width) != X -> xconfigure.width || - nxagentOption(Height) != X -> xconfigure.height)) - { - nxagentShadowResize = 1; - } + if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1 && + (nxagentOption(Width) != X -> xconfigure.width || + nxagentOption(Height) != X -> xconfigure.height)) + { + nxagentShadowResize = 1; + } - nxagentChangeOption(Width, X -> xconfigure.width); - nxagentChangeOption(Height, X -> xconfigure.height); + nxagentChangeOption(Width, X -> xconfigure.width); + nxagentChangeOption(Height, X -> xconfigure.height); - nxagentChangeOption(ViewportXSpan, (int) X -> xconfigure.width - - (int) nxagentOption(RootWidth)); - nxagentChangeOption(ViewportYSpan, (int) X -> xconfigure.height - - (int) nxagentOption(RootHeight)); + nxagentChangeOption(ViewportXSpan, (int) X -> xconfigure.width - + (int) nxagentOption(RootWidth)); + nxagentChangeOption(ViewportYSpan, (int) X -> xconfigure.height - + (int) nxagentOption(RootHeight)); - nxagentMoveViewport(pScreen, 0, 0); + nxagentMoveViewport(pScreen, 0, 0); - if (nxagentOption(Shadow) == 1 || - (nxagentOption(Width) == nxagentOption(RootWidth) && - nxagentOption(Height) == nxagentOption(RootHeight))) - { - doRandR = 0; - } + if (nxagentOption(Shadow) == 1 || + (nxagentOption(Width) == nxagentOption(RootWidth) && + nxagentOption(Height) == nxagentOption(RootHeight))) + { + doRandR = 0; + } - if (doRandR) - { - #ifdef TEST - fprintf(stderr,"nxagentHandleConfigureNotify: Width %d Height %d.\n", - nxagentOption(Width), nxagentOption(Height)); - #endif + nxagentChangeOption(Width, X -> xconfigure.width); + nxagentChangeOption(Height, X -> xconfigure.height); - nxagentRRSetScreenConfig(screenInfo.screens[DefaultScreen(nxagentDisplay)], - nxagentOption(Width), nxagentOption(Height)); - } + XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, + X -> xconfigure.width, X -> xconfigure.height); + + if (nxagentOption(Fullscreen) == 0) + { + nxagentMoveViewport(pScreen, 0, 0); + } + else + { + nxagentChangeOption(RootX, (nxagentOption(Width) - + nxagentOption(RootWidth)) / 2); + nxagentChangeOption(RootY, (nxagentOption(Height) - + nxagentOption(RootHeight)) / 2); + nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - + nxagentOption(RootWidth)); + nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - + nxagentOption(RootHeight)); + + nxagentUpdateViewportFrame(0, 0, nxagentOption(RootWidth), + nxagentOption(RootHeight)); + + XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), + nxagentOption(RootX), nxagentOption(RootY)); + } + + if (doRandR) + { + #ifdef TEST + fprintf(stderr,"nxagentHandleConfigureNotify: Width %d Height %d.\n", + nxagentOption(Width), nxagentOption(Height)); + #endif + + nxagentRRSetScreenConfig(screenInfo.screens[DefaultScreen(nxagentDisplay)], + nxagentOption(Width), nxagentOption(Height)); } return 1; @@ -3042,8 +3443,6 @@ int nxagentHandleConfigureNotify(XEvent* X) int nxagentHandleReparentNotify(XEvent* X) { - ScreenPtr pScreen = nxagentScreen(X -> xreparent.window); - #ifdef TEST fprintf(stderr, "nxagentHandleReparentNotify: Going to handle a new reparent event.\n"); #endif @@ -3096,6 +3495,8 @@ int nxagentHandleReparentNotify(XEvent* X) #ifdef WARNING fprintf(stderr, "nxagentHandleReparentNotify: WARNING! Failed QueryTree request.\n"); #endif + + break; } if (result && children_return) @@ -3148,6 +3549,95 @@ int nxagentHandleReparentNotify(XEvent* X) return 1; } + else if (nxagentWMIsRunning == 1 && nxagentOption(Fullscreen) == 0 && + nxagentOption(WMBorderWidth) == -1) + { + XlibWindow w; + XlibWindow rootReturn = 0; + XlibWindow parentReturn = 0; + XlibWindow junk; + XlibWindow *childrenReturn = NULL; + unsigned int nchildrenReturn = 0; + Status result; + XWindowAttributes attributes; + int x, y; + int xParent, yParent; + + /* + * Calculate the absolute upper-left X e Y + */ + + if ((XGetWindowAttributes(nxagentDisplay, X -> xreparent.window, + &attributes) == 0)) + { + #ifdef WARNING + fprintf(stderr, "nxagentHandleReparentNotify: WARNING! " + "XGetWindowAttributes failed.\n"); + #endif + + return 1; + } + + x = attributes.x; + y = attributes.y; + + XTranslateCoordinates(nxagentDisplay, X -> xreparent.window, + attributes.root, -attributes.border_width, + -attributes.border_width, &x, &y, &junk); + + /* + * Calculate the parent X and parent Y. + */ + + w = X -> xreparent.parent; + + if (w != DefaultRootWindow(nxagentDisplay)) + { + do + { + result = XQueryTree(nxagentDisplay, w, &rootReturn, &parentReturn, + &childrenReturn, &nchildrenReturn); + + if (parentReturn == rootReturn || parentReturn == 0 || result == 0) + { + break; + } + + if (result == 1 && childrenReturn != NULL) + { + XFree(childrenReturn); + } + + w = parentReturn; + } + while (True); + + /* + * WM reparented. Find edge of the frame. + */ + + if (XGetWindowAttributes(nxagentDisplay, w, &attributes) == 0) + { + #ifdef WARNING + fprintf(stderr, "nxagentHandleReparentNotify: WARNING! " + "XGetWindowAttributes failed for parent window.\n"); + #endif + + return 1; + } + + xParent = attributes.x; + yParent = attributes.y; + + /* + * Difference between Absolute X and Parent X gives thickness of side frame. + * Difference between Absolute Y and Parent Y gives thickness of title bar. + */ + + nxagentChangeOption(WMBorderWidth, (x - xParent)); + nxagentChangeOption(WMTitleHeight, (y - yParent)); + } + } return 1; } @@ -3308,6 +3798,13 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) int resource; + int result; + + if (nxagentPointerAndKeyboardGrabbed == 1) + { + return; + } + #ifdef TEST fprintf(stderr, "nxagentGrabPointerAndKeyboard: Grabbing pointer and keyboard with event at [%p].\n", (void *) X); @@ -3326,8 +3823,22 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) fprintf(stderr, "nxagentGrabPointerAndKeyboard: Going to grab the keyboard in context [B1].\n"); #endif - XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, - True, GrabModeAsync, GrabModeAsync, now); + result = XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, + True, GrabModeAsync, GrabModeAsync, now); + + if (result != GrabSuccess) + { + return; + } + + /* + * The smart scheduler could be stopped while + * waiting for the reply. In this case we need + * to yield explicitly to avoid to be stuck in + * the dispatch loop forever. + */ + + isItTimeToYield = 1; #ifdef TEST fprintf(stderr, "nxagentGrabPointerAndKeyboard: Going to grab the pointer in context [B2].\n"); @@ -3356,12 +3867,19 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) XSetInputFocus(nxagentDisplay, nxagentFullscreenWindow, RevertToParent, now); } + + nxagentPointerAndKeyboardGrabbed = 1; } void nxagentUngrabPointerAndKeyboard(XEvent *X) { unsigned long now; + if (nxagentPointerAndKeyboardGrabbed == 0) + { + return; + } + #ifdef TEST fprintf(stderr, "nxagentUngrabPointerAndKeyboard: Ungrabbing pointer and keyboard with event at [%p].\n", (void *) X); @@ -3387,6 +3905,8 @@ void nxagentUngrabPointerAndKeyboard(XEvent *X) #endif XUngrabPointer(nxagentDisplay, now); + + nxagentPointerAndKeyboardGrabbed = 0; } void nxagentDeactivatePointerGrab() @@ -4022,4 +4542,180 @@ void nxagentGuessDumpInputInfo(ClientPtr client, Atom property, char *data) } } +void nxagentDeactivateInputDevicesGrabs() +{ + fprintf(stderr, "Info: Deactivating input devices grabs.\n"); + + if (inputInfo.pointer -> grab) + { + (*inputInfo.pointer -> DeactivateGrab)(inputInfo.pointer); + } + + if (inputInfo.keyboard -> grab) + { + (*inputInfo.keyboard -> DeactivateGrab)(inputInfo.keyboard); + } +} + +static const char *nxagentGrabStateToString(int state) +{ + switch (state) + { + case 0: + return "NOT_GRABBED"; + case 1: + return "THAWED"; + case 2: + return "THAWED_BOTH"; + case 3: + return "FREEZE_NEXT_EVENT"; + case 4: + return "FREEZE_BOTH_NEXT_EVENT"; + case 5: + return "FROZEN_NO_EVENT"; + case 6: + return "FROZEN_WITH_EVENT"; + case 7: + return "THAW_OTHERS"; + default: + return "unknown state"; + } +} + +void nxagentDumpInputDevicesState(void) +{ + int i, k; + int mask = 1; + CARD8 val; + DeviceIntPtr dev; + GrabPtr grab; + WindowPtr pWin = NULL; + + fprintf(stderr, "\n*** Dump input devices state: BEGIN ***" + "\nKeys down:"); + + dev = inputInfo.keyboard; + + for (i = 0; i < DOWN_LENGTH; i++) + { + val = dev -> key -> down[i]; + + if (val != 0) + { + for (k = 0; k < 8; k++) + { + if (val & (mask << k)) + { + fprintf(stderr, "\n\t[%d] [%s]", i * 8 + k, + XKeysymToString(XKeycodeToKeysym(nxagentDisplay, i * 8 + k, 0))); + } + } + } + } + + fprintf(stderr, "\nKeyboard device state: \n\tdevice [%p]\n\tlast grab time [%lu]" + "\n\tfrozen [%s]\n\tstate [%s]\n\tother [%p]\n\tevent count [%d]" + "\n\tfrom passive grab [%s]\n\tactivating key [%d]", dev, + dev -> grabTime.milliseconds, dev -> sync.frozen ? "Yes": "No", + nxagentGrabStateToString(dev -> sync.state), + dev -> sync.other, dev -> sync.evcount, + dev -> fromPassiveGrab ? "Yes" : "No", + dev -> activatingKey); + + grab = dev -> grab; + + if (grab) + { + fprintf(stderr, "\nKeyboard grab state: \n\twindow pointer [%p]" + "\n\towner events flag [%s]\n\tgrab mode [%s]", + grab -> window, grab -> ownerEvents ? "True" : "False", + grab -> keyboardMode ? "asynchronous" : "synchronous"); + + /* + * Passive grabs. + */ + + pWin = grab -> window; + grab = wPassiveGrabs(pWin); + + while (grab) + { + fprintf(stderr, "\nPassive grab state: \n\tdevice [%p]\n\towner events flag [%s]" + "\n\tpointer grab mode [%s]\n\tkeyboard grab mode [%s]\n\tevent type [%d]" + "\n\tmodifiers [%x]\n\tbutton/key [%u]\n\tevent mask [%lx]", + grab -> device, grab -> ownerEvents ? "True" : "False", + grab -> pointerMode ? "asynchronous" : "synchronous", + grab -> keyboardMode ? "asynchronous" : "synchronous", + grab -> type, grab -> modifiersDetail.exact, + grab -> detail.exact, grab -> eventMask); + + grab = grab -> next; + } + } + + fprintf(stderr, "\nButtons down:"); + + dev = inputInfo.pointer; + + for (i = 0; i < DOWN_LENGTH; i++) + { + val = dev -> button -> down[i]; + + if (val != 0) + { + for (k = 0; k < 8; k++) + { + if (val & (mask << k)) + { + fprintf(stderr, "\n\t[%d]", i * 8 + k); + } + } + } + } + + fprintf(stderr, "\nPointer device state: \n\tdevice [%p]\n\tlast grab time [%lu]" + "\n\tfrozen [%s]\n\tstate [%s]\n\tother [%p]\n\tevent count [%d]" + "\n\tfrom passive grab [%s]\n\tactivating button [%d]", dev, + dev -> grabTime.milliseconds, dev -> sync.frozen ? "Yes" : "No", + nxagentGrabStateToString(dev -> sync.state), + dev -> sync.other, dev -> sync.evcount, + dev -> fromPassiveGrab ? "Yes" : "No", + dev -> activatingKey); + + grab = dev -> grab; + + if (grab) + { + fprintf(stderr, "\nPointer grab state: \n\twindow pointer [%p]" + "\n\towner events flag [%s]\n\tgrab mode [%s]", + grab -> window, grab -> ownerEvents ? "True" : "False", + grab -> pointerMode ? "asynchronous" : "synchronous"); + + if (grab -> window != pWin) + { + /* + * Passive grabs. + */ + + grab = wPassiveGrabs(grab -> window); + + while (grab) + { + fprintf(stderr, "\nPassive grab state: \n\tdevice [%p]\n\towner events flag [%s]" + "\n\tpointer grab mode [%s]\n\tkeyboard grab mode [%s]\n\tevent type [%d]" + "\n\tmodifiers [%x]\n\tbutton/key [%u]\n\tevent mask [%lx]", + grab -> device, grab -> ownerEvents ? "True" : "False", + grab -> pointerMode ? "asynchronous" : "synchronous", + grab -> keyboardMode ? "asynchronous" : "synchronous", + grab -> type, grab -> modifiersDetail.exact, + grab -> detail.exact, grab -> eventMask); + + grab = grab -> next; + } + } + } + + fprintf(stderr, "\n*** Dump input devices state: FINISH ***\n"); +} + #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.h b/nx-X11/programs/Xserver/hw/nxagent/Events.h index ab0d25764..109475c16 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -29,9 +29,14 @@ enum HandleEventResult { doNothing = 0, doMinimize, + doDebugTree, doCloseSession, doStartKbd, doSwitchFullscreen, + doViewportMoveUp, + doViewportMoveLeft, + doViewportMoveRight, + doViewportMoveDown, doViewportLeft, doViewportUp, doViewportRight, diff --git a/nx-X11/programs/Xserver/hw/nxagent/Extensions.c b/nx-X11/programs/Xserver/hw/nxagent/Extensions.c index f2954a3e9..e76cbb4ad 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Extensions.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Extensions.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Extensions.h b/nx-X11/programs/Xserver/hw/nxagent/Extensions.h index f76229867..620645d00 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Extensions.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Extensions.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Font.c b/nx-X11/programs/Xserver/hw/nxagent/Font.c index 87f9f0201..13b819322 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Font.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Font.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -827,7 +827,10 @@ static XFontStruct *nxagentLoadBestQueryFont(Display* dpy, char *fontName, FontP for (j = 0; j < numSearchFields; j++) { - free (searchFields[j]); + if (searchFields[j] != NULL) + { + free(searchFields[j]); + } } } } @@ -846,7 +849,10 @@ static XFontStruct *nxagentLoadBestQueryFont(Display* dpy, char *fontName, FontP for (j = 0; j < numFontFields; j++) { - free (fontNameFields[j]); + if (fontNameFields[j] != NULL) + { + free(fontNameFields[j]); + } } return fontStruct; @@ -1765,6 +1771,10 @@ int nxagentSplitString(char *string, char *fields[], int nfields, char *sep) strncpy(fields[i], current, fieldlen); *(fields[i] + fieldlen) = 0; } + else + { + fields[i] = NULL; + } current = next + seplen; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Font.h b/nx-X11/programs/Xserver/hw/nxagent/Font.h index 3ae086b44..75ae3f6f5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Font.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Font.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GC.c b/nx-X11/programs/Xserver/hw/nxagent/GC.c index 4ca069790..c53e3b9f7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GC.c +++ b/nx-X11/programs/Xserver/hw/nxagent/GC.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCOps.c b/nx-X11/programs/Xserver/hw/nxagent/GCOps.c index 83aa04f11..85730797e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCOps.c +++ b/nx-X11/programs/Xserver/hw/nxagent/GCOps.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -594,6 +594,8 @@ RegionPtr nxagentCopyArea(DrawablePtr pSrcDrawable, DrawablePtr pDstDrawable, unsigned int format; unsigned long planeMask = 0xffffffff; + int oldDstxyValue; + RegionPtr pDstRegion; int skip = 0; @@ -605,6 +607,91 @@ RegionPtr nxagentCopyArea(DrawablePtr pSrcDrawable, DrawablePtr pDstDrawable, (void *) pDstDrawable, srcx, srcy, dstx, dsty, width, height); #endif + /* + * Here, before using fbDoCopy() called by fbCopyArea(), + * it should be provided that the cast in fbDoCopy() from + * int to short int would not cut off significative bits. + */ + + if (dstx + pDstDrawable->x + width > 32767) + { + #ifdef WARNING + fprintf(stderr, "nxagentCopyArea: x2 exceeding short int.\n"); + #endif + + width = 32767 - dstx - pDstDrawable->x; + + if (width <= 0) + { + #ifdef TEST + fprintf(stderr, "nxagentCopyArea: Returning null on x2 check.\n"); + #endif + + return NullRegion; + } + } + + if (dstx + pDstDrawable->x < -32768) + { + #ifdef WARNING + fprintf(stderr, "nxagentCopyArea: x1 exceeding short int.\n"); + #endif + + width += pDstDrawable->x + dstx + 32768; + srcx -= pDstDrawable->x + dstx + 32768; + dstx = -32768 - pDstDrawable->x; + + if (width <= 0) + { + #ifdef TEST + fprintf(stderr, "nxagentCopyArea: Returning null on x1 check.\n"); + #endif + + return NullRegion; + } + } + + oldDstxyValue = dsty; + + if (dsty + pDstDrawable->y + height > 32767) + { + #ifdef WARNING + fprintf(stderr, "nxagentCopyArea: y2 exceeding short int.\n"); + #endif + + height = 32767 - dsty - pDstDrawable->y; + + if (height <= 0) + { + #ifdef TEST + fprintf(stderr, "nxagentCopyArea: Returning null on y2 check.\n"); + #endif + + return NullRegion; + } + } + + if (dsty + pDstDrawable->y < -32768) + { + #ifdef WARNING + fprintf(stderr, "nxagentCopyArea: y1 exceeding short int.\n"); + #endif + + height += 32768 + pDstDrawable->y + dsty; + srcy -= 32768 + pDstDrawable->y + dsty; + dsty = -32768 - pDstDrawable->y; + + if (height <= 0) + { + #ifdef TEST + fprintf(stderr, "nxagentCopyArea: Returning null on y1 check.\n"); + #endif + + return NullRegion; + } + } + + if (nxagentGCTrap == 1 || nxagentShmTrap == 1) { if (pSrcDrawable -> type == DRAWABLE_PIXMAP && diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCOps.h b/nx-X11/programs/Xserver/hw/nxagent/GCOps.h index 14d30e392..7ae6d9923 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCOps.h +++ b/nx-X11/programs/Xserver/hw/nxagent/GCOps.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCs.h b/nx-X11/programs/Xserver/hw/nxagent/GCs.h index 207d563ed..bec290088 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCs.h +++ b/nx-X11/programs/Xserver/hw/nxagent/GCs.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Handlers.c b/nx-X11/programs/Xserver/hw/nxagent/Handlers.c index 3abc3575f..be407f160 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Handlers.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Handlers.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -105,6 +105,13 @@ #define MINIMUM_DISPLAY_BUFFER 512 +#ifdef NX_DEBUG_INPUT +extern int nxagentDebugInputDevices; +extern unsigned long nxagentLastInputDevicesDumpTime; + +extern void nxagentDumpInputDevicesState(void); +#endif + /* * Used in the handling of the X desktop * manager protocol. @@ -186,6 +193,18 @@ void nxagentBlockHandler(pointer data, struct timeval **timeout, pointer mask) now = GetTimeInMillis(); + #ifdef NX_DEBUG_INPUT + + if (nxagentDebugInputDevices == 1 && + now - nxagentLastInputDevicesDumpTime > 5000) + { + nxagentLastInputDevicesDumpTime = now; + + nxagentDumpInputDevicesState(); + } + + #endif + if (nxagentNeedConnectionChange() == 1) { #ifdef TEST @@ -508,7 +527,8 @@ void nxagentBlockHandler(pointer data, struct timeval **timeout, pointer mask) synchronize, nxagentReady); #endif - if (nxagentQueuedEvents(nxagentDisplay) > 0) + if (NXDisplayError(nxagentDisplay) == 0 && + nxagentQueuedEvents(nxagentDisplay) > 0) { #ifdef WARNING fprintf(stderr, "nxagentBlockHandler: WARNING! Forcing a null timeout with events queued.\n"); @@ -540,6 +560,8 @@ void nxagentBlockHandler(pointer data, struct timeval **timeout, pointer mask) #endif + nxagentPrintGeometry(); + #ifdef BLOCKS fprintf(stderr, "[End block]\n"); #endif @@ -820,6 +842,8 @@ FIXME: Must queue multiple writes and handle #endif + nxagentPrintGeometry(); + #ifdef BLOCKS fprintf(stderr, "[End block]\n"); #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/Handlers.h b/nx-X11/programs/Xserver/hw/nxagent/Handlers.h index fc72c7060..fe8aeef36 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Handlers.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Handlers.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Holder.c b/nx-X11/programs/Xserver/hw/nxagent/Holder.c index 087d66017..a9ac77c09 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Holder.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Holder.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Holder.h b/nx-X11/programs/Xserver/hw/nxagent/Holder.h index 6dc2b8ed2..9896aeead 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Holder.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Holder.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Icons.h b/nx-X11/programs/Xserver/hw/nxagent/Icons.h index cb2e08521..4d0e216cd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Icons.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Icons.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Image.c b/nx-X11/programs/Xserver/hw/nxagent/Image.c index 4e08f6bf1..e8405ed3a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Image.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Image.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Image.h b/nx-X11/programs/Xserver/hw/nxagent/Image.h index fb77f3c80..7805b0312 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Image.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Image.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Imakefile b/nx-X11/programs/Xserver/hw/nxagent/Imakefile index 633e17a22..51173e410 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Imakefile +++ b/nx-X11/programs/Xserver/hw/nxagent/Imakefile @@ -206,7 +206,8 @@ DEFINES = -g $(OS_DEFINES) $(EXT_DEFINES) $(UPG_DEFINES) \ -DNXAGENT_SPLASH \ -DNXAGENT_ARTSD \ -UNX_DEBUG_INPUT \ - -UPANORAMIX + -UPANORAMIX \ + -UDEBUG_TREE all:: $(OBJS) diff --git a/nx-X11/programs/Xserver/hw/nxagent/Init.c b/nx-X11/programs/Xserver/hw/nxagent/Init.c index 81ed0c43e..64b6583bf 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Init.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Init.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -74,7 +74,7 @@ is" without express or implied warranty. #undef DEBUG #undef DUMP -#define NXAGENT_VERSION "3.3.0" +#define NXAGENT_VERSION "3.4.0" /* * ProcVector array defined in tables.c. @@ -193,7 +193,7 @@ void InitOutput(ScreenInfo *screenInfo, int argc, char *argv[]) if (serverGeneration <= 1) { fprintf(stderr, "\nNXAGENT - Version " NXAGENT_VERSION "\n\n"); - fprintf(stderr, "Copyright (C) 2001, 2007 NoMachine.\n"); + fprintf(stderr, "Copyright (C) 2001, 2010 NoMachine.\n"); fprintf(stderr, "See http://www.nomachine.com/ for more information.\n\n"); fprintf(stderr, "Info: Agent running with pid '%d'.\n", getpid()); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Init.h b/nx-X11/programs/Xserver/hw/nxagent/Init.h index 63e27bada..576c1a74d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Init.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Init.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c index 73b4c706a..b0aeabeea 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -1791,7 +1791,6 @@ void nxagentResetKeycodeConversion(void) { int result; XkbAgentInfoRec info; - XkbDescPtr xkb; result = XkbQueryExtension(nxagentDisplay, &info.Opcode, &info.EventBase, &info.ErrorBase, &info.MajorVersion, diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h index 50dd2be78..1a953358a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c index ea06913f8..de1da8654 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -31,6 +31,12 @@ extern Bool nxagentWMIsRunning; extern Bool nxagentIpaq; +#ifdef NX_DEBUG_INPUT +int nxagentDebugInputDevices = 0; +unsigned long nxagentLastInputDevicesDumpTime = 0; +extern void nxagentDeactivateInputDevicesGrabs(); +#endif + /* * Set here the required log level. */ @@ -86,6 +92,18 @@ int nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) { switch (sym) { + #ifdef DEBUG_TREE + + case XK_q: + case XK_Q: + { + *result = doDebugTree; + + break; + } + + #endif /* DEBUG_TREE */ + case XK_t: case XK_T: { @@ -209,6 +227,105 @@ int nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) } #endif + + #ifdef NX_DEBUG_INPUT + + case XK_X: + case XK_x: + { + /* + * Used to test the input devices state. + */ + + if (X -> type == KeyPress) + { + if (nxagentDebugInputDevices == 0) + { + fprintf(stderr, "Info: Turning input devices debug ON.\n"); + + nxagentDebugInputDevices = 1; + } + else + { + fprintf(stderr, "Info: Turning input devices debug OFF.\n"); + + nxagentDebugInputDevices = 0; + + nxagentLastInputDevicesDumpTime = 0; + } + } + + return 1; + } + + case XK_Y: + case XK_y: + { + /* + * Used to deactivate input devices grab. + */ + + if (X -> type == KeyPress) + { + nxagentDeactivateInputDevicesGrabs(); + } + + return 1; + } + + #endif + } + } + else if ((X -> state & nxagentAltMetaMask) && + ((X -> state & (ControlMask | ShiftMask)) == (ControlMask | + ShiftMask))) + { + switch (sym) + { + case XK_Left: + case XK_KP_Left: + { + if (nxagentOption(Rootless) == 0 && + nxagentOption(DesktopResize) == 0) + { + *result = doViewportMoveLeft; + } + + break; + } + case XK_Up: + case XK_KP_Up: + { + if (nxagentOption(Rootless) == 0 && + nxagentOption(DesktopResize) == 0) + { + *result = doViewportMoveUp; + } + + break; + } + case XK_Right: + case XK_KP_Right: + { + if (nxagentOption(Rootless) == 0 && + nxagentOption(DesktopResize) == 0) + { + *result = doViewportMoveRight; + } + + break; + } + case XK_Down: + case XK_KP_Down: + { + if (nxagentOption(Rootless) == 0 && + nxagentOption(DesktopResize) == 0) + { + *result = doViewportMoveDown; + } + + break; + } } } diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h index 49a35db1d..e9ca59ff2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/LICENSE b/nx-X11/programs/Xserver/hw/nxagent/LICENSE index f3e15ee70..141ca13ea 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/LICENSE +++ b/nx-X11/programs/Xserver/hw/nxagent/LICENSE @@ -1,4 +1,4 @@ -Copyright (C) 2001, 2007 NoMachine - http://www.nomachine.com/. +Copyright (c) 2001, 2010 NoMachine - http://www.nomachine.com/. NXAGENT and NX extensions to X are copyright of NoMachine. diff --git a/nx-X11/programs/Xserver/hw/nxagent/Literals.h b/nx-X11/programs/Xserver/hw/nxagent/Literals.h index f6aab84e4..377dd7e25 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Literals.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Literals.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Millis.c b/nx-X11/programs/Xserver/hw/nxagent/Millis.c index 38435d9a8..bde85f090 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Millis.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Millis.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Millis.h b/nx-X11/programs/Xserver/hw/nxagent/Millis.h index 8ee380ae1..2125eca3e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Millis.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Millis.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c index 90da743a2..5106ffa8c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original index 90da743a2..5106ffa8c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c index 83103ffd6..0d8584218 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original index 83103ffd6..0d8584218 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c index dd607e0ca..cd8ced7a6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original index dd607e0ca..cd8ced7a6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c index 295b885c2..852ad1503 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original index 295b885c2..852ad1503 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c index dfd82b76b..55248195f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original index dfd82b76b..55248195f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c index 599e4c616..614d2db39 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original index 599e4c616..614d2db39 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h index 970d0bb4d..08ffb35b0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original index 970d0bb4d..08ffb35b0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c index 2521ae5c7..806cf2900 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original index 2521ae5c7..806cf2900 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c index 64ba970c9..a9c501b34 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original index 64ba970c9..a9c501b34 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h index a1790c3f0..26a95fe9f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original index a1790c3f0..26a95fe9f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c index f5cf91607..14b6136d4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original index f5cf91607..14b6136d4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c index 6f53dcdad..b7039e1e0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original index 6f53dcdad..b7039e1e0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c index 20aca4619..0940a3602 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c @@ -31,7 +31,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -40,7 +40,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original index 20aca4619..0940a3602 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original @@ -31,7 +31,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -40,7 +40,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c index 16328f9ab..0954cf8ae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original index 16328f9ab..0954cf8ae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -15,7 +15,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c index 91dafb6c6..8d05175ff 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h index 3fb504ea9..4e800e96d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h b/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h index 33b05b1f0..ae3a03d86 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Options.c b/nx-X11/programs/Xserver/hw/nxagent/Options.c index 64dbe3b42..1f04b0daf 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Options.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Options.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -38,6 +38,11 @@ AgentOptionsRec nxagentOptionsBackup; AgentOptionsPtr nxagentOptionsPtr = &nxagentOptions; +/* + * If this is set, print the geometry in the block handler. + */ + +unsigned int nxagentPrintGeometryFlags = 0; /* * This must be called at startup to initialize * the options repository to the default values. @@ -58,6 +63,9 @@ void nxagentInitOptions() nxagentOptions.Height = 0; nxagentOptions.BorderWidth = 0; + nxagentOptions.WMBorderWidth = -1; + nxagentOptions.WMTitleHeight = -1; + nxagentOptions.SavedX = 0; nxagentOptions.SavedY = 0; nxagentOptions.SavedWidth = 0; @@ -163,6 +171,9 @@ void nxagentResetOptions() nxagentOptions.TileWidth = UNDEFINED; nxagentOptions.TileHeight = UNDEFINED; + + nxagentOptions.WMBorderWidth = -1; + nxagentOptions.WMTitleHeight = -1; } void nxagentSaveOptions() diff --git a/nx-X11/programs/Xserver/hw/nxagent/Options.h b/nx-X11/programs/Xserver/hw/nxagent/Options.h index aa78489b1..1bc7eaa4c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Options.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Options.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -29,6 +29,8 @@ #define UNDEFINED -1 #define COPY_UNLIMITED -1 +extern unsigned int nxagentPrintGeometryFlags; + typedef enum _BackingStoreMode { BackingStoreUndefined = -1, @@ -124,6 +126,9 @@ typedef struct _AgentOptions * screen. */ + int WMBorderWidth; + int WMTitleHeight; + int SavedX; int SavedY; int SavedWidth; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixels.c b/nx-X11/programs/Xserver/hw/nxagent/Pixels.c index 03970a14f..10c705dfc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixels.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixels.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h index f9f88233e..ea7c375ee 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -108,6 +108,12 @@ FIXME: The condition checking for the render avoid problems with the render composi- te on XFree86 remote server. */ +/* +FIXME: Changed macro: NXAGENT_SHOULD_DEFER_COMPOSITE + to handle situation, when pSrc -> pDrawable + is NULL. This case happens with gradients + and solid fill. + #define NXAGENT_SHOULD_DEFER_COMPOSITE(pSrc, pMask, pDst) \ ((nxagentRenderVersionMajor == 0 && \ nxagentRenderVersionMinor == 8 && \ @@ -118,6 +124,18 @@ FIXME: The condition checking for the render nxagentOption(DeferLevel) == 1) || \ (nxagentOption(DeferLevel) >= 2 && \ nxagentOption(LinkType) < LINK_TYPE_ADSL)) +*/ +#define NXAGENT_SHOULD_DEFER_COMPOSITE(pSrc, pMask, pDst) \ + ((nxagentRenderVersionMajor == 0 && \ + nxagentRenderVersionMinor == 8 && \ + (pDst) -> pDrawable -> type == DRAWABLE_PIXMAP) || \ + (nxagentOption(DeferLevel) >= 2 && \ + nxagentOption(LinkType) < LINK_TYPE_ADSL) || \ + (nxagentOption(DeferLevel) == 1 && \ + (pDst) -> pDrawable -> type == DRAWABLE_PIXMAP && \ + (((pSrc) -> pDrawable && nxagentDrawableStatus((pSrc) -> pDrawable) == NotSynchronized) || \ + ((pMask) && nxagentDrawableStatus((pMask) -> pDrawable) == NotSynchronized)))) + #define NXAGENT_SHOULD_DEFER_PUTIMAGE(pDrawable) \ (nxagentSplitTrap == 0 && \ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c index 4aea92e2d..1718c7363 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h b/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h index 5cf340d36..234650dd4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c index f53dfbe52..9c1bfaace 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -57,6 +57,13 @@ is" without express or implied warranty. #undef TEST #undef DEBUG +/* + * The nxagentReversePointerMap array is used to + * memorize remote display pointer map. + */ + +unsigned char nxagentReversePointerMap[MAXBUTTONS]; + void nxagentChangePointerControl(DeviceIntPtr pDev, PtrCtrl *ctrl) { /* @@ -125,6 +132,8 @@ int nxagentPointerProc(DeviceIntPtr pDev, int onoff) return Success; } + nxagentInitPointerMap(); + nxagentEnablePointerEvents(); break; @@ -155,3 +164,28 @@ int nxagentPointerProc(DeviceIntPtr pDev, int onoff) return Success; } + +void nxagentInitPointerMap(void) +{ + int numButtons; + + int i; + + unsigned char pointerMap[MAXBUTTONS]; + + #ifdef DEBUG + fprintf(stderr, "nxagentInitPointerMap: Going to retrieve the " + "pointer map from remote display.\n"); + #endif + + numButtons = XGetPointerMapping(nxagentDisplay, pointerMap, MAXBUTTONS); + + /* + * Computing revers pointer map. + */ + + for (i = 1; i <= numButtons; i++) + { + nxagentReversePointerMap[pointerMap[i - 1] - 1] = i; + } +} diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h index 2adee6cb3..b0bb3f99c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -38,8 +38,17 @@ is" without express or implied warranty. (ButtonPressMask | ButtonReleaseMask | PointerMotionMask | \ EnterWindowMask | LeaveWindowMask) +/* + * The nxagentReversePointerMap array is used to + * memorize remote display pointer map. + */ + +extern unsigned char nxagentReversePointerMap[MAXBUTTONS]; + void nxagentChangePointerControl(DeviceIntPtr pDev, PtrCtrl *ctrl); int nxagentPointerProc(DeviceIntPtr pDev, int onoff); +void nxagentInitPointerMap(void); + #endif /* __Pointer_H__ */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c index 69b73a942..e63b481b2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -81,6 +81,8 @@ extern Bool nxagentUninstallFontServerPath(void); extern void nxagentRemoveXConnection(void); +extern void nxagentInitPointerMap(void); + static char *nxagentGetReconnectError(void); void nxagentInitializeRecLossyLevel(void); @@ -257,7 +259,11 @@ TODO: This should be reset only when if ((dispatchException & DE_TERMINATE) == 0) { + #ifdef NX_DEBUG_INPUT + fprintf(stderr, "Session: Session suspended at '%s' timestamp [%lu].\n", GetTimeAsString(), GetTimeInMillis()); + #else fprintf(stderr, "Session: Session suspended at '%s'.\n", GetTimeAsString()); + #endif } nxagentResetDisplayHandlers(); @@ -580,6 +586,8 @@ Bool nxagentReconnectSession(void) nxagentOldKeyboard = NULL; } + nxagentInitPointerMap(); + nxagentDeactivatePointerGrab(); nxagentWakeupByReconnect(); @@ -609,7 +617,11 @@ Bool nxagentReconnectSession(void) goto nxagentReconnectError; } + #ifdef NX_DEBUG_INPUT + fprintf(stderr, "Session: Session resumed at '%s' timestamp [%lu].\n", GetTimeAsString(), GetTimeInMillis()); + #else fprintf(stderr, "Session: Session resumed at '%s'.\n", GetTimeAsString()); + #endif nxagentRemoveSplashWindow(NULL); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h index 0a2a8a6a7..12d0742df 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.c b/nx-X11/programs/Xserver/hw/nxagent/Render.c index f2d7b15f9..4f0f76474 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -147,8 +147,6 @@ void nxagentCursorPostSaveRenderInfo(CursorPtr pCursor, ScreenPtr pScreen, int nxagentCreatePicture(PicturePtr pPicture, Mask mask); -void nxagentDestroyPicture(PicturePtr pPicture); - int nxagentChangePictureClip(PicturePtr pPicture, int clipType, int nRects, xRectangle *rects, int xOrigin, int yOrigin); @@ -1010,12 +1008,15 @@ void nxagentComposite(CARD8 op, PicturePtr pSrc, PicturePtr pMask, PicturePtr pD #ifdef DEBUG - fprintf(stderr, "nxagentComposite: Source Picture [%lu][%p] with drawable [%s%s][%p].\n", - nxagentPicturePriv(pSrc) -> picture, (void *) pSrc, - (pSrc -> pDrawable -> type == DRAWABLE_PIXMAP && - nxagentIsShmPixmap((PixmapPtr) pSrc -> pDrawable)) ? "Shared " : "", - pSrc -> pDrawable -> type == DRAWABLE_PIXMAP ? "Pixmap" : "Window", - (void *) pSrc -> pDrawable); + if (pSrc -> pDrawable != NULL) + { + fprintf(stderr, "nxagentComposite: Source Picture [%lu][%p] with drawable [%s%s][%p].\n", + nxagentPicturePriv(pSrc) -> picture, (void *) pSrc, + (pSrc -> pDrawable -> type == DRAWABLE_PIXMAP && + nxagentIsShmPixmap((PixmapPtr) pSrc -> pDrawable)) ? "Shared " : "", + pSrc -> pDrawable -> type == DRAWABLE_PIXMAP ? "Pixmap" : "Window", + (void *) pSrc -> pDrawable); + } fprintf(stderr, "nxagentComposite: Destination Picture [%lu][%p] with drawable [%s%s][%p].\n", nxagentPicturePriv(pDst) -> picture, (void *) pDst, @@ -1064,16 +1065,19 @@ void nxagentComposite(CARD8 op, PicturePtr pSrc, PicturePtr pMask, PicturePtr pD * the wrong data. */ - nxagentSynchronizeShmPixmap(pSrc -> pDrawable, xSrc, ySrc, width, height); - - if (nxagentDrawableStatus(pSrc -> pDrawable) == NotSynchronized) + if (pSrc -> pDrawable != NULL) { - #ifdef TEST - fprintf(stderr, "nxagentComposite: Synchronizing the source drawable [%p].\n", - (void *) pSrc -> pDrawable); - #endif + nxagentSynchronizeShmPixmap(pSrc -> pDrawable, xSrc, ySrc, width, height); - nxagentSynchronizeDrawable(pSrc -> pDrawable, DO_WAIT, NEVER_BREAK, NULL); + if (nxagentDrawableStatus(pSrc -> pDrawable) == NotSynchronized) + { + #ifdef TEST + fprintf(stderr, "nxagentComposite: Synchronizing the source drawable [%p].\n", + (void *) pSrc -> pDrawable); + #endif + + nxagentSynchronizeDrawable(pSrc -> pDrawable, DO_WAIT, NEVER_BREAK, NULL); + } } if (pDst -> pDrawable != pSrc -> pDrawable) @@ -2811,3 +2815,248 @@ Bool nxagentDisconnectAllPicture() return True; } +void nxagentRenderCreateSolidFill(PicturePtr pPicture, xRenderColor *color) +{ + Picture id; + + if (nxagentRenderEnable == False) + { + return; + } + + #ifdef DEBUG + + fprintf(stderr, "nxagentRenderCreateSolidFill: Got called.\n"); + + if (pPicture == NULL) + { + fprintf(stderr, "nxagentRenderCreateSolidFill: WARNING! pPicture pointer is NULL.\n"); + } + + if (color == NULL) + { + fprintf(stderr, "nxagentRenderCreateSolidFill: WARNING! color pointer is NULL.\n"); + } + + #endif /* #ifdef DEBUG */ + + memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, + sizeof(XRenderPictureAttributes_)); + + id = XRenderCreateSolidFill(nxagentDisplay, (XRenderColor *) color); + + #ifdef DEBUG + XSync(nxagentDisplay, 0); + #endif + + #ifdef TEST + fprintf(stderr, "nxagentRenderCreateSolidFill: Created solid fill xid [%lu].\n", id); + #endif + + nxagentPicturePriv(pPicture) -> picture = id; +} + +void nxagentRenderCreateLinearGradient(PicturePtr pPicture, xPointFixed *p1, + xPointFixed *p2, int nStops, + xFixed *stops, + xRenderColor *colors) +{ + Picture id; + + XLinearGradient linearGradient; + + if (nxagentRenderEnable == False) + { + return; + } + + #ifdef DEBUG + + fprintf(stderr, "nxagentRenderCreateLinearGradient: Got called.\n"); + + if (pPicture == NULL) + { + fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! pPicture pointer is NULL.\n"); + } + + if (p1 == NULL) + { + fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! p1 pointer is NULL.\n"); + } + + if (p2 == NULL) + { + fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! p2 pointer is NULL.\n"); + } + + if (stops == NULL) + { + fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! stops pointer is NULL.\n"); + } + + if (colors == NULL) + { + fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! colors pointer is NULL.\n"); + } + + #endif /* #ifdef DEBUG */ + + memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, + sizeof(XRenderPictureAttributes_)); + + linearGradient.p1.x = (XFixed) p1 -> x; + linearGradient.p1.y = (XFixed) p1 -> y; + linearGradient.p2.x = (XFixed) p2 -> x; + linearGradient.p2.y = (XFixed) p2 -> y; + + id = XRenderCreateLinearGradient(nxagentDisplay, &linearGradient, + (XFixed *) stops, + (XRenderColor *) colors, nStops); + + #ifdef DEBUG + XSync(nxagentDisplay, 0); + #endif + + #ifdef TEST + fprintf(stderr, "nxagentRenderCreateLinearGradient: Created linear gradient xid [%lu].\n", id); + #endif + + nxagentPicturePriv(pPicture) -> picture = id; +} + +void nxagentRenderCreateRadialGradient(PicturePtr pPicture, xPointFixed *inner, + xPointFixed *outer, + xFixed innerRadius, + xFixed outerRadius, + int nStops, + xFixed *stops, + xRenderColor *colors) +{ + Picture id; + + XRadialGradient radialGradient; + + if (nxagentRenderEnable == False) + { + return; + } + + #ifdef DEBUG + + fprintf(stderr, "nxagentRenderCreateRadialGradient: Got called.\n"); + + if (pPicture == NULL) + { + fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! pPicture pointer is NULL.\n"); + } + + if (inner == NULL) + { + fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! inner pointer is NULL.\n"); + } + + if (outer == NULL) + { + fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! outer pointer is NULL.\n"); + } + + if (stops == NULL) + { + fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! stops pointer is NULL.\n"); + } + + if (colors == NULL) + { + fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! colors pointer is NULL.\n"); + } + + #endif /* #ifdef DEBUG */ + + memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, + sizeof(XRenderPictureAttributes_)); + + radialGradient.inner.x = (XFixed) inner -> x; + radialGradient.inner.y = (XFixed) inner -> y; + radialGradient.inner.radius = (XFixed) innerRadius; + radialGradient.outer.x = (XFixed) outer -> x; + radialGradient.outer.y = (XFixed) outer -> y; + radialGradient.outer.radius = (XFixed) outerRadius; + + id = XRenderCreateRadialGradient(nxagentDisplay, &radialGradient, + (XFixed *) stops, + (XRenderColor *) colors, nStops); + + #ifdef DEBUG + XSync(nxagentDisplay, 0); + #endif + + #ifdef TEST + fprintf(stderr, "nxagentRenderCreateRadialGradient: Created radial gradient xid [%lu].\n", id); + #endif + + nxagentPicturePriv(pPicture) -> picture = id; +} + +void nxagentRenderCreateConicalGradient(PicturePtr pPicture, + xPointFixed *center, + xFixed angle, int nStops, + xFixed *stops, + xRenderColor *colors) +{ + Picture id; + + XConicalGradient conicalGradient; + + if (nxagentRenderEnable == False) + { + return; + } + + #ifdef DEBUG + + fprintf(stderr, "nxagentRenderCreateConicalGradient: Got called.\n"); + + if (pPicture == NULL) + { + fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! pPicture pointer is NULL.\n"); + } + + if (center == NULL) + { + fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! center pointer is NULL.\n"); + } + + if (stops == NULL) + { + fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! stops pointer is NULL.\n"); + } + + if (colors == NULL) + { + fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! colors pointer is NULL.\n"); + } + + #endif /* #ifdef DEBUG */ + + memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, + sizeof(XRenderPictureAttributes_)); + + conicalGradient.center.x = (XFixed) center -> x; + conicalGradient.center.y = (XFixed) center -> y; + conicalGradient.angle = (XFixed) angle; + + id = XRenderCreateConicalGradient(nxagentDisplay, &conicalGradient, + (XFixed *) stops, + (XRenderColor *) colors, nStops); + + #ifdef DEBUG + XSync(nxagentDisplay, 0); + #endif + + #ifdef TEST + fprintf(stderr, "nxagentRenderCreateConicalGradient: Created conical gradient xid [%lu].\n", id); + #endif + + nxagentPicturePriv(pPicture) -> picture = id; +} + diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.h b/nx-X11/programs/Xserver/hw/nxagent/Render.h index 240dc3901..4346a4e1e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -105,4 +105,6 @@ void nxagentDisconnectPicture(pointer p0, XID x1, void* p2); void nxagentReconnectGlyphSet(void* p0, XID x1, void *p2); +void nxagentDestroyPicture(PicturePtr pPicture); + #endif /* __Render_H__ */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c index 79cb74efa..612e71cf7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -60,6 +60,27 @@ typedef struct } nxagentWMHints; +/* + * This structure is compatible with 32 + * and 64 bit library interface. It has + * been copied from Xatomtype.h and it's + * a parameter of XChangeProperty(). + */ + +typedef struct +{ + unsigned long flags; + long input; + long initialState; + unsigned long iconPixmap; + unsigned long iconWindow; + long iconX; + long iconY; + unsigned long iconMask; + unsigned long windowGroup; +} +nxagentPropWMHints; + WindowPtr nxagentRootlessWindow = NULL; #define TOP_LEVEL_TABLE_UNIT 100 @@ -429,6 +450,7 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) Atom propertyX, typeX; char *output = NULL; nxagentWMHints wmHints; + nxagentPropWMHints propHints; Bool export = False; Bool freeMem = False; @@ -489,8 +511,22 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) wmHints.flags |= InputHint; wmHints.input = True; - output = (char*) &wmHints; - export = True; + /* + * Initialize the structure used in XChangeProperty(). + */ + + propHints.flags = wmHints.flags; + propHints.input = (wmHints.input == True ? 1 : 0); + propHints.initialState = wmHints.initial_state; + propHints.iconPixmap = wmHints.icon_pixmap; + propHints.iconWindow = wmHints.icon_window; + propHints.iconX = wmHints.icon_x; + propHints.iconY = wmHints.icon_y; + propHints.iconMask = wmHints.icon_mask; + propHints.windowGroup = wmHints.window_group; + + output = (char*) &propHints; + export = True; if ((wmHints.flags & IconPixmapHint) && (wmHints.icon_pixmap != None)) { @@ -504,17 +540,17 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) nxagentSynchronizeRegion((DrawablePtr) icon, NullRegion, NEVER_BREAK, NULL); } - wmHints.icon_pixmap = nxagentPixmap(icon); + propHints.iconPixmap = nxagentPixmap(icon); } else { - wmHints.flags &= ~IconPixmapHint; + propHints.flags &= ~IconPixmapHint; #ifdef WARNING fprintf(stderr, "nxagentExportProperty: WARNING! Failed to look up icon pixmap %x from hint " "exporting property %s type %s on window %p.\n", (unsigned int) wmHints.icon_pixmap, propertyS, typeS, - (void*)pWin); + (void *) pWin); #endif } } @@ -526,17 +562,17 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) if (icon) { - wmHints.icon_window = nxagentWindow(icon); + propHints.iconWindow = nxagentWindow(icon); } else { - wmHints.flags &= ~IconWindowHint; + propHints.flags &= ~IconWindowHint; #ifdef WARNING fprintf(stderr, "nxagentExportProperty: WARNING! Failed to look up icon window %x from hint " "exporting property %s type %s on window %p.\n", (unsigned int) wmHints.icon_window, propertyS, typeS, - (void*)pWin); + (void *) pWin); #endif } } @@ -548,17 +584,17 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) if (icon) { - wmHints.icon_mask = nxagentPixmap(icon); + propHints.iconMask = nxagentPixmap(icon); } else { - wmHints.flags &= ~IconMaskHint; + propHints.flags &= ~IconMaskHint; #ifdef WARNING fprintf(stderr, "nxagentExportProperty: WARNING! Failed to look up icon mask %x from hint " "exporting property %s type %s on window %p.\n", (unsigned int) wmHints.icon_mask, propertyS, typeS, - (void*)pWin); + (void *) pWin); #endif } } @@ -570,17 +606,17 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) if (window) { - wmHints.window_group = nxagentWindow(window); + propHints.windowGroup = nxagentWindow(window); } else { - wmHints.flags &= ~WindowGroupHint; + propHints.flags &= ~WindowGroupHint; #ifdef WARNING fprintf(stderr, "nxagentExportProperty: WARNING! Failed to look up window group %x from hint " "exporting property %s type %s on window %p.\n", (unsigned int) wmHints.window_group, propertyS, typeS, - (void*)pWin); + (void *) pWin); #endif } } @@ -590,6 +626,7 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) XlibAtom *atoms = malloc(nUnits * sizeof(*atoms)); Atom *input = value; int i; + int j = 0; freeMem = True; export = True; @@ -597,16 +634,40 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) for (i = 0; i < nUnits; i++) { - atoms[i] = nxagentLocalToRemoteAtom(input[i]); - - if (atoms[i] == None) - { - #ifdef WARNING - fprintf(stderr, "nxagentExportProperty: WARNING! Failed to convert local atom %ld [%s].\n", - (long int) input[i], validateString(NameForAtom(input[i]))); - #endif - } + /* + * Exporting the _NET_WM_PING property could + * result in rootless windows being grayed out + * when the compiz window manager is running. + * + * Better solution would probably be to handle + * the communication with the window manager + * instead of just getting rid of the property. + */ + + if (strcmp(NameForAtom(input[i]), "_NET_WM_PING") != 0) + { + atoms[j] = nxagentLocalToRemoteAtom(input[i]); + + if (atoms[j] == None) + { + #ifdef WARNING + fprintf(stderr, "nxagentExportProperty: WARNING! Failed to convert local atom %ld [%s].\n", + (long int) input[i], validateString(NameForAtom(input[i]))); + #endif + } + + j++; + } + #ifdef TEST + else + { + fprintf(stderr, "nxagentExportProperty: WARNING! " + "Not exporting the _NET_WM_PING property.\n"); + } + #endif } + + nUnits = j; } else if (strcmp(typeS, "WINDOW") == 0) { diff --git a/nx-X11/programs/Xserver/hw/nxagent/Rootless.h b/nx-X11/programs/Xserver/hw/nxagent/Rootless.h index 90d25d0c1..ece4c9d31 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Rootless.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Rootless.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.c b/nx-X11/programs/Xserver/hw/nxagent/Screen.c index 524bafd10..2db7df8fe 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -160,7 +160,6 @@ void nxagentPropagateArtsdProperties(ScreenPtr pScreen, char *port); #endif -Window nxagentIconWindow = None; Window nxagentFullscreenWindow = None; #ifdef VIEWPORT_FRAME @@ -288,166 +287,6 @@ void nxagentSetPixmapFormats(ScreenInfo *screenInfo) } } -void nxagentMinimizeFromFullScreen(ScreenPtr pScreen) -{ - XUnmapWindow(nxagentDisplay, nxagentFullscreenWindow); - - if(nxagentIpaq) - { - XMapWindow(nxagentDisplay, nxagentIconWindow); - XIconifyWindow(nxagentDisplay, nxagentIconWindow, - DefaultScreen(nxagentDisplay)); - } - else - { - XIconifyWindow(nxagentDisplay, nxagentIconWindow, - DefaultScreen(nxagentDisplay)); - } -} - -void nxagentMaximizeToFullScreen(ScreenPtr pScreen) -{ - if(nxagentIpaq) - { - XUnmapWindow(nxagentDisplay, nxagentIconWindow); - - XMapWindow(nxagentDisplay, nxagentFullscreenWindow); - } - else - { -/* - XUnmapWindow(nxagentDisplay, nxagentIconWindow); -*/ -/* -FIXME: We'll chech for ReparentNotify and LeaveNotify events after XReparentWindow() - in order to avoid the session window is iconified. - We could avoid the sesssion window is iconified when a LeaveNotify event is received, - so this check would be unnecessary. -*/ - struct timeval timeout; - int i; - XEvent e; - - XReparentWindow(nxagentDisplay, nxagentFullscreenWindow, - RootWindow(nxagentDisplay, DefaultScreen(nxagentDisplay)), 0, 0); - - for (i = 0; i < 100 && nxagentWMIsRunning; i++) - { - #ifdef TEST - fprintf(stderr, "nxagentSwitchFullscreen: WARNING! Going to wait for the ReparentNotify event.\n"); - #endif - - if (XCheckTypedWindowEvent(nxagentDisplay, nxagentFullscreenWindow, ReparentNotify, &e)) - { - break; - } - - XSync(nxagentDisplay, 0); - - timeout.tv_sec = 0; - timeout.tv_usec = 50 * 1000; - - nxagentWaitEvents(nxagentDisplay, &timeout); - } - - XMapRaised(nxagentDisplay, nxagentFullscreenWindow); - - XIconifyWindow(nxagentDisplay, nxagentIconWindow, - DefaultScreen(nxagentDisplay)); - - while (XCheckTypedWindowEvent(nxagentDisplay, nxagentFullscreenWindow, LeaveNotify, &e)); -/* - XMapWindow(nxagentDisplay, nxagentIconWindow); -*/ - } -} - -Window nxagentCreateIconWindow() -{ - XSetWindowAttributes attributes; - unsigned long valuemask; - char* window_name; - XTextProperty windowName; - XSizeHints sizeHints; - XWMHints wmHints; - Window w; - Mask mask; - - /* - * Create icon window. - */ - - attributes.override_redirect = False; - attributes.colormap = DefaultColormap(nxagentDisplay, DefaultScreen(nxagentDisplay)); - attributes.background_pixmap = nxagentScreenSaverPixmap; - valuemask = CWOverrideRedirect | CWBackPixmap | CWColormap; - - #ifdef TEST - fprintf(stderr, "nxagentCreateIconWindow: Going to create new icon window.\n"); - #endif - - w = XCreateWindow(nxagentDisplay, DefaultRootWindow(nxagentDisplay), - 0, 0, 1, 1, 0, - DefaultDepth(nxagentDisplay, DefaultScreen(nxagentDisplay)), - InputOutput, - DefaultVisual(nxagentDisplay, DefaultScreen(nxagentDisplay)), - valuemask, &attributes); - - #ifdef TEST - fprintf(stderr, "nxagentCreateIconWindow: Created new icon window with id [%ld].\n", - nxagentIconWindow); - #endif - - /* - * Set hints to the window manager for the icon window. - */ - - window_name = nxagentWindowName; - XStringListToTextProperty(&window_name, 1, &windowName); - sizeHints.flags = PMinSize | PMaxSize; - sizeHints.min_width = sizeHints.max_width = 1; - sizeHints.min_height = sizeHints.max_height = 1; - wmHints.flags = IconPixmapHint | IconMaskHint; - wmHints.initial_state = IconicState; - wmHints.icon_pixmap = nxagentIconPixmap; - - if (useXpmIcon) - { - wmHints.icon_mask = nxagentIconShape; - wmHints.flags = IconPixmapHint | IconMaskHint; - } - else - { - wmHints.flags = StateHint | IconPixmapHint; - } - - XSetWMProperties(nxagentDisplay, w, - &windowName, &windowName, - NULL , 0 , &sizeHints, &wmHints, NULL); - - /* - * Enable events from the icon window. - */ - - nxagentGetDefaultEventMask(&mask); - - XSelectInput(nxagentDisplay, w, (mask & ~(KeyPressMask | - KeyReleaseMask)) | StructureNotifyMask); - - /* - * Notify to client if user closes icon window. - */ - - if (nxagentWMIsRunning && !nxagentOption(Rootless)) - { - XlibAtom deleteWMAtom = nxagentAtoms[2]; /* WM_DELETE_WINDOW */ - - XSetWMProtocols(nxagentDisplay, w, &deleteWMAtom, 1); - } - - return w; -} - Bool nxagentMagicPixelZone(int x, int y) { return (x >= nxagentOption(Width) - 1 && y < 1); @@ -977,6 +816,8 @@ Bool nxagentOpenScreen(int index, ScreenPtr pScreen, nxagentChangeOption(Fullscreen, False); + nxagentFullscreenWindow = 0; + resetAgentPosition = True; } @@ -1382,8 +1223,6 @@ N/A if (nxagentOption(Fullscreen)) { - attributes.override_redirect = True; - /* * We need to disable the host's screensaver or * it will otherwise grab the screen even if it @@ -1609,8 +1448,7 @@ N/A if (nxagentDoFullGeneration == 1 || nxagentReconnectTrap == 1) { - valuemask = CWBackPixel | CWEventMask | CWColormap | - (nxagentOption(Fullscreen) == 1 ? CWOverrideRedirect : 0); + valuemask = CWBackPixel | CWEventMask | CWColormap; attributes.background_pixel = nxagentBlackPixel; @@ -1620,8 +1458,6 @@ N/A if (nxagentOption(Fullscreen) == 1) { - attributes.override_redirect = True; - if (nxagentReconnectTrap) { /* @@ -1754,7 +1590,7 @@ N/A sizeHints.width = nxagentOption(RootWidth); sizeHints.height = nxagentOption(RootHeight); - if (nxagentOption(DesktopResize) == 1) + if (nxagentOption(DesktopResize) == 1 || nxagentOption(Fullscreen) == 1) { sizeHints.max_width = WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); sizeHints.max_height = HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); @@ -1799,37 +1635,6 @@ N/A XClearWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum]); - if (nxagentOption(Fullscreen)) - { - valuemask = CWBackPixmap | CWColormap | CWOverrideRedirect; - } - else - { - valuemask = CWBackPixmap | CWColormap; - } - - attributes.background_pixmap = nxagentScreenSaverPixmap; - attributes.colormap = DefaultColormap(nxagentDisplay, DefaultScreen(nxagentDisplay)); - - if (nxagentOption(Fullscreen)) - { - attributes.override_redirect = False; - if (nxagentReconnectTrap) - { - XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, True, GrabModeAsync, - GrabModeAsync, CurrentTime); - } - } - - if (nxagentOption(Fullscreen)) - { - nxagentIconWindow = nxagentCreateIconWindow(); - } - else - { - nxagentIconWindow = 0; - } - /* * When we don't have window manager we grab keyboard * to let nxagent get keyboard events. @@ -1880,13 +1685,6 @@ N/A */ XSetWMProtocols(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], &deleteWMatom, 1); - - /* - if (nxagentOption(Fullscreen)) - { - XSetWMProtocols(nxagentDisplay, nxagentIconWindow, &deleteWMatom, 1); - } - */ } else { @@ -2266,13 +2064,10 @@ FIXME: We should try to restore the previously if (nxagentOption(Fullscreen)) { - nxagentChangeOption(Width, WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - nxagentChangeOption(Height, HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - - nxagentChangeOption(RootX, (WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)) - - nxagentOption(RootWidth)) / 2); - nxagentChangeOption(RootY, (HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)) - - nxagentOption(RootHeight)) / 2); + nxagentChangeOption(RootX, (nxagentOption(Width) - + nxagentOption(RootWidth)) / 2); + nxagentChangeOption(RootY, (nxagentOption(Height) - + nxagentOption(RootHeight)) / 2); } else { @@ -2283,62 +2078,6 @@ FIXME: We should try to restore the previously nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - nxagentOption(RootWidth)); nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - nxagentOption(RootHeight)); - /* - * Change agent window size and size hints. - */ - - sizeHints.flags = PPosition | PMinSize | PMaxSize; - sizeHints.x = nxagentOption(X); - sizeHints.y = nxagentOption(Y); - - sizeHints.min_width = MIN_NXAGENT_WIDTH; - sizeHints.min_height = MIN_NXAGENT_HEIGHT; - sizeHints.width = width; - sizeHints.height = height; - - if (nxagentOption(DesktopResize) == 1) - { - sizeHints.max_width = WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); - sizeHints.max_height = HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); - } - else - { - sizeHints.max_width = nxagentOption(RootWidth); - sizeHints.max_height = nxagentOption(RootHeight); - } - - if (nxagentUserGeometry.flag & XValue || nxagentUserGeometry.flag & YValue) - { - sizeHints.flags |= USPosition; - } - - if (nxagentUserGeometry.flag & WidthValue || nxagentUserGeometry.flag & HeightValue) - { - sizeHints.flags |= USSize; - } - - XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], &sizeHints); - - if (nxagentOption(Fullscreen)) - { - XResizeWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], - WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)), - HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - - XResizeWindow(nxagentDisplay, nxagentInputWindows[pScreen -> myNum], - WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)), - HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - } - else - { - XResizeWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], width, height); - - if (nxagentOption(Rootless) == 0) - { - XResizeWindow(nxagentDisplay, nxagentInputWindows[pScreen -> myNum], width, height); - } - } - /* * Set properties for the agent root window. */ @@ -2360,8 +2099,6 @@ FIXME: We should try to restore the previously (*pScreen -> PositionWindow)(WindowTable[pScreen -> myNum], 0, 0); - pRootWinSize = &WindowTable[pScreen -> myNum] -> winSize; - nxagentSetRootClip(pScreen, 1); XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[0]), @@ -2369,12 +2106,17 @@ FIXME: We should try to restore the previously nxagentMoveViewport(pScreen, 0, 0); + /* + * Update pointer bounds. + */ + + ScreenRestructured(pScreen); + #ifdef TEST nxagentPrintAgentGeometry("After Resize Screen", "nxagentResizeScreen:"); #endif - fprintf(stderr, "Info: Screen [%d] resized to geometry [%dx%d].\n", - pScreen -> myNum, width, height); + nxagentSetPrintGeometry(pScreen -> myNum); return 1; @@ -2451,9 +2193,10 @@ int nxagentShadowInit(ScreenPtr pScreen, WindowPtr pWin) #endif #ifdef TEST - fprintf(stderr, "Info: Init shadow session. nxagentDisplayName [%s] nxagentDisplay " - "[%p] nxagentShadowDisplayName [%s].\n", nxagentDisplayName, - (void *) nxagentDisplay, nxagentShadowDisplayName); + fprintf(stderr, "Info: Init shadow session. nxagentDisplayName [%s] " + "nxagentDisplay [%p] nxagentShadowDisplayName [%s].\n", + nxagentDisplayName, (void *) nxagentDisplay, + nxagentShadowDisplayName); #endif if (nxagentKeyboard != NULL) @@ -2463,7 +2206,7 @@ int nxagentShadowInit(ScreenPtr pScreen, WindowPtr pWin) if(nxagentKeyboard[i] == 0 || nxagentKeyboard[i + 1] == 0 || i == 0) { #ifdef WARNING - fprintf(stderr,"Warning: Wrong keyboard type: %s.\n", nxagentKeyboard); + fprintf(stderr,"WARNING! Wrong keyboard type: %s.\n", nxagentKeyboard); #endif } else @@ -2475,7 +2218,8 @@ int nxagentShadowInit(ScreenPtr pScreen, WindowPtr pWin) } #ifdef DEBUG - fprintf(stderr, "nxagentShadowInit: Setting the master uid [%d].\n", nxagentShadowUid); + fprintf(stderr, "nxagentShadowInit: Setting the master uid [%d].\n", + nxagentShadowUid); #endif #if !defined (__CYGWIN32__) && !defined (WIN32) @@ -2495,8 +2239,9 @@ int nxagentShadowInit(ScreenPtr pScreen, WindowPtr pWin) if (NXShadowCreate(nxagentDisplay, layout, nxagentShadowDisplayName, (void *) &nxagentShadowDisplay) != 1) { - #ifdef TEST - fprintf(stderr, "nxagentShadowInit: Failed to initialize shadow display [%s].\n", nxagentShadowDisplayName); + #ifdef PANIIC + fprintf(stderr, "nxagentShadowInit: PANIC! Failed to initialize shadow " + "display [%s].\n", nxagentShadowDisplayName); #endif return -1; @@ -2519,8 +2264,8 @@ int nxagentShadowInit(ScreenPtr pScreen, WindowPtr pWin) if (NXShadowAddUpdaterDisplay(nxagentDisplay, &nxagentShadowWidth, &nxagentShadowHeight, &nxagentMasterDepth) == 0) { - #ifdef TEST - fprintf(stderr, "nxagentShadowInit: Failed to add display [%s].\n", + #ifdef PANIC + fprintf(stderr, "nxagentShadowInit: PANIC! Failed to add display [%s].\n", nxagentDisplayName); #endif @@ -2540,16 +2285,73 @@ int nxagentShadowInit(ScreenPtr pScreen, WindowPtr pWin) nxagentOption(RootHeight) * 1.0 / nxagentShadowHeight); } - if (DefaultVisualOfScreen(DefaultScreenOfDisplay(nxagentDisplay)) -> class != TrueColor || - DefaultVisualOfScreen(DefaultScreenOfDisplay(nxagentShadowDisplay)) -> class != TrueColor) + if (DefaultVisualOfScreen(DefaultScreenOfDisplay(nxagentDisplay)) -> + class != TrueColor) { - #ifdef TEST - fprintf(stderr, "nxagentShadowInit: PANIC! The visual class is not TrueColor.\n"); + #ifdef PANIC + fprintf(stderr, "nxagentShadowInit: PANIC! The visual class of the remote " + "X server is not TrueColor.\n"); #endif return -1; } + if (DefaultVisualOfScreen(DefaultScreenOfDisplay(nxagentShadowDisplay)) -> + class != TrueColor) + { + #ifdef PANIC + + const char *className; + + switch (DefaultVisualOfScreen(DefaultScreenOfDisplay(nxagentShadowDisplay)) -> class) + { + case StaticGray: + { + className = "StaticGray"; + + break; + } + case StaticColor: + { + className = "StaticColor"; + + break; + } + case PseudoColor: + { + className = "PseudoColor"; + + break; + } + case DirectColor: + { + className = "DirectColor"; + + break; + } + case GrayScale: + { + className = "GrayScale"; + + break; + } + default: + { + className = ""; + + break; + } + } + + fprintf(stderr, "nxagentShadowInit: PANIC! Cannot shadow the display. " + "%s visual class is not supported. Only TrueColor visuals " + "are supported.\n", className); + + #endif /* #endif PANIC */ + + return -1; + } + #endif nxagentShadowDepth = pScreen -> rootDepth; @@ -2566,7 +2368,8 @@ int nxagentShadowInit(ScreenPtr pScreen, WindowPtr pWin) else if (nxagentShadowDepth == 8) { #ifdef PANIC - fprintf(stderr, "nxagentShadowInit: PANIC! The target depth is 8 bit.\n"); + fprintf(stderr, "nxagentShadowInit: PANIC! Unable to shadow a %d bit " + "display with a 8 bit screen depth.\n", nxagentMasterDepth); #endif return -1; @@ -2585,7 +2388,8 @@ int nxagentShadowInit(ScreenPtr pScreen, WindowPtr pWin) else if (nxagentShadowDepth == 8) { #ifdef PANIC - fprintf(stderr, "nxagentShadowInit: PANIC! The target depth is 8 bit.\n"); + fprintf(stderr, "nxagentShadowInit: PANIC! Unable to shadow a 16 bit " + "display with a 8 bit screen depth.\n"); #endif return -1; @@ -2600,7 +2404,8 @@ int nxagentShadowInit(ScreenPtr pScreen, WindowPtr pWin) if (nxagentShadowDepth != 8) { #ifdef PANIC - fprintf(stderr, "nxagentShadowInit: PANIC! The target depth is 8 bit.\n"); + fprintf(stderr, "nxagentShadowInit: PANIC! Unable to shadow a 8 bit " + "display with a %d bit screen depth.\n", nxagentShadowDepth); #endif return -1; @@ -3046,7 +2851,7 @@ void nxagentShadowAdaptDepth(unsigned int width, unsigned int height, #ifdef WARNING fprintf(stderr, "nxagentCorrectDepthShadow: WARNING! Visual not found. Using default visual.\n"); #endif - + pVisual = nxagentVisuals[nxagentDefaultVisualIndex].visual; } @@ -3473,10 +3278,10 @@ int nxagentRRSetScreenConfig(ScreenPtr pScreen, int width, int height) RRScreenSizePtr oldSizes; pScrPriv = rrGetScrPriv(pScreen); - + oldWidth = pScreen->width; oldHeight = pScreen->height; - + if (!pScrPriv) { return 1; @@ -3556,7 +3361,7 @@ int nxagentRRSetScreenConfig(ScreenPtr pScreen, int width, int height) } RREditConnectionInfo (pScreen); - + /* * Fix pointer bounds and location */ @@ -3694,7 +3499,8 @@ void nxagentSaveAreas(PixmapPtr pPixmap, RegionPtr prgnSave, int xorg, int yorg, return; } -void nxagentRestoreAreas(PixmapPtr pPixmap, RegionPtr prgnRestore, int xorg, int yorg, WindowPtr pWin) +void nxagentRestoreAreas(PixmapPtr pPixmap, RegionPtr prgnRestore, int xorg, + int yorg, WindowPtr pWin) { PixmapPtr pVirtualPixmap; RegionPtr clipRegion; @@ -3710,6 +3516,14 @@ void nxagentRestoreAreas(PixmapPtr pPixmap, RegionPtr prgnRestore, int xorg, int BoxRec extents; miBSWindowPtr pBackingStore; + /* + * Limit the area to restore to the + * root window size. + */ + + REGION_INTERSECT(pWin -> pScreen, prgnRestore, prgnRestore, + &WindowTable[pWin -> drawable.pScreen -> myNum] -> winSize); + pBackingStore = (miBSWindowPtr) pWin -> backStorage; pVirtualPixmap = nxagentVirtualPixmap(pPixmap); @@ -3903,6 +3717,24 @@ void nxagentShadowAdaptToRatio(void) REGION_UNINIT(pScreen, ®ion); } +void nxagentPrintGeometry() +{ + int i; + + for (i = 0; i < screenInfo.numScreens; i++) + { + if (nxagentPrintGeometryFlags && (1 << i)) + { + fprintf(stderr, "Info: Screen [%d] resized to geometry [%dx%d] " + "fullscreen [%d].\n", i, screenInfo.screens[i] -> width, + screenInfo.screens[i] -> height, + nxagentOption(Fullscreen)); + } + } + + nxagentPrintGeometryFlags = 0; +} + #ifdef DUMP void nxagentShowPixmap(PixmapPtr pPixmap, int x, int y, int width, int height) diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.h b/nx-X11/programs/Xserver/hw/nxagent/Screen.h index 3550dd553..1ab6caad2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -36,6 +36,9 @@ is" without express or implied warranty. #define MIN_NXAGENT_HEIGHT 60 #define NXAGENT_FRAME_WIDTH 2000 +#define nxagentSetPrintGeometry(screen) \ + nxagentPrintGeometryFlags = (1 << (screen)); + extern int nxagentClients; extern int nxagentAutoDisconnectTimeout; @@ -44,7 +47,6 @@ extern ScreenPtr nxagentDefaultScreen; extern Pixmap nxagentPixmapLogo; -extern Window nxagentIconWindow; extern Window nxagentFullscreenWindow; extern RegionRec nxagentShadowUpdateRegion; @@ -58,6 +60,8 @@ extern short nxagentShadowUid; void nxagentSetScreenInfo(ScreenInfo *screenInfo); void nxagentSetPixmapFormats(ScreenInfo *screenInfo); +void nxagentPrintGeometry(); + extern Window nxagentDefaultWindows[MAXSCREENS]; extern Window nxagentInputWindows[MAXSCREENS]; extern Window nxagentScreenSaverWindows[MAXSCREENS]; @@ -83,11 +87,6 @@ extern int nxagentBitsPerPixel(int depth); void nxagentSetScreenSaverTime(void); -void nxagentMinimizeFromFullScreen(ScreenPtr pScreen); -void nxagentMaximizeToFullScreen(ScreenPtr pScreen); - -Window nxagentCreateIconWindow(void); - Bool nxagentMagicPixelZone(int x, int y); Bool nxagentResizeScreen(ScreenPtr pScreen, int width, int height, diff --git a/nx-X11/programs/Xserver/hw/nxagent/Splash.c b/nx-X11/programs/Xserver/hw/nxagent/Splash.c index 8de74b85b..24dbf1413 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Splash.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Splash.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Splash.h b/nx-X11/programs/Xserver/hw/nxagent/Splash.h index bcc3a90b1..86920ad8b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Splash.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Splash.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Split.c b/nx-X11/programs/Xserver/hw/nxagent/Split.c index 8f1c65eba..bf7f705b9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Split.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Split.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Split.h b/nx-X11/programs/Xserver/hw/nxagent/Split.h index 397feef16..60be29b39 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Split.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Split.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/TestExt.c b/nx-X11/programs/Xserver/hw/nxagent/TestExt.c index 704c63e51..1d5fdee20 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/TestExt.c +++ b/nx-X11/programs/Xserver/hw/nxagent/TestExt.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.c b/nx-X11/programs/Xserver/hw/nxagent/Trap.c index 2796b2f14..22de3bc1b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Trap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.h b/nx-X11/programs/Xserver/hw/nxagent/Trap.h index 493a18a1b..aa6937e70 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Trap.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Utils.h b/nx-X11/programs/Xserver/hw/nxagent/Utils.h index 9334a7868..830b2753f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Utils.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Utils.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Visual.c b/nx-X11/programs/Xserver/hw/nxagent/Visual.c index 2a8283a30..f38931677 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Visual.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Visual.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Visual.h b/nx-X11/programs/Xserver/hw/nxagent/Visual.h index 6d8a8742d..c682f92dd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Visual.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Visual.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Window.c b/nx-X11/programs/Xserver/hw/nxagent/Window.c index 8da5d8bd1..2da21b91c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Window.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Window.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -692,222 +692,91 @@ void nxagentRestackWindow(WindowPtr pWin, WindowPtr pOldNextSib) void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn) { - Window w; - XSetWindowAttributes attributes; - unsigned long valuemask; + XEvent e; + XSizeHints sizeHints; - if (nxagentOption(Rootless)) + if (nxagentOption(Rootless) == 1) { return; } - if (!switchOn) + if (switchOn == 0) { nxagentWMDetect(); - if (!nxagentWMIsRunning) - { - #ifdef WARNING - fprintf(stderr, "Warning: Can't switch to window mode, no window manager has been detected.\n"); - #endif - - return; - } - } - - w = nxagentDefaultWindows[pScreen -> myNum]; - attributes.override_redirect = switchOn; - valuemask = CWOverrideRedirect; - XUnmapWindow(nxagentDisplay, w); - XChangeWindowAttributes(nxagentDisplay, w, valuemask, &attributes); - - if (switchOn) - { /* - * Change to fullscreen mode. + * The smart scheduler could be stopped while + * waiting for the reply. In this case we need + * to yield explicitly to avoid to be stuck in + * the dispatch loop forever. */ - struct timeval timeout; - int i; - XEvent e; - - /* - * Wait for window manager reparenting the default window. - */ + isItTimeToYield = 1; - for (i = 0; i < 100 && nxagentWMIsRunning; i++) + if (nxagentWMIsRunning == 0) { - #ifdef TEST - fprintf(stderr, "nxagentSwitchFullscreen: WARNING! Going to wait for the ReparentNotify event.\n"); + #ifdef WARNING + fprintf(stderr, "Warning: Can't switch to window mode, no window manager " + "has been detected.\n"); #endif - if (XCheckTypedWindowEvent(nxagentDisplay, w, ReparentNotify, &e)) - { - break; - } - - /* - * This should also flush - * the NX link for us. - */ - - XSync(nxagentDisplay, 0); - - timeout.tv_sec = 0; - timeout.tv_usec = 50 * 1000; - - nxagentWaitEvents(nxagentDisplay, &timeout); + return; } + } - if (i < 100) - { - /* - * The window manager has done with the reparent - * operation. We can resize and map the window. - */ - - nxagentChangeOption(Fullscreen, True); - - /* - * Save the window-mode configuration. - */ - - nxagentChangeOption(SavedX, nxagentOption(X)); - nxagentChangeOption(SavedY, nxagentOption(Y)); - nxagentChangeOption(SavedWidth, nxagentOption(Width)); - nxagentChangeOption(SavedHeight, nxagentOption(Height)); - nxagentChangeOption(SavedRootWidth, nxagentOption(RootWidth)); - nxagentChangeOption(SavedRootHeight, nxagentOption(RootHeight)); - - /* - * Reconf the Default window. - */ - - nxagentChangeOption(X, 0); - nxagentChangeOption(Y, 0); - nxagentChangeOption(Width, WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - nxagentChangeOption(Height, HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - - /* - * Move the root window. - */ - - nxagentChangeOption(RootX, (nxagentOption(Width) - nxagentOption(RootWidth)) / 2); - nxagentChangeOption(RootY, (nxagentOption(Height) - nxagentOption(RootHeight)) / 2); - nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - nxagentOption(RootWidth)); - nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - nxagentOption(RootHeight)); - - XMoveResizeWindow(nxagentDisplay, w, nxagentOption(X), nxagentOption(Y), - nxagentOption(Width), nxagentOption(Height)); - - nxagentUpdateViewportFrame(0, 0, nxagentOption(RootWidth), nxagentOption(RootHeight)); - - XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), - nxagentOption(RootX), nxagentOption(RootY)); - - /* - * We disable the screensaver when changing - * mode to fullscreen. Is it really needed? - */ - - XSetScreenSaver(nxagentDisplay, 0, 0, DefaultExposures, DefaultBlanking); - - if (nxagentIconWindow == None) - { - nxagentIconWindow = nxagentCreateIconWindow(); + #ifdef TEST + fprintf(stderr, "nxagentSwitchFullscreen: Switching to %s mode.\n", + switchOn ? "fullscreen" : "windowed"); + #endif - XMapWindow(nxagentDisplay, nxagentIconWindow); - } + nxagentChangeOption(Fullscreen, switchOn); - XMapRaised(nxagentDisplay, w); - XSetInputFocus(nxagentDisplay, w, RevertToParent, CurrentTime); - XCheckTypedWindowEvent(nxagentDisplay, w, LeaveNotify, &e); - nxagentFullscreenWindow = w; + if (nxagentOption(DesktopResize) == 1) + { + sizeHints.flags = PSize; - if (nxagentOption(DesktopResize) == 1) - { - if (nxagentOption(Shadow) == 0) - { - nxagentRRSetScreenConfig(pScreen, WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)), - HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - } - else - { - nxagentShadowAdaptToRatio(); - } - } - } - else + if (switchOn == 1) { - /* - * We have waited for a reparent event unsuccessfully. - * Something happened to the window manager. - */ - - #ifdef WARNING - fprintf(stderr, "nxagentSwitchFullscreen: WARNING! Expected ReparentNotify event missing.\n"); - #endif - - nxagentWMIsRunning = False; - attributes.override_redirect = False; - XChangeWindowAttributes(nxagentDisplay, w, valuemask, &attributes); - XMapWindow(nxagentDisplay, w); + sizeHints.width = + WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); + sizeHints.height = + HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); } - } - else - { - /* - * FIXME: - * It could be necessary: - * - To restore screensaver. - * - To set or reset nxagentForceBackingStore flag. - * - To grab keyboard. - * - To propagate device settings to the X server if no WM is running. - */ - - /* - * Change to windowed mode. - */ - - nxagentChangeOption(Fullscreen, False); - XDestroyWindow(nxagentDisplay, nxagentIconWindow); - nxagentIconWindow = nxagentFullscreenWindow = None; - - if (nxagentOption(DesktopResize) == 1) + else { - nxagentChangeOption(RootWidth, nxagentOption(SavedRootWidth)); - nxagentChangeOption(RootHeight, nxagentOption(SavedRootHeight)); - - if (nxagentOption(Shadow) == 0) - { - nxagentRRSetScreenConfig(pScreen, nxagentOption(RootWidth), nxagentOption(RootHeight)); - } + sizeHints.width = nxagentOption(RootWidth); + sizeHints.height = nxagentOption(RootHeight); } - nxagentChangeOption(X, nxagentOption(SavedX)); - nxagentChangeOption(Y, nxagentOption(SavedY)); - nxagentChangeOption(Width, nxagentOption(SavedWidth)); - nxagentChangeOption(Height, nxagentOption(SavedHeight)); + XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], + &sizeHints); + } - if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1) - { - nxagentShadowAdaptToRatio(); - } + memset(&e, 0, sizeof(e)); - XMoveResizeWindow(nxagentDisplay, w, nxagentOption(X), nxagentOption(Y), - nxagentOption(Width), nxagentOption(Height)); + e.xclient.type = ClientMessage; + e.xclient.message_type = nxagentAtoms[13]; /* _NET_WM_STATE */ + e.xclient.display = nxagentDisplay; + e.xclient.window = nxagentDefaultWindows[pScreen -> myNum]; + e.xclient.format = 32; + e.xclient.data.l[0] = nxagentOption(Fullscreen) ? 1 : 0; + e.xclient.data.l[1] = nxagentAtoms[14]; /* _NET_WM_STATE_FULLSCREEN */ - nxagentUpdateViewportFrame(0, 0, nxagentOption(Width), nxagentOption(Height)); + XSendEvent(nxagentDisplay, DefaultRootWindow(nxagentDisplay), False, + SubstructureRedirectMask, &e); - XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), 0, 0); - XMapWindow(nxagentDisplay, w); + if (switchOn == 1) + { + nxagentFullscreenWindow = nxagentDefaultWindows[pScreen -> myNum]; - nxagentChangeOption(RootX, 0); - nxagentChangeOption(RootY, 0); + nxagentGrabPointerAndKeyboard(NULL); } + else + { + nxagentFullscreenWindow = None; - XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, - nxagentOption(Width), nxagentOption(Height)); + nxagentUngrabPointerAndKeyboard(NULL); + } } #ifdef VIEWPORT_FRAME @@ -2409,6 +2278,11 @@ void nxagentMapDefaultWindows() #endif XMapWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum]); + + if (nxagentOption(Fullscreen) == 1 && nxagentWMIsRunning == 1) + { + nxagentSwitchFullscreen(pScreen, 1); + } } /* @@ -2438,26 +2312,6 @@ void nxagentMapDefaultWindows() nxagentDefaultWindows[i], CurrentTime); } - /* - * Map the icon window. - */ - - if (nxagentIconWindow != 0) - { - #ifdef TEST - fprintf(stderr, "nxagentMapDefaultWindows: Mapping icon window id [%ld].\n", - nxagentIconWindow); - #endif - - XMapWindow(nxagentDisplay, nxagentIconWindow); - - if (nxagentIpaq != 0) - { - XIconifyWindow(nxagentDisplay, nxagentIconWindow, - DefaultScreen(nxagentDisplay)); - } - } - /* * Ensure that the fullscreen window gets the focus. */ @@ -2895,6 +2749,13 @@ FIXME: Do we need to set save unders attribute here? XSizeHints *props, hints; unsigned char *data = NULL; + #ifdef _XSERVER64 + + unsigned char *data64 = NULL; + unsigned int i; + + #endif + hints.flags = 0; ret = GetWindowProperty(pWin, @@ -2903,10 +2764,13 @@ FIXME: Do we need to set save unders attribute here? False, XA_WM_SIZE_HINTS, &type, &format, &nItems, &bytesLeft, &data); - props = (XSizeHints*) data; + /* + * 72 is the number of bytes returned by + * sizeof(XSizeHints) on 32 bit platforms. + */ if (ret == Success && - ((format >> 3) * nItems) == sizeof(XSizeHints) && + ((format >> 3) * nItems) == 72 && bytesLeft == 0 && type == XA_WM_SIZE_HINTS) { @@ -2915,6 +2779,30 @@ FIXME: Do we need to set save unders attribute here? (void*)pWin, pWin -> drawable.id, nxagentWindow(pWin)); #endif + #ifdef _XSERVER64 + + data64 = (unsigned char *) malloc(sizeof(XSizeHints) + 4); + + for (i = 0; i < 4; i++) + { + *(data64 + i) = *(data + i); + } + + *(((int *) data64) + 1) = 0; + + for (i = 8; i < sizeof(XSizeHints) + 4; i++) + { + *(data64 + i) = *(data + i - 4); + } + + props = (XSizeHints *) data64; + + #else + + props = (XSizeHints *) data; + + #endif /* _XSERVER64 */ + hints = *props; } else @@ -2933,6 +2821,15 @@ FIXME: Do we need to set save unders attribute here? XSetWMNormalHints(nxagentDisplay, nxagentWindow(pWin), &hints); + + #ifdef _XSERVER64 + + if (data64 != NULL) + { + free(data64); + } + + #endif } } diff --git a/nx-X11/programs/Xserver/hw/nxagent/Windows.h b/nx-X11/programs/Xserver/hw/nxagent/Windows.h index ca33f1448..6fc97b341 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Windows.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Windows.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c index c49f1587f..7bc1c74cb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original index c49f1587f..7bc1c74cb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c index f84ca0e03..ba4e1e662 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -513,13 +513,6 @@ Dispatch(void) * completed. We can now handle our clients. */ - if (serverGeneration > nxagentMaxAllowedResets) - { - fprintf(stderr, "Session: Session started at '%s'.\n", GetTimeAsString()); - - nxagentSessionState = SESSION_UP; - } - #ifdef XKB nxagentInitXkbWrapper(); @@ -603,6 +596,21 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio clientReady[1] = NXAGENT_WAKEUP; } + if (serverGeneration > nxagentMaxAllowedResets && + nxagentSessionState == SESSION_STARTING && + (nxagentOption(Xdmcp) == 0 || nxagentXdmcpUp == 1)) + { + #ifdef NX_DEBUG_INPUT + fprintf(stderr, "Session: Session started at '%s' timestamp [%lu].\n", + GetTimeAsString(), GetTimeInMillis()); + #else + fprintf(stderr, "Session: Session started at '%s'.\n", + GetTimeAsString()); + #endif + + nxagentSessionState = SESSION_UP; + } + #ifdef BLOCKS fprintf(stderr, "[End dispatch]\n"); #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original index f84ca0e03..ba4e1e662 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -513,13 +513,6 @@ Dispatch(void) * completed. We can now handle our clients. */ - if (serverGeneration > nxagentMaxAllowedResets) - { - fprintf(stderr, "Session: Session started at '%s'.\n", GetTimeAsString()); - - nxagentSessionState = SESSION_UP; - } - #ifdef XKB nxagentInitXkbWrapper(); @@ -603,6 +596,21 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio clientReady[1] = NXAGENT_WAKEUP; } + if (serverGeneration > nxagentMaxAllowedResets && + nxagentSessionState == SESSION_STARTING && + (nxagentOption(Xdmcp) == 0 || nxagentXdmcpUp == 1)) + { + #ifdef NX_DEBUG_INPUT + fprintf(stderr, "Session: Session started at '%s' timestamp [%lu].\n", + GetTimeAsString(), GetTimeInMillis()); + #else + fprintf(stderr, "Session: Session started at '%s'.\n", + GetTimeAsString()); + #endif + + nxagentSessionState = SESSION_UP; + } + #ifdef BLOCKS fprintf(stderr, "[End dispatch]\n"); #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c index b431796be..225ecdaf8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original index b431796be..225ecdaf8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c index a8a2a68bd..8e87d58c4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -191,6 +191,7 @@ xEvent *xeviexE; #ifdef NX_DEBUG_INPUT extern int nxagentDebugInput; +extern int nxagentDebugInputDevices; #endif extern Display *nxagentDisplay; @@ -1865,6 +1866,12 @@ DeliverEventsToWindow(register WindowPtr pWin, xEvent *pEvents, int count, tempGrab.pointerMode = GrabModeAsync; tempGrab.confineTo = NullWindow; tempGrab.cursor = NullCursor; + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "DeliverEventsToWindow: Activating passive grab on pointer.\n"); + } + #endif (*inputInfo.pointer->ActivateGrab)(inputInfo.pointer, &tempGrab, currentTime, TRUE); } @@ -2735,6 +2742,13 @@ CheckPassiveGrabsOnWindow( tempGrab.modifiersDetail.exact&(~0x1f00); } #endif + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "CheckPassiveGrabsOnWindow: Activating passive grab on %s.\n", + device == inputInfo.keyboard ? "keyboard" : "pointer"); + } + #endif (*device->ActivateGrab)(device, grab, currentTime, TRUE); FixUpEventFromWindow(xE, grab->window, None, TRUE); @@ -3093,7 +3107,17 @@ drawable.id:0; else DeliverFocusedEvent(keybd, xE, sprite.win, count); if (deactivateGrab) + #ifdef NX_DEBUG_INPUT + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcessKeyboardEvent: Deactivating grab on keyboard.\n"); + } + #endif (*keybd->DeactivateGrab)(keybd); + #ifdef NX_DEBUG_INPUT + } + #endif } #ifdef XKB @@ -3320,7 +3344,17 @@ ProcessPointerEvent (register xEvent *xE, register DeviceIntPtr mouse, int count mouse, count); #endif if (deactivateGrab) + #ifdef NX_DEBUG_INPUT + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcessPointerEvent: Deactivating grab on pointer.\n"); + } + #endif (*mouse->DeactivateGrab)(mouse); + #ifdef NX_DEBUG_INPUT + } + #endif } #define AtMostOneClient \ @@ -4041,6 +4075,12 @@ ProcGrabPointer(ClientPtr client) pWin = SecurityLookupWindow(stuff->grabWindow, client, SecurityReadAccess); if (!pWin) return BadWindow; + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcGrabPointer: pWin [%p] client [%d].\n", pWin, client -> index); + } + #endif if (stuff->confineTo == None) confineTo = NullWindow; else @@ -4100,6 +4140,12 @@ ProcGrabPointer(ClientPtr client) tempGrab.keyboardMode = stuff->keyboardMode; tempGrab.pointerMode = stuff->pointerMode; tempGrab.device = device; + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcGrabPointer: Activating active grab on pointer.\n"); + } + #endif (*device->ActivateGrab)(device, &tempGrab, time, FALSE); if (oldCursor) FreeCursor (oldCursor, (Cursor)0); @@ -4163,6 +4209,12 @@ ProcUngrabPointer(ClientPtr client) TimeStamp time; REQUEST(xResourceReq); + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabPointer: client [%d].\n", client -> index); + } + #endif REQUEST_SIZE_MATCH(xResourceReq); UpdateCurrentTime(); grab = device->grab; @@ -4170,7 +4222,25 @@ ProcUngrabPointer(ClientPtr client) if ((CompareTimeStamps(time, currentTime) != LATER) && (CompareTimeStamps(time, device->grabTime) != EARLIER) && (grab) && SameClient(grab, client)) + #ifdef NX_DEBUG_INPUT + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabPointer: Deactivating grab on pointer.\n"); + } + #endif (*device->DeactivateGrab)(device); + #ifdef NX_DEBUG_INPUT + } + else + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabPointer: current time [%lu] request time [%lu] grab time [%lu].\n", + currentTime.milliseconds, time.milliseconds, device->grabTime.milliseconds); + } + } + #endif return Success; } @@ -4225,6 +4295,12 @@ GrabDevice(register ClientPtr client, register DeviceIntPtr dev, tempGrab.pointerMode = other_mode; tempGrab.eventMask = mask; tempGrab.device = dev; + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "GrabDevice: Activating active grab on keyboard.\n"); + } + #endif (*dev->ActivateGrab)(dev, &tempGrab, time, FALSE); *status = GrabSuccess; } @@ -4238,6 +4314,12 @@ ProcGrabKeyboard(ClientPtr client) REQUEST(xGrabKeyboardReq); int result; + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcGrabKeyboard: client [%d].\n", client -> index); + } + #endif REQUEST_SIZE_MATCH(xGrabKeyboardReq); #ifdef XCSECURITY if (!SecurityCheckDeviceAccess(client, inputInfo.keyboard, TRUE)) @@ -4268,6 +4350,12 @@ ProcUngrabKeyboard(ClientPtr client) TimeStamp time; REQUEST(xResourceReq); + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabKeyboard: client [%d].\n", client -> index); + } + #endif REQUEST_SIZE_MATCH(xResourceReq); UpdateCurrentTime(); grab = device->grab; @@ -4275,7 +4363,25 @@ ProcUngrabKeyboard(ClientPtr client) if ((CompareTimeStamps(time, currentTime) != LATER) && (CompareTimeStamps(time, device->grabTime) != EARLIER) && (grab) && SameClient(grab, client)) + #ifdef NX_DEBUG_INPUT + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabKeyboard: Deactivating grab on keyboard.\n"); + } + #endif (*device->DeactivateGrab)(device); + #ifdef NX_DEBUG_INPUT + } + else + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabKeyboard: current time [%lu] request time [%lu] grab time [%lu].\n", + currentTime.milliseconds, time.milliseconds, device->grabTime.milliseconds); + } + } + #endif return Success; } diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original index a8a2a68bd..8e87d58c4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -191,6 +191,7 @@ xEvent *xeviexE; #ifdef NX_DEBUG_INPUT extern int nxagentDebugInput; +extern int nxagentDebugInputDevices; #endif extern Display *nxagentDisplay; @@ -1865,6 +1866,12 @@ DeliverEventsToWindow(register WindowPtr pWin, xEvent *pEvents, int count, tempGrab.pointerMode = GrabModeAsync; tempGrab.confineTo = NullWindow; tempGrab.cursor = NullCursor; + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "DeliverEventsToWindow: Activating passive grab on pointer.\n"); + } + #endif (*inputInfo.pointer->ActivateGrab)(inputInfo.pointer, &tempGrab, currentTime, TRUE); } @@ -2735,6 +2742,13 @@ CheckPassiveGrabsOnWindow( tempGrab.modifiersDetail.exact&(~0x1f00); } #endif + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "CheckPassiveGrabsOnWindow: Activating passive grab on %s.\n", + device == inputInfo.keyboard ? "keyboard" : "pointer"); + } + #endif (*device->ActivateGrab)(device, grab, currentTime, TRUE); FixUpEventFromWindow(xE, grab->window, None, TRUE); @@ -3093,7 +3107,17 @@ drawable.id:0; else DeliverFocusedEvent(keybd, xE, sprite.win, count); if (deactivateGrab) + #ifdef NX_DEBUG_INPUT + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcessKeyboardEvent: Deactivating grab on keyboard.\n"); + } + #endif (*keybd->DeactivateGrab)(keybd); + #ifdef NX_DEBUG_INPUT + } + #endif } #ifdef XKB @@ -3320,7 +3344,17 @@ ProcessPointerEvent (register xEvent *xE, register DeviceIntPtr mouse, int count mouse, count); #endif if (deactivateGrab) + #ifdef NX_DEBUG_INPUT + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcessPointerEvent: Deactivating grab on pointer.\n"); + } + #endif (*mouse->DeactivateGrab)(mouse); + #ifdef NX_DEBUG_INPUT + } + #endif } #define AtMostOneClient \ @@ -4041,6 +4075,12 @@ ProcGrabPointer(ClientPtr client) pWin = SecurityLookupWindow(stuff->grabWindow, client, SecurityReadAccess); if (!pWin) return BadWindow; + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcGrabPointer: pWin [%p] client [%d].\n", pWin, client -> index); + } + #endif if (stuff->confineTo == None) confineTo = NullWindow; else @@ -4100,6 +4140,12 @@ ProcGrabPointer(ClientPtr client) tempGrab.keyboardMode = stuff->keyboardMode; tempGrab.pointerMode = stuff->pointerMode; tempGrab.device = device; + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcGrabPointer: Activating active grab on pointer.\n"); + } + #endif (*device->ActivateGrab)(device, &tempGrab, time, FALSE); if (oldCursor) FreeCursor (oldCursor, (Cursor)0); @@ -4163,6 +4209,12 @@ ProcUngrabPointer(ClientPtr client) TimeStamp time; REQUEST(xResourceReq); + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabPointer: client [%d].\n", client -> index); + } + #endif REQUEST_SIZE_MATCH(xResourceReq); UpdateCurrentTime(); grab = device->grab; @@ -4170,7 +4222,25 @@ ProcUngrabPointer(ClientPtr client) if ((CompareTimeStamps(time, currentTime) != LATER) && (CompareTimeStamps(time, device->grabTime) != EARLIER) && (grab) && SameClient(grab, client)) + #ifdef NX_DEBUG_INPUT + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabPointer: Deactivating grab on pointer.\n"); + } + #endif (*device->DeactivateGrab)(device); + #ifdef NX_DEBUG_INPUT + } + else + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabPointer: current time [%lu] request time [%lu] grab time [%lu].\n", + currentTime.milliseconds, time.milliseconds, device->grabTime.milliseconds); + } + } + #endif return Success; } @@ -4225,6 +4295,12 @@ GrabDevice(register ClientPtr client, register DeviceIntPtr dev, tempGrab.pointerMode = other_mode; tempGrab.eventMask = mask; tempGrab.device = dev; + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "GrabDevice: Activating active grab on keyboard.\n"); + } + #endif (*dev->ActivateGrab)(dev, &tempGrab, time, FALSE); *status = GrabSuccess; } @@ -4238,6 +4314,12 @@ ProcGrabKeyboard(ClientPtr client) REQUEST(xGrabKeyboardReq); int result; + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcGrabKeyboard: client [%d].\n", client -> index); + } + #endif REQUEST_SIZE_MATCH(xGrabKeyboardReq); #ifdef XCSECURITY if (!SecurityCheckDeviceAccess(client, inputInfo.keyboard, TRUE)) @@ -4268,6 +4350,12 @@ ProcUngrabKeyboard(ClientPtr client) TimeStamp time; REQUEST(xResourceReq); + #ifdef NX_DEBUG_INPUT + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabKeyboard: client [%d].\n", client -> index); + } + #endif REQUEST_SIZE_MATCH(xResourceReq); UpdateCurrentTime(); grab = device->grab; @@ -4275,7 +4363,25 @@ ProcUngrabKeyboard(ClientPtr client) if ((CompareTimeStamps(time, currentTime) != LATER) && (CompareTimeStamps(time, device->grabTime) != EARLIER) && (grab) && SameClient(grab, client)) + #ifdef NX_DEBUG_INPUT + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabKeyboard: Deactivating grab on keyboard.\n"); + } + #endif (*device->DeactivateGrab)(device); + #ifdef NX_DEBUG_INPUT + } + else + { + if (nxagentDebugInputDevices == 1) + { + fprintf(stderr, "ProcUngrabKeyboard: current time [%lu] request time [%lu] grab time [%lu].\n", + currentTime.milliseconds, time.milliseconds, device->grabTime.milliseconds); + } + } + #endif return Success; } diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c index a510c9356..6e67b7ffe 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original index a510c9356..6e67b7ffe 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c index aee27e820..172252b32 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original index aee27e820..172252b32 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c index f51a8bce9..6340de537 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original index f51a8bce9..6340de537 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c index 3e105ac64..d6cd96631 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original index 3e105ac64..d6cd96631 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h index 0f30843d6..e78a1bf14 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original index 0f30843d6..e78a1bf14 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c index af07fdcc2..c71ea8142 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original index af07fdcc2..c71ea8142 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c index 6ad60223f..efb295861 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original index 6ad60223f..efb295861 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c index e08f5e45f..d2bead0bc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original index e08f5e45f..d2bead0bc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c index 1731e0753..be1096c6c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original index 1731e0753..be1096c6c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c index 5d6f71475..be961c400 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -62,6 +62,7 @@ #include "Screen.h" #include "Pixmaps.h" #include "Drawable.h" +#include "Render.h" #define PANIC #define WARNING @@ -1063,7 +1064,47 @@ static void initGradient(SourcePictPtr pGradient, int stopCount, static PicturePtr createSourcePicture(void) { PicturePtr pPicture; - pPicture = (PicturePtr) xalloc(sizeof(PictureRec)); + + extern int nxagentPicturePrivateIndex; + + unsigned int totalPictureSize; + + DevUnion *ppriv; + + char *privPictureRecAddr; + + int i; + + /* + * Compute size of entire PictureRect, plus privates. + */ + + totalPictureSize = sizeof(PictureRec) + + picturePrivateCount * sizeof(DevUnion) + + sizeof(nxagentPrivPictureRec); + + pPicture = (PicturePtr) xalloc(totalPictureSize); + + if (pPicture != NULL) + { + ppriv = (DevUnion *) (pPicture + 1); + + for (i = 0; i < picturePrivateCount; ++i) + { + /* + * Other privates are inaccessible. + */ + + ppriv[i].ptr = NULL; + } + + privPictureRecAddr = (char *) &ppriv[picturePrivateCount]; + + ppriv[nxagentPicturePrivateIndex].ptr = (pointer) privPictureRecAddr; + + pPicture -> devPrivates = ppriv; + } + pPicture->pDrawable = 0; pPicture->pFormat = 0; pPicture->pNext = 0; @@ -1697,6 +1738,10 @@ FreePicture (pointer value, if (--pPicture->refcnt == 0) { +#ifdef NXAGENT_SERVER + nxagentDestroyPicture(pPicture); +#endif + if (pPicture->transform) xfree (pPicture->transform); if (!pPicture->pDrawable) { diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original index 5d6f71475..be961c400 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -62,6 +62,7 @@ #include "Screen.h" #include "Pixmaps.h" #include "Drawable.h" +#include "Render.h" #define PANIC #define WARNING @@ -1063,7 +1064,47 @@ static void initGradient(SourcePictPtr pGradient, int stopCount, static PicturePtr createSourcePicture(void) { PicturePtr pPicture; - pPicture = (PicturePtr) xalloc(sizeof(PictureRec)); + + extern int nxagentPicturePrivateIndex; + + unsigned int totalPictureSize; + + DevUnion *ppriv; + + char *privPictureRecAddr; + + int i; + + /* + * Compute size of entire PictureRect, plus privates. + */ + + totalPictureSize = sizeof(PictureRec) + + picturePrivateCount * sizeof(DevUnion) + + sizeof(nxagentPrivPictureRec); + + pPicture = (PicturePtr) xalloc(totalPictureSize); + + if (pPicture != NULL) + { + ppriv = (DevUnion *) (pPicture + 1); + + for (i = 0; i < picturePrivateCount; ++i) + { + /* + * Other privates are inaccessible. + */ + + ppriv[i].ptr = NULL; + } + + privPictureRecAddr = (char *) &ppriv[picturePrivateCount]; + + ppriv[nxagentPicturePrivateIndex].ptr = (pointer) privPictureRecAddr; + + pPicture -> devPrivates = ppriv; + } + pPicture->pDrawable = 0; pPicture->pFormat = 0; pPicture->pNext = 0; @@ -1697,6 +1738,10 @@ FreePicture (pointer value, if (--pPicture->refcnt == 0) { +#ifdef NXAGENT_SERVER + nxagentDestroyPicture(pPicture); +#endif + if (pPicture->transform) xfree (pPicture->transform); if (!pPicture->pDrawable) { diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h index 255411a9b..b6cee91f1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original index 255411a9b..b6cee91f1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c index 772a1fbe5..d02f3f015 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original index 772a1fbe5..d02f3f015 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c index 426d15b1b..e1bb44148 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original index 426d15b1b..e1bb44148 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c index de2df855f..562cd2c66 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c @@ -26,7 +26,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -35,7 +35,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -116,7 +116,6 @@ int nxagentCursorSaveRenderInfo(ScreenPtr, CursorPtr); void nxagentCursorPostSaveRenderInfo(CursorPtr, ScreenPtr, PicturePtr, int, int); int nxagentRenderRealizeCursor(ScreenPtr, CursorPtr); int nxagentCreatePicture(PicturePtr, Mask); -void nxagentDestroyPicture(PicturePtr pPicture); void nxagentChangePicture(PicturePtr, Mask); int nxagentChangePictureClip(PicturePtr, int, int, xRectangle *, int, int); void nxagentComposite(CARD8, PicturePtr, PicturePtr, PicturePtr, INT16, INT16, @@ -132,6 +131,28 @@ void nxagentSetPictureFilter(PicturePtr pPicture, char *filter, int name_size, void nxagentTrapezoids(CARD8 op, PicturePtr pSrc, PicturePtr pDst, PictFormatPtr maskFormat, INT16 xSrc, INT16 ySrc, int ntrap, xTrapezoid *traps); +void nxagentRenderCreateSolidFill(PicturePtr pPicture, xRenderColor *color); + +void nxagentRenderCreateLinearGradient(PicturePtr pPicture, xPointFixed *p1, + xPointFixed *p2, int nStops, + xFixed *stops, + xRenderColor *colors); + +void nxagentRenderCreateRadialGradient(PicturePtr pPicture, xPointFixed *inner, + xPointFixed *outer, + xFixed innerRadius, + xFixed outerRadius, + int nStops, + xFixed *stops, + xRenderColor *colors); + +void nxagentRenderCreateConicalGradient(PicturePtr pPicture, + xPointFixed *center, + xFixed angle, int nStops, + xFixed *stops, + xRenderColor *colors); + + /* * The void pointer is actually a XGlyphElt8. */ @@ -823,8 +844,6 @@ ProcRenderFreePicture (ClientPtr client) VERIFY_PICTURE (pPicture, stuff->picture, client, SecurityDestroyAccess, RenderErrBase + BadPicture); - nxagentDestroyPicture(pPicture); - FreeResource (stuff->picture, RT_NONE); return(client->noClientException); } @@ -926,9 +945,16 @@ ProcRenderComposite (ClientPtr client) RenderErrBase + BadPicture); VERIFY_ALPHA (pMask, stuff->mask, client, SecurityReadAccess, RenderErrBase + BadPicture); +/* +FIXME: Imported change from newest version of Xorg. Changed pSrc to pDst. + if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || (pMask && pMask->pDrawable && pSrc->pDrawable->pScreen != pMask->pDrawable->pScreen)) return BadMatch; +*/ + if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || + (pMask && pMask->pDrawable && pDst->pDrawable->pScreen != pMask->pDrawable->pScreen)) + return BadMatch; ValidatePicture (pSrc); if (pMask) @@ -2336,6 +2362,11 @@ static int ProcRenderCreateSolidFill(ClientPtr client) pPicture = CreateSolidPicture(stuff->pid, &stuff->color, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateSolidFill(pPicture, &stuff -> color); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2367,6 +2398,12 @@ static int ProcRenderCreateLinearGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateLinearGradient(pPicture, &stuff->p1, &stuff->p2, + stuff->nStops, stops, colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2397,6 +2434,14 @@ static int ProcRenderCreateRadialGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateRadialGradient(pPicture, &stuff->inner, &stuff->outer, + stuff->inner_radius, + stuff->outer_radius, + stuff->nStops, stops, colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2426,6 +2471,13 @@ static int ProcRenderCreateConicalGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateConicalGradient(pPicture, &stuff->center, + stuff->angle, stuff->nStops, stops, + colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original index de2df855f..562cd2c66 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original @@ -26,7 +26,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -35,7 +35,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ @@ -116,7 +116,6 @@ int nxagentCursorSaveRenderInfo(ScreenPtr, CursorPtr); void nxagentCursorPostSaveRenderInfo(CursorPtr, ScreenPtr, PicturePtr, int, int); int nxagentRenderRealizeCursor(ScreenPtr, CursorPtr); int nxagentCreatePicture(PicturePtr, Mask); -void nxagentDestroyPicture(PicturePtr pPicture); void nxagentChangePicture(PicturePtr, Mask); int nxagentChangePictureClip(PicturePtr, int, int, xRectangle *, int, int); void nxagentComposite(CARD8, PicturePtr, PicturePtr, PicturePtr, INT16, INT16, @@ -132,6 +131,28 @@ void nxagentSetPictureFilter(PicturePtr pPicture, char *filter, int name_size, void nxagentTrapezoids(CARD8 op, PicturePtr pSrc, PicturePtr pDst, PictFormatPtr maskFormat, INT16 xSrc, INT16 ySrc, int ntrap, xTrapezoid *traps); +void nxagentRenderCreateSolidFill(PicturePtr pPicture, xRenderColor *color); + +void nxagentRenderCreateLinearGradient(PicturePtr pPicture, xPointFixed *p1, + xPointFixed *p2, int nStops, + xFixed *stops, + xRenderColor *colors); + +void nxagentRenderCreateRadialGradient(PicturePtr pPicture, xPointFixed *inner, + xPointFixed *outer, + xFixed innerRadius, + xFixed outerRadius, + int nStops, + xFixed *stops, + xRenderColor *colors); + +void nxagentRenderCreateConicalGradient(PicturePtr pPicture, + xPointFixed *center, + xFixed angle, int nStops, + xFixed *stops, + xRenderColor *colors); + + /* * The void pointer is actually a XGlyphElt8. */ @@ -823,8 +844,6 @@ ProcRenderFreePicture (ClientPtr client) VERIFY_PICTURE (pPicture, stuff->picture, client, SecurityDestroyAccess, RenderErrBase + BadPicture); - nxagentDestroyPicture(pPicture); - FreeResource (stuff->picture, RT_NONE); return(client->noClientException); } @@ -926,9 +945,16 @@ ProcRenderComposite (ClientPtr client) RenderErrBase + BadPicture); VERIFY_ALPHA (pMask, stuff->mask, client, SecurityReadAccess, RenderErrBase + BadPicture); +/* +FIXME: Imported change from newest version of Xorg. Changed pSrc to pDst. + if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || (pMask && pMask->pDrawable && pSrc->pDrawable->pScreen != pMask->pDrawable->pScreen)) return BadMatch; +*/ + if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || + (pMask && pMask->pDrawable && pDst->pDrawable->pScreen != pMask->pDrawable->pScreen)) + return BadMatch; ValidatePicture (pSrc); if (pMask) @@ -2336,6 +2362,11 @@ static int ProcRenderCreateSolidFill(ClientPtr client) pPicture = CreateSolidPicture(stuff->pid, &stuff->color, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateSolidFill(pPicture, &stuff -> color); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2367,6 +2398,12 @@ static int ProcRenderCreateLinearGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateLinearGradient(pPicture, &stuff->p1, &stuff->p2, + stuff->nStops, stops, colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2397,6 +2434,14 @@ static int ProcRenderCreateRadialGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateRadialGradient(pPicture, &stuff->inner, &stuff->outer, + stuff->inner_radius, + stuff->outer_radius, + stuff->nStops, stops, colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2426,6 +2471,13 @@ static int ProcRenderCreateConicalGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateConicalGradient(pPicture, &stuff->center, + stuff->angle, stuff->nStops, stops, + colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c index 91e03cb0e..8c69217e7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original index 91e03cb0e..8c69217e7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c index a6d638ea7..b99cbe3e3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original index a6d638ea7..b99cbe3e3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c index 24dad322f..4022bc397 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original index 24dad322f..4022bc397 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c index 15fdd9ff3..aa902226e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original index 15fdd9ff3..aa902226e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm b/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm index d35ac4ec1..5955f1705 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm +++ b/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm b/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm index 497fa2511..e7dee27b1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm +++ b/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c b/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c index 81c479233..80419d871 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c +++ b/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/screensaver b/nx-X11/programs/Xserver/hw/nxagent/screensaver index b9408a2b7..4c5c10620 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/screensaver +++ b/nx-X11/programs/Xserver/hw/nxagent/screensaver @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2003 NoMachine, http://www.nomachine.com. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -9,7 +9,7 @@ /* */ /* Check http://www.nomachine.com/licensing.html for applicability. */ /* */ -/* NX and NoMachine are trademarks of NoMachine S.r.l. */ +/* NX and NoMachine are trademarks of Medialogic S.p.A. */ /* */ /* All rights reserved. */ /* */ -- cgit v1.2.3 From 25af86cd3aaa61dc4a3d69825aa523177c2229e1 Mon Sep 17 00:00:00 2001 From: Reinhard Tartler Date: Mon, 10 Oct 2011 17:58:57 +0200 Subject: Imported nxagent-3.4.0-16.tar.gz Summary: Imported nxagent-3.4.0-16.tar.gz Keywords: Imported nxagent-3.4.0-16.tar.gz into Git repository --- nx-X11/programs/Xserver/hw/nxagent/Agent.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Args.c | 15 +- nx-X11/programs/Xserver/hw/nxagent/Args.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Atoms.c | 32 +-- nx-X11/programs/Xserver/hw/nxagent/Atoms.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Binder.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Binder.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/CHANGELOG | 59 +++++ nx-X11/programs/Xserver/hw/nxagent/Client.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Client.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Clipboard.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Clipboard.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Colormap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Colormap.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Composite.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Composite.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Cursor.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Cursor.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Dialog.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Dialog.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Display.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Display.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Drawable.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Drawable.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Error.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Error.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Events.c | 284 ++++++++++---------- nx-X11/programs/Xserver/hw/nxagent/Events.h | 3 +- nx-X11/programs/Xserver/hw/nxagent/Extensions.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Extensions.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Font.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Font.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/GC.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCOps.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCOps.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCs.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Handlers.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Handlers.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Holder.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Holder.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Icons.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Image.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Image.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Init.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Init.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keyboard.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keyboard.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keystroke.c | 14 +- nx-X11/programs/Xserver/hw/nxagent/Keystroke.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/LICENSE | 2 +- nx-X11/programs/Xserver/hw/nxagent/Literals.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Millis.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Millis.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c | 2 +- .../Xserver/hw/nxagent/NXdispatch.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c | 2 +- .../Xserver/hw/nxagent/NXdixfonts.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXevents.c | 2 +- .../Xserver/hw/nxagent/NXevents.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXextension.c | 2 +- .../Xserver/hw/nxagent/NXextension.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyph.c | 2 +- .../Xserver/hw/nxagent/NXglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c | 2 +- .../Xserver/hw/nxagent/NXglyphcurs.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h | 2 +- .../Xserver/hw/nxagent/NXglyphstr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c | 2 +- .../Xserver/hw/nxagent/NXmiglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXpicture.c | 2 +- .../Xserver/hw/nxagent/NXpicture.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h | 2 +- .../Xserver/hw/nxagent/NXpicturestr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXproperty.c | 2 +- .../Xserver/hw/nxagent/NXproperty.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXrandr.c | 2 +- .../Xserver/hw/nxagent/NXrandr.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXrender.c | 2 +- .../Xserver/hw/nxagent/NXrender.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXwindow.c | 2 +- .../Xserver/hw/nxagent/NXwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Options.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Options.h | 9 +- nx-X11/programs/Xserver/hw/nxagent/Pixels.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pixels.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pixmap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pointer.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pointer.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Reconnect.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Reconnect.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Render.c | 12 +- nx-X11/programs/Xserver/hw/nxagent/Render.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Rootless.c | 56 +++- nx-X11/programs/Xserver/hw/nxagent/Rootless.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Screen.c | 195 +++++++++++++- nx-X11/programs/Xserver/hw/nxagent/Screen.h | 10 +- nx-X11/programs/Xserver/hw/nxagent/Splash.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Splash.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Split.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Split.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/TestExt.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Trap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Trap.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Utils.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Visual.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Visual.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Window.c | 285 +++++++++++++++++++-- nx-X11/programs/Xserver/hw/nxagent/Windows.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c | 2 +- .../Xserver/hw/nxagent/X/NXdamage.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c | 2 +- .../Xserver/hw/nxagent/X/NXdispatch.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c | 2 +- .../Xserver/hw/nxagent/X/NXdixfonts.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c | 2 +- .../Xserver/hw/nxagent/X/NXevents.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c | 2 +- .../Xserver/hw/nxagent/X/NXextension.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c | 2 +- .../Xserver/hw/nxagent/X/NXglxext.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c | 2 +- .../Xserver/hw/nxagent/X/NXglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c | 2 +- .../Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h | 2 +- .../Xserver/hw/nxagent/X/NXglyphstr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c | 2 +- .../Xserver/hw/nxagent/X/NXmiexpose.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c | 2 +- .../Xserver/hw/nxagent/X/NXmiglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c | 2 +- .../Xserver/hw/nxagent/X/NXmitrap.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c | 2 +- .../Xserver/hw/nxagent/X/NXmiwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c | 7 +- .../Xserver/hw/nxagent/X/NXpicture.c.NX.original | 7 +- .../programs/Xserver/hw/nxagent/X/NXpicturestr.h | 2 +- .../hw/nxagent/X/NXpicturestr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c | 2 +- .../Xserver/hw/nxagent/X/NXproperty.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c | 2 +- .../Xserver/hw/nxagent/X/NXrandr.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c | 2 +- .../Xserver/hw/nxagent/X/NXrender.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c | 2 +- .../Xserver/hw/nxagent/X/NXresource.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c | 2 +- .../Xserver/hw/nxagent/X/NXshm.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c | 2 +- .../Xserver/hw/nxagent/X/NXwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c | 2 +- .../Xserver/hw/nxagent/X/NXxvdisp.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm | 2 +- nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm | 2 +- nx-X11/programs/Xserver/hw/nxagent/os2Stub.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/screensaver | 2 +- 160 files changed, 943 insertions(+), 339 deletions(-) (limited to 'nx-X11/programs/Xserver/hw/nxagent/Render.h') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Agent.h b/nx-X11/programs/Xserver/hw/nxagent/Agent.h index 3f2c93fdb..dbed1e0d8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Agent.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Agent.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.c b/nx-X11/programs/Xserver/hw/nxagent/Args.c index c2e58bd58..8fbb275a6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Args.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Args.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -562,11 +562,15 @@ int ddxProcessArgument(int argc, char *argv[], int i) if (!strcmp(argv[i],"fullscreen")) { nxagentChangeOption(Fullscreen, True); + + nxagentChangeOption(AllScreens, True); } else if (!strcmp(argv[i],"ipaq")) { nxagentChangeOption(Fullscreen, True); + nxagentChangeOption(AllScreens, True); + nxagentIpaq = True; } else @@ -1071,10 +1075,14 @@ static void nxagentParseOptions(char *name, char *value) else if (!strcmp(value, "1")) { nxagentChangeOption(Fullscreen, True); + + nxagentChangeOption(AllScreens, True); } else if (!strcmp(value, "0")) { nxagentChangeOption(Fullscreen, False); + + nxagentChangeOption(AllScreens, False); } else { @@ -1680,6 +1688,11 @@ N/A nxagentChangeOption(Fullscreen, False); } + if (nxagentOption(AllScreens) == UNDEFINED) + { + nxagentChangeOption(AllScreens, False); + } + if (nxagentOption(Binder) == UNDEFINED) { nxagentChangeOption(Binder, False); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.h b/nx-X11/programs/Xserver/hw/nxagent/Args.h index 92650a4a0..9cb97ca03 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Args.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Args.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c index 171df95a9..578731f07 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -66,21 +66,21 @@ Atom nxagentAtoms[NXAGENT_NUMBER_OF_ATOMS]; static char *nxagentAtomNames[NXAGENT_NUMBER_OF_ATOMS + 1] = { - "NX_IDENTITY", /* 0 */ - "WM_PROTOCOLS", /* 1 */ - "WM_DELETE_WINDOW", /* 2 */ - "WM_NX_READY", /* 3 */ - "MCOPGLOBALS", /* 4 */ - "NX_CUT_BUFFER_SERVER", /* 5 */ - "TARGETS", /* 6 */ - "TEXT", /* 7 */ - "NX_AGENT_SIGNATURE", /* 8 */ - "NXDARWIN", /* 9 */ - "CLIPBOARD", /* 10 */ - "TIMESTAMP", /* 11 */ - "UTF8_STRING", /* 12 */ - "_NET_WM_STATE", /* 13 */ - "_NET_WM_STATE_FULLSCREEN", /* 14 */ + "NX_IDENTITY", /* 0 */ + "WM_PROTOCOLS", /* 1 */ + "WM_DELETE_WINDOW", /* 2 */ + "WM_NX_READY", /* 3 */ + "MCOPGLOBALS", /* 4 */ + "NX_CUT_BUFFER_SERVER", /* 5 */ + "TARGETS", /* 6 */ + "TEXT", /* 7 */ + "NX_AGENT_SIGNATURE", /* 8 */ + "NXDARWIN", /* 9 */ + "CLIPBOARD", /* 10 */ + "TIMESTAMP", /* 11 */ + "UTF8_STRING", /* 12 */ + "_NET_WM_STATE", /* 13 */ + "_NET_WM_STATE_FULLSCREEN", /* 14 */ NULL, NULL }; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h index f49f2751e..d5b7fe5aa 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.c b/nx-X11/programs/Xserver/hw/nxagent/Binder.c index 34433bd2b..d40aaebe6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Binder.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.h b/nx-X11/programs/Xserver/hw/nxagent/Binder.h index e0da3e357..f28a82b9f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Binder.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG index 3f0a6abcd..64e41b8cc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG +++ b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG @@ -1,5 +1,64 @@ ChangeLog: +nxagent-3.4.0-16 + +- Updated copyright to year 2011. + +nxagent-3.4.0-15 + +- Added reference to fixed TR11H02405. + +nxagent-3.4.0-14 + +- Reverted fix for TR03H02335 implemented in nxagent-3.4.0-6. The + emulation of right click by Control key + left click introduces + issues for some applications changing the reaction to the left click + depending on the state of Control key. Issue reported in TR03H02335 + affects Apple laptop touchpads having a single button acting as + left button: on those devices the right button can be emulated by + a double-fingered tap (using two fingertips simultaneously). + +nxagent-3.4.0-13 + +- Fixed TR12H02414. Exported property must be split if ChangeProperty + request exceeds 262140 bytes. + +- Reset AllScreens option at reconnection time if full screen mode + have to be automatically turned off. + +nxagent-3.4.0-12 + +- If one of the two full screen modes is active ('one screen' or 'all + screens') both keystrokes Ctrl-Alt-F and Ctrl-Alt-Shift-F change the + mode back to 'windowed'. + +- Fixed TR11H02405. XRenderFreePicture is called only for pictures + that were actually created on the X server side. + +- Ctrl+Alt+f switch fullscreen to all monitors, while Ctrl+Alt+Shift+f + does it to one monitor only. + +- If the fullscreen option is enabled at the startup, session starts + in the fullscreen mode on all monitors. + +- Added a call to XReparentWindow in the nxagentSwitchAllScreens(). + +- Corrected focus and grab when switching to fullscreen on + all monitors. + +- Removed a compile warning e deleted some unused variables. + +- Removed nxagentPointerAndKeyboardGrabbed variable. + +- Use the override redirect attribute to switch to fullscreen to all + monitors instead of send _NET_WM_FULLSCREEN_MONITORS hint to the WM. + +- Added nxagentMinimizeFromFullScreen(), nxagentMaximizeToFullScreen() + and nxagentCreateIconWindow(). + +- Removed check on EnterNotify to grab the keyboard in fullscreen + mode not only if mode is 'NotifyNormal'. + nxagent-3.4.0-11 - Corrected switching between viewport mode and resize mode. diff --git a/nx-X11/programs/Xserver/hw/nxagent/Client.c b/nx-X11/programs/Xserver/hw/nxagent/Client.c index acfaab7c0..63ed0e134 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Client.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Client.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Client.h b/nx-X11/programs/Xserver/hw/nxagent/Client.h index 45f87fc66..a9b06c845 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Client.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Client.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c index eb830234d..2742e147f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h index 2750ddfd2..43189df81 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c index 259aa3b24..b0f0507b5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.h b/nx-X11/programs/Xserver/hw/nxagent/Colormap.h index 8321e8038..b2960590c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Composite.c b/nx-X11/programs/Xserver/hw/nxagent/Composite.c index b0640ff11..c79104fc1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Composite.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Composite.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Composite.h b/nx-X11/programs/Xserver/hw/nxagent/Composite.h index fb1d6d8e9..e875d0051 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Composite.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Composite.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Cursor.c b/nx-X11/programs/Xserver/hw/nxagent/Cursor.c index 141ba3a64..9ed7c233f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Cursor.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Cursor.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Cursor.h b/nx-X11/programs/Xserver/hw/nxagent/Cursor.h index 11e407efd..df7dc44f7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Cursor.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Cursor.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Dialog.c b/nx-X11/programs/Xserver/hw/nxagent/Dialog.c index 2f807b1dc..0fb9491a4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Dialog.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Dialog.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Dialog.h b/nx-X11/programs/Xserver/hw/nxagent/Dialog.h index aa845c7c2..bd12f3097 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Dialog.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Dialog.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.c b/nx-X11/programs/Xserver/hw/nxagent/Display.c index 1a57788e6..87be98116 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.h b/nx-X11/programs/Xserver/hw/nxagent/Display.h index 35b7857ad..454150d6e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Drawable.c b/nx-X11/programs/Xserver/hw/nxagent/Drawable.c index 75057097a..9c167743f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Drawable.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Drawable.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Drawable.h b/nx-X11/programs/Xserver/hw/nxagent/Drawable.h index 146610efb..c987fa119 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Drawable.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Drawable.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Error.c b/nx-X11/programs/Xserver/hw/nxagent/Error.c index 963cfa287..43bf85900 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Error.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Error.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Error.h b/nx-X11/programs/Xserver/hw/nxagent/Error.h index 2d6083d4e..e55fd71a5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Error.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Error.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.c b/nx-X11/programs/Xserver/hw/nxagent/Events.c index 1576962fb..b9da934d6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -205,8 +205,6 @@ CARD32 nxagentLastEventTime = 0; CARD32 nxagentLastKeyPressTime = 0; Time nxagentLastServerTime = 0; -int nxagentPointerAndKeyboardGrabbed = 0; - /* * Used for storing windows that need to * receive expose events from the agent. @@ -806,6 +804,7 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) Bool startKbd = False; Bool closeSession = False; Bool switchFullscreen = False; + Bool switchAllScreens = False; /* * Last entered top level window. @@ -990,6 +989,12 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) break; } + case doSwitchAllScreens: + { + switchAllScreens = TRUE; + + break; + } case doViewportMoveUp: { nxagentMoveViewport(pScreen, 0, -nxagentOption(Height)); @@ -1193,23 +1198,6 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentInputEvent = 1; - if (nxagentOption(ClientOs) == ClientOsMac && (X.xbutton.state & ControlMask) == ControlMask) - { - x.u.u.type = ButtonPress; - x.u.u.detail = inputInfo.pointer -> button -> map[3]; - x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); - - mieqEnqueue(&x); - - x.u.u.type = ButtonRelease; - x.u.u.detail = inputInfo.pointer -> button -> map[3]; - x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); - - mieqEnqueue(&x); - - break; - } - if (nxagentOption(Fullscreen)) { if (nxagentMagicPixelZone(X.xbutton.x, X.xbutton.y)) @@ -1313,11 +1301,6 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentInputEvent = 1; - if (nxagentOption(ClientOs) == ClientOsMac && (X.xbutton.state & ControlMask) == ControlMask) - { - break; - } - if (viewportCursor) { /* @@ -1688,14 +1671,11 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentScreenTrap = 0; } - if (nxagentOption(Fullscreen) == 1) + if (nxagentOption(Fullscreen) == 1 && + X.xcrossing.window == nxagentFullscreenWindow && + X.xcrossing.detail != NotifyInferior) { - if (X.xcrossing.window == nxagentDefaultWindows[0] && - X.xcrossing.detail != NotifyInferior && - X.xcrossing.mode == NotifyNormal) - { - nxagentGrabPointerAndKeyboard(&X); - } + nxagentGrabPointerAndKeyboard(&X); } if (X.xcrossing.detail != NotifyInferior) @@ -2002,7 +1982,8 @@ FIXME: Don't enqueue the KeyRelease event if the key was } if (nxagentUseNXTrans == 1 && nxagentOption(Rootless) == 0 && - nxagentOption(Nested) == 0) + nxagentOption(Nested) == 0 && + X.xmap.window != nxagentIconWindow) { nxagentVisibility = VisibilityFullyObscured; } @@ -2041,6 +2022,15 @@ FIXME: Don't enqueue the KeyRelease event if the key was } } + if (nxagentOption(AllScreens) == 1) + { + if (X.xmap.window == nxagentIconWindow) + { + pScreen = nxagentScreen(X.xmap.window); + nxagentMaximizeToFullScreen(pScreen); + } + } + if (nxagentOption(Fullscreen) == 1) { nxagentVisibility = VisibilityUnobscured; @@ -2136,14 +2126,40 @@ FIXME: Don't enqueue the KeyRelease event if the key was if (nxagentWMIsRunning) { - XIconifyWindow(nxagentDisplay, nxagentDefaultWindows[0], - DefaultScreen(nxagentDisplay)); + if (nxagentOption(AllScreens)) + { + nxagentMinimizeFromFullScreen(pScreen); + } + else + { + XIconifyWindow(nxagentDisplay, nxagentDefaultWindows[0], + DefaultScreen(nxagentDisplay)); + } } } if (switchFullscreen) { - nxagentSwitchFullscreen(pScreen, !nxagentOption(Fullscreen)); + if (nxagentOption(AllScreens) == 1 && nxagentOption(Fullscreen) == 1) + { + nxagentSwitchAllScreens(pScreen, 0); + } + else + { + nxagentSwitchFullscreen(pScreen, !nxagentOption(Fullscreen)); + } + } + + if (switchAllScreens) + { + if (nxagentOption(AllScreens) == 0 && nxagentOption(Fullscreen) == 1) + { + nxagentSwitchFullscreen(pScreen, 0); + } + else + { + nxagentSwitchAllScreens(pScreen, !nxagentOption(AllScreens)); + } } if (startKbd) @@ -2615,6 +2631,7 @@ int nxagentHandleGraphicsExposeEvent(XEvent *X) int nxagentHandleClientMessageEvent(XEvent *X, enum HandleEventResult *result) { + ScreenPtr pScreen; WindowPtr pWin; xEvent x; @@ -2730,8 +2747,20 @@ int nxagentHandleClientMessageEvent(XEvent *X, enum HandleEventResult *result) fprintf(stderr, "Events: WM_DELETE_WINDOW arrived Atom = %ld.\n", wmAtom); #endif - if (X -> xclient.window == nxagentDefaultWindows[0] || - nxagentWMIsRunning == 0) + if (X -> xclient.window == nxagentIconWindow) + { + pScreen = nxagentScreen(X -> xmap.window); + + XMapRaised(nxagentDisplay, nxagentFullscreenWindow); + + XIconifyWindow(nxagentDisplay, nxagentIconWindow, + DefaultScreen(nxagentDisplay)); + + } + + if (X -> xclient.window == (nxagentOption(Fullscreen) ? + nxagentIconWindow : nxagentDefaultWindows[0]) || + nxagentWMIsRunning == 0) { *result = doCloseSession; } @@ -3328,110 +3357,113 @@ int nxagentHandleConfigureNotify(XEvent* X) if (X -> xconfigure.window == nxagentDefaultWindows[pScreen -> myNum]) { - if (nxagentOption(DesktopResize) == 1) + if (nxagentOption(AllScreens) == 0) { - if (nxagentOption(Width) != X -> xconfigure.width || - nxagentOption(Height) != X -> xconfigure.height) + if (nxagentOption(DesktopResize) == 1) { - Bool newEvents = False; + if (nxagentOption(Width) != X -> xconfigure.width || + nxagentOption(Height) != X -> xconfigure.height) + { + Bool newEvents = False; - doRandR = True; + doRandR = True; - NXFlushDisplay(nxagentDisplay, NXFlushLink); + NXFlushDisplay(nxagentDisplay, NXFlushLink); - do - { - newEvents = False; + do + { + newEvents = False; - timeout.tv_sec = 0; - timeout.tv_usec = 500 * 1000; + timeout.tv_sec = 0; + timeout.tv_usec = 500 * 1000; - nxagentWaitEvents(nxagentDisplay, &timeout); + nxagentWaitEvents(nxagentDisplay, &timeout); - /* - * This should also flush - * the NX link for us. - */ + /* + * This should also flush + * the NX link for us. + */ - XSync(nxagentDisplay, 0); + XSync(nxagentDisplay, 0); - while (XCheckTypedWindowEvent(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], - ConfigureNotify, X)) - { - newEvents = True; - } + while (XCheckTypedWindowEvent(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], + ConfigureNotify, X)) + { + newEvents = True; + } - } while (newEvents); + } while (newEvents); + } } - } - if (nxagentWMIsRunning == 0 || X -> xconfigure.send_event) - { - nxagentChangeOption(X, X -> xconfigure.x); - nxagentChangeOption(Y, X -> xconfigure.y); - } + if (nxagentWMIsRunning == 0 || X -> xconfigure.send_event) + { + nxagentChangeOption(X, X -> xconfigure.x); + nxagentChangeOption(Y, X -> xconfigure.y); + } - if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1 && - (nxagentOption(Width) != X -> xconfigure.width || - nxagentOption(Height) != X -> xconfigure.height)) - { - nxagentShadowResize = 1; - } + if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1 && + (nxagentOption(Width) != X -> xconfigure.width || + nxagentOption(Height) != X -> xconfigure.height)) + { + nxagentShadowResize = 1; + } - nxagentChangeOption(Width, X -> xconfigure.width); - nxagentChangeOption(Height, X -> xconfigure.height); + nxagentChangeOption(Width, X -> xconfigure.width); + nxagentChangeOption(Height, X -> xconfigure.height); - nxagentChangeOption(ViewportXSpan, (int) X -> xconfigure.width - - (int) nxagentOption(RootWidth)); - nxagentChangeOption(ViewportYSpan, (int) X -> xconfigure.height - - (int) nxagentOption(RootHeight)); + nxagentChangeOption(ViewportXSpan, (int) X -> xconfigure.width - + (int) nxagentOption(RootWidth)); + nxagentChangeOption(ViewportYSpan, (int) X -> xconfigure.height - + (int) nxagentOption(RootHeight)); - nxagentMoveViewport(pScreen, 0, 0); + nxagentMoveViewport(pScreen, 0, 0); - if (nxagentOption(Shadow) == 1 || - (nxagentOption(Width) == nxagentOption(RootWidth) && - nxagentOption(Height) == nxagentOption(RootHeight))) - { - doRandR = 0; - } + if (nxagentOption(Shadow) == 1 || + (nxagentOption(Width) == nxagentOption(RootWidth) && + nxagentOption(Height) == nxagentOption(RootHeight))) + { + doRandR = 0; + } - nxagentChangeOption(Width, X -> xconfigure.width); - nxagentChangeOption(Height, X -> xconfigure.height); + nxagentChangeOption(Width, X -> xconfigure.width); + nxagentChangeOption(Height, X -> xconfigure.height); - XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, - X -> xconfigure.width, X -> xconfigure.height); + XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, + X -> xconfigure.width, X -> xconfigure.height); - if (nxagentOption(Fullscreen) == 0) - { - nxagentMoveViewport(pScreen, 0, 0); - } - else - { - nxagentChangeOption(RootX, (nxagentOption(Width) - - nxagentOption(RootWidth)) / 2); - nxagentChangeOption(RootY, (nxagentOption(Height) - - nxagentOption(RootHeight)) / 2); - nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - - nxagentOption(RootWidth)); - nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - - nxagentOption(RootHeight)); - - nxagentUpdateViewportFrame(0, 0, nxagentOption(RootWidth), - nxagentOption(RootHeight)); - - XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), - nxagentOption(RootX), nxagentOption(RootY)); - } + if (nxagentOption(Fullscreen) == 0) + { + nxagentMoveViewport(pScreen, 0, 0); + } + else + { + nxagentChangeOption(RootX, (nxagentOption(Width) - + nxagentOption(RootWidth)) / 2); + nxagentChangeOption(RootY, (nxagentOption(Height) - + nxagentOption(RootHeight)) / 2); + nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - + nxagentOption(RootWidth)); + nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - + nxagentOption(RootHeight)); + + nxagentUpdateViewportFrame(0, 0, nxagentOption(RootWidth), + nxagentOption(RootHeight)); + + XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), + nxagentOption(RootX), nxagentOption(RootY)); + } - if (doRandR) - { - #ifdef TEST - fprintf(stderr,"nxagentHandleConfigureNotify: Width %d Height %d.\n", - nxagentOption(Width), nxagentOption(Height)); - #endif + if (doRandR) + { + #ifdef TEST + fprintf(stderr,"nxagentHandleConfigureNotify: Width %d Height %d.\n", + nxagentOption(Width), nxagentOption(Height)); + #endif - nxagentRRSetScreenConfig(screenInfo.screens[DefaultScreen(nxagentDisplay)], - nxagentOption(Width), nxagentOption(Height)); + nxagentRRSetScreenConfig(screenInfo.screens[DefaultScreen(nxagentDisplay)], + nxagentOption(Width), nxagentOption(Height)); + } } return 1; @@ -3800,11 +3832,6 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) int result; - if (nxagentPointerAndKeyboardGrabbed == 1) - { - return; - } - #ifdef TEST fprintf(stderr, "nxagentGrabPointerAndKeyboard: Grabbing pointer and keyboard with event at [%p].\n", (void *) X); @@ -3867,19 +3894,12 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) XSetInputFocus(nxagentDisplay, nxagentFullscreenWindow, RevertToParent, now); } - - nxagentPointerAndKeyboardGrabbed = 1; } void nxagentUngrabPointerAndKeyboard(XEvent *X) { unsigned long now; - if (nxagentPointerAndKeyboardGrabbed == 0) - { - return; - } - #ifdef TEST fprintf(stderr, "nxagentUngrabPointerAndKeyboard: Ungrabbing pointer and keyboard with event at [%p].\n", (void *) X); @@ -3905,8 +3925,6 @@ void nxagentUngrabPointerAndKeyboard(XEvent *X) #endif XUngrabPointer(nxagentDisplay, now); - - nxagentPointerAndKeyboardGrabbed = 0; } void nxagentDeactivatePointerGrab() diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.h b/nx-X11/programs/Xserver/hw/nxagent/Events.h index 109475c16..c74fa151f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -33,6 +33,7 @@ enum HandleEventResult doCloseSession, doStartKbd, doSwitchFullscreen, + doSwitchAllScreens, doViewportMoveUp, doViewportMoveLeft, doViewportMoveRight, diff --git a/nx-X11/programs/Xserver/hw/nxagent/Extensions.c b/nx-X11/programs/Xserver/hw/nxagent/Extensions.c index e76cbb4ad..aced24ff4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Extensions.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Extensions.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Extensions.h b/nx-X11/programs/Xserver/hw/nxagent/Extensions.h index 620645d00..5335cf87c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Extensions.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Extensions.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Font.c b/nx-X11/programs/Xserver/hw/nxagent/Font.c index 13b819322..5e58b792b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Font.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Font.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Font.h b/nx-X11/programs/Xserver/hw/nxagent/Font.h index 75ae3f6f5..63cb6aa24 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Font.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Font.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GC.c b/nx-X11/programs/Xserver/hw/nxagent/GC.c index c53e3b9f7..71562d999 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GC.c +++ b/nx-X11/programs/Xserver/hw/nxagent/GC.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCOps.c b/nx-X11/programs/Xserver/hw/nxagent/GCOps.c index 85730797e..e18b034eb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCOps.c +++ b/nx-X11/programs/Xserver/hw/nxagent/GCOps.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCOps.h b/nx-X11/programs/Xserver/hw/nxagent/GCOps.h index 7ae6d9923..fa4967aee 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCOps.h +++ b/nx-X11/programs/Xserver/hw/nxagent/GCOps.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCs.h b/nx-X11/programs/Xserver/hw/nxagent/GCs.h index bec290088..f7e13477a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCs.h +++ b/nx-X11/programs/Xserver/hw/nxagent/GCs.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Handlers.c b/nx-X11/programs/Xserver/hw/nxagent/Handlers.c index be407f160..310b572cc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Handlers.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Handlers.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Handlers.h b/nx-X11/programs/Xserver/hw/nxagent/Handlers.h index fe8aeef36..3d3b335c0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Handlers.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Handlers.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Holder.c b/nx-X11/programs/Xserver/hw/nxagent/Holder.c index a9ac77c09..bfd907cde 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Holder.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Holder.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Holder.h b/nx-X11/programs/Xserver/hw/nxagent/Holder.h index 9896aeead..c39b98780 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Holder.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Holder.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Icons.h b/nx-X11/programs/Xserver/hw/nxagent/Icons.h index 4d0e216cd..0601584d4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Icons.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Icons.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Image.c b/nx-X11/programs/Xserver/hw/nxagent/Image.c index e8405ed3a..e499b7a11 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Image.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Image.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Image.h b/nx-X11/programs/Xserver/hw/nxagent/Image.h index 7805b0312..57272ab18 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Image.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Image.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Init.c b/nx-X11/programs/Xserver/hw/nxagent/Init.c index 64b6583bf..789ff3446 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Init.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Init.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Init.h b/nx-X11/programs/Xserver/hw/nxagent/Init.h index 576c1a74d..cf154e86d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Init.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Init.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c index b0aeabeea..8db38892e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h index 1a953358a..0e11a8a13 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c index de1da8654..6c6e477ab 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -116,7 +116,7 @@ int nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) { if (nxagentOption(Rootless) == False) { - *result = doSwitchFullscreen; + *result = doSwitchAllScreens; } break; @@ -282,6 +282,16 @@ int nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) { switch (sym) { + case XK_f: + case XK_F: + { + if (nxagentOption(Rootless) == 0) + { + *result = doSwitchFullscreen; + } + + break; + } case XK_Left: case XK_KP_Left: { diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h index e9ca59ff2..ef71a8851 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/LICENSE b/nx-X11/programs/Xserver/hw/nxagent/LICENSE index 141ca13ea..8446e6f55 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/LICENSE +++ b/nx-X11/programs/Xserver/hw/nxagent/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2001, 2010 NoMachine - http://www.nomachine.com/. +Copyright (c) 2001, 2011 NoMachine - http://www.nomachine.com/. NXAGENT and NX extensions to X are copyright of NoMachine. diff --git a/nx-X11/programs/Xserver/hw/nxagent/Literals.h b/nx-X11/programs/Xserver/hw/nxagent/Literals.h index 377dd7e25..aaa3430d6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Literals.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Literals.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Millis.c b/nx-X11/programs/Xserver/hw/nxagent/Millis.c index bde85f090..e9c739eeb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Millis.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Millis.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Millis.h b/nx-X11/programs/Xserver/hw/nxagent/Millis.h index 2125eca3e..69d247bbc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Millis.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Millis.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c index 5106ffa8c..4f59b8098 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original index 5106ffa8c..4f59b8098 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c index 0d8584218..1cccfd972 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original index 0d8584218..1cccfd972 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c index cd8ced7a6..f697cf3ca 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original index cd8ced7a6..f697cf3ca 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c index 852ad1503..1d86bf870 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original index 852ad1503..1d86bf870 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c index 55248195f..22483b3fd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original index 55248195f..22483b3fd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c index 614d2db39..9212bf438 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original index 614d2db39..9212bf438 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h index 08ffb35b0..0f122be4a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original index 08ffb35b0..0f122be4a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c index 806cf2900..09901ba9c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original index 806cf2900..09901ba9c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c index a9c501b34..d32cdb6c4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original index a9c501b34..d32cdb6c4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h index 26a95fe9f..91eab0125 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original index 26a95fe9f..91eab0125 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c index 14b6136d4..20a6bd6dc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original index 14b6136d4..20a6bd6dc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c index b7039e1e0..d593fa6aa 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original index b7039e1e0..d593fa6aa 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c index 0940a3602..43607ac08 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c @@ -31,7 +31,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original index 0940a3602..43607ac08 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original @@ -31,7 +31,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c index 0954cf8ae..95ecde951 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original index 0954cf8ae..95ecde951 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c index 8d05175ff..37b2c74fd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h index 4e800e96d..160dc6517 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h b/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h index ae3a03d86..97ae77e29 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Options.c b/nx-X11/programs/Xserver/hw/nxagent/Options.c index 1f04b0daf..5d7855667 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Options.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Options.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Options.h b/nx-X11/programs/Xserver/hw/nxagent/Options.h index 1bc7eaa4c..7850a0586 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Options.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Options.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -102,6 +102,13 @@ typedef struct _AgentOptions int Fullscreen; + /* + * True if the fullscreen NX session will + * extend on all available screens. + */ + + int AllScreens; + /* * Set to the auto-disconnect timeout, if * the user activated this feature. diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixels.c b/nx-X11/programs/Xserver/hw/nxagent/Pixels.c index 10c705dfc..d3ab9dd2f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixels.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixels.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h index ea7c375ee..918d74dc7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c index 1718c7363..ad7e9c313 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h b/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h index 234650dd4..98d5666d1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c index 9c1bfaace..a751974af 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h index b0bb3f99c..3b9ccce15 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c index e63b481b2..b78660240 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h index 12d0742df..c321bfada 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.c b/nx-X11/programs/Xserver/hw/nxagent/Render.c index 4f0f76474..6c74c147f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -584,16 +584,16 @@ XRenderPictFormat *nxagentMatchingFormats(PictFormatPtr pFormat) void nxagentDestroyPicture(PicturePtr pPicture) { + if (pPicture == NULL || nxagentPicturePriv(pPicture) -> picture == 0) + { + return; + } + #ifdef TEST fprintf(stderr, "nxagentDestroyPicture: Going to destroy picture at [%p].\n", (void *) pPicture); #endif - if (pPicture == NULL) - { - return; - } - XRenderFreePicture(nxagentDisplay, nxagentPicturePriv(pPicture) -> picture); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.h b/nx-X11/programs/Xserver/hw/nxagent/Render.h index 4346a4e1e..6f61ca85f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c index 612e71cf7..706aa9320 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -725,7 +725,57 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) } else { - XChangeProperty(nxagentDisplay, nxagentWindow(pWin), propertyX, typeX, format, mode, (void*)output, nUnits); + #ifdef TEST + fprintf(stderr, "nxagentExportProperty: Property [%lu] format [%i] " + "units [%lu].\n", propertyX, format, nUnits); + #endif + + if ((format >> 3) * nUnits + sizeof(xChangePropertyReq) < + (MAX_REQUEST_SIZE << 2)) + { + XChangeProperty(nxagentDisplay, nxagentWindow(pWin), propertyX, typeX, + format, mode, (void*)output, nUnits); + } + else if (mode == PropModeReplace) + { + int n; + char *data; + + XDeleteProperty(nxagentDisplay, nxagentWindow(pWin), propertyX); + + data = (char *) output; + + while (nUnits > 0) + { + if ((format >> 3) * nUnits + sizeof(xChangePropertyReq) < + (MAX_REQUEST_SIZE << 2)) + { + n = nUnits; + } + else + { + n = ((MAX_REQUEST_SIZE << 2) - sizeof(xChangePropertyReq)) / + (format >> 3); + } + + XChangeProperty(nxagentDisplay, nxagentWindow(pWin), propertyX, + typeX, format, PropModeAppend, (void*) data, n); + + nUnits -= n; + + data = (char *) data + n * (format >> 3); + } + } + else + { + #ifdef WARNING + fprintf(stderr, "nxagentExportProperty: WARNING! " + "Property [%lu] too long.\n", propertyX); + #endif + + goto nxagentExportPropertyError; + } + nxagentAddPropertyToList(propertyX, pWin); } } @@ -740,6 +790,8 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) #endif } + nxagentExportPropertyError: + if (freeMem) { xfree(output); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Rootless.h b/nx-X11/programs/Xserver/hw/nxagent/Rootless.h index ece4c9d31..1ea258db3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Rootless.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Rootless.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.c b/nx-X11/programs/Xserver/hw/nxagent/Screen.c index 2db7df8fe..0a0d409eb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -160,6 +160,7 @@ void nxagentPropagateArtsdProperties(ScreenPtr pScreen, char *port); #endif +Window nxagentIconWindow = None; Window nxagentFullscreenWindow = None; #ifdef VIEWPORT_FRAME @@ -287,6 +288,166 @@ void nxagentSetPixmapFormats(ScreenInfo *screenInfo) } } +void nxagentMinimizeFromFullScreen(ScreenPtr pScreen) +{ + XUnmapWindow(nxagentDisplay, nxagentFullscreenWindow); + + if (nxagentIpaq) + { + XMapWindow(nxagentDisplay, nxagentIconWindow); + XIconifyWindow(nxagentDisplay, nxagentIconWindow, + DefaultScreen(nxagentDisplay)); + } + else + { + XIconifyWindow(nxagentDisplay, nxagentIconWindow, + DefaultScreen(nxagentDisplay)); + } +} + +void nxagentMaximizeToFullScreen(ScreenPtr pScreen) +{ + if (nxagentIpaq) + { + XUnmapWindow(nxagentDisplay, nxagentIconWindow); + + XMapWindow(nxagentDisplay, nxagentFullscreenWindow); + } + else + { +/* + XUnmapWindow(nxagentDisplay, nxagentIconWindow); +*/ +/* +FIXME: We'll chech for ReparentNotify and LeaveNotify events after XReparentWindow() + in order to avoid the session window is iconified. + We could avoid the sesssion window is iconified when a LeaveNotify event is received, + so this check would be unnecessary. +*/ + struct timeval timeout; + int i; + XEvent e; + + XReparentWindow(nxagentDisplay, nxagentFullscreenWindow, + RootWindow(nxagentDisplay, DefaultScreen(nxagentDisplay)), 0, 0); + + for (i = 0; i < 100 && nxagentWMIsRunning; i++) + { + #ifdef TEST + fprintf(stderr, "nxagentMaximizeToFullscreen: WARNING! Going to wait for the ReparentNotify event.\n"); + #endif + + if (XCheckTypedWindowEvent(nxagentDisplay, nxagentFullscreenWindow, ReparentNotify, &e)) + { + break; + } + + XSync(nxagentDisplay, 0); + + timeout.tv_sec = 0; + timeout.tv_usec = 50 * 1000; + + nxagentWaitEvents(nxagentDisplay, &timeout); + } + + XMapRaised(nxagentDisplay, nxagentFullscreenWindow); + + XIconifyWindow(nxagentDisplay, nxagentIconWindow, + DefaultScreen(nxagentDisplay)); + + while (XCheckTypedWindowEvent(nxagentDisplay, nxagentFullscreenWindow, LeaveNotify, &e)); +/* + XMapWindow(nxagentDisplay, nxagentIconWindow); +*/ + } +} + +Window nxagentCreateIconWindow() +{ + XSetWindowAttributes attributes; + unsigned long valuemask; + char* window_name; + XTextProperty windowName; + XSizeHints sizeHints; + XWMHints wmHints; + Window w; + Mask mask; + + /* + * Create icon window. + */ + + attributes.override_redirect = False; + attributes.colormap = DefaultColormap(nxagentDisplay, DefaultScreen(nxagentDisplay)); + attributes.background_pixmap = nxagentScreenSaverPixmap; + valuemask = CWOverrideRedirect | CWBackPixmap | CWColormap; + + #ifdef TEST + fprintf(stderr, "nxagentCreateIconWindow: Going to create new icon window.\n"); + #endif + + w = XCreateWindow(nxagentDisplay, DefaultRootWindow(nxagentDisplay), + 0, 0, 1, 1, 0, + DefaultDepth(nxagentDisplay, DefaultScreen(nxagentDisplay)), + InputOutput, + DefaultVisual(nxagentDisplay, DefaultScreen(nxagentDisplay)), + valuemask, &attributes); + + #ifdef TEST + fprintf(stderr, "nxagentCreateIconWindow: Created new icon window with id [%ld].\n", + nxagentIconWindow); + #endif + + /* + * Set hints to the window manager for the icon window. + */ + + window_name = nxagentWindowName; + XStringListToTextProperty(&window_name, 1, &windowName); + sizeHints.flags = PMinSize | PMaxSize; + sizeHints.min_width = sizeHints.max_width = 1; + sizeHints.min_height = sizeHints.max_height = 1; + wmHints.flags = IconPixmapHint | IconMaskHint; + wmHints.initial_state = IconicState; + wmHints.icon_pixmap = nxagentIconPixmap; + + if (useXpmIcon) + { + wmHints.icon_mask = nxagentIconShape; + wmHints.flags = IconPixmapHint | IconMaskHint; + } + else + { + wmHints.flags = StateHint | IconPixmapHint; + } + + XSetWMProperties(nxagentDisplay, w, + &windowName, &windowName, + NULL , 0 , &sizeHints, &wmHints, NULL); + + /* + * Enable events from the icon window. + */ + + nxagentGetDefaultEventMask(&mask); + + XSelectInput(nxagentDisplay, w, (mask & ~(KeyPressMask | + KeyReleaseMask)) | StructureNotifyMask); + + /* + * Notify to client if user closes icon window. + */ + + if (nxagentWMIsRunning && !nxagentOption(Rootless)) + { + XlibAtom deleteWMAtom = nxagentAtoms[2]; /* WM_DELETE_WINDOW */ + + XSetWMProtocols(nxagentDisplay, w, &deleteWMAtom, 1); + } + + return w; +} + Bool nxagentMagicPixelZone(int x, int y) { return (x >= nxagentOption(Width) - 1 && y < 1); @@ -816,6 +977,8 @@ Bool nxagentOpenScreen(int index, ScreenPtr pScreen, nxagentChangeOption(Fullscreen, False); + nxagentChangeOption(AllScreens, False); + nxagentFullscreenWindow = 0; resetAgentPosition = True; @@ -1221,6 +1384,11 @@ N/A nxagentChangeOption(Height, gattributes.height); } + if (nxagentOption(AllScreens)) + { + attributes.override_redirect = True; + } + if (nxagentOption(Fullscreen)) { /* @@ -1448,7 +1616,8 @@ N/A if (nxagentDoFullGeneration == 1 || nxagentReconnectTrap == 1) { - valuemask = CWBackPixel | CWEventMask | CWColormap; + valuemask = CWBackPixel | CWEventMask | CWColormap | + (nxagentOption(AllScreens) == 1 ? CWOverrideRedirect : 0); attributes.background_pixel = nxagentBlackPixel; @@ -1456,6 +1625,11 @@ N/A attributes.colormap = nxagentDefaultVisualColormap(nxagentDefaultVisual(pScreen)); + if (nxagentOption(AllScreens) == 1) + { + attributes.override_redirect = True; + } + if (nxagentOption(Fullscreen) == 1) { if (nxagentReconnectTrap) @@ -1635,6 +1809,21 @@ N/A XClearWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum]); + if (nxagentOption(AllScreens)) + { + if (nxagentReconnectTrap) + { + XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, True, GrabModeAsync, + GrabModeAsync, CurrentTime); + } + + nxagentIconWindow = nxagentCreateIconWindow(); + } + else + { + nxagentIconWindow = 0; + } + /* * When we don't have window manager we grab keyboard * to let nxagent get keyboard events. @@ -1983,8 +2172,6 @@ Bool nxagentResizeScreen(ScreenPtr pScreen, int width, int height, int oldMmWidth; int oldMmHeight; - RegionPtr pRootWinSize; - #ifdef TEST nxagentPrintAgentGeometry("Before Resize Screen", "nxagentResizeScreen:"); #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.h b/nx-X11/programs/Xserver/hw/nxagent/Screen.h index 1ab6caad2..5b1957755 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -47,6 +47,8 @@ extern ScreenPtr nxagentDefaultScreen; extern Pixmap nxagentPixmapLogo; +extern Window nxagentIconWindow; + extern Window nxagentFullscreenWindow; extern RegionRec nxagentShadowUpdateRegion; @@ -87,6 +89,12 @@ extern int nxagentBitsPerPixel(int depth); void nxagentSetScreenSaverTime(void); +void nxagentMinimizeFromFullScreen(ScreenPtr pScreen); + +void nxagentMaximizeToFullScreen(ScreenPtr pScreen); + +Window nxagentCreateIconWindow(void); + Bool nxagentMagicPixelZone(int x, int y); Bool nxagentResizeScreen(ScreenPtr pScreen, int width, int height, diff --git a/nx-X11/programs/Xserver/hw/nxagent/Splash.c b/nx-X11/programs/Xserver/hw/nxagent/Splash.c index 24dbf1413..235c48c23 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Splash.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Splash.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Splash.h b/nx-X11/programs/Xserver/hw/nxagent/Splash.h index 86920ad8b..f7ba6c2e2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Splash.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Splash.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Split.c b/nx-X11/programs/Xserver/hw/nxagent/Split.c index bf7f705b9..4cc2ea607 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Split.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Split.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Split.h b/nx-X11/programs/Xserver/hw/nxagent/Split.h index 60be29b39..2be449a18 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Split.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Split.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/TestExt.c b/nx-X11/programs/Xserver/hw/nxagent/TestExt.c index 1d5fdee20..6bce2eaeb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/TestExt.c +++ b/nx-X11/programs/Xserver/hw/nxagent/TestExt.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.c b/nx-X11/programs/Xserver/hw/nxagent/Trap.c index 22de3bc1b..f5e6bde0e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Trap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.h b/nx-X11/programs/Xserver/hw/nxagent/Trap.h index aa6937e70..9258e3b67 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Trap.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Utils.h b/nx-X11/programs/Xserver/hw/nxagent/Utils.h index 830b2753f..f5bd55d8b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Utils.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Utils.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Visual.c b/nx-X11/programs/Xserver/hw/nxagent/Visual.c index f38931677..b086c0e9a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Visual.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Visual.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Visual.h b/nx-X11/programs/Xserver/hw/nxagent/Visual.h index c682f92dd..8436f79ad 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Visual.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Visual.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Window.c b/nx-X11/programs/Xserver/hw/nxagent/Window.c index 2da21b91c..3e6d41d04 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Window.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Window.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -693,7 +693,6 @@ void nxagentRestackWindow(WindowPtr pWin, WindowPtr pOldNextSib) void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn) { XEvent e; - XSizeHints sizeHints; if (nxagentOption(Rootless) == 1) { @@ -731,27 +730,6 @@ void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn) nxagentChangeOption(Fullscreen, switchOn); - if (nxagentOption(DesktopResize) == 1) - { - sizeHints.flags = PSize; - - if (switchOn == 1) - { - sizeHints.width = - WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); - sizeHints.height = - HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); - } - else - { - sizeHints.width = nxagentOption(RootWidth); - sizeHints.height = nxagentOption(RootHeight); - } - - XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], - &sizeHints); - } - memset(&e, 0, sizeof(e)); e.xclient.type = ClientMessage; @@ -779,6 +757,245 @@ void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn) } } +void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn) +{ + Window w; + XSetWindowAttributes attributes; + unsigned long valuemask; + + if (nxagentOption(Rootless)) + { + return; + } + + if (!switchOn) + { + nxagentWMDetect(); + + if (!nxagentWMIsRunning) + { + #ifdef WARNING + fprintf(stderr, "Warning: Can't switch to window mode, no window manager has been detected.\n"); + #endif + + return; + } + } + + w = nxagentDefaultWindows[pScreen -> myNum]; + attributes.override_redirect = switchOn; + valuemask = CWOverrideRedirect; + XUnmapWindow(nxagentDisplay, w); + XChangeWindowAttributes(nxagentDisplay, w, valuemask, &attributes); + + XReparentWindow(nxagentDisplay, w, DefaultRootWindow(nxagentDisplay), 0, 0); + + if (switchOn) + { + /* + * Change to fullscreen mode. + */ + + struct timeval timeout; + int i; + XEvent e; + + /* + * Wait for window manager reparenting the default window. + */ + + for (i = 0; i < 100 && nxagentWMIsRunning; i++) + { + #ifdef TEST + fprintf(stderr, "nxagentSwitchAllScreens: WARNING! Going to wait for the ReparentNotify event.\n"); + #endif + + if (XCheckTypedWindowEvent(nxagentDisplay, w, ReparentNotify, &e)) + { + break; + } + + /* + * This should also flush + * the NX link for us. + */ + + XSync(nxagentDisplay, 0); + + timeout.tv_sec = 0; + timeout.tv_usec = 50 * 1000; + + nxagentWaitEvents(nxagentDisplay, &timeout); + } + + if (i < 100) + { + /* + * The window manager has done with the reparent + * operation. We can resize and map the window. + */ + + nxagentChangeOption(Fullscreen, True); + nxagentChangeOption(AllScreens, True); + + + /* + * Save the window-mode configuration. + */ + + nxagentChangeOption(SavedX, nxagentOption(X)); + nxagentChangeOption(SavedY, nxagentOption(Y)); + nxagentChangeOption(SavedWidth, nxagentOption(Width)); + nxagentChangeOption(SavedHeight, nxagentOption(Height)); + nxagentChangeOption(SavedRootWidth, nxagentOption(RootWidth)); + nxagentChangeOption(SavedRootHeight, nxagentOption(RootHeight)); + + /* + * Reconf the Default window. + */ + + nxagentChangeOption(X, 0); + nxagentChangeOption(Y, 0); + nxagentChangeOption(Width, WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); + nxagentChangeOption(Height, HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); + + /* + * Move the root window. + */ + + nxagentChangeOption(RootX, (nxagentOption(Width) - nxagentOption(RootWidth)) / 2); + nxagentChangeOption(RootY, (nxagentOption(Height) - nxagentOption(RootHeight)) / 2); + nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - nxagentOption(RootWidth)); + nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - nxagentOption(RootHeight)); + + XMoveResizeWindow(nxagentDisplay, w, nxagentOption(X), nxagentOption(Y), + nxagentOption(Width), nxagentOption(Height)); + + nxagentUpdateViewportFrame(0, 0, nxagentOption(RootWidth), nxagentOption(RootHeight)); + + XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), + nxagentOption(RootX), nxagentOption(RootY)); + + /* + * We disable the screensaver when changing + * mode to fullscreen. Is it really needed? + */ + + XSetScreenSaver(nxagentDisplay, 0, 0, DefaultExposures, DefaultBlanking); + + if (nxagentIconWindow == None) + { + nxagentIconWindow = nxagentCreateIconWindow(); + + XMapWindow(nxagentDisplay, nxagentIconWindow); + } + + XMapRaised(nxagentDisplay, w); + XSetInputFocus(nxagentDisplay, w, RevertToParent, CurrentTime); + XCheckTypedWindowEvent(nxagentDisplay, w, LeaveNotify, &e); + nxagentFullscreenWindow = w; + + if (nxagentOption(DesktopResize) == 1) + { + if (nxagentOption(Shadow) == 0) + { + nxagentRRSetScreenConfig(pScreen, WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)), + HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); + } + else + { + nxagentShadowAdaptToRatio(); + } + } + } + else + { + /* + * We have waited for a reparent event unsuccessfully. + * Something happened to the window manager. + */ + + #ifdef WARNING + fprintf(stderr, "nxagentSwitchAllScreens: WARNING! Expected ReparentNotify event missing.\n"); + #endif + + nxagentWMIsRunning = False; + attributes.override_redirect = False; + XChangeWindowAttributes(nxagentDisplay, w, valuemask, &attributes); + XMapWindow(nxagentDisplay, w); + } + } + else + { + /* + * FIXME: + * It could be necessary: + * - To restore screensaver. + * - To set or reset nxagentForceBackingStore flag. + * - To propagate device settings to the X server if no WM is running. + */ + + /* + * Change to windowed mode. + */ + + nxagentChangeOption(Fullscreen, False); + nxagentChangeOption(AllScreens, False); + + XDestroyWindow(nxagentDisplay, nxagentIconWindow); + + nxagentIconWindow = nxagentFullscreenWindow = None; + + if (nxagentOption(DesktopResize) == 1) + { + nxagentChangeOption(RootWidth, nxagentOption(SavedRootWidth)); + nxagentChangeOption(RootHeight, nxagentOption(SavedRootHeight)); + + if (nxagentOption(Shadow) == 0) + { + nxagentRRSetScreenConfig(pScreen, nxagentOption(RootWidth), nxagentOption(RootHeight)); + } + } + + if (nxagentOption(WMBorderWidth) > 0 && nxagentOption(WMTitleHeight) > 0) + { + nxagentChangeOption(X, nxagentOption(SavedX) - + nxagentOption(WMBorderWidth)); + nxagentChangeOption(Y, nxagentOption(SavedY) - + nxagentOption(WMTitleHeight)); + } + else + { + nxagentChangeOption(X, nxagentOption(SavedX)); + nxagentChangeOption(Y, nxagentOption(SavedY)); + } + + nxagentChangeOption(Width, nxagentOption(SavedWidth)); + nxagentChangeOption(Height, nxagentOption(SavedHeight)); + + if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1) + { + nxagentShadowAdaptToRatio(); + } + + XMoveResizeWindow(nxagentDisplay, w, nxagentOption(X), nxagentOption(Y), + nxagentOption(Width), nxagentOption(Height)); + + nxagentUpdateViewportFrame(0, 0, nxagentOption(Width), nxagentOption(Height)); + + XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), 0, 0); + XMapWindow(nxagentDisplay, w); + + nxagentChangeOption(RootX, 0); + nxagentChangeOption(RootY, 0); + } + + XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, + nxagentOption(Width), nxagentOption(Height)); + + nxagentSetPrintGeometry(pScreen -> myNum); +} + #ifdef VIEWPORT_FRAME void nxagentUpdateViewportFrame(int x, int y, int w, int h) @@ -2281,7 +2498,7 @@ void nxagentMapDefaultWindows() if (nxagentOption(Fullscreen) == 1 && nxagentWMIsRunning == 1) { - nxagentSwitchFullscreen(pScreen, 1); + nxagentMaximizeToFullScreen(pScreen); } } @@ -2312,6 +2529,26 @@ void nxagentMapDefaultWindows() nxagentDefaultWindows[i], CurrentTime); } + /* + * Map the icon window. + */ + + if (nxagentIconWindow != 0) + { + #ifdef TEST + fprintf(stderr, "nxagentMapDefaultWindows: Mapping icon window id [%ld].\n", + nxagentIconWindow); + #endif + + XMapWindow(nxagentDisplay, nxagentIconWindow); + + if (nxagentIpaq != 0) + { + XIconifyWindow(nxagentDisplay, nxagentIconWindow, + DefaultScreen(nxagentDisplay)); + } + } + /* * Ensure that the fullscreen window gets the focus. */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Windows.h b/nx-X11/programs/Xserver/hw/nxagent/Windows.h index 6fc97b341..3ca74ba8e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Windows.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Windows.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -222,6 +222,8 @@ void nxagentSetTopLevelEventMask(WindowPtr pWin); void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn); +void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn); + void nxagentMoveViewport(ScreenPtr pScreen, int hShift, int vShift); #ifdef VIEWPORT_FRAME diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c index 7bc1c74cb..cf5d48ba2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original index 7bc1c74cb..cf5d48ba2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c index ba4e1e662..69ad30d2d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original index ba4e1e662..69ad30d2d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c index 225ecdaf8..04fc047fc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original index 225ecdaf8..04fc047fc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c index 8e87d58c4..c5593adbb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original index 8e87d58c4..c5593adbb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c index 6e67b7ffe..ead9b9d28 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original index 6e67b7ffe..ead9b9d28 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c index 172252b32..51c547984 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original index 172252b32..51c547984 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c index 6340de537..cd65fdc0e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original index 6340de537..cd65fdc0e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c index d6cd96631..7a1d813b3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original index d6cd96631..7a1d813b3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h index e78a1bf14..fa6b5fb02 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original index e78a1bf14..fa6b5fb02 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c index c71ea8142..3fc73cf3b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original index c71ea8142..3fc73cf3b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c index efb295861..5f32334ae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original index efb295861..5f32334ae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c index d2bead0bc..f418654b4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original index d2bead0bc..f418654b4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c index be1096c6c..190294979 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original index be1096c6c..190294979 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c index be961c400..d9054b4b6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -873,6 +873,9 @@ AllocatePicture (ScreenPtr pScreen) else ppriv->ptr = (pointer)NULL; } + + nxagentPicturePriv(pPicture) -> picture = 0; + return pPicture; } @@ -1103,6 +1106,8 @@ static PicturePtr createSourcePicture(void) ppriv[nxagentPicturePrivateIndex].ptr = (pointer) privPictureRecAddr; pPicture -> devPrivates = ppriv; + + nxagentPicturePriv(pPicture) -> picture = 0; } pPicture->pDrawable = 0; diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original index be961c400..d9054b4b6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -873,6 +873,9 @@ AllocatePicture (ScreenPtr pScreen) else ppriv->ptr = (pointer)NULL; } + + nxagentPicturePriv(pPicture) -> picture = 0; + return pPicture; } @@ -1103,6 +1106,8 @@ static PicturePtr createSourcePicture(void) ppriv[nxagentPicturePrivateIndex].ptr = (pointer) privPictureRecAddr; pPicture -> devPrivates = ppriv; + + nxagentPicturePriv(pPicture) -> picture = 0; } pPicture->pDrawable = 0; diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h index b6cee91f1..0d1a8e1d8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original index b6cee91f1..0d1a8e1d8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c index d02f3f015..cd1ec6ddd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original index d02f3f015..cd1ec6ddd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c index e1bb44148..5f460f23e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original index e1bb44148..5f460f23e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c index 562cd2c66..89e790135 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c @@ -26,7 +26,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original index 562cd2c66..89e790135 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original @@ -26,7 +26,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c index 8c69217e7..d1c8325f2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original index 8c69217e7..d1c8325f2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c index b99cbe3e3..eaaa92041 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original index b99cbe3e3..eaaa92041 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c index 4022bc397..76e86fd2a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original index 4022bc397..76e86fd2a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c index aa902226e..f6dad312a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original index aa902226e..f6dad312a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm b/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm index 5955f1705..dd8be6cb3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm +++ b/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm b/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm index e7dee27b1..854e0a611 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm +++ b/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c b/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c index 80419d871..9ec7e6bc8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c +++ b/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/screensaver b/nx-X11/programs/Xserver/hw/nxagent/screensaver index 4c5c10620..ef7cd661a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/screensaver +++ b/nx-X11/programs/Xserver/hw/nxagent/screensaver @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ -- cgit v1.2.3 From d30ef0340e759378964b75e8143625ecaea245b0 Mon Sep 17 00:00:00 2001 From: Reinhard Tartler Date: Mon, 10 Oct 2011 17:58:58 +0200 Subject: Imported nxagent-3.4.0-3.tar.gz Summary: Imported nxagent-3.4.0-3.tar.gz Keywords: Imported nxagent-3.4.0-3.tar.gz into Git repository --- nx-X11/programs/Xserver/hw/nxagent/Agent.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Args.c | 19 +- nx-X11/programs/Xserver/hw/nxagent/Args.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Atoms.c | 30 +- nx-X11/programs/Xserver/hw/nxagent/Atoms.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Binder.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Binder.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/CHANGELOG | 165 ------ nx-X11/programs/Xserver/hw/nxagent/Client.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Client.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Clipboard.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Clipboard.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Colormap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Colormap.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Composite.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Composite.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Cursor.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Cursor.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Dialog.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Dialog.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Display.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Display.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Drawable.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Drawable.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Error.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Error.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Events.c | 603 ++------------------- nx-X11/programs/Xserver/hw/nxagent/Events.h | 8 +- nx-X11/programs/Xserver/hw/nxagent/Extensions.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Extensions.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Font.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Font.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/GC.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCOps.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCOps.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCs.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Handlers.c | 5 +- nx-X11/programs/Xserver/hw/nxagent/Handlers.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Holder.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Holder.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Icons.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Image.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Image.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Imakefile | 3 +- nx-X11/programs/Xserver/hw/nxagent/Init.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Init.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keyboard.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keyboard.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keystroke.c | 78 +-- nx-X11/programs/Xserver/hw/nxagent/Keystroke.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/LICENSE | 2 +- nx-X11/programs/Xserver/hw/nxagent/Literals.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Millis.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Millis.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c | 2 +- .../Xserver/hw/nxagent/NXdispatch.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c | 2 +- .../Xserver/hw/nxagent/NXdixfonts.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXevents.c | 2 +- .../Xserver/hw/nxagent/NXevents.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXextension.c | 2 +- .../Xserver/hw/nxagent/NXextension.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyph.c | 2 +- .../Xserver/hw/nxagent/NXglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c | 2 +- .../Xserver/hw/nxagent/NXglyphcurs.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h | 2 +- .../Xserver/hw/nxagent/NXglyphstr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c | 2 +- .../Xserver/hw/nxagent/NXmiglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXpicture.c | 2 +- .../Xserver/hw/nxagent/NXpicture.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h | 2 +- .../Xserver/hw/nxagent/NXpicturestr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXproperty.c | 2 +- .../Xserver/hw/nxagent/NXproperty.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXrandr.c | 2 +- .../Xserver/hw/nxagent/NXrandr.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXrender.c | 2 +- .../Xserver/hw/nxagent/NXrender.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXwindow.c | 2 +- .../Xserver/hw/nxagent/NXwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Options.c | 8 +- nx-X11/programs/Xserver/hw/nxagent/Options.h | 12 +- nx-X11/programs/Xserver/hw/nxagent/Pixels.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pixels.h | 20 +- nx-X11/programs/Xserver/hw/nxagent/Pixmap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pointer.c | 36 +- nx-X11/programs/Xserver/hw/nxagent/Pointer.h | 11 +- nx-X11/programs/Xserver/hw/nxagent/Reconnect.c | 6 +- nx-X11/programs/Xserver/hw/nxagent/Reconnect.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Render.c | 293 +--------- nx-X11/programs/Xserver/hw/nxagent/Render.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/Rootless.c | 99 +--- nx-X11/programs/Xserver/hw/nxagent/Rootless.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Screen.c | 130 ++++- nx-X11/programs/Xserver/hw/nxagent/Screen.h | 6 +- nx-X11/programs/Xserver/hw/nxagent/Splash.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Splash.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Split.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Split.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/TestExt.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Trap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Trap.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Utils.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Visual.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Visual.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Window.c | 152 +----- nx-X11/programs/Xserver/hw/nxagent/Windows.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c | 2 +- .../Xserver/hw/nxagent/X/NXdamage.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c | 28 +- .../Xserver/hw/nxagent/X/NXdispatch.c.NX.original | 28 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c | 2 +- .../Xserver/hw/nxagent/X/NXdixfonts.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c | 2 +- .../Xserver/hw/nxagent/X/NXevents.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c | 2 +- .../Xserver/hw/nxagent/X/NXextension.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c | 2 +- .../Xserver/hw/nxagent/X/NXglxext.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c | 2 +- .../Xserver/hw/nxagent/X/NXglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c | 2 +- .../Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h | 2 +- .../Xserver/hw/nxagent/X/NXglyphstr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c | 2 +- .../Xserver/hw/nxagent/X/NXmiexpose.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c | 2 +- .../Xserver/hw/nxagent/X/NXmiglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c | 2 +- .../Xserver/hw/nxagent/X/NXmitrap.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c | 2 +- .../Xserver/hw/nxagent/X/NXmiwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c | 54 +- .../Xserver/hw/nxagent/X/NXpicture.c.NX.original | 54 +- .../programs/Xserver/hw/nxagent/X/NXpicturestr.h | 2 +- .../hw/nxagent/X/NXpicturestr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c | 2 +- .../Xserver/hw/nxagent/X/NXproperty.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c | 2 +- .../Xserver/hw/nxagent/X/NXrandr.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c | 60 +- .../Xserver/hw/nxagent/X/NXrender.c.NX.original | 60 +- nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c | 2 +- .../Xserver/hw/nxagent/X/NXresource.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c | 2 +- .../Xserver/hw/nxagent/X/NXshm.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c | 2 +- .../Xserver/hw/nxagent/X/NXwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c | 2 +- .../Xserver/hw/nxagent/X/NXxvdisp.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm | 2 +- nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm | 2 +- nx-X11/programs/Xserver/hw/nxagent/os2Stub.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/screensaver | 2 +- 161 files changed, 382 insertions(+), 1866 deletions(-) (limited to 'nx-X11/programs/Xserver/hw/nxagent/Render.h') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Agent.h b/nx-X11/programs/Xserver/hw/nxagent/Agent.h index dbed1e0d8..13f87c96e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Agent.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Agent.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.c b/nx-X11/programs/Xserver/hw/nxagent/Args.c index 8fbb275a6..0588f43d6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Args.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Args.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -562,15 +562,11 @@ int ddxProcessArgument(int argc, char *argv[], int i) if (!strcmp(argv[i],"fullscreen")) { nxagentChangeOption(Fullscreen, True); - - nxagentChangeOption(AllScreens, True); } else if (!strcmp(argv[i],"ipaq")) { nxagentChangeOption(Fullscreen, True); - nxagentChangeOption(AllScreens, True); - nxagentIpaq = True; } else @@ -1075,14 +1071,10 @@ static void nxagentParseOptions(char *name, char *value) else if (!strcmp(value, "1")) { nxagentChangeOption(Fullscreen, True); - - nxagentChangeOption(AllScreens, True); } else if (!strcmp(value, "0")) { nxagentChangeOption(Fullscreen, False); - - nxagentChangeOption(AllScreens, False); } else { @@ -1216,7 +1208,7 @@ static void nxagentParseOptions(char *name, char *value) { nxagentChangeOption(ClientOs, ClientOsSolaris); } - else if (strcmp(value, "macosx") == 0) + else if (strcmp(value, "mac") == 0) { nxagentChangeOption(ClientOs, ClientOsMac); } @@ -1520,7 +1512,7 @@ N/A int splitMode = 0; int splitSize = 0; - unsigned int packMethod = PACK_NONE; + unsigned int packMethod = PACK_NONE; unsigned int packQuality = 9; int dataLevel = 0; @@ -1688,11 +1680,6 @@ N/A nxagentChangeOption(Fullscreen, False); } - if (nxagentOption(AllScreens) == UNDEFINED) - { - nxagentChangeOption(AllScreens, False); - } - if (nxagentOption(Binder) == UNDEFINED) { nxagentChangeOption(Binder, False); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.h b/nx-X11/programs/Xserver/hw/nxagent/Args.h index 9cb97ca03..2aac8e387 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Args.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Args.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c index 578731f07..13f9b8082 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -66,21 +66,19 @@ Atom nxagentAtoms[NXAGENT_NUMBER_OF_ATOMS]; static char *nxagentAtomNames[NXAGENT_NUMBER_OF_ATOMS + 1] = { - "NX_IDENTITY", /* 0 */ - "WM_PROTOCOLS", /* 1 */ - "WM_DELETE_WINDOW", /* 2 */ - "WM_NX_READY", /* 3 */ - "MCOPGLOBALS", /* 4 */ - "NX_CUT_BUFFER_SERVER", /* 5 */ - "TARGETS", /* 6 */ - "TEXT", /* 7 */ - "NX_AGENT_SIGNATURE", /* 8 */ - "NXDARWIN", /* 9 */ - "CLIPBOARD", /* 10 */ - "TIMESTAMP", /* 11 */ - "UTF8_STRING", /* 12 */ - "_NET_WM_STATE", /* 13 */ - "_NET_WM_STATE_FULLSCREEN", /* 14 */ + "NX_IDENTITY", /* 0 */ + "WM_PROTOCOLS", /* 1 */ + "WM_DELETE_WINDOW", /* 2 */ + "WM_NX_READY", /* 3 */ + "MCOPGLOBALS", /* 4 */ + "NX_CUT_BUFFER_SERVER", /* 5 */ + "TARGETS", /* 6 */ + "TEXT", /* 7 */ + "NX_AGENT_SIGNATURE", /* 8 */ + "NXDARWIN", /* 9 */ + "CLIPBOARD", /* 10 */ + "TIMESTAMP", /* 11 */ + "UTF8_STRING", /* 12 */ NULL, NULL }; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h index d5b7fe5aa..842b820db 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -22,7 +22,7 @@ #include "../../include/window.h" #include "screenint.h" -#define NXAGENT_NUMBER_OF_ATOMS 16 +#define NXAGENT_NUMBER_OF_ATOMS 14 extern Atom nxagentAtoms[NXAGENT_NUMBER_OF_ATOMS]; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.c b/nx-X11/programs/Xserver/hw/nxagent/Binder.c index d40aaebe6..4fb5224fb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Binder.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.h b/nx-X11/programs/Xserver/hw/nxagent/Binder.h index f28a82b9f..c4daeea8c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Binder.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG index 64e41b8cc..4e964d0ad 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG +++ b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG @@ -1,170 +1,5 @@ ChangeLog: -nxagent-3.4.0-16 - -- Updated copyright to year 2011. - -nxagent-3.4.0-15 - -- Added reference to fixed TR11H02405. - -nxagent-3.4.0-14 - -- Reverted fix for TR03H02335 implemented in nxagent-3.4.0-6. The - emulation of right click by Control key + left click introduces - issues for some applications changing the reaction to the left click - depending on the state of Control key. Issue reported in TR03H02335 - affects Apple laptop touchpads having a single button acting as - left button: on those devices the right button can be emulated by - a double-fingered tap (using two fingertips simultaneously). - -nxagent-3.4.0-13 - -- Fixed TR12H02414. Exported property must be split if ChangeProperty - request exceeds 262140 bytes. - -- Reset AllScreens option at reconnection time if full screen mode - have to be automatically turned off. - -nxagent-3.4.0-12 - -- If one of the two full screen modes is active ('one screen' or 'all - screens') both keystrokes Ctrl-Alt-F and Ctrl-Alt-Shift-F change the - mode back to 'windowed'. - -- Fixed TR11H02405. XRenderFreePicture is called only for pictures - that were actually created on the X server side. - -- Ctrl+Alt+f switch fullscreen to all monitors, while Ctrl+Alt+Shift+f - does it to one monitor only. - -- If the fullscreen option is enabled at the startup, session starts - in the fullscreen mode on all monitors. - -- Added a call to XReparentWindow in the nxagentSwitchAllScreens(). - -- Corrected focus and grab when switching to fullscreen on - all monitors. - -- Removed a compile warning e deleted some unused variables. - -- Removed nxagentPointerAndKeyboardGrabbed variable. - -- Use the override redirect attribute to switch to fullscreen to all - monitors instead of send _NET_WM_FULLSCREEN_MONITORS hint to the WM. - -- Added nxagentMinimizeFromFullScreen(), nxagentMaximizeToFullScreen() - and nxagentCreateIconWindow(). - -- Removed check on EnterNotify to grab the keyboard in fullscreen - mode not only if mode is 'NotifyNormal'. - -nxagent-3.4.0-11 - -- Corrected switching between viewport mode and resize mode. - -- Fixed TR04H02340. Keycode is correctly translated in shadow sessions - also if the remote X display is using evdev. - -nxagent-3.4.0-10 - -- Handled XGrabKeyboard() return value. - -- Fixed TR10D01512. NumLock and CapsLock keys are now synchronized - between local and remote. - -nxagent-3.4.0-9 - -- Fixed TR06H02362. No icon was swown in the task bar. - -- Fixed keyboard grab in fullscreen mode. - -- Fixed compiler warnings. - -nxagent-3.4.0-8 - -- Grab the keyboard in fullscreen mode on EnterNotify only if mode is - 'NotifyNormal'. - -- Yield control in the dispatch loop in case we stop the smart sche- - duler timer while waiting for a reply from the remote display. - -nxagent-3.4.0-7 - -- Fixed TR08D01478. The communication with the compiz window manager - by means of the _NET_WM_PING property was not handled properly. - -- Fixed a type mismatch in XKB events on 64 bit platforms. - -- Moved grab/ungrab keyboard from focus in/out event to enter/leave - notify event. - -- Removed nxagentIconWindow because it's not longer used. - -nxagent-3.4.0-6 - -- Fixed TR09F02102. Problem was with pointer buttons map. - -- Fixed TR02H02327. Some KeyRelease events was discarded. - -- Fixed up Num and Caps locks. - -- Fixed TR03H02335. Emulated right mouse button for Mac clients. - -- Added utilities to print info about internal and remote windows. - -- Fixed TR01F01995. Solved a picture resource leak by destroying remo- - te pictures only when their reference counter returns to zero. - -- Fixed TR04H02337. Errors occurred because pictures with no drawable - were handled badly. - -- Implemented handling nxagent's private for gradient pictures and so- - lid fill picture. - -- Fixed BadMatch condition check in function ProcRenderComposite. - -- Fixed nxagentComposite() to handle situations with source picture - drawable pointing to NULL. - -- Implemented render acceleration for requests: CreateSolidFill, - CreateLinearGradient, CreateRadialGradient, CreateConicalGradient. - -- Fixed TR03G02196. Dialogs are shown to the fore when the NX session - is in fullscreen mode. - -- Changed mechanism to switch to fullscreen mode. Now the override - redirect attribute is no longer used and _NET_WM_STATE_FULLSCREEN - hint is sent to the WM. - -nxagent-3.4.0-5 - -- Updated copyright to year 2010. - -nxagent-3.4.0-4 - -- Fixed TR07F02090. Now XDMCP sessions start without problems. - -- Fixed TR08G02259. Corrected window border granularity of rootless - session at reconnection on 64 bit platforms. - -- Fixed TR11G02290. Forcing null timeout with queued events only if - display connection is up. This prevents the flood of session log. - -- Fixed TR10G02287. Now QueryTree's loop is aborted in case of failure - and session log isn't filled anymore with repeated warning messages. - -- Fixed TR01G02154. Corrected window placement when switching between - fullscreen and windowed mode. - -- Fixed TR09G02276. Now the agent does not receive unwanted characters - while interacting with the local window manager. - -- Implemented FR02G02174. Added ability to do large screen pans in - viewport mode through key combination Ctrl+Alt+Shift+Arrow. - -- Corrected parsing of the 'client' option when the client OS is Mac. - nxagent-3.4.0-3 - Fixed TR09G02271. The array containing the font name fields was not diff --git a/nx-X11/programs/Xserver/hw/nxagent/Client.c b/nx-X11/programs/Xserver/hw/nxagent/Client.c index 63ed0e134..b0db1df0f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Client.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Client.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Client.h b/nx-X11/programs/Xserver/hw/nxagent/Client.h index a9b06c845..4b12ed127 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Client.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Client.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c index 2742e147f..442b1c871 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h index 43189df81..5a592a4da 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c index b0f0507b5..d9a979a42 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.h b/nx-X11/programs/Xserver/hw/nxagent/Colormap.h index b2960590c..a8e225460 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Composite.c b/nx-X11/programs/Xserver/hw/nxagent/Composite.c index c79104fc1..44bab3cf9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Composite.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Composite.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Composite.h b/nx-X11/programs/Xserver/hw/nxagent/Composite.h index e875d0051..c5dede9eb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Composite.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Composite.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Cursor.c b/nx-X11/programs/Xserver/hw/nxagent/Cursor.c index 9ed7c233f..7e4385712 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Cursor.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Cursor.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Cursor.h b/nx-X11/programs/Xserver/hw/nxagent/Cursor.h index df7dc44f7..7b4e6beac 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Cursor.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Cursor.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Dialog.c b/nx-X11/programs/Xserver/hw/nxagent/Dialog.c index 0fb9491a4..c6f8a9104 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Dialog.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Dialog.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Dialog.h b/nx-X11/programs/Xserver/hw/nxagent/Dialog.h index bd12f3097..5c71fad87 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Dialog.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Dialog.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.c b/nx-X11/programs/Xserver/hw/nxagent/Display.c index 87be98116..c1a80b391 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.h b/nx-X11/programs/Xserver/hw/nxagent/Display.h index 454150d6e..4c04c5ba8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Drawable.c b/nx-X11/programs/Xserver/hw/nxagent/Drawable.c index 9c167743f..ddd7f13ca 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Drawable.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Drawable.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Drawable.h b/nx-X11/programs/Xserver/hw/nxagent/Drawable.h index c987fa119..6ce0e3156 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Drawable.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Drawable.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Error.c b/nx-X11/programs/Xserver/hw/nxagent/Error.c index 43bf85900..2a8173019 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Error.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Error.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Error.h b/nx-X11/programs/Xserver/hw/nxagent/Error.h index e55fd71a5..f7a53cbd1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Error.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Error.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.c b/nx-X11/programs/Xserver/hw/nxagent/Events.c index b9da934d6..83665ff90 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -76,9 +76,7 @@ #include "input.h" #endif -#define Time XlibXID #include "XKBlib.h" -#undef Time #define GC XlibGC #define Font XlibFont @@ -220,16 +218,6 @@ static void nxagentForwardRemoteExpose(void); static int nxagentClipAndSendExpose(WindowPtr pWin, pointer ptr); -/* - * This is from NXproperty.c. - */ - -int GetWindowProperty(WindowPtr pWin, Atom property, long longOffset, - long longLength, Bool delete, Atom type, - Atom *actualType, int *format, unsigned - long *nItems, unsigned long *bytesAfter, - unsigned char **propData); - /* * Associate a resource to a drawable and * store the region affected by the split @@ -286,280 +274,6 @@ void ProcessInputEvents() mieqProcessInputEvents(); } -#ifdef DEBUG_TREE - -/* - * Print ID and name of window. - */ - -void nxagentRemoteWindowID(Window window, Bool newline) -{ -#ifdef NO_I18N - char *winName; -#else - XTextProperty tp; -#endif - - fprintf(stderr, "0x%lx", window); - - if (!window) - { - fprintf(stderr, " (none) "); - } - else - { - if (window == DefaultRootWindow(nxagentDisplay)) - { - fprintf(stderr, " (the root window) "); - } - -#ifdef NO_I18N - - if (!XFetchName(nxagentDisplay, window, &winName)) - { - fprintf(stderr, " (has no name) "); - } - else if (winName) - { - fprintf(stderr, " \"%s\" ", winName); - XFree(winName); - } - -#else - - if (XGetWMName(nxagentDisplay, window, &tp) != 0) - { - fprintf(stderr, " (has no name) "); - } - else if (tp.nitems > 0) - { - int count = 0; - int i, ret; - char **list = NULL; - - fprintf(stderr, " \""); - - ret = XmbTextPropertyToTextList(nxagentDisplay, &tp, &list, &count); - - if ((ret == Success || ret > 0) && list != NULL) - { - for (i = 0; i < count; i++) - { - fprintf(stderr, "%s", list[i]); - } - - XFreeStringList(list); - } - else - { - fprintf(stderr, "%s", tp.value); - } - - fprintf(stderr, "\" "); - } - -#endif - - else - { - fprintf(stderr, " (has no name) "); - } - } - - if (newline == TRUE) - { - fprintf(stderr, "\n"); - } - - return; -} - -/* - * Print info about remote window. - */ - -void nxagentRemoteWindowInfo(Window win, int indent, Bool newLine) -{ - XWindowAttributes attributes; - int i; - - if (XGetWindowAttributes(nxagentDisplay, win, &attributes) == 0) - { - return; - } - - for (i = 0; i < indent; i++) - { - fprintf(stderr, " "); - } - - fprintf(stderr, "x=%d y=%d width=%d height=%d class=%s map_state=%s " - "override_redirect=%s\n", attributes.x, attributes.y, - attributes.width, attributes.height, (attributes.class == 0) ? - "InputOutput" : "InputOnly", (attributes.map_state == 0) ? - "IsUnmapped" : (attributes.map_state == 1 ? - "IsUnviewable" : "IsViewable"), - (attributes.override_redirect == 0) ? - "No" : "Yes" ); - - if (newLine == TRUE) - { - fprintf(stderr, "\n"); - } -} - -/* - * Walk remote windows tree. - */ - -void nxagentRemoteWindowsTree(Window window, int level) -{ - int i, j; - Window rootWin, parentWin; - unsigned int numChildren; - Window *childList; - - if (!XQueryTree(nxagentDisplay, window, &rootWin, &parentWin, &childList, - &numChildren)) - { - fprintf(stderr, "nxagentRemoteWindowsTree - XQueryTree failed.\n"); - - return; - } - - if (level == 0) - { - fprintf(stderr, "\n"); - - fprintf(stderr, " Root Window ID: "); - nxagentRemoteWindowID(rootWin, TRUE); - - fprintf(stderr, " Parent window ID: "); - nxagentRemoteWindowID(parentWin, TRUE); - } - - if (level == 0 || numChildren > 0) - { - fprintf(stderr, " "); - - for (j = 0; j < level; j++) - { - fprintf(stderr, " "); - } - - fprintf(stderr, "%d child%s%s\n", numChildren, (numChildren == 1) ? "" : - "ren", (numChildren == 1) ? ":" : "."); - } - - for (i = (int) numChildren - 1; i >= 0; i--) - { - fprintf(stderr, " "); - - for (j = 0; j < level; j++) - { - fprintf(stderr, " "); - } - - nxagentRemoteWindowID(childList[i], TRUE); - - nxagentRemoteWindowInfo(childList[i], (level * 5) + 6, TRUE); - - nxagentRemoteWindowsTree(childList[i], level + 1); - } - - if (childList) - { - XFree((char *) childList); - } -} - -/* - * Print info about internal window. - */ - -void nxagentInternalWindowInfo(WindowPtr pWin, int indent, Bool newLine) -{ - int i; - int result; - unsigned long ulReturnItems; - unsigned long ulReturnBytesLeft; - Atom atomReturnType; - int iReturnFormat; - unsigned char *pszReturnData = NULL; - - fprintf(stderr, "Window ID=[0x%lx] Remote ID=[0x%lx] ", pWin -> drawable.id, - nxagentWindow(pWin)); - - result = GetWindowProperty(pWin, MakeAtom("WM_NAME", 7, False) , 0, - sizeof(CARD32), False, AnyPropertyType, - &atomReturnType, &iReturnFormat, - &ulReturnItems, &ulReturnBytesLeft, - &pszReturnData); - - fprintf(stderr, "Name: "); - - if (result == Success && pszReturnData != NULL) - { - pszReturnData[ulReturnItems] = '\0'; - - fprintf(stderr, "\"%s\"\n", (char *) pszReturnData); - } - else - { - fprintf(stderr, "%s\n", "( has no name )"); - } - - for (i = 0; i < indent; i++) - { - fprintf(stderr, " "); - } - - fprintf(stderr, "x=%d y=%d width=%d height=%d class=%s map_state=%s " - "override_redirect=%s", pWin -> drawable.x, pWin -> drawable.y, - pWin -> drawable.width, pWin -> drawable.height, - (pWin -> drawable.class == 0) ? "InputOutput" : - "InputOnly", (pWin -> mapped == 0) ? - "IsUnmapped" : (pWin -> mapped == 1 ? - "IsUnviewable" : "IsViewable"), - (pWin -> overrideRedirect == 0) ? - "No" : "Yes"); - - if (newLine == TRUE) - { - fprintf(stderr, "\n"); - } -} - -/* - * Walk internal windows tree. - */ - -void nxagentInternalWindowsTree(WindowPtr pWin, int indent) -{ - WindowPtr pChild; - int i; - - while (pWin) - { - pChild = pWin -> firstChild; - - for (i = 0; i < indent; i++) - { - fprintf(stderr, " "); - } - - nxagentInternalWindowInfo(pWin, indent, TRUE); - - fprintf(stderr, "\n"); - - nxagentInternalWindowsTree(pChild, indent + 4); - - pWin = pWin -> nextSib; - } -} - -#endif /* DEBUG_TREE */ - void nxagentSwitchResizeMode(ScreenPtr pScreen) { XSizeHints sizeHints; @@ -576,14 +290,8 @@ void nxagentSwitchResizeMode(ScreenPtr pScreen) nxagentLaunchDialog(DIALOG_DISABLE_DESKTOP_RESIZE_MODE); - if (nxagentOption(Fullscreen) == 0) - { - sizeHints.max_width = nxagentOption(RootWidth); - sizeHints.max_height = nxagentOption(RootHeight); - - XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], - &sizeHints); - } + sizeHints.max_width = nxagentOption(RootWidth); + sizeHints.max_height = nxagentOption(RootHeight); } else { @@ -591,8 +299,7 @@ void nxagentSwitchResizeMode(ScreenPtr pScreen) nxagentLaunchDialog(DIALOG_ENABLE_DESKTOP_RESIZE_MODE); - nxagentRRSetScreenConfig(pScreen, nxagentOption(Width), - nxagentOption(Height)); + nxagentRRSetScreenConfig(pScreen, nxagentOption(Width), nxagentOption(Height)); if (nxagentOption(ClientOs) == ClientOsWinnt) { @@ -601,10 +308,10 @@ void nxagentSwitchResizeMode(ScreenPtr pScreen) sizeHints.max_width = WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); sizeHints.max_height = HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); - - XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], - &sizeHints); } + + XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], + &sizeHints); } void nxagentShadowSwitchResizeMode(ScreenPtr pScreen) @@ -804,7 +511,6 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) Bool startKbd = False; Bool closeSession = False; Bool switchFullscreen = False; - Bool switchAllScreens = False; /* * Last entered top level window. @@ -949,22 +655,6 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) { break; } - - #ifdef DEBUG_TREE - - case doDebugTree: - { - fprintf(stderr, "\n ========== nxagentRemoteWindowsTree ==========\n"); - nxagentRemoteWindowsTree(nxagentWindow(WindowTable[0]), 0); - - fprintf(stderr, "\n========== nxagentInternalWindowsTree ==========\n"); - nxagentInternalWindowsTree(WindowTable[0], 0); - - break; - } - - #endif /* DEBUG_TREE */ - case doCloseSession: { closeSession = TRUE; @@ -989,36 +679,6 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) break; } - case doSwitchAllScreens: - { - switchAllScreens = TRUE; - - break; - } - case doViewportMoveUp: - { - nxagentMoveViewport(pScreen, 0, -nxagentOption(Height)); - - break; - } - case doViewportMoveDown: - { - nxagentMoveViewport(pScreen, 0, nxagentOption(Height)); - - break; - } - case doViewportMoveLeft: - { - nxagentMoveViewport(pScreen, -nxagentOption(Width), 0); - - break; - } - case doViewportMoveRight: - { - nxagentMoveViewport(pScreen, nxagentOption(Width), 0); - - break; - } case doViewportUp: { nxagentMoveViewport(pScreen, 0, -nextinc(viewportInc)); @@ -1095,8 +755,6 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) if (nxagentOption(ViewOnly) == 0 && nxagentOption(Shadow) == 1 && result == doNothing) { - X.xkey.keycode = nxagentConvertKeycode(X.xkey.keycode); - NXShadowEvent(nxagentDisplay, X); } @@ -1105,27 +763,6 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) case KeyRelease: { enum HandleEventResult result; - int sendKey = 0; - -/* -FIXME: If we don't flush the queue here, it could happen - that the inputInfo structure will not be up to date - when we perform the following check on down keys. -*/ - ProcessInputEvents(); - -/* -FIXME: Don't enqueue the KeyRelease event if the key was - not already pressed. This workaround avoids a fake - KeyPress is enqueued by the XKEYBOARD extension. - Another solution would be to let the events are - enqueued and to remove the KeyPress afterwards. -*/ - if (BitIsOn(inputInfo.keyboard -> key -> down, - nxagentConvertKeycode(X.xkey.keycode))) - { - sendKey = 1; - } #ifdef TEST fprintf(stderr, "nxagentDispatchEvents: Going to handle new KeyRelease event.\n"); @@ -1171,7 +808,7 @@ FIXME: Don't enqueue the KeyRelease event if the key was x.u.keyButtonPointer.time = nxagentLastEventTime; } - if (!(nxagentCheckSpecialKeystroke(&X.xkey, &result)) && sendKey == 1) + if (!(nxagentCheckSpecialKeystroke(&X.xkey, &result))) { mieqEnqueue(&x); @@ -1179,8 +816,6 @@ FIXME: Don't enqueue the KeyRelease event if the key was if (nxagentOption(ViewOnly) == 0 && nxagentOption(Shadow)) { - X.xkey.keycode = nxagentConvertKeycode(X.xkey.keycode); - NXShadowEvent(nxagentDisplay, X); } } @@ -1244,7 +879,7 @@ FIXME: Don't enqueue the KeyRelease event if the key was X.xbutton.subwindow == None)) { x.u.u.type = ButtonPress; - x.u.u.detail = inputInfo.pointer -> button -> map[nxagentReversePointerMap[X.xbutton.button - 1]]; + x.u.u.detail = X.xbutton.button; x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); if (nxagentOption(Rootless)) @@ -1317,7 +952,7 @@ FIXME: Don't enqueue the KeyRelease event if the key was if (minimize != True) { x.u.u.type = ButtonRelease; - x.u.u.detail = inputInfo.pointer -> button -> map[nxagentReversePointerMap[X.xbutton.button - 1]]; + x.u.u.detail = X.xbutton.button; x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); if (nxagentOption(Rootless)) @@ -1671,11 +1306,13 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentScreenTrap = 0; } - if (nxagentOption(Fullscreen) == 1 && - X.xcrossing.window == nxagentFullscreenWindow && - X.xcrossing.detail != NotifyInferior) + if (nxagentOption(Fullscreen)) { - nxagentGrabPointerAndKeyboard(&X); + if (X.xcrossing.window == nxagentFullscreenWindow && + X.xcrossing.detail != NotifyInferior) + { + nxagentGrabPointerAndKeyboard(&X); + } } if (X.xcrossing.detail != NotifyInferior) @@ -1724,11 +1361,14 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentLastEnteredWindow = NULL; } - if (X.xcrossing.window == nxagentDefaultWindows[0] && - X.xcrossing.detail != NotifyInferior && - X.xcrossing.mode == NotifyNormal) + if (nxagentOption(Fullscreen)) { - nxagentUngrabPointerAndKeyboard(&X); + if (X.xcrossing.window == nxagentFullscreenWindow && + X.xcrossing.detail != NotifyInferior && + X.xcrossing.mode == NotifyNormal) + { + nxagentUngrabPointerAndKeyboard(&X); + } } if (X.xcrossing.detail != NotifyInferior) @@ -1982,8 +1622,7 @@ FIXME: Don't enqueue the KeyRelease event if the key was } if (nxagentUseNXTrans == 1 && nxagentOption(Rootless) == 0 && - nxagentOption(Nested) == 0 && - X.xmap.window != nxagentIconWindow) + nxagentOption(Nested) == 0 && X.xmap.window != nxagentIconWindow) { nxagentVisibility = VisibilityFullyObscured; } @@ -2022,17 +1661,14 @@ FIXME: Don't enqueue the KeyRelease event if the key was } } - if (nxagentOption(AllScreens) == 1) + if (nxagentOption(Fullscreen) == 1) { if (X.xmap.window == nxagentIconWindow) { pScreen = nxagentScreen(X.xmap.window); nxagentMaximizeToFullScreen(pScreen); } - } - if (nxagentOption(Fullscreen) == 1) - { nxagentVisibility = VisibilityUnobscured; nxagentVisibilityStop = False; nxagentVisibilityTimeout = GetTimeInMillis() + 2000; @@ -2042,17 +1678,10 @@ FIXME: Don't enqueue the KeyRelease event if the key was } case MappingNotify: { - XMappingEvent *mappingEvent = (XMappingEvent *) &X; - #ifdef DEBUG fprintf(stderr, "nxagentDispatchEvents: WARNING! Going to handle new MappingNotify event.\n"); #endif - if (mappingEvent -> request == MappingPointer) - { - nxagentInitPointerMap(); - } - break; } default: @@ -2126,40 +1755,20 @@ FIXME: Don't enqueue the KeyRelease event if the key was if (nxagentWMIsRunning) { - if (nxagentOption(AllScreens)) + if (nxagentOption(Fullscreen)) { nxagentMinimizeFromFullScreen(pScreen); } else { - XIconifyWindow(nxagentDisplay, nxagentDefaultWindows[0], - DefaultScreen(nxagentDisplay)); + XIconifyWindow(nxagentDisplay, nxagentDefaultWindows[0], DefaultScreen(nxagentDisplay)); } } } if (switchFullscreen) { - if (nxagentOption(AllScreens) == 1 && nxagentOption(Fullscreen) == 1) - { - nxagentSwitchAllScreens(pScreen, 0); - } - else - { - nxagentSwitchFullscreen(pScreen, !nxagentOption(Fullscreen)); - } - } - - if (switchAllScreens) - { - if (nxagentOption(AllScreens) == 0 && nxagentOption(Fullscreen) == 1) - { - nxagentSwitchFullscreen(pScreen, 0); - } - else - { - nxagentSwitchAllScreens(pScreen, !nxagentOption(AllScreens)); - } + nxagentSwitchFullscreen(pScreen, !nxagentOption(Fullscreen)); } if (startKbd) @@ -2312,16 +1921,8 @@ int nxagentHandleKeyPress(XEvent *X, enum HandleEventResult *result) return 1; } - if (X -> xkey.keycode == 66) - { - nxagentXkbState.Caps = (~nxagentXkbState.Caps & 1); - } - else if (X -> xkey.keycode == 77) - { - nxagentXkbState.Num = (~nxagentXkbState.Num & 1); - } - nxagentLastEventTime = nxagentLastKeyPressTime = GetTimeInMillis(); + x.u.u.type = KeyPress; x.u.u.detail = nxagentConvertKeycode(X -> xkey.keycode); @@ -2759,8 +2360,7 @@ int nxagentHandleClientMessageEvent(XEvent *X, enum HandleEventResult *result) } if (X -> xclient.window == (nxagentOption(Fullscreen) ? - nxagentIconWindow : nxagentDefaultWindows[0]) || - nxagentWMIsRunning == 0) + nxagentIconWindow : nxagentDefaultWindows[0])) { *result = doCloseSession; } @@ -3357,7 +2957,7 @@ int nxagentHandleConfigureNotify(XEvent* X) if (X -> xconfigure.window == nxagentDefaultWindows[pScreen -> myNum]) { - if (nxagentOption(AllScreens) == 0) + if (nxagentOption(Fullscreen) == 0) { if (nxagentOption(DesktopResize) == 1) { @@ -3426,34 +3026,6 @@ int nxagentHandleConfigureNotify(XEvent* X) doRandR = 0; } - nxagentChangeOption(Width, X -> xconfigure.width); - nxagentChangeOption(Height, X -> xconfigure.height); - - XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, - X -> xconfigure.width, X -> xconfigure.height); - - if (nxagentOption(Fullscreen) == 0) - { - nxagentMoveViewport(pScreen, 0, 0); - } - else - { - nxagentChangeOption(RootX, (nxagentOption(Width) - - nxagentOption(RootWidth)) / 2); - nxagentChangeOption(RootY, (nxagentOption(Height) - - nxagentOption(RootHeight)) / 2); - nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - - nxagentOption(RootWidth)); - nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - - nxagentOption(RootHeight)); - - nxagentUpdateViewportFrame(0, 0, nxagentOption(RootWidth), - nxagentOption(RootHeight)); - - XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), - nxagentOption(RootX), nxagentOption(RootY)); - } - if (doRandR) { #ifdef TEST @@ -3475,6 +3047,8 @@ int nxagentHandleConfigureNotify(XEvent* X) int nxagentHandleReparentNotify(XEvent* X) { + ScreenPtr pScreen = nxagentScreen(X -> xreparent.window); + #ifdef TEST fprintf(stderr, "nxagentHandleReparentNotify: Going to handle a new reparent event.\n"); #endif @@ -3527,8 +3101,6 @@ int nxagentHandleReparentNotify(XEvent* X) #ifdef WARNING fprintf(stderr, "nxagentHandleReparentNotify: WARNING! Failed QueryTree request.\n"); #endif - - break; } if (result && children_return) @@ -3581,95 +3153,6 @@ int nxagentHandleReparentNotify(XEvent* X) return 1; } - else if (nxagentWMIsRunning == 1 && nxagentOption(Fullscreen) == 0 && - nxagentOption(WMBorderWidth) == -1) - { - XlibWindow w; - XlibWindow rootReturn = 0; - XlibWindow parentReturn = 0; - XlibWindow junk; - XlibWindow *childrenReturn = NULL; - unsigned int nchildrenReturn = 0; - Status result; - XWindowAttributes attributes; - int x, y; - int xParent, yParent; - - /* - * Calculate the absolute upper-left X e Y - */ - - if ((XGetWindowAttributes(nxagentDisplay, X -> xreparent.window, - &attributes) == 0)) - { - #ifdef WARNING - fprintf(stderr, "nxagentHandleReparentNotify: WARNING! " - "XGetWindowAttributes failed.\n"); - #endif - - return 1; - } - - x = attributes.x; - y = attributes.y; - - XTranslateCoordinates(nxagentDisplay, X -> xreparent.window, - attributes.root, -attributes.border_width, - -attributes.border_width, &x, &y, &junk); - - /* - * Calculate the parent X and parent Y. - */ - - w = X -> xreparent.parent; - - if (w != DefaultRootWindow(nxagentDisplay)) - { - do - { - result = XQueryTree(nxagentDisplay, w, &rootReturn, &parentReturn, - &childrenReturn, &nchildrenReturn); - - if (parentReturn == rootReturn || parentReturn == 0 || result == 0) - { - break; - } - - if (result == 1 && childrenReturn != NULL) - { - XFree(childrenReturn); - } - - w = parentReturn; - } - while (True); - - /* - * WM reparented. Find edge of the frame. - */ - - if (XGetWindowAttributes(nxagentDisplay, w, &attributes) == 0) - { - #ifdef WARNING - fprintf(stderr, "nxagentHandleReparentNotify: WARNING! " - "XGetWindowAttributes failed for parent window.\n"); - #endif - - return 1; - } - - xParent = attributes.x; - yParent = attributes.y; - - /* - * Difference between Absolute X and Parent X gives thickness of side frame. - * Difference between Absolute Y and Parent Y gives thickness of title bar. - */ - - nxagentChangeOption(WMBorderWidth, (x - xParent)); - nxagentChangeOption(WMTitleHeight, (y - yParent)); - } - } return 1; } @@ -3830,8 +3313,6 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) int resource; - int result; - #ifdef TEST fprintf(stderr, "nxagentGrabPointerAndKeyboard: Grabbing pointer and keyboard with event at [%p].\n", (void *) X); @@ -3850,22 +3331,8 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) fprintf(stderr, "nxagentGrabPointerAndKeyboard: Going to grab the keyboard in context [B1].\n"); #endif - result = XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, - True, GrabModeAsync, GrabModeAsync, now); - - if (result != GrabSuccess) - { - return; - } - - /* - * The smart scheduler could be stopped while - * waiting for the reply. In this case we need - * to yield explicitly to avoid to be stuck in - * the dispatch loop forever. - */ - - isItTimeToYield = 1; + XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, + True, GrabModeAsync, GrabModeAsync, now); #ifdef TEST fprintf(stderr, "nxagentGrabPointerAndKeyboard: Going to grab the pointer in context [B2].\n"); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.h b/nx-X11/programs/Xserver/hw/nxagent/Events.h index c74fa151f..3e04222a2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -29,15 +29,9 @@ enum HandleEventResult { doNothing = 0, doMinimize, - doDebugTree, doCloseSession, doStartKbd, doSwitchFullscreen, - doSwitchAllScreens, - doViewportMoveUp, - doViewportMoveLeft, - doViewportMoveRight, - doViewportMoveDown, doViewportLeft, doViewportUp, doViewportRight, diff --git a/nx-X11/programs/Xserver/hw/nxagent/Extensions.c b/nx-X11/programs/Xserver/hw/nxagent/Extensions.c index aced24ff4..748afa53e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Extensions.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Extensions.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Extensions.h b/nx-X11/programs/Xserver/hw/nxagent/Extensions.h index 5335cf87c..06185170e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Extensions.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Extensions.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Font.c b/nx-X11/programs/Xserver/hw/nxagent/Font.c index 5e58b792b..b14dc883b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Font.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Font.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Font.h b/nx-X11/programs/Xserver/hw/nxagent/Font.h index 63cb6aa24..d95cbdc83 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Font.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Font.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GC.c b/nx-X11/programs/Xserver/hw/nxagent/GC.c index 71562d999..55a0a0031 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GC.c +++ b/nx-X11/programs/Xserver/hw/nxagent/GC.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCOps.c b/nx-X11/programs/Xserver/hw/nxagent/GCOps.c index e18b034eb..d2cc58400 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCOps.c +++ b/nx-X11/programs/Xserver/hw/nxagent/GCOps.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCOps.h b/nx-X11/programs/Xserver/hw/nxagent/GCOps.h index fa4967aee..666a098bf 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCOps.h +++ b/nx-X11/programs/Xserver/hw/nxagent/GCOps.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCs.h b/nx-X11/programs/Xserver/hw/nxagent/GCs.h index f7e13477a..460469696 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCs.h +++ b/nx-X11/programs/Xserver/hw/nxagent/GCs.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Handlers.c b/nx-X11/programs/Xserver/hw/nxagent/Handlers.c index 310b572cc..e43fbb931 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Handlers.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Handlers.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -527,8 +527,7 @@ void nxagentBlockHandler(pointer data, struct timeval **timeout, pointer mask) synchronize, nxagentReady); #endif - if (NXDisplayError(nxagentDisplay) == 0 && - nxagentQueuedEvents(nxagentDisplay) > 0) + if (nxagentQueuedEvents(nxagentDisplay) > 0) { #ifdef WARNING fprintf(stderr, "nxagentBlockHandler: WARNING! Forcing a null timeout with events queued.\n"); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Handlers.h b/nx-X11/programs/Xserver/hw/nxagent/Handlers.h index 3d3b335c0..8cf92b219 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Handlers.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Handlers.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Holder.c b/nx-X11/programs/Xserver/hw/nxagent/Holder.c index bfd907cde..02fde6782 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Holder.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Holder.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Holder.h b/nx-X11/programs/Xserver/hw/nxagent/Holder.h index c39b98780..469da223d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Holder.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Holder.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Icons.h b/nx-X11/programs/Xserver/hw/nxagent/Icons.h index 0601584d4..350e76487 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Icons.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Icons.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Image.c b/nx-X11/programs/Xserver/hw/nxagent/Image.c index e499b7a11..ec7a60a96 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Image.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Image.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Image.h b/nx-X11/programs/Xserver/hw/nxagent/Image.h index 57272ab18..bd6d4c948 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Image.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Image.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Imakefile b/nx-X11/programs/Xserver/hw/nxagent/Imakefile index 51173e410..633e17a22 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Imakefile +++ b/nx-X11/programs/Xserver/hw/nxagent/Imakefile @@ -206,8 +206,7 @@ DEFINES = -g $(OS_DEFINES) $(EXT_DEFINES) $(UPG_DEFINES) \ -DNXAGENT_SPLASH \ -DNXAGENT_ARTSD \ -UNX_DEBUG_INPUT \ - -UPANORAMIX \ - -UDEBUG_TREE + -UPANORAMIX all:: $(OBJS) diff --git a/nx-X11/programs/Xserver/hw/nxagent/Init.c b/nx-X11/programs/Xserver/hw/nxagent/Init.c index 789ff3446..f60d7c457 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Init.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Init.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -193,7 +193,7 @@ void InitOutput(ScreenInfo *screenInfo, int argc, char *argv[]) if (serverGeneration <= 1) { fprintf(stderr, "\nNXAGENT - Version " NXAGENT_VERSION "\n\n"); - fprintf(stderr, "Copyright (C) 2001, 2010 NoMachine.\n"); + fprintf(stderr, "Copyright (C) 2001, 2007 NoMachine.\n"); fprintf(stderr, "See http://www.nomachine.com/ for more information.\n\n"); fprintf(stderr, "Info: Agent running with pid '%d'.\n", getpid()); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Init.h b/nx-X11/programs/Xserver/hw/nxagent/Init.h index cf154e86d..16c74ea99 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Init.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Init.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c index 8db38892e..a4729e9b7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h index 0e11a8a13..4c7395a43 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c index 6c6e477ab..eee13db2d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -92,18 +92,6 @@ int nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) { switch (sym) { - #ifdef DEBUG_TREE - - case XK_q: - case XK_Q: - { - *result = doDebugTree; - - break; - } - - #endif /* DEBUG_TREE */ - case XK_t: case XK_T: { @@ -116,7 +104,7 @@ int nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) { if (nxagentOption(Rootless) == False) { - *result = doSwitchAllScreens; + *result = doSwitchFullscreen; } break; @@ -276,68 +264,6 @@ int nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) #endif } } - else if ((X -> state & nxagentAltMetaMask) && - ((X -> state & (ControlMask | ShiftMask)) == (ControlMask | - ShiftMask))) - { - switch (sym) - { - case XK_f: - case XK_F: - { - if (nxagentOption(Rootless) == 0) - { - *result = doSwitchFullscreen; - } - - break; - } - case XK_Left: - case XK_KP_Left: - { - if (nxagentOption(Rootless) == 0 && - nxagentOption(DesktopResize) == 0) - { - *result = doViewportMoveLeft; - } - - break; - } - case XK_Up: - case XK_KP_Up: - { - if (nxagentOption(Rootless) == 0 && - nxagentOption(DesktopResize) == 0) - { - *result = doViewportMoveUp; - } - - break; - } - case XK_Right: - case XK_KP_Right: - { - if (nxagentOption(Rootless) == 0 && - nxagentOption(DesktopResize) == 0) - { - *result = doViewportMoveRight; - } - - break; - } - case XK_Down: - case XK_KP_Down: - { - if (nxagentOption(Rootless) == 0 && - nxagentOption(DesktopResize) == 0) - { - *result = doViewportMoveDown; - } - - break; - } - } - } return (*result == doNothing) ? 0 : 1; } diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h index ef71a8851..fea97975c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/LICENSE b/nx-X11/programs/Xserver/hw/nxagent/LICENSE index 8446e6f55..451196c1a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/LICENSE +++ b/nx-X11/programs/Xserver/hw/nxagent/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2001, 2011 NoMachine - http://www.nomachine.com/. +Copyright (c) 2001, 2009 NoMachine - http://www.nomachine.com/. NXAGENT and NX extensions to X are copyright of NoMachine. diff --git a/nx-X11/programs/Xserver/hw/nxagent/Literals.h b/nx-X11/programs/Xserver/hw/nxagent/Literals.h index aaa3430d6..21c27afa1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Literals.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Literals.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Millis.c b/nx-X11/programs/Xserver/hw/nxagent/Millis.c index e9c739eeb..e275b985f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Millis.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Millis.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Millis.h b/nx-X11/programs/Xserver/hw/nxagent/Millis.h index 69d247bbc..9b6d879d7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Millis.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Millis.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c index 4f59b8098..e189b9539 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original index 4f59b8098..e189b9539 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c index 1cccfd972..b57401ceb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original index 1cccfd972..b57401ceb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c index f697cf3ca..b01e4a452 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original index f697cf3ca..b01e4a452 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c index 1d86bf870..9bb868f2b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original index 1d86bf870..9bb868f2b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c index 22483b3fd..6ec64afae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original index 22483b3fd..6ec64afae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c index 9212bf438..6352c88d1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original index 9212bf438..6352c88d1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h index 0f122be4a..0874f0fef 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original index 0f122be4a..0874f0fef 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c index 09901ba9c..e0f6d1cdf 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original index 09901ba9c..e0f6d1cdf 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c index d32cdb6c4..95178d362 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original index d32cdb6c4..95178d362 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h index 91eab0125..90a31d36f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original index 91eab0125..90a31d36f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c index 20a6bd6dc..06d6074ad 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original index 20a6bd6dc..06d6074ad 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c index d593fa6aa..179cc1ab0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original index d593fa6aa..179cc1ab0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c index 43607ac08..a670c3521 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c @@ -31,7 +31,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original index 43607ac08..a670c3521 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original @@ -31,7 +31,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c index 95ecde951..a0d4cd6ee 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original index 95ecde951..a0d4cd6ee 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c index 37b2c74fd..a8aa254ff 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h index 160dc6517..8ceb49418 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h b/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h index 97ae77e29..727161648 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Options.c b/nx-X11/programs/Xserver/hw/nxagent/Options.c index 5d7855667..955be61bc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Options.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Options.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -63,9 +63,6 @@ void nxagentInitOptions() nxagentOptions.Height = 0; nxagentOptions.BorderWidth = 0; - nxagentOptions.WMBorderWidth = -1; - nxagentOptions.WMTitleHeight = -1; - nxagentOptions.SavedX = 0; nxagentOptions.SavedY = 0; nxagentOptions.SavedWidth = 0; @@ -171,9 +168,6 @@ void nxagentResetOptions() nxagentOptions.TileWidth = UNDEFINED; nxagentOptions.TileHeight = UNDEFINED; - - nxagentOptions.WMBorderWidth = -1; - nxagentOptions.WMTitleHeight = -1; } void nxagentSaveOptions() diff --git a/nx-X11/programs/Xserver/hw/nxagent/Options.h b/nx-X11/programs/Xserver/hw/nxagent/Options.h index 7850a0586..7126338a8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Options.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Options.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -102,13 +102,6 @@ typedef struct _AgentOptions int Fullscreen; - /* - * True if the fullscreen NX session will - * extend on all available screens. - */ - - int AllScreens; - /* * Set to the auto-disconnect timeout, if * the user activated this feature. @@ -133,9 +126,6 @@ typedef struct _AgentOptions * screen. */ - int WMBorderWidth; - int WMTitleHeight; - int SavedX; int SavedY; int SavedWidth; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixels.c b/nx-X11/programs/Xserver/hw/nxagent/Pixels.c index d3ab9dd2f..eb8daf8f3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixels.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixels.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h index 918d74dc7..cd2df1fa6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -108,12 +108,6 @@ FIXME: The condition checking for the render avoid problems with the render composi- te on XFree86 remote server. */ -/* -FIXME: Changed macro: NXAGENT_SHOULD_DEFER_COMPOSITE - to handle situation, when pSrc -> pDrawable - is NULL. This case happens with gradients - and solid fill. - #define NXAGENT_SHOULD_DEFER_COMPOSITE(pSrc, pMask, pDst) \ ((nxagentRenderVersionMajor == 0 && \ nxagentRenderVersionMinor == 8 && \ @@ -124,18 +118,6 @@ FIXME: Changed macro: NXAGENT_SHOULD_DEFER_COMPOSITE nxagentOption(DeferLevel) == 1) || \ (nxagentOption(DeferLevel) >= 2 && \ nxagentOption(LinkType) < LINK_TYPE_ADSL)) -*/ -#define NXAGENT_SHOULD_DEFER_COMPOSITE(pSrc, pMask, pDst) \ - ((nxagentRenderVersionMajor == 0 && \ - nxagentRenderVersionMinor == 8 && \ - (pDst) -> pDrawable -> type == DRAWABLE_PIXMAP) || \ - (nxagentOption(DeferLevel) >= 2 && \ - nxagentOption(LinkType) < LINK_TYPE_ADSL) || \ - (nxagentOption(DeferLevel) == 1 && \ - (pDst) -> pDrawable -> type == DRAWABLE_PIXMAP && \ - (((pSrc) -> pDrawable && nxagentDrawableStatus((pSrc) -> pDrawable) == NotSynchronized) || \ - ((pMask) && nxagentDrawableStatus((pMask) -> pDrawable) == NotSynchronized)))) - #define NXAGENT_SHOULD_DEFER_PUTIMAGE(pDrawable) \ (nxagentSplitTrap == 0 && \ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c index ad7e9c313..9a4776192 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h b/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h index 98d5666d1..93df4d444 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c index a751974af..8a6702d18 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -57,13 +57,6 @@ is" without express or implied warranty. #undef TEST #undef DEBUG -/* - * The nxagentReversePointerMap array is used to - * memorize remote display pointer map. - */ - -unsigned char nxagentReversePointerMap[MAXBUTTONS]; - void nxagentChangePointerControl(DeviceIntPtr pDev, PtrCtrl *ctrl) { /* @@ -132,8 +125,6 @@ int nxagentPointerProc(DeviceIntPtr pDev, int onoff) return Success; } - nxagentInitPointerMap(); - nxagentEnablePointerEvents(); break; @@ -164,28 +155,3 @@ int nxagentPointerProc(DeviceIntPtr pDev, int onoff) return Success; } - -void nxagentInitPointerMap(void) -{ - int numButtons; - - int i; - - unsigned char pointerMap[MAXBUTTONS]; - - #ifdef DEBUG - fprintf(stderr, "nxagentInitPointerMap: Going to retrieve the " - "pointer map from remote display.\n"); - #endif - - numButtons = XGetPointerMapping(nxagentDisplay, pointerMap, MAXBUTTONS); - - /* - * Computing revers pointer map. - */ - - for (i = 1; i <= numButtons; i++) - { - nxagentReversePointerMap[pointerMap[i - 1] - 1] = i; - } -} diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h index 3b9ccce15..3d8899bbe 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -38,17 +38,8 @@ is" without express or implied warranty. (ButtonPressMask | ButtonReleaseMask | PointerMotionMask | \ EnterWindowMask | LeaveWindowMask) -/* - * The nxagentReversePointerMap array is used to - * memorize remote display pointer map. - */ - -extern unsigned char nxagentReversePointerMap[MAXBUTTONS]; - void nxagentChangePointerControl(DeviceIntPtr pDev, PtrCtrl *ctrl); int nxagentPointerProc(DeviceIntPtr pDev, int onoff); -void nxagentInitPointerMap(void); - #endif /* __Pointer_H__ */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c index b78660240..c656f2912 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -81,8 +81,6 @@ extern Bool nxagentUninstallFontServerPath(void); extern void nxagentRemoveXConnection(void); -extern void nxagentInitPointerMap(void); - static char *nxagentGetReconnectError(void); void nxagentInitializeRecLossyLevel(void); @@ -586,8 +584,6 @@ Bool nxagentReconnectSession(void) nxagentOldKeyboard = NULL; } - nxagentInitPointerMap(); - nxagentDeactivatePointerGrab(); nxagentWakeupByReconnect(); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h index c321bfada..6a3b56fc7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.c b/nx-X11/programs/Xserver/hw/nxagent/Render.c index 6c74c147f..5c6503e64 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -147,6 +147,8 @@ void nxagentCursorPostSaveRenderInfo(CursorPtr pCursor, ScreenPtr pScreen, int nxagentCreatePicture(PicturePtr pPicture, Mask mask); +void nxagentDestroyPicture(PicturePtr pPicture); + int nxagentChangePictureClip(PicturePtr pPicture, int clipType, int nRects, xRectangle *rects, int xOrigin, int yOrigin); @@ -584,16 +586,16 @@ XRenderPictFormat *nxagentMatchingFormats(PictFormatPtr pFormat) void nxagentDestroyPicture(PicturePtr pPicture) { - if (pPicture == NULL || nxagentPicturePriv(pPicture) -> picture == 0) - { - return; - } - #ifdef TEST fprintf(stderr, "nxagentDestroyPicture: Going to destroy picture at [%p].\n", (void *) pPicture); #endif + if (pPicture == NULL) + { + return; + } + XRenderFreePicture(nxagentDisplay, nxagentPicturePriv(pPicture) -> picture); @@ -1008,15 +1010,12 @@ void nxagentComposite(CARD8 op, PicturePtr pSrc, PicturePtr pMask, PicturePtr pD #ifdef DEBUG - if (pSrc -> pDrawable != NULL) - { - fprintf(stderr, "nxagentComposite: Source Picture [%lu][%p] with drawable [%s%s][%p].\n", - nxagentPicturePriv(pSrc) -> picture, (void *) pSrc, - (pSrc -> pDrawable -> type == DRAWABLE_PIXMAP && - nxagentIsShmPixmap((PixmapPtr) pSrc -> pDrawable)) ? "Shared " : "", - pSrc -> pDrawable -> type == DRAWABLE_PIXMAP ? "Pixmap" : "Window", - (void *) pSrc -> pDrawable); - } + fprintf(stderr, "nxagentComposite: Source Picture [%lu][%p] with drawable [%s%s][%p].\n", + nxagentPicturePriv(pSrc) -> picture, (void *) pSrc, + (pSrc -> pDrawable -> type == DRAWABLE_PIXMAP && + nxagentIsShmPixmap((PixmapPtr) pSrc -> pDrawable)) ? "Shared " : "", + pSrc -> pDrawable -> type == DRAWABLE_PIXMAP ? "Pixmap" : "Window", + (void *) pSrc -> pDrawable); fprintf(stderr, "nxagentComposite: Destination Picture [%lu][%p] with drawable [%s%s][%p].\n", nxagentPicturePriv(pDst) -> picture, (void *) pDst, @@ -1065,19 +1064,16 @@ void nxagentComposite(CARD8 op, PicturePtr pSrc, PicturePtr pMask, PicturePtr pD * the wrong data. */ - if (pSrc -> pDrawable != NULL) - { - nxagentSynchronizeShmPixmap(pSrc -> pDrawable, xSrc, ySrc, width, height); + nxagentSynchronizeShmPixmap(pSrc -> pDrawable, xSrc, ySrc, width, height); - if (nxagentDrawableStatus(pSrc -> pDrawable) == NotSynchronized) - { - #ifdef TEST - fprintf(stderr, "nxagentComposite: Synchronizing the source drawable [%p].\n", - (void *) pSrc -> pDrawable); - #endif + if (nxagentDrawableStatus(pSrc -> pDrawable) == NotSynchronized) + { + #ifdef TEST + fprintf(stderr, "nxagentComposite: Synchronizing the source drawable [%p].\n", + (void *) pSrc -> pDrawable); + #endif - nxagentSynchronizeDrawable(pSrc -> pDrawable, DO_WAIT, NEVER_BREAK, NULL); - } + nxagentSynchronizeDrawable(pSrc -> pDrawable, DO_WAIT, NEVER_BREAK, NULL); } if (pDst -> pDrawable != pSrc -> pDrawable) @@ -2815,248 +2811,3 @@ Bool nxagentDisconnectAllPicture() return True; } -void nxagentRenderCreateSolidFill(PicturePtr pPicture, xRenderColor *color) -{ - Picture id; - - if (nxagentRenderEnable == False) - { - return; - } - - #ifdef DEBUG - - fprintf(stderr, "nxagentRenderCreateSolidFill: Got called.\n"); - - if (pPicture == NULL) - { - fprintf(stderr, "nxagentRenderCreateSolidFill: WARNING! pPicture pointer is NULL.\n"); - } - - if (color == NULL) - { - fprintf(stderr, "nxagentRenderCreateSolidFill: WARNING! color pointer is NULL.\n"); - } - - #endif /* #ifdef DEBUG */ - - memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, - sizeof(XRenderPictureAttributes_)); - - id = XRenderCreateSolidFill(nxagentDisplay, (XRenderColor *) color); - - #ifdef DEBUG - XSync(nxagentDisplay, 0); - #endif - - #ifdef TEST - fprintf(stderr, "nxagentRenderCreateSolidFill: Created solid fill xid [%lu].\n", id); - #endif - - nxagentPicturePriv(pPicture) -> picture = id; -} - -void nxagentRenderCreateLinearGradient(PicturePtr pPicture, xPointFixed *p1, - xPointFixed *p2, int nStops, - xFixed *stops, - xRenderColor *colors) -{ - Picture id; - - XLinearGradient linearGradient; - - if (nxagentRenderEnable == False) - { - return; - } - - #ifdef DEBUG - - fprintf(stderr, "nxagentRenderCreateLinearGradient: Got called.\n"); - - if (pPicture == NULL) - { - fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! pPicture pointer is NULL.\n"); - } - - if (p1 == NULL) - { - fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! p1 pointer is NULL.\n"); - } - - if (p2 == NULL) - { - fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! p2 pointer is NULL.\n"); - } - - if (stops == NULL) - { - fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! stops pointer is NULL.\n"); - } - - if (colors == NULL) - { - fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! colors pointer is NULL.\n"); - } - - #endif /* #ifdef DEBUG */ - - memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, - sizeof(XRenderPictureAttributes_)); - - linearGradient.p1.x = (XFixed) p1 -> x; - linearGradient.p1.y = (XFixed) p1 -> y; - linearGradient.p2.x = (XFixed) p2 -> x; - linearGradient.p2.y = (XFixed) p2 -> y; - - id = XRenderCreateLinearGradient(nxagentDisplay, &linearGradient, - (XFixed *) stops, - (XRenderColor *) colors, nStops); - - #ifdef DEBUG - XSync(nxagentDisplay, 0); - #endif - - #ifdef TEST - fprintf(stderr, "nxagentRenderCreateLinearGradient: Created linear gradient xid [%lu].\n", id); - #endif - - nxagentPicturePriv(pPicture) -> picture = id; -} - -void nxagentRenderCreateRadialGradient(PicturePtr pPicture, xPointFixed *inner, - xPointFixed *outer, - xFixed innerRadius, - xFixed outerRadius, - int nStops, - xFixed *stops, - xRenderColor *colors) -{ - Picture id; - - XRadialGradient radialGradient; - - if (nxagentRenderEnable == False) - { - return; - } - - #ifdef DEBUG - - fprintf(stderr, "nxagentRenderCreateRadialGradient: Got called.\n"); - - if (pPicture == NULL) - { - fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! pPicture pointer is NULL.\n"); - } - - if (inner == NULL) - { - fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! inner pointer is NULL.\n"); - } - - if (outer == NULL) - { - fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! outer pointer is NULL.\n"); - } - - if (stops == NULL) - { - fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! stops pointer is NULL.\n"); - } - - if (colors == NULL) - { - fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! colors pointer is NULL.\n"); - } - - #endif /* #ifdef DEBUG */ - - memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, - sizeof(XRenderPictureAttributes_)); - - radialGradient.inner.x = (XFixed) inner -> x; - radialGradient.inner.y = (XFixed) inner -> y; - radialGradient.inner.radius = (XFixed) innerRadius; - radialGradient.outer.x = (XFixed) outer -> x; - radialGradient.outer.y = (XFixed) outer -> y; - radialGradient.outer.radius = (XFixed) outerRadius; - - id = XRenderCreateRadialGradient(nxagentDisplay, &radialGradient, - (XFixed *) stops, - (XRenderColor *) colors, nStops); - - #ifdef DEBUG - XSync(nxagentDisplay, 0); - #endif - - #ifdef TEST - fprintf(stderr, "nxagentRenderCreateRadialGradient: Created radial gradient xid [%lu].\n", id); - #endif - - nxagentPicturePriv(pPicture) -> picture = id; -} - -void nxagentRenderCreateConicalGradient(PicturePtr pPicture, - xPointFixed *center, - xFixed angle, int nStops, - xFixed *stops, - xRenderColor *colors) -{ - Picture id; - - XConicalGradient conicalGradient; - - if (nxagentRenderEnable == False) - { - return; - } - - #ifdef DEBUG - - fprintf(stderr, "nxagentRenderCreateConicalGradient: Got called.\n"); - - if (pPicture == NULL) - { - fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! pPicture pointer is NULL.\n"); - } - - if (center == NULL) - { - fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! center pointer is NULL.\n"); - } - - if (stops == NULL) - { - fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! stops pointer is NULL.\n"); - } - - if (colors == NULL) - { - fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! colors pointer is NULL.\n"); - } - - #endif /* #ifdef DEBUG */ - - memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, - sizeof(XRenderPictureAttributes_)); - - conicalGradient.center.x = (XFixed) center -> x; - conicalGradient.center.y = (XFixed) center -> y; - conicalGradient.angle = (XFixed) angle; - - id = XRenderCreateConicalGradient(nxagentDisplay, &conicalGradient, - (XFixed *) stops, - (XRenderColor *) colors, nStops); - - #ifdef DEBUG - XSync(nxagentDisplay, 0); - #endif - - #ifdef TEST - fprintf(stderr, "nxagentRenderCreateConicalGradient: Created conical gradient xid [%lu].\n", id); - #endif - - nxagentPicturePriv(pPicture) -> picture = id; -} - diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.h b/nx-X11/programs/Xserver/hw/nxagent/Render.h index 6f61ca85f..77e842d16 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -105,6 +105,4 @@ void nxagentDisconnectPicture(pointer p0, XID x1, void* p2); void nxagentReconnectGlyphSet(void* p0, XID x1, void *p2); -void nxagentDestroyPicture(PicturePtr pPicture); - #endif /* __Render_H__ */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c index 706aa9320..53f4df41e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -626,7 +626,6 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) XlibAtom *atoms = malloc(nUnits * sizeof(*atoms)); Atom *input = value; int i; - int j = 0; freeMem = True; export = True; @@ -634,40 +633,16 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) for (i = 0; i < nUnits; i++) { - /* - * Exporting the _NET_WM_PING property could - * result in rootless windows being grayed out - * when the compiz window manager is running. - * - * Better solution would probably be to handle - * the communication with the window manager - * instead of just getting rid of the property. - */ - - if (strcmp(NameForAtom(input[i]), "_NET_WM_PING") != 0) - { - atoms[j] = nxagentLocalToRemoteAtom(input[i]); - - if (atoms[j] == None) - { - #ifdef WARNING - fprintf(stderr, "nxagentExportProperty: WARNING! Failed to convert local atom %ld [%s].\n", - (long int) input[i], validateString(NameForAtom(input[i]))); - #endif - } - - j++; - } - #ifdef TEST - else - { - fprintf(stderr, "nxagentExportProperty: WARNING! " - "Not exporting the _NET_WM_PING property.\n"); - } - #endif + atoms[i] = nxagentLocalToRemoteAtom(input[i]); + + if (atoms[i] == None) + { + #ifdef WARNING + fprintf(stderr, "nxagentExportProperty: WARNING! Failed to convert local atom %ld [%s].\n", + (long int) input[i], validateString(NameForAtom(input[i]))); + #endif + } } - - nUnits = j; } else if (strcmp(typeS, "WINDOW") == 0) { @@ -725,57 +700,7 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) } else { - #ifdef TEST - fprintf(stderr, "nxagentExportProperty: Property [%lu] format [%i] " - "units [%lu].\n", propertyX, format, nUnits); - #endif - - if ((format >> 3) * nUnits + sizeof(xChangePropertyReq) < - (MAX_REQUEST_SIZE << 2)) - { - XChangeProperty(nxagentDisplay, nxagentWindow(pWin), propertyX, typeX, - format, mode, (void*)output, nUnits); - } - else if (mode == PropModeReplace) - { - int n; - char *data; - - XDeleteProperty(nxagentDisplay, nxagentWindow(pWin), propertyX); - - data = (char *) output; - - while (nUnits > 0) - { - if ((format >> 3) * nUnits + sizeof(xChangePropertyReq) < - (MAX_REQUEST_SIZE << 2)) - { - n = nUnits; - } - else - { - n = ((MAX_REQUEST_SIZE << 2) - sizeof(xChangePropertyReq)) / - (format >> 3); - } - - XChangeProperty(nxagentDisplay, nxagentWindow(pWin), propertyX, - typeX, format, PropModeAppend, (void*) data, n); - - nUnits -= n; - - data = (char *) data + n * (format >> 3); - } - } - else - { - #ifdef WARNING - fprintf(stderr, "nxagentExportProperty: WARNING! " - "Property [%lu] too long.\n", propertyX); - #endif - - goto nxagentExportPropertyError; - } - + XChangeProperty(nxagentDisplay, nxagentWindow(pWin), propertyX, typeX, format, mode, (void*)output, nUnits); nxagentAddPropertyToList(propertyX, pWin); } } @@ -790,8 +715,6 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) #endif } - nxagentExportPropertyError: - if (freeMem) { xfree(output); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Rootless.h b/nx-X11/programs/Xserver/hw/nxagent/Rootless.h index 1ea258db3..5538b58ea 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Rootless.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Rootless.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.c b/nx-X11/programs/Xserver/hw/nxagent/Screen.c index 0a0d409eb..4f4160765 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -292,7 +292,7 @@ void nxagentMinimizeFromFullScreen(ScreenPtr pScreen) { XUnmapWindow(nxagentDisplay, nxagentFullscreenWindow); - if (nxagentIpaq) + if(nxagentIpaq) { XMapWindow(nxagentDisplay, nxagentIconWindow); XIconifyWindow(nxagentDisplay, nxagentIconWindow, @@ -307,7 +307,7 @@ void nxagentMinimizeFromFullScreen(ScreenPtr pScreen) void nxagentMaximizeToFullScreen(ScreenPtr pScreen) { - if (nxagentIpaq) + if(nxagentIpaq) { XUnmapWindow(nxagentDisplay, nxagentIconWindow); @@ -334,7 +334,7 @@ FIXME: We'll chech for ReparentNotify and LeaveNotify events after XReparentWind for (i = 0; i < 100 && nxagentWMIsRunning; i++) { #ifdef TEST - fprintf(stderr, "nxagentMaximizeToFullscreen: WARNING! Going to wait for the ReparentNotify event.\n"); + fprintf(stderr, "nxagentSwitchFullscreen: WARNING! Going to wait for the ReparentNotify event.\n"); #endif if (XCheckTypedWindowEvent(nxagentDisplay, nxagentFullscreenWindow, ReparentNotify, &e)) @@ -977,10 +977,6 @@ Bool nxagentOpenScreen(int index, ScreenPtr pScreen, nxagentChangeOption(Fullscreen, False); - nxagentChangeOption(AllScreens, False); - - nxagentFullscreenWindow = 0; - resetAgentPosition = True; } @@ -1384,13 +1380,10 @@ N/A nxagentChangeOption(Height, gattributes.height); } - if (nxagentOption(AllScreens)) - { - attributes.override_redirect = True; - } - if (nxagentOption(Fullscreen)) { + attributes.override_redirect = True; + /* * We need to disable the host's screensaver or * it will otherwise grab the screen even if it @@ -1617,7 +1610,7 @@ N/A nxagentReconnectTrap == 1) { valuemask = CWBackPixel | CWEventMask | CWColormap | - (nxagentOption(AllScreens) == 1 ? CWOverrideRedirect : 0); + (nxagentOption(Fullscreen) == 1 ? CWOverrideRedirect : 0); attributes.background_pixel = nxagentBlackPixel; @@ -1625,13 +1618,10 @@ N/A attributes.colormap = nxagentDefaultVisualColormap(nxagentDefaultVisual(pScreen)); - if (nxagentOption(AllScreens) == 1) + if (nxagentOption(Fullscreen) == 1) { attributes.override_redirect = True; - } - if (nxagentOption(Fullscreen) == 1) - { if (nxagentReconnectTrap) { /* @@ -1764,7 +1754,7 @@ N/A sizeHints.width = nxagentOption(RootWidth); sizeHints.height = nxagentOption(RootHeight); - if (nxagentOption(DesktopResize) == 1 || nxagentOption(Fullscreen) == 1) + if (nxagentOption(DesktopResize) == 1) { sizeHints.max_width = WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); sizeHints.max_height = HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); @@ -1809,14 +1799,30 @@ N/A XClearWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum]); - if (nxagentOption(AllScreens)) + if (nxagentOption(Fullscreen)) + { + valuemask = CWBackPixmap | CWColormap | CWOverrideRedirect; + } + else + { + valuemask = CWBackPixmap | CWColormap; + } + + attributes.background_pixmap = nxagentScreenSaverPixmap; + attributes.colormap = DefaultColormap(nxagentDisplay, DefaultScreen(nxagentDisplay)); + + if (nxagentOption(Fullscreen)) { + attributes.override_redirect = False; if (nxagentReconnectTrap) { XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, True, GrabModeAsync, GrabModeAsync, CurrentTime); } + } + if (nxagentOption(Fullscreen)) + { nxagentIconWindow = nxagentCreateIconWindow(); } else @@ -1874,6 +1880,13 @@ N/A */ XSetWMProtocols(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], &deleteWMatom, 1); + + /* + if (nxagentOption(Fullscreen)) + { + XSetWMProtocols(nxagentDisplay, nxagentIconWindow, &deleteWMatom, 1); + } + */ } else { @@ -2172,6 +2185,8 @@ Bool nxagentResizeScreen(ScreenPtr pScreen, int width, int height, int oldMmWidth; int oldMmHeight; + RegionPtr pRootWinSize; + #ifdef TEST nxagentPrintAgentGeometry("Before Resize Screen", "nxagentResizeScreen:"); #endif @@ -2251,10 +2266,13 @@ FIXME: We should try to restore the previously if (nxagentOption(Fullscreen)) { - nxagentChangeOption(RootX, (nxagentOption(Width) - - nxagentOption(RootWidth)) / 2); - nxagentChangeOption(RootY, (nxagentOption(Height) - - nxagentOption(RootHeight)) / 2); + nxagentChangeOption(Width, WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); + nxagentChangeOption(Height, HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); + + nxagentChangeOption(RootX, (WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)) + - nxagentOption(RootWidth)) / 2); + nxagentChangeOption(RootY, (HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)) + - nxagentOption(RootHeight)) / 2); } else { @@ -2265,6 +2283,62 @@ FIXME: We should try to restore the previously nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - nxagentOption(RootWidth)); nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - nxagentOption(RootHeight)); + /* + * Change agent window size and size hints. + */ + + sizeHints.flags = PPosition | PMinSize | PMaxSize; + sizeHints.x = nxagentOption(X); + sizeHints.y = nxagentOption(Y); + + sizeHints.min_width = MIN_NXAGENT_WIDTH; + sizeHints.min_height = MIN_NXAGENT_HEIGHT; + sizeHints.width = width; + sizeHints.height = height; + + if (nxagentOption(DesktopResize) == 1) + { + sizeHints.max_width = WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); + sizeHints.max_height = HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); + } + else + { + sizeHints.max_width = nxagentOption(RootWidth); + sizeHints.max_height = nxagentOption(RootHeight); + } + + if (nxagentUserGeometry.flag & XValue || nxagentUserGeometry.flag & YValue) + { + sizeHints.flags |= USPosition; + } + + if (nxagentUserGeometry.flag & WidthValue || nxagentUserGeometry.flag & HeightValue) + { + sizeHints.flags |= USSize; + } + + XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], &sizeHints); + + if (nxagentOption(Fullscreen)) + { + XResizeWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], + WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)), + HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); + + XResizeWindow(nxagentDisplay, nxagentInputWindows[pScreen -> myNum], + WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)), + HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); + } + else + { + XResizeWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], width, height); + + if (nxagentOption(Rootless) == 0) + { + XResizeWindow(nxagentDisplay, nxagentInputWindows[pScreen -> myNum], width, height); + } + } + /* * Set properties for the agent root window. */ @@ -2286,6 +2360,8 @@ FIXME: We should try to restore the previously (*pScreen -> PositionWindow)(WindowTable[pScreen -> myNum], 0, 0); + pRootWinSize = &WindowTable[pScreen -> myNum] -> winSize; + nxagentSetRootClip(pScreen, 1); XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[0]), @@ -2293,12 +2369,6 @@ FIXME: We should try to restore the previously nxagentMoveViewport(pScreen, 0, 0); - /* - * Update pointer bounds. - */ - - ScreenRestructured(pScreen); - #ifdef TEST nxagentPrintAgentGeometry("After Resize Screen", "nxagentResizeScreen:"); #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.h b/nx-X11/programs/Xserver/hw/nxagent/Screen.h index 5b1957755..ab8c01a73 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -48,7 +48,6 @@ extern ScreenPtr nxagentDefaultScreen; extern Pixmap nxagentPixmapLogo; extern Window nxagentIconWindow; - extern Window nxagentFullscreenWindow; extern RegionRec nxagentShadowUpdateRegion; @@ -62,8 +61,6 @@ extern short nxagentShadowUid; void nxagentSetScreenInfo(ScreenInfo *screenInfo); void nxagentSetPixmapFormats(ScreenInfo *screenInfo); -void nxagentPrintGeometry(); - extern Window nxagentDefaultWindows[MAXSCREENS]; extern Window nxagentInputWindows[MAXSCREENS]; extern Window nxagentScreenSaverWindows[MAXSCREENS]; @@ -90,7 +87,6 @@ extern int nxagentBitsPerPixel(int depth); void nxagentSetScreenSaverTime(void); void nxagentMinimizeFromFullScreen(ScreenPtr pScreen); - void nxagentMaximizeToFullScreen(ScreenPtr pScreen); Window nxagentCreateIconWindow(void); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Splash.c b/nx-X11/programs/Xserver/hw/nxagent/Splash.c index 235c48c23..54b355762 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Splash.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Splash.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Splash.h b/nx-X11/programs/Xserver/hw/nxagent/Splash.h index f7ba6c2e2..a677f209b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Splash.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Splash.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Split.c b/nx-X11/programs/Xserver/hw/nxagent/Split.c index 4cc2ea607..061ab8c45 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Split.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Split.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Split.h b/nx-X11/programs/Xserver/hw/nxagent/Split.h index 2be449a18..88e55485c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Split.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Split.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/TestExt.c b/nx-X11/programs/Xserver/hw/nxagent/TestExt.c index 6bce2eaeb..17e6a89e1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/TestExt.c +++ b/nx-X11/programs/Xserver/hw/nxagent/TestExt.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.c b/nx-X11/programs/Xserver/hw/nxagent/Trap.c index f5e6bde0e..c6f62c43f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Trap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.h b/nx-X11/programs/Xserver/hw/nxagent/Trap.h index 9258e3b67..13bbf65c7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Trap.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Utils.h b/nx-X11/programs/Xserver/hw/nxagent/Utils.h index f5bd55d8b..bf2aa1c26 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Utils.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Utils.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Visual.c b/nx-X11/programs/Xserver/hw/nxagent/Visual.c index b086c0e9a..46fe90f39 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Visual.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Visual.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Visual.h b/nx-X11/programs/Xserver/hw/nxagent/Visual.h index 8436f79ad..d60f0d824 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Visual.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Visual.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Window.c b/nx-X11/programs/Xserver/hw/nxagent/Window.c index 3e6d41d04..2abfd5ea0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Window.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Window.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -691,73 +691,6 @@ void nxagentRestackWindow(WindowPtr pWin, WindowPtr pOldNextSib) } void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn) -{ - XEvent e; - - if (nxagentOption(Rootless) == 1) - { - return; - } - - if (switchOn == 0) - { - nxagentWMDetect(); - - /* - * The smart scheduler could be stopped while - * waiting for the reply. In this case we need - * to yield explicitly to avoid to be stuck in - * the dispatch loop forever. - */ - - isItTimeToYield = 1; - - if (nxagentWMIsRunning == 0) - { - #ifdef WARNING - fprintf(stderr, "Warning: Can't switch to window mode, no window manager " - "has been detected.\n"); - #endif - - return; - } - } - - #ifdef TEST - fprintf(stderr, "nxagentSwitchFullscreen: Switching to %s mode.\n", - switchOn ? "fullscreen" : "windowed"); - #endif - - nxagentChangeOption(Fullscreen, switchOn); - - memset(&e, 0, sizeof(e)); - - e.xclient.type = ClientMessage; - e.xclient.message_type = nxagentAtoms[13]; /* _NET_WM_STATE */ - e.xclient.display = nxagentDisplay; - e.xclient.window = nxagentDefaultWindows[pScreen -> myNum]; - e.xclient.format = 32; - e.xclient.data.l[0] = nxagentOption(Fullscreen) ? 1 : 0; - e.xclient.data.l[1] = nxagentAtoms[14]; /* _NET_WM_STATE_FULLSCREEN */ - - XSendEvent(nxagentDisplay, DefaultRootWindow(nxagentDisplay), False, - SubstructureRedirectMask, &e); - - if (switchOn == 1) - { - nxagentFullscreenWindow = nxagentDefaultWindows[pScreen -> myNum]; - - nxagentGrabPointerAndKeyboard(NULL); - } - else - { - nxagentFullscreenWindow = None; - - nxagentUngrabPointerAndKeyboard(NULL); - } -} - -void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn) { Window w; XSetWindowAttributes attributes; @@ -788,8 +721,6 @@ void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn) XUnmapWindow(nxagentDisplay, w); XChangeWindowAttributes(nxagentDisplay, w, valuemask, &attributes); - XReparentWindow(nxagentDisplay, w, DefaultRootWindow(nxagentDisplay), 0, 0); - if (switchOn) { /* @@ -807,7 +738,7 @@ void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn) for (i = 0; i < 100 && nxagentWMIsRunning; i++) { #ifdef TEST - fprintf(stderr, "nxagentSwitchAllScreens: WARNING! Going to wait for the ReparentNotify event.\n"); + fprintf(stderr, "nxagentSwitchFullscreen: WARNING! Going to wait for the ReparentNotify event.\n"); #endif if (XCheckTypedWindowEvent(nxagentDisplay, w, ReparentNotify, &e)) @@ -836,8 +767,6 @@ void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn) */ nxagentChangeOption(Fullscreen, True); - nxagentChangeOption(AllScreens, True); - /* * Save the window-mode configuration. @@ -916,9 +845,9 @@ void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn) */ #ifdef WARNING - fprintf(stderr, "nxagentSwitchAllScreens: WARNING! Expected ReparentNotify event missing.\n"); + fprintf(stderr, "nxagentSwitchFullscreen: WARNING! Expected ReparentNotify event missing.\n"); #endif - + nxagentWMIsRunning = False; attributes.override_redirect = False; XChangeWindowAttributes(nxagentDisplay, w, valuemask, &attributes); @@ -932,6 +861,7 @@ void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn) * It could be necessary: * - To restore screensaver. * - To set or reset nxagentForceBackingStore flag. + * - To grab keyboard. * - To propagate device settings to the X server if no WM is running. */ @@ -940,10 +870,7 @@ void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn) */ nxagentChangeOption(Fullscreen, False); - nxagentChangeOption(AllScreens, False); - XDestroyWindow(nxagentDisplay, nxagentIconWindow); - nxagentIconWindow = nxagentFullscreenWindow = None; if (nxagentOption(DesktopResize) == 1) @@ -957,19 +884,8 @@ void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn) } } - if (nxagentOption(WMBorderWidth) > 0 && nxagentOption(WMTitleHeight) > 0) - { - nxagentChangeOption(X, nxagentOption(SavedX) - - nxagentOption(WMBorderWidth)); - nxagentChangeOption(Y, nxagentOption(SavedY) - - nxagentOption(WMTitleHeight)); - } - else - { - nxagentChangeOption(X, nxagentOption(SavedX)); - nxagentChangeOption(Y, nxagentOption(SavedY)); - } - + nxagentChangeOption(X, nxagentOption(SavedX)); + nxagentChangeOption(Y, nxagentOption(SavedY)); nxagentChangeOption(Width, nxagentOption(SavedWidth)); nxagentChangeOption(Height, nxagentOption(SavedHeight)); @@ -993,7 +909,7 @@ void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn) XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, nxagentOption(Width), nxagentOption(Height)); - nxagentSetPrintGeometry(pScreen -> myNum); + nxagentSetPrintGeometry(pScreen -> myNum); } #ifdef VIEWPORT_FRAME @@ -2495,11 +2411,6 @@ void nxagentMapDefaultWindows() #endif XMapWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum]); - - if (nxagentOption(Fullscreen) == 1 && nxagentWMIsRunning == 1) - { - nxagentMaximizeToFullScreen(pScreen); - } } /* @@ -2986,13 +2897,6 @@ FIXME: Do we need to set save unders attribute here? XSizeHints *props, hints; unsigned char *data = NULL; - #ifdef _XSERVER64 - - unsigned char *data64 = NULL; - unsigned int i; - - #endif - hints.flags = 0; ret = GetWindowProperty(pWin, @@ -3001,13 +2905,10 @@ FIXME: Do we need to set save unders attribute here? False, XA_WM_SIZE_HINTS, &type, &format, &nItems, &bytesLeft, &data); - /* - * 72 is the number of bytes returned by - * sizeof(XSizeHints) on 32 bit platforms. - */ + props = (XSizeHints*) data; if (ret == Success && - ((format >> 3) * nItems) == 72 && + ((format >> 3) * nItems) == sizeof(XSizeHints) && bytesLeft == 0 && type == XA_WM_SIZE_HINTS) { @@ -3016,30 +2917,6 @@ FIXME: Do we need to set save unders attribute here? (void*)pWin, pWin -> drawable.id, nxagentWindow(pWin)); #endif - #ifdef _XSERVER64 - - data64 = (unsigned char *) malloc(sizeof(XSizeHints) + 4); - - for (i = 0; i < 4; i++) - { - *(data64 + i) = *(data + i); - } - - *(((int *) data64) + 1) = 0; - - for (i = 8; i < sizeof(XSizeHints) + 4; i++) - { - *(data64 + i) = *(data + i - 4); - } - - props = (XSizeHints *) data64; - - #else - - props = (XSizeHints *) data; - - #endif /* _XSERVER64 */ - hints = *props; } else @@ -3058,15 +2935,6 @@ FIXME: Do we need to set save unders attribute here? XSetWMNormalHints(nxagentDisplay, nxagentWindow(pWin), &hints); - - #ifdef _XSERVER64 - - if (data64 != NULL) - { - free(data64); - } - - #endif } } diff --git a/nx-X11/programs/Xserver/hw/nxagent/Windows.h b/nx-X11/programs/Xserver/hw/nxagent/Windows.h index 3ca74ba8e..f77db372d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Windows.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Windows.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -222,8 +222,6 @@ void nxagentSetTopLevelEventMask(WindowPtr pWin); void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn); -void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn); - void nxagentMoveViewport(ScreenPtr pScreen, int hShift, int vShift); #ifdef VIEWPORT_FRAME diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c index cf5d48ba2..967c5656e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original index cf5d48ba2..967c5656e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c index 69ad30d2d..d9da23738 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -513,6 +513,17 @@ Dispatch(void) * completed. We can now handle our clients. */ + if (serverGeneration > nxagentMaxAllowedResets) + { + #ifdef NX_DEBUG_INPUT + fprintf(stderr, "Session: Session started at '%s' timestamp [%lu].\n", GetTimeAsString(), GetTimeInMillis()); + #else + fprintf(stderr, "Session: Session started at '%s'.\n", GetTimeAsString()); + #endif + + nxagentSessionState = SESSION_UP; + } + #ifdef XKB nxagentInitXkbWrapper(); @@ -596,21 +607,6 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio clientReady[1] = NXAGENT_WAKEUP; } - if (serverGeneration > nxagentMaxAllowedResets && - nxagentSessionState == SESSION_STARTING && - (nxagentOption(Xdmcp) == 0 || nxagentXdmcpUp == 1)) - { - #ifdef NX_DEBUG_INPUT - fprintf(stderr, "Session: Session started at '%s' timestamp [%lu].\n", - GetTimeAsString(), GetTimeInMillis()); - #else - fprintf(stderr, "Session: Session started at '%s'.\n", - GetTimeAsString()); - #endif - - nxagentSessionState = SESSION_UP; - } - #ifdef BLOCKS fprintf(stderr, "[End dispatch]\n"); #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original index 69ad30d2d..d9da23738 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -513,6 +513,17 @@ Dispatch(void) * completed. We can now handle our clients. */ + if (serverGeneration > nxagentMaxAllowedResets) + { + #ifdef NX_DEBUG_INPUT + fprintf(stderr, "Session: Session started at '%s' timestamp [%lu].\n", GetTimeAsString(), GetTimeInMillis()); + #else + fprintf(stderr, "Session: Session started at '%s'.\n", GetTimeAsString()); + #endif + + nxagentSessionState = SESSION_UP; + } + #ifdef XKB nxagentInitXkbWrapper(); @@ -596,21 +607,6 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio clientReady[1] = NXAGENT_WAKEUP; } - if (serverGeneration > nxagentMaxAllowedResets && - nxagentSessionState == SESSION_STARTING && - (nxagentOption(Xdmcp) == 0 || nxagentXdmcpUp == 1)) - { - #ifdef NX_DEBUG_INPUT - fprintf(stderr, "Session: Session started at '%s' timestamp [%lu].\n", - GetTimeAsString(), GetTimeInMillis()); - #else - fprintf(stderr, "Session: Session started at '%s'.\n", - GetTimeAsString()); - #endif - - nxagentSessionState = SESSION_UP; - } - #ifdef BLOCKS fprintf(stderr, "[End dispatch]\n"); #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c index 04fc047fc..4361985fd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original index 04fc047fc..4361985fd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c index c5593adbb..467381054 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original index c5593adbb..467381054 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c index ead9b9d28..9bfb28426 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original index ead9b9d28..9bfb28426 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c index 51c547984..3d021a0c4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original index 51c547984..3d021a0c4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c index cd65fdc0e..577659a82 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original index cd65fdc0e..577659a82 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c index 7a1d813b3..b11b10fb9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original index 7a1d813b3..b11b10fb9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h index fa6b5fb02..b6d563c6b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original index fa6b5fb02..b6d563c6b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c index 3fc73cf3b..652b85dd7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original index 3fc73cf3b..652b85dd7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c index 5f32334ae..4eabd17f9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original index 5f32334ae..4eabd17f9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c index f418654b4..124356427 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original index f418654b4..124356427 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c index 190294979..d486d19c5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original index 190294979..d486d19c5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c index d9054b4b6..5cd3e5073 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -62,7 +62,6 @@ #include "Screen.h" #include "Pixmaps.h" #include "Drawable.h" -#include "Render.h" #define PANIC #define WARNING @@ -873,9 +872,6 @@ AllocatePicture (ScreenPtr pScreen) else ppriv->ptr = (pointer)NULL; } - - nxagentPicturePriv(pPicture) -> picture = 0; - return pPicture; } @@ -1067,49 +1063,7 @@ static void initGradient(SourcePictPtr pGradient, int stopCount, static PicturePtr createSourcePicture(void) { PicturePtr pPicture; - - extern int nxagentPicturePrivateIndex; - - unsigned int totalPictureSize; - - DevUnion *ppriv; - - char *privPictureRecAddr; - - int i; - - /* - * Compute size of entire PictureRect, plus privates. - */ - - totalPictureSize = sizeof(PictureRec) + - picturePrivateCount * sizeof(DevUnion) + - sizeof(nxagentPrivPictureRec); - - pPicture = (PicturePtr) xalloc(totalPictureSize); - - if (pPicture != NULL) - { - ppriv = (DevUnion *) (pPicture + 1); - - for (i = 0; i < picturePrivateCount; ++i) - { - /* - * Other privates are inaccessible. - */ - - ppriv[i].ptr = NULL; - } - - privPictureRecAddr = (char *) &ppriv[picturePrivateCount]; - - ppriv[nxagentPicturePrivateIndex].ptr = (pointer) privPictureRecAddr; - - pPicture -> devPrivates = ppriv; - - nxagentPicturePriv(pPicture) -> picture = 0; - } - + pPicture = (PicturePtr) xalloc(sizeof(PictureRec)); pPicture->pDrawable = 0; pPicture->pFormat = 0; pPicture->pNext = 0; @@ -1743,10 +1697,6 @@ FreePicture (pointer value, if (--pPicture->refcnt == 0) { -#ifdef NXAGENT_SERVER - nxagentDestroyPicture(pPicture); -#endif - if (pPicture->transform) xfree (pPicture->transform); if (!pPicture->pDrawable) { diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original index d9054b4b6..5cd3e5073 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -62,7 +62,6 @@ #include "Screen.h" #include "Pixmaps.h" #include "Drawable.h" -#include "Render.h" #define PANIC #define WARNING @@ -873,9 +872,6 @@ AllocatePicture (ScreenPtr pScreen) else ppriv->ptr = (pointer)NULL; } - - nxagentPicturePriv(pPicture) -> picture = 0; - return pPicture; } @@ -1067,49 +1063,7 @@ static void initGradient(SourcePictPtr pGradient, int stopCount, static PicturePtr createSourcePicture(void) { PicturePtr pPicture; - - extern int nxagentPicturePrivateIndex; - - unsigned int totalPictureSize; - - DevUnion *ppriv; - - char *privPictureRecAddr; - - int i; - - /* - * Compute size of entire PictureRect, plus privates. - */ - - totalPictureSize = sizeof(PictureRec) + - picturePrivateCount * sizeof(DevUnion) + - sizeof(nxagentPrivPictureRec); - - pPicture = (PicturePtr) xalloc(totalPictureSize); - - if (pPicture != NULL) - { - ppriv = (DevUnion *) (pPicture + 1); - - for (i = 0; i < picturePrivateCount; ++i) - { - /* - * Other privates are inaccessible. - */ - - ppriv[i].ptr = NULL; - } - - privPictureRecAddr = (char *) &ppriv[picturePrivateCount]; - - ppriv[nxagentPicturePrivateIndex].ptr = (pointer) privPictureRecAddr; - - pPicture -> devPrivates = ppriv; - - nxagentPicturePriv(pPicture) -> picture = 0; - } - + pPicture = (PicturePtr) xalloc(sizeof(PictureRec)); pPicture->pDrawable = 0; pPicture->pFormat = 0; pPicture->pNext = 0; @@ -1743,10 +1697,6 @@ FreePicture (pointer value, if (--pPicture->refcnt == 0) { -#ifdef NXAGENT_SERVER - nxagentDestroyPicture(pPicture); -#endif - if (pPicture->transform) xfree (pPicture->transform); if (!pPicture->pDrawable) { diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h index 0d1a8e1d8..d11e1fe21 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original index 0d1a8e1d8..d11e1fe21 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c index cd1ec6ddd..ac61552f0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original index cd1ec6ddd..ac61552f0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c index 5f460f23e..fa40a4921 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original index 5f460f23e..fa40a4921 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c index 89e790135..7c60d856c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c @@ -26,7 +26,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -116,6 +116,7 @@ int nxagentCursorSaveRenderInfo(ScreenPtr, CursorPtr); void nxagentCursorPostSaveRenderInfo(CursorPtr, ScreenPtr, PicturePtr, int, int); int nxagentRenderRealizeCursor(ScreenPtr, CursorPtr); int nxagentCreatePicture(PicturePtr, Mask); +void nxagentDestroyPicture(PicturePtr pPicture); void nxagentChangePicture(PicturePtr, Mask); int nxagentChangePictureClip(PicturePtr, int, int, xRectangle *, int, int); void nxagentComposite(CARD8, PicturePtr, PicturePtr, PicturePtr, INT16, INT16, @@ -131,28 +132,6 @@ void nxagentSetPictureFilter(PicturePtr pPicture, char *filter, int name_size, void nxagentTrapezoids(CARD8 op, PicturePtr pSrc, PicturePtr pDst, PictFormatPtr maskFormat, INT16 xSrc, INT16 ySrc, int ntrap, xTrapezoid *traps); -void nxagentRenderCreateSolidFill(PicturePtr pPicture, xRenderColor *color); - -void nxagentRenderCreateLinearGradient(PicturePtr pPicture, xPointFixed *p1, - xPointFixed *p2, int nStops, - xFixed *stops, - xRenderColor *colors); - -void nxagentRenderCreateRadialGradient(PicturePtr pPicture, xPointFixed *inner, - xPointFixed *outer, - xFixed innerRadius, - xFixed outerRadius, - int nStops, - xFixed *stops, - xRenderColor *colors); - -void nxagentRenderCreateConicalGradient(PicturePtr pPicture, - xPointFixed *center, - xFixed angle, int nStops, - xFixed *stops, - xRenderColor *colors); - - /* * The void pointer is actually a XGlyphElt8. */ @@ -844,6 +823,8 @@ ProcRenderFreePicture (ClientPtr client) VERIFY_PICTURE (pPicture, stuff->picture, client, SecurityDestroyAccess, RenderErrBase + BadPicture); + nxagentDestroyPicture(pPicture); + FreeResource (stuff->picture, RT_NONE); return(client->noClientException); } @@ -945,16 +926,9 @@ ProcRenderComposite (ClientPtr client) RenderErrBase + BadPicture); VERIFY_ALPHA (pMask, stuff->mask, client, SecurityReadAccess, RenderErrBase + BadPicture); -/* -FIXME: Imported change from newest version of Xorg. Changed pSrc to pDst. - if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || (pMask && pMask->pDrawable && pSrc->pDrawable->pScreen != pMask->pDrawable->pScreen)) return BadMatch; -*/ - if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || - (pMask && pMask->pDrawable && pDst->pDrawable->pScreen != pMask->pDrawable->pScreen)) - return BadMatch; ValidatePicture (pSrc); if (pMask) @@ -2362,11 +2336,6 @@ static int ProcRenderCreateSolidFill(ClientPtr client) pPicture = CreateSolidPicture(stuff->pid, &stuff->color, &error); if (!pPicture) return error; - /* AGENT SERVER */ - - nxagentRenderCreateSolidFill(pPicture, &stuff -> color); - - /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2398,12 +2367,6 @@ static int ProcRenderCreateLinearGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; - /* AGENT SERVER */ - - nxagentRenderCreateLinearGradient(pPicture, &stuff->p1, &stuff->p2, - stuff->nStops, stops, colors); - - /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2434,14 +2397,6 @@ static int ProcRenderCreateRadialGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; - /* AGENT SERVER */ - - nxagentRenderCreateRadialGradient(pPicture, &stuff->inner, &stuff->outer, - stuff->inner_radius, - stuff->outer_radius, - stuff->nStops, stops, colors); - - /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2471,13 +2426,6 @@ static int ProcRenderCreateConicalGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; - /* AGENT SERVER */ - - nxagentRenderCreateConicalGradient(pPicture, &stuff->center, - stuff->angle, stuff->nStops, stops, - colors); - - /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original index 89e790135..7c60d856c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original @@ -26,7 +26,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -116,6 +116,7 @@ int nxagentCursorSaveRenderInfo(ScreenPtr, CursorPtr); void nxagentCursorPostSaveRenderInfo(CursorPtr, ScreenPtr, PicturePtr, int, int); int nxagentRenderRealizeCursor(ScreenPtr, CursorPtr); int nxagentCreatePicture(PicturePtr, Mask); +void nxagentDestroyPicture(PicturePtr pPicture); void nxagentChangePicture(PicturePtr, Mask); int nxagentChangePictureClip(PicturePtr, int, int, xRectangle *, int, int); void nxagentComposite(CARD8, PicturePtr, PicturePtr, PicturePtr, INT16, INT16, @@ -131,28 +132,6 @@ void nxagentSetPictureFilter(PicturePtr pPicture, char *filter, int name_size, void nxagentTrapezoids(CARD8 op, PicturePtr pSrc, PicturePtr pDst, PictFormatPtr maskFormat, INT16 xSrc, INT16 ySrc, int ntrap, xTrapezoid *traps); -void nxagentRenderCreateSolidFill(PicturePtr pPicture, xRenderColor *color); - -void nxagentRenderCreateLinearGradient(PicturePtr pPicture, xPointFixed *p1, - xPointFixed *p2, int nStops, - xFixed *stops, - xRenderColor *colors); - -void nxagentRenderCreateRadialGradient(PicturePtr pPicture, xPointFixed *inner, - xPointFixed *outer, - xFixed innerRadius, - xFixed outerRadius, - int nStops, - xFixed *stops, - xRenderColor *colors); - -void nxagentRenderCreateConicalGradient(PicturePtr pPicture, - xPointFixed *center, - xFixed angle, int nStops, - xFixed *stops, - xRenderColor *colors); - - /* * The void pointer is actually a XGlyphElt8. */ @@ -844,6 +823,8 @@ ProcRenderFreePicture (ClientPtr client) VERIFY_PICTURE (pPicture, stuff->picture, client, SecurityDestroyAccess, RenderErrBase + BadPicture); + nxagentDestroyPicture(pPicture); + FreeResource (stuff->picture, RT_NONE); return(client->noClientException); } @@ -945,16 +926,9 @@ ProcRenderComposite (ClientPtr client) RenderErrBase + BadPicture); VERIFY_ALPHA (pMask, stuff->mask, client, SecurityReadAccess, RenderErrBase + BadPicture); -/* -FIXME: Imported change from newest version of Xorg. Changed pSrc to pDst. - if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || (pMask && pMask->pDrawable && pSrc->pDrawable->pScreen != pMask->pDrawable->pScreen)) return BadMatch; -*/ - if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || - (pMask && pMask->pDrawable && pDst->pDrawable->pScreen != pMask->pDrawable->pScreen)) - return BadMatch; ValidatePicture (pSrc); if (pMask) @@ -2362,11 +2336,6 @@ static int ProcRenderCreateSolidFill(ClientPtr client) pPicture = CreateSolidPicture(stuff->pid, &stuff->color, &error); if (!pPicture) return error; - /* AGENT SERVER */ - - nxagentRenderCreateSolidFill(pPicture, &stuff -> color); - - /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2398,12 +2367,6 @@ static int ProcRenderCreateLinearGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; - /* AGENT SERVER */ - - nxagentRenderCreateLinearGradient(pPicture, &stuff->p1, &stuff->p2, - stuff->nStops, stops, colors); - - /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2434,14 +2397,6 @@ static int ProcRenderCreateRadialGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; - /* AGENT SERVER */ - - nxagentRenderCreateRadialGradient(pPicture, &stuff->inner, &stuff->outer, - stuff->inner_radius, - stuff->outer_radius, - stuff->nStops, stops, colors); - - /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2471,13 +2426,6 @@ static int ProcRenderCreateConicalGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; - /* AGENT SERVER */ - - nxagentRenderCreateConicalGradient(pPicture, &stuff->center, - stuff->angle, stuff->nStops, stops, - colors); - - /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c index d1c8325f2..cffe8008b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original index d1c8325f2..cffe8008b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c index eaaa92041..ef830b73f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original index eaaa92041..ef830b73f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c index 76e86fd2a..ea133eaae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original index 76e86fd2a..ea133eaae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c index f6dad312a..497a62fe0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original index f6dad312a..497a62fe0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm b/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm index dd8be6cb3..5023265e9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm +++ b/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm b/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm index 854e0a611..3fce57ff7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm +++ b/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c b/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c index 9ec7e6bc8..f4d0a2d55 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c +++ b/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/screensaver b/nx-X11/programs/Xserver/hw/nxagent/screensaver index ef7cd661a..2fcf5dc87 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/screensaver +++ b/nx-X11/programs/Xserver/hw/nxagent/screensaver @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2003 NoMachine, http://www.nomachine.com. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ -- cgit v1.2.3 From c078024019d334eb96fbfaf922c64297c9a0c6e0 Mon Sep 17 00:00:00 2001 From: Reinhard Tartler Date: Mon, 10 Oct 2011 17:58:59 +0200 Subject: Imported nxagent-3.4.0-5.tar.gz Summary: Imported nxagent-3.4.0-5.tar.gz Keywords: Imported nxagent-3.4.0-5.tar.gz into Git repository --- nx-X11/programs/Xserver/hw/nxagent/Agent.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Args.c | 6 +- nx-X11/programs/Xserver/hw/nxagent/Args.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Atoms.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Atoms.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Binder.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Binder.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/CHANGELOG | 28 +++++ nx-X11/programs/Xserver/hw/nxagent/Client.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Client.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Clipboard.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Clipboard.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Colormap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Colormap.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Composite.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Composite.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Cursor.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Cursor.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Dialog.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Dialog.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Display.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Display.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Drawable.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Drawable.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Error.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Error.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Events.c | 134 ++++++++++++++++++++- nx-X11/programs/Xserver/hw/nxagent/Events.h | 6 +- nx-X11/programs/Xserver/hw/nxagent/Extensions.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Extensions.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Font.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Font.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/GC.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCOps.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCOps.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCs.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Handlers.c | 5 +- nx-X11/programs/Xserver/hw/nxagent/Handlers.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Holder.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Holder.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Icons.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Image.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Image.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Init.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Init.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keyboard.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keyboard.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keystroke.c | 54 ++++++++- nx-X11/programs/Xserver/hw/nxagent/Keystroke.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/LICENSE | 2 +- nx-X11/programs/Xserver/hw/nxagent/Literals.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Millis.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Millis.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c | 2 +- .../Xserver/hw/nxagent/NXdispatch.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c | 2 +- .../Xserver/hw/nxagent/NXdixfonts.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXevents.c | 2 +- .../Xserver/hw/nxagent/NXevents.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXextension.c | 2 +- .../Xserver/hw/nxagent/NXextension.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyph.c | 2 +- .../Xserver/hw/nxagent/NXglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c | 2 +- .../Xserver/hw/nxagent/NXglyphcurs.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h | 2 +- .../Xserver/hw/nxagent/NXglyphstr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c | 2 +- .../Xserver/hw/nxagent/NXmiglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXpicture.c | 2 +- .../Xserver/hw/nxagent/NXpicture.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h | 2 +- .../Xserver/hw/nxagent/NXpicturestr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXproperty.c | 2 +- .../Xserver/hw/nxagent/NXproperty.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXrandr.c | 2 +- .../Xserver/hw/nxagent/NXrandr.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXrender.c | 2 +- .../Xserver/hw/nxagent/NXrender.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXwindow.c | 2 +- .../Xserver/hw/nxagent/NXwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Options.c | 8 +- nx-X11/programs/Xserver/hw/nxagent/Options.h | 5 +- nx-X11/programs/Xserver/hw/nxagent/Pixels.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pixels.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pixmap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pointer.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pointer.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Reconnect.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Reconnect.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Render.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Render.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Rootless.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Rootless.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Screen.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Screen.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Splash.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Splash.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Split.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Split.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/TestExt.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Trap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Trap.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Utils.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Visual.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Visual.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Window.c | 64 +++++++++- nx-X11/programs/Xserver/hw/nxagent/Windows.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c | 2 +- .../Xserver/hw/nxagent/X/NXdamage.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c | 28 +++-- .../Xserver/hw/nxagent/X/NXdispatch.c.NX.original | 28 +++-- nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c | 2 +- .../Xserver/hw/nxagent/X/NXdixfonts.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c | 2 +- .../Xserver/hw/nxagent/X/NXevents.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c | 2 +- .../Xserver/hw/nxagent/X/NXextension.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c | 2 +- .../Xserver/hw/nxagent/X/NXglxext.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c | 2 +- .../Xserver/hw/nxagent/X/NXglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c | 2 +- .../Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h | 2 +- .../Xserver/hw/nxagent/X/NXglyphstr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c | 2 +- .../Xserver/hw/nxagent/X/NXmiexpose.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c | 2 +- .../Xserver/hw/nxagent/X/NXmiglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c | 2 +- .../Xserver/hw/nxagent/X/NXmitrap.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c | 2 +- .../Xserver/hw/nxagent/X/NXmiwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c | 2 +- .../Xserver/hw/nxagent/X/NXpicture.c.NX.original | 2 +- .../programs/Xserver/hw/nxagent/X/NXpicturestr.h | 2 +- .../hw/nxagent/X/NXpicturestr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c | 2 +- .../Xserver/hw/nxagent/X/NXproperty.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c | 2 +- .../Xserver/hw/nxagent/X/NXrandr.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c | 2 +- .../Xserver/hw/nxagent/X/NXrender.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c | 2 +- .../Xserver/hw/nxagent/X/NXresource.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c | 2 +- .../Xserver/hw/nxagent/X/NXshm.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c | 2 +- .../Xserver/hw/nxagent/X/NXwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c | 2 +- .../Xserver/hw/nxagent/X/NXxvdisp.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm | 2 +- nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm | 2 +- nx-X11/programs/Xserver/hw/nxagent/os2Stub.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/screensaver | 2 +- 160 files changed, 476 insertions(+), 190 deletions(-) (limited to 'nx-X11/programs/Xserver/hw/nxagent/Render.h') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Agent.h b/nx-X11/programs/Xserver/hw/nxagent/Agent.h index 13f87c96e..3f2c93fdb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Agent.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Agent.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.c b/nx-X11/programs/Xserver/hw/nxagent/Args.c index 0588f43d6..c2e58bd58 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Args.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Args.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -1208,7 +1208,7 @@ static void nxagentParseOptions(char *name, char *value) { nxagentChangeOption(ClientOs, ClientOsSolaris); } - else if (strcmp(value, "mac") == 0) + else if (strcmp(value, "macosx") == 0) { nxagentChangeOption(ClientOs, ClientOsMac); } @@ -1512,7 +1512,7 @@ N/A int splitMode = 0; int splitSize = 0; - unsigned int packMethod = PACK_NONE; + unsigned int packMethod = PACK_NONE; unsigned int packQuality = 9; int dataLevel = 0; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.h b/nx-X11/programs/Xserver/hw/nxagent/Args.h index 2aac8e387..92650a4a0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Args.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Args.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c index 13f9b8082..7f12406f5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h index 842b820db..d8acb9442 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.c b/nx-X11/programs/Xserver/hw/nxagent/Binder.c index 4fb5224fb..34433bd2b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Binder.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.h b/nx-X11/programs/Xserver/hw/nxagent/Binder.h index c4daeea8c..e0da3e357 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Binder.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG index 4e964d0ad..1a82e9abf 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG +++ b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG @@ -1,5 +1,33 @@ ChangeLog: +nxagent-3.4.0-5 + +- Updated copyright to year 2010. + +nxagent-3.4.0-4 + +- Fixed TR07F02090. Now XDMCP sessions start without problems. + +- Fixed TR08G02259. Corrected window border granularity of rootless + session at reconnection on 64 bit platforms. + +- Fixed TR11G02290. Forcing null timeout with queued events only if + display connection is up. This prevents the flood of session log. + +- Fixed TR10G02287. Now QueryTree's loop is aborted in case of failure + and session log isn't filled anymore with repeated warning messages. + +- Fixed TR01G02154. Corrected window placement when switching between + fullscreen and windowed mode. + +- Fixed TR09G02276. Now the agent does not receive unwanted characters + while interacting with the local window manager. + +- Implemented FR02G02174. Added ability to do large screen pans in + viewport mode through key combination Ctrl+Alt+Shift+Arrow. + +- Corrected parsing of the 'client' option when the client OS is Mac. + nxagent-3.4.0-3 - Fixed TR09G02271. The array containing the font name fields was not diff --git a/nx-X11/programs/Xserver/hw/nxagent/Client.c b/nx-X11/programs/Xserver/hw/nxagent/Client.c index b0db1df0f..acfaab7c0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Client.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Client.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Client.h b/nx-X11/programs/Xserver/hw/nxagent/Client.h index 4b12ed127..45f87fc66 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Client.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Client.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c index 442b1c871..eb830234d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h index 5a592a4da..2750ddfd2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c index d9a979a42..259aa3b24 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.h b/nx-X11/programs/Xserver/hw/nxagent/Colormap.h index a8e225460..8321e8038 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Composite.c b/nx-X11/programs/Xserver/hw/nxagent/Composite.c index 44bab3cf9..b0640ff11 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Composite.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Composite.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Composite.h b/nx-X11/programs/Xserver/hw/nxagent/Composite.h index c5dede9eb..fb1d6d8e9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Composite.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Composite.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Cursor.c b/nx-X11/programs/Xserver/hw/nxagent/Cursor.c index 7e4385712..141ba3a64 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Cursor.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Cursor.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Cursor.h b/nx-X11/programs/Xserver/hw/nxagent/Cursor.h index 7b4e6beac..11e407efd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Cursor.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Cursor.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Dialog.c b/nx-X11/programs/Xserver/hw/nxagent/Dialog.c index c6f8a9104..2f807b1dc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Dialog.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Dialog.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Dialog.h b/nx-X11/programs/Xserver/hw/nxagent/Dialog.h index 5c71fad87..aa845c7c2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Dialog.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Dialog.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.c b/nx-X11/programs/Xserver/hw/nxagent/Display.c index c1a80b391..1a57788e6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.h b/nx-X11/programs/Xserver/hw/nxagent/Display.h index 4c04c5ba8..35b7857ad 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Drawable.c b/nx-X11/programs/Xserver/hw/nxagent/Drawable.c index ddd7f13ca..75057097a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Drawable.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Drawable.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Drawable.h b/nx-X11/programs/Xserver/hw/nxagent/Drawable.h index 6ce0e3156..146610efb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Drawable.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Drawable.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Error.c b/nx-X11/programs/Xserver/hw/nxagent/Error.c index 2a8173019..963cfa287 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Error.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Error.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Error.h b/nx-X11/programs/Xserver/hw/nxagent/Error.h index f7a53cbd1..2d6083d4e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Error.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Error.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.c b/nx-X11/programs/Xserver/hw/nxagent/Events.c index 83665ff90..ca21423aa 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -679,6 +679,30 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) break; } + case doViewportMoveUp: + { + nxagentMoveViewport(pScreen, 0, -nxagentOption(Height)); + + break; + } + case doViewportMoveDown: + { + nxagentMoveViewport(pScreen, 0, nxagentOption(Height)); + + break; + } + case doViewportMoveLeft: + { + nxagentMoveViewport(pScreen, -nxagentOption(Width), 0); + + break; + } + case doViewportMoveRight: + { + nxagentMoveViewport(pScreen, nxagentOption(Width), 0); + + break; + } case doViewportUp: { nxagentMoveViewport(pScreen, 0, -nextinc(viewportInc)); @@ -763,6 +787,20 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) case KeyRelease: { enum HandleEventResult result; + int sendKey = 0; + +/* +FIXME: Don't enqueue the KeyRelease event if the key was + not already pressed. This workaround avoids a fake + KeyPress is enqueued by the XKEYBOARD extension. + Another solution would be to let the events are + enqueued and to remove the KeyPress afterwards. +*/ + + if (inputInfo.keyboard -> key -> down[X.xkey.keycode >> 3] & (1 << (X.xkey.keycode & 7))) + { + sendKey = 1; + } #ifdef TEST fprintf(stderr, "nxagentDispatchEvents: Going to handle new KeyRelease event.\n"); @@ -808,7 +846,7 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) x.u.keyButtonPointer.time = nxagentLastEventTime; } - if (!(nxagentCheckSpecialKeystroke(&X.xkey, &result))) + if (!(nxagentCheckSpecialKeystroke(&X.xkey, &result)) && sendKey == 1) { mieqEnqueue(&x); @@ -3101,6 +3139,8 @@ int nxagentHandleReparentNotify(XEvent* X) #ifdef WARNING fprintf(stderr, "nxagentHandleReparentNotify: WARNING! Failed QueryTree request.\n"); #endif + + break; } if (result && children_return) @@ -3153,6 +3193,96 @@ int nxagentHandleReparentNotify(XEvent* X) return 1; } + else if (nxagentWMIsRunning == 1 && nxagentOption(Fullscreen) == 0 && + nxagentOption(WMBorderWidth) == -1) + { + XlibWindow w; + XlibWindow rootReturn = 0; + XlibWindow parentReturn = 0; + XlibWindow junk; + XlibWindow *childrenReturn = NULL; + unsigned int nchildrenReturn = 0; + Status result; + XSizeHints hints; + XWindowAttributes attributes; + int x, y; + int xParent, yParent; + + /* + * Calculate the absolute upper-left X e Y + */ + + if ((XGetWindowAttributes(nxagentDisplay, X -> xreparent.window, + &attributes) == 0)) + { + #ifdef WARNING + fprintf(stderr, "nxagentHandleReparentNotify: WARNING! " + "XGetWindowAttributes failed.\n"); + #endif + + return 1; + } + + x = attributes.x; + y = attributes.y; + + XTranslateCoordinates(nxagentDisplay, X -> xreparent.window, + attributes.root, -attributes.border_width, + -attributes.border_width, &x, &y, &junk); + + /* + * Calculate the parent X and parent Y. + */ + + w = X -> xreparent.parent; + + if (w != DefaultRootWindow(nxagentDisplay)) + { + do + { + result = XQueryTree(nxagentDisplay, w, &rootReturn, &parentReturn, + &childrenReturn, &nchildrenReturn); + + if (parentReturn == rootReturn || parentReturn == 0 || result == 0) + { + break; + } + + if (result == 1 && childrenReturn != NULL) + { + XFree(childrenReturn); + } + + w = parentReturn; + } + while (True); + + /* + * WM reparented. Find edge of the frame. + */ + + if (XGetWindowAttributes(nxagentDisplay, w, &attributes) == 0) + { + #ifdef WARNING + fprintf(stderr, "nxagentHandleReparentNotify: WARNING! " + "XGetWindowAttributes failed for parent window.\n"); + #endif + + return 1; + } + + xParent = attributes.x; + yParent = attributes.y; + + /* + * Difference between Absolute X and Parent X gives thickness of side frame. + * Difference between Absolute Y and Parent Y gives thickness of title bar. + */ + + nxagentChangeOption(WMBorderWidth, (x - xParent)); + nxagentChangeOption(WMTitleHeight, (y - yParent)); + } + } return 1; } diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.h b/nx-X11/programs/Xserver/hw/nxagent/Events.h index 3e04222a2..238a229f9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -32,6 +32,10 @@ enum HandleEventResult doCloseSession, doStartKbd, doSwitchFullscreen, + doViewportMoveUp, + doViewportMoveLeft, + doViewportMoveRight, + doViewportMoveDown, doViewportLeft, doViewportUp, doViewportRight, diff --git a/nx-X11/programs/Xserver/hw/nxagent/Extensions.c b/nx-X11/programs/Xserver/hw/nxagent/Extensions.c index 748afa53e..e76cbb4ad 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Extensions.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Extensions.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Extensions.h b/nx-X11/programs/Xserver/hw/nxagent/Extensions.h index 06185170e..620645d00 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Extensions.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Extensions.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Font.c b/nx-X11/programs/Xserver/hw/nxagent/Font.c index b14dc883b..13b819322 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Font.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Font.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Font.h b/nx-X11/programs/Xserver/hw/nxagent/Font.h index d95cbdc83..75ae3f6f5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Font.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Font.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GC.c b/nx-X11/programs/Xserver/hw/nxagent/GC.c index 55a0a0031..c53e3b9f7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GC.c +++ b/nx-X11/programs/Xserver/hw/nxagent/GC.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCOps.c b/nx-X11/programs/Xserver/hw/nxagent/GCOps.c index d2cc58400..85730797e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCOps.c +++ b/nx-X11/programs/Xserver/hw/nxagent/GCOps.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCOps.h b/nx-X11/programs/Xserver/hw/nxagent/GCOps.h index 666a098bf..7ae6d9923 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCOps.h +++ b/nx-X11/programs/Xserver/hw/nxagent/GCOps.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCs.h b/nx-X11/programs/Xserver/hw/nxagent/GCs.h index 460469696..bec290088 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCs.h +++ b/nx-X11/programs/Xserver/hw/nxagent/GCs.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Handlers.c b/nx-X11/programs/Xserver/hw/nxagent/Handlers.c index e43fbb931..be407f160 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Handlers.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Handlers.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -527,7 +527,8 @@ void nxagentBlockHandler(pointer data, struct timeval **timeout, pointer mask) synchronize, nxagentReady); #endif - if (nxagentQueuedEvents(nxagentDisplay) > 0) + if (NXDisplayError(nxagentDisplay) == 0 && + nxagentQueuedEvents(nxagentDisplay) > 0) { #ifdef WARNING fprintf(stderr, "nxagentBlockHandler: WARNING! Forcing a null timeout with events queued.\n"); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Handlers.h b/nx-X11/programs/Xserver/hw/nxagent/Handlers.h index 8cf92b219..fe8aeef36 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Handlers.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Handlers.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Holder.c b/nx-X11/programs/Xserver/hw/nxagent/Holder.c index 02fde6782..a9ac77c09 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Holder.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Holder.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Holder.h b/nx-X11/programs/Xserver/hw/nxagent/Holder.h index 469da223d..9896aeead 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Holder.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Holder.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Icons.h b/nx-X11/programs/Xserver/hw/nxagent/Icons.h index 350e76487..4d0e216cd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Icons.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Icons.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Image.c b/nx-X11/programs/Xserver/hw/nxagent/Image.c index ec7a60a96..e8405ed3a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Image.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Image.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Image.h b/nx-X11/programs/Xserver/hw/nxagent/Image.h index bd6d4c948..7805b0312 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Image.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Image.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Init.c b/nx-X11/programs/Xserver/hw/nxagent/Init.c index f60d7c457..64b6583bf 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Init.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Init.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -193,7 +193,7 @@ void InitOutput(ScreenInfo *screenInfo, int argc, char *argv[]) if (serverGeneration <= 1) { fprintf(stderr, "\nNXAGENT - Version " NXAGENT_VERSION "\n\n"); - fprintf(stderr, "Copyright (C) 2001, 2007 NoMachine.\n"); + fprintf(stderr, "Copyright (C) 2001, 2010 NoMachine.\n"); fprintf(stderr, "See http://www.nomachine.com/ for more information.\n\n"); fprintf(stderr, "Info: Agent running with pid '%d'.\n", getpid()); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Init.h b/nx-X11/programs/Xserver/hw/nxagent/Init.h index 16c74ea99..576c1a74d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Init.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Init.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c index a4729e9b7..b0aeabeea 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h index 4c7395a43..1a953358a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c index eee13db2d..a2e4fb06f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -264,6 +264,58 @@ int nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) #endif } } + else if ((X -> state & nxagentAltMetaMask) && + ((X -> state & (ControlMask | ShiftMask)) == (ControlMask | + ShiftMask))) + { + switch (sym) + { + case XK_Left: + case XK_KP_Left: + { + if (nxagentOption(Rootless) == 0 && + nxagentOption(DesktopResize) == 0) + { + *result = doViewportMoveLeft; + } + + break; + } + case XK_Up: + case XK_KP_Up: + { + if (nxagentOption(Rootless) == 0 && + nxagentOption(DesktopResize) == 0) + { + *result = doViewportMoveUp; + } + + break; + } + case XK_Right: + case XK_KP_Right: + { + if (nxagentOption(Rootless) == 0 && + nxagentOption(DesktopResize) == 0) + { + *result = doViewportMoveRight; + } + + break; + } + case XK_Down: + case XK_KP_Down: + { + if (nxagentOption(Rootless) == 0 && + nxagentOption(DesktopResize) == 0) + { + *result = doViewportMoveDown; + } + + break; + } + } + } return (*result == doNothing) ? 0 : 1; } diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h index fea97975c..e9ca59ff2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/LICENSE b/nx-X11/programs/Xserver/hw/nxagent/LICENSE index 451196c1a..141ca13ea 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/LICENSE +++ b/nx-X11/programs/Xserver/hw/nxagent/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2001, 2009 NoMachine - http://www.nomachine.com/. +Copyright (c) 2001, 2010 NoMachine - http://www.nomachine.com/. NXAGENT and NX extensions to X are copyright of NoMachine. diff --git a/nx-X11/programs/Xserver/hw/nxagent/Literals.h b/nx-X11/programs/Xserver/hw/nxagent/Literals.h index 21c27afa1..377dd7e25 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Literals.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Literals.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Millis.c b/nx-X11/programs/Xserver/hw/nxagent/Millis.c index e275b985f..bde85f090 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Millis.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Millis.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Millis.h b/nx-X11/programs/Xserver/hw/nxagent/Millis.h index 9b6d879d7..2125eca3e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Millis.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Millis.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c index e189b9539..5106ffa8c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original index e189b9539..5106ffa8c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c index b57401ceb..0d8584218 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original index b57401ceb..0d8584218 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c index b01e4a452..cd8ced7a6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original index b01e4a452..cd8ced7a6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c index 9bb868f2b..852ad1503 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original index 9bb868f2b..852ad1503 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c index 6ec64afae..55248195f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original index 6ec64afae..55248195f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c index 6352c88d1..614d2db39 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original index 6352c88d1..614d2db39 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h index 0874f0fef..08ffb35b0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original index 0874f0fef..08ffb35b0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c index e0f6d1cdf..806cf2900 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original index e0f6d1cdf..806cf2900 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c index 95178d362..a9c501b34 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original index 95178d362..a9c501b34 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h index 90a31d36f..26a95fe9f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original index 90a31d36f..26a95fe9f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c index 06d6074ad..14b6136d4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original index 06d6074ad..14b6136d4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c index 179cc1ab0..b7039e1e0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original index 179cc1ab0..b7039e1e0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c index a670c3521..0940a3602 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c @@ -31,7 +31,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original index a670c3521..0940a3602 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original @@ -31,7 +31,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c index a0d4cd6ee..0954cf8ae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original index a0d4cd6ee..0954cf8ae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c index a8aa254ff..8d05175ff 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h index 8ceb49418..4e800e96d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h b/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h index 727161648..ae3a03d86 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Options.c b/nx-X11/programs/Xserver/hw/nxagent/Options.c index 955be61bc..1f04b0daf 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Options.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Options.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -63,6 +63,9 @@ void nxagentInitOptions() nxagentOptions.Height = 0; nxagentOptions.BorderWidth = 0; + nxagentOptions.WMBorderWidth = -1; + nxagentOptions.WMTitleHeight = -1; + nxagentOptions.SavedX = 0; nxagentOptions.SavedY = 0; nxagentOptions.SavedWidth = 0; @@ -168,6 +171,9 @@ void nxagentResetOptions() nxagentOptions.TileWidth = UNDEFINED; nxagentOptions.TileHeight = UNDEFINED; + + nxagentOptions.WMBorderWidth = -1; + nxagentOptions.WMTitleHeight = -1; } void nxagentSaveOptions() diff --git a/nx-X11/programs/Xserver/hw/nxagent/Options.h b/nx-X11/programs/Xserver/hw/nxagent/Options.h index 7126338a8..1bc7eaa4c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Options.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Options.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -126,6 +126,9 @@ typedef struct _AgentOptions * screen. */ + int WMBorderWidth; + int WMTitleHeight; + int SavedX; int SavedY; int SavedWidth; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixels.c b/nx-X11/programs/Xserver/hw/nxagent/Pixels.c index eb8daf8f3..10c705dfc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixels.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixels.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h index cd2df1fa6..e046771cc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c index 9a4776192..1718c7363 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h b/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h index 93df4d444..234650dd4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c index 8a6702d18..34012d3d5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h index 3d8899bbe..0807b08ae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c index c656f2912..598ffc188 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h index 6a3b56fc7..12d0742df 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.c b/nx-X11/programs/Xserver/hw/nxagent/Render.c index 5c6503e64..6bc54c86e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.h b/nx-X11/programs/Xserver/hw/nxagent/Render.h index 77e842d16..81ba3369d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c index 53f4df41e..a8ce4c7cd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Rootless.h b/nx-X11/programs/Xserver/hw/nxagent/Rootless.h index 5538b58ea..ece4c9d31 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Rootless.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Rootless.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.c b/nx-X11/programs/Xserver/hw/nxagent/Screen.c index 4f4160765..bdd30afee 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.h b/nx-X11/programs/Xserver/hw/nxagent/Screen.h index ab8c01a73..6ffebe0ea 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Splash.c b/nx-X11/programs/Xserver/hw/nxagent/Splash.c index 54b355762..24dbf1413 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Splash.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Splash.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Splash.h b/nx-X11/programs/Xserver/hw/nxagent/Splash.h index a677f209b..86920ad8b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Splash.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Splash.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Split.c b/nx-X11/programs/Xserver/hw/nxagent/Split.c index 061ab8c45..bf7f705b9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Split.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Split.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Split.h b/nx-X11/programs/Xserver/hw/nxagent/Split.h index 88e55485c..60be29b39 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Split.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Split.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/TestExt.c b/nx-X11/programs/Xserver/hw/nxagent/TestExt.c index 17e6a89e1..1d5fdee20 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/TestExt.c +++ b/nx-X11/programs/Xserver/hw/nxagent/TestExt.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.c b/nx-X11/programs/Xserver/hw/nxagent/Trap.c index c6f62c43f..22de3bc1b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Trap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.h b/nx-X11/programs/Xserver/hw/nxagent/Trap.h index 13bbf65c7..aa6937e70 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Trap.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Utils.h b/nx-X11/programs/Xserver/hw/nxagent/Utils.h index bf2aa1c26..830b2753f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Utils.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Utils.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Visual.c b/nx-X11/programs/Xserver/hw/nxagent/Visual.c index 46fe90f39..f38931677 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Visual.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Visual.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Visual.h b/nx-X11/programs/Xserver/hw/nxagent/Visual.h index d60f0d824..c682f92dd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Visual.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Visual.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Window.c b/nx-X11/programs/Xserver/hw/nxagent/Window.c index 2abfd5ea0..449458ade 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Window.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Window.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -884,8 +884,19 @@ void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn) } } - nxagentChangeOption(X, nxagentOption(SavedX)); - nxagentChangeOption(Y, nxagentOption(SavedY)); + if (nxagentOption(WMBorderWidth) > 0 && nxagentOption(WMTitleHeight) > 0) + { + nxagentChangeOption(X, nxagentOption(SavedX) - + nxagentOption(WMBorderWidth)); + nxagentChangeOption(Y, nxagentOption(SavedY) - + nxagentOption(WMTitleHeight)); + } + else + { + nxagentChangeOption(X, nxagentOption(SavedX)); + nxagentChangeOption(Y, nxagentOption(SavedY)); + } + nxagentChangeOption(Width, nxagentOption(SavedWidth)); nxagentChangeOption(Height, nxagentOption(SavedHeight)); @@ -2897,6 +2908,13 @@ FIXME: Do we need to set save unders attribute here? XSizeHints *props, hints; unsigned char *data = NULL; + #ifdef _XSERVER64 + + unsigned char *data64 = NULL; + unsigned int i; + + #endif + hints.flags = 0; ret = GetWindowProperty(pWin, @@ -2905,10 +2923,13 @@ FIXME: Do we need to set save unders attribute here? False, XA_WM_SIZE_HINTS, &type, &format, &nItems, &bytesLeft, &data); - props = (XSizeHints*) data; + /* + * 72 is the number of bytes returned by + * sizeof(XSizeHints) on 32 bit platforms. + */ if (ret == Success && - ((format >> 3) * nItems) == sizeof(XSizeHints) && + ((format >> 3) * nItems) == 72 && bytesLeft == 0 && type == XA_WM_SIZE_HINTS) { @@ -2917,6 +2938,30 @@ FIXME: Do we need to set save unders attribute here? (void*)pWin, pWin -> drawable.id, nxagentWindow(pWin)); #endif + #ifdef _XSERVER64 + + data64 = (unsigned char *) malloc(sizeof(XSizeHints) + 4); + + for (i = 0; i < 4; i++) + { + *(data64 + i) = *(data + i); + } + + *(((int *) data64) + 1) = 0; + + for (i = 8; i < sizeof(XSizeHints) + 4; i++) + { + *(data64 + i) = *(data + i - 4); + } + + props = (XSizeHints *) data64; + + #else + + props = (XSizeHints *) data; + + #endif /* _XSERVER64 */ + hints = *props; } else @@ -2935,6 +2980,15 @@ FIXME: Do we need to set save unders attribute here? XSetWMNormalHints(nxagentDisplay, nxagentWindow(pWin), &hints); + + #ifdef _XSERVER64 + + if (data64 != NULL) + { + free(data64); + } + + #endif } } diff --git a/nx-X11/programs/Xserver/hw/nxagent/Windows.h b/nx-X11/programs/Xserver/hw/nxagent/Windows.h index f77db372d..6fc97b341 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Windows.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Windows.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c index 967c5656e..7bc1c74cb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original index 967c5656e..7bc1c74cb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c index d9da23738..ba4e1e662 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -513,17 +513,6 @@ Dispatch(void) * completed. We can now handle our clients. */ - if (serverGeneration > nxagentMaxAllowedResets) - { - #ifdef NX_DEBUG_INPUT - fprintf(stderr, "Session: Session started at '%s' timestamp [%lu].\n", GetTimeAsString(), GetTimeInMillis()); - #else - fprintf(stderr, "Session: Session started at '%s'.\n", GetTimeAsString()); - #endif - - nxagentSessionState = SESSION_UP; - } - #ifdef XKB nxagentInitXkbWrapper(); @@ -607,6 +596,21 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio clientReady[1] = NXAGENT_WAKEUP; } + if (serverGeneration > nxagentMaxAllowedResets && + nxagentSessionState == SESSION_STARTING && + (nxagentOption(Xdmcp) == 0 || nxagentXdmcpUp == 1)) + { + #ifdef NX_DEBUG_INPUT + fprintf(stderr, "Session: Session started at '%s' timestamp [%lu].\n", + GetTimeAsString(), GetTimeInMillis()); + #else + fprintf(stderr, "Session: Session started at '%s'.\n", + GetTimeAsString()); + #endif + + nxagentSessionState = SESSION_UP; + } + #ifdef BLOCKS fprintf(stderr, "[End dispatch]\n"); #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original index d9da23738..ba4e1e662 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -513,17 +513,6 @@ Dispatch(void) * completed. We can now handle our clients. */ - if (serverGeneration > nxagentMaxAllowedResets) - { - #ifdef NX_DEBUG_INPUT - fprintf(stderr, "Session: Session started at '%s' timestamp [%lu].\n", GetTimeAsString(), GetTimeInMillis()); - #else - fprintf(stderr, "Session: Session started at '%s'.\n", GetTimeAsString()); - #endif - - nxagentSessionState = SESSION_UP; - } - #ifdef XKB nxagentInitXkbWrapper(); @@ -607,6 +596,21 @@ Reply Total Cached Bits In Bits Out Bits/Reply Ratio clientReady[1] = NXAGENT_WAKEUP; } + if (serverGeneration > nxagentMaxAllowedResets && + nxagentSessionState == SESSION_STARTING && + (nxagentOption(Xdmcp) == 0 || nxagentXdmcpUp == 1)) + { + #ifdef NX_DEBUG_INPUT + fprintf(stderr, "Session: Session started at '%s' timestamp [%lu].\n", + GetTimeAsString(), GetTimeInMillis()); + #else + fprintf(stderr, "Session: Session started at '%s'.\n", + GetTimeAsString()); + #endif + + nxagentSessionState = SESSION_UP; + } + #ifdef BLOCKS fprintf(stderr, "[End dispatch]\n"); #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c index 4361985fd..225ecdaf8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original index 4361985fd..225ecdaf8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c index 467381054..8e87d58c4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original index 467381054..8e87d58c4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c index 9bfb28426..6e67b7ffe 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original index 9bfb28426..6e67b7ffe 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c index 3d021a0c4..172252b32 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original index 3d021a0c4..172252b32 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c index 577659a82..6340de537 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original index 577659a82..6340de537 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c index b11b10fb9..d6cd96631 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original index b11b10fb9..d6cd96631 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h index b6d563c6b..e78a1bf14 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original index b6d563c6b..e78a1bf14 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c index 652b85dd7..c71ea8142 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original index 652b85dd7..c71ea8142 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c index 4eabd17f9..efb295861 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original index 4eabd17f9..efb295861 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c index 124356427..d2bead0bc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original index 124356427..d2bead0bc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c index d486d19c5..be1096c6c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original index d486d19c5..be1096c6c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c index 5cd3e5073..18697a576 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original index 5cd3e5073..18697a576 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h index d11e1fe21..b6cee91f1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original index d11e1fe21..b6cee91f1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c index ac61552f0..d02f3f015 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original index ac61552f0..d02f3f015 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c index fa40a4921..e1bb44148 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original index fa40a4921..e1bb44148 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c index 7c60d856c..ffc199704 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c @@ -26,7 +26,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original index 7c60d856c..ffc199704 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original @@ -26,7 +26,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c index cffe8008b..8c69217e7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original index cffe8008b..8c69217e7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c index ef830b73f..b99cbe3e3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original index ef830b73f..b99cbe3e3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c index ea133eaae..4022bc397 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original index ea133eaae..4022bc397 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c index 497a62fe0..aa902226e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original index 497a62fe0..aa902226e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm b/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm index 5023265e9..5955f1705 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm +++ b/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm b/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm index 3fce57ff7..e7dee27b1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm +++ b/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c b/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c index f4d0a2d55..80419d871 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c +++ b/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/screensaver b/nx-X11/programs/Xserver/hw/nxagent/screensaver index 2fcf5dc87..4c5c10620 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/screensaver +++ b/nx-X11/programs/Xserver/hw/nxagent/screensaver @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2003 NoMachine, http://www.nomachine.com. */ +/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ -- cgit v1.2.3 From b7494f082ad56049c24927afdf89abc852fe06bb Mon Sep 17 00:00:00 2001 From: Reinhard Tartler Date: Mon, 10 Oct 2011 17:58:59 +0200 Subject: Imported nxagent-3.4.0-8.tar.gz Summary: Imported nxagent-3.4.0-8.tar.gz Keywords: Imported nxagent-3.4.0-8.tar.gz into Git repository --- nx-X11/programs/Xserver/hw/nxagent/Atoms.c | 28 +- nx-X11/programs/Xserver/hw/nxagent/Atoms.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/CHANGELOG | 56 +++ nx-X11/programs/Xserver/hw/nxagent/Events.c | 553 +++++++++++++++++---- nx-X11/programs/Xserver/hw/nxagent/Events.h | 1 + nx-X11/programs/Xserver/hw/nxagent/Imakefile | 3 +- nx-X11/programs/Xserver/hw/nxagent/Keystroke.c | 12 + nx-X11/programs/Xserver/hw/nxagent/Pixels.h | 18 + nx-X11/programs/Xserver/hw/nxagent/Pointer.c | 34 ++ nx-X11/programs/Xserver/hw/nxagent/Pointer.h | 9 + nx-X11/programs/Xserver/hw/nxagent/Reconnect.c | 4 + nx-X11/programs/Xserver/hw/nxagent/Render.c | 281 ++++++++++- nx-X11/programs/Xserver/hw/nxagent/Render.h | 2 + nx-X11/programs/Xserver/hw/nxagent/Rootless.c | 43 +- nx-X11/programs/Xserver/hw/nxagent/Screen.c | 234 +-------- nx-X11/programs/Xserver/hw/nxagent/Screen.h | 3 - nx-X11/programs/Xserver/hw/nxagent/Window.c | 269 ++-------- nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c | 47 +- .../Xserver/hw/nxagent/X/NXpicture.c.NX.original | 47 +- nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c | 58 ++- .../Xserver/hw/nxagent/X/NXrender.c.NX.original | 58 ++- 21 files changed, 1179 insertions(+), 583 deletions(-) (limited to 'nx-X11/programs/Xserver/hw/nxagent/Render.h') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c index 7f12406f5..171df95a9 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c @@ -66,19 +66,21 @@ Atom nxagentAtoms[NXAGENT_NUMBER_OF_ATOMS]; static char *nxagentAtomNames[NXAGENT_NUMBER_OF_ATOMS + 1] = { - "NX_IDENTITY", /* 0 */ - "WM_PROTOCOLS", /* 1 */ - "WM_DELETE_WINDOW", /* 2 */ - "WM_NX_READY", /* 3 */ - "MCOPGLOBALS", /* 4 */ - "NX_CUT_BUFFER_SERVER", /* 5 */ - "TARGETS", /* 6 */ - "TEXT", /* 7 */ - "NX_AGENT_SIGNATURE", /* 8 */ - "NXDARWIN", /* 9 */ - "CLIPBOARD", /* 10 */ - "TIMESTAMP", /* 11 */ - "UTF8_STRING", /* 12 */ + "NX_IDENTITY", /* 0 */ + "WM_PROTOCOLS", /* 1 */ + "WM_DELETE_WINDOW", /* 2 */ + "WM_NX_READY", /* 3 */ + "MCOPGLOBALS", /* 4 */ + "NX_CUT_BUFFER_SERVER", /* 5 */ + "TARGETS", /* 6 */ + "TEXT", /* 7 */ + "NX_AGENT_SIGNATURE", /* 8 */ + "NXDARWIN", /* 9 */ + "CLIPBOARD", /* 10 */ + "TIMESTAMP", /* 11 */ + "UTF8_STRING", /* 12 */ + "_NET_WM_STATE", /* 13 */ + "_NET_WM_STATE_FULLSCREEN", /* 14 */ NULL, NULL }; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h index d8acb9442..f49f2751e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h @@ -22,7 +22,7 @@ #include "../../include/window.h" #include "screenint.h" -#define NXAGENT_NUMBER_OF_ATOMS 14 +#define NXAGENT_NUMBER_OF_ATOMS 16 extern Atom nxagentAtoms[NXAGENT_NUMBER_OF_ATOMS]; diff --git a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG index 1a82e9abf..9e067d407 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG +++ b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG @@ -1,5 +1,61 @@ ChangeLog: +nxagent-3.4.0-8 + +- Grab the keyboard in fullscreen mode on EnterNotify only if mode is + 'NotifyNormal'. + +- Yield control in the dispatch loop in case we stop the smart sche- + duler timer while waiting for a reply from the remote display. + +nxagent-3.4.0-7 + +- Fixed TR08D01478. The communication with the compiz window manager + by means of the _NET_WM_PING property was not handled properly. + +- Fixed a type mismatch in XKB events on 64 bit platforms. + +- Moved grab/ungrab keyboard from focus in/out event to enter/leave + notify event. + +- Removed nxagentIconWindow because it's not longer used. + +nxagent-3.4.0-6 + +- Fixed TR09F02102. Problem was with pointer buttons map. + +- Fixed TR02H02327. Some KeyRelease events was discarded. + +- Fixed up Num and Caps locks. + +- Fixed TR03H02335. Emulated right mouse button for Mac clients. + +- Added utilities to print info about internal and remote windows. + +- Fixed TR01F01995. Solved a picture resource leak by destroying remo- + te pictures only when their reference counter returns to zero. + +- Fixed TR04H02337. Errors occurred because pictures with no drawable + were handled badly. + +- Implemented handling nxagent's private for gradient pictures and so- + lid fill picture. + +- Fixed BadMatch condition check in function ProcRenderComposite. + +- Fixed nxagentComposite() to handle situations with source picture + drawable pointing to NULL. + +- Implemented render acceleration for requests: CreateSolidFill, + CreateLinearGradient, CreateRadialGradient, CreateConicalGradient. + +- Fixed TR03G02196. Dialogs are shown to the fore when the NX session + is in fullscreen mode. + +- Changed mechanism to switch to fullscreen mode. Now the override + redirect attribute is no longer used and _NET_WM_STATE_FULLSCREEN + hint is sent to the WM. + nxagent-3.4.0-5 - Updated copyright to year 2010. diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.c b/nx-X11/programs/Xserver/hw/nxagent/Events.c index ca21423aa..33eafa55b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.c @@ -76,7 +76,9 @@ #include "input.h" #endif +#define Time XlibXID #include "XKBlib.h" +#undef Time #define GC XlibGC #define Font XlibFont @@ -203,6 +205,8 @@ CARD32 nxagentLastEventTime = 0; CARD32 nxagentLastKeyPressTime = 0; Time nxagentLastServerTime = 0; +int nxagentPointerAndKeyboardGrabbed = 0; + /* * Used for storing windows that need to * receive expose events from the agent. @@ -218,6 +222,16 @@ static void nxagentForwardRemoteExpose(void); static int nxagentClipAndSendExpose(WindowPtr pWin, pointer ptr); +/* + * This is from NXproperty.c. + */ + +int GetWindowProperty(WindowPtr pWin, Atom property, long longOffset, + long longLength, Bool delete, Atom type, + Atom *actualType, int *format, unsigned + long *nItems, unsigned long *bytesAfter, + unsigned char **propData); + /* * Associate a resource to a drawable and * store the region affected by the split @@ -274,6 +288,280 @@ void ProcessInputEvents() mieqProcessInputEvents(); } +#ifdef DEBUG_TREE + +/* + * Print ID and name of window. + */ + +void nxagentRemoteWindowID(Window window, Bool newline) +{ +#ifdef NO_I18N + char *winName; +#else + XTextProperty tp; +#endif + + fprintf(stderr, "0x%lx", window); + + if (!window) + { + fprintf(stderr, " (none) "); + } + else + { + if (window == DefaultRootWindow(nxagentDisplay)) + { + fprintf(stderr, " (the root window) "); + } + +#ifdef NO_I18N + + if (!XFetchName(nxagentDisplay, window, &winName)) + { + fprintf(stderr, " (has no name) "); + } + else if (winName) + { + fprintf(stderr, " \"%s\" ", winName); + XFree(winName); + } + +#else + + if (XGetWMName(nxagentDisplay, window, &tp) != 0) + { + fprintf(stderr, " (has no name) "); + } + else if (tp.nitems > 0) + { + int count = 0; + int i, ret; + char **list = NULL; + + fprintf(stderr, " \""); + + ret = XmbTextPropertyToTextList(nxagentDisplay, &tp, &list, &count); + + if ((ret == Success || ret > 0) && list != NULL) + { + for (i = 0; i < count; i++) + { + fprintf(stderr, "%s", list[i]); + } + + XFreeStringList(list); + } + else + { + fprintf(stderr, "%s", tp.value); + } + + fprintf(stderr, "\" "); + } + +#endif + + else + { + fprintf(stderr, " (has no name) "); + } + } + + if (newline == TRUE) + { + fprintf(stderr, "\n"); + } + + return; +} + +/* + * Print info about remote window. + */ + +void nxagentRemoteWindowInfo(Window win, int indent, Bool newLine) +{ + XWindowAttributes attributes; + int i; + + if (XGetWindowAttributes(nxagentDisplay, win, &attributes) == 0) + { + return; + } + + for (i = 0; i < indent; i++) + { + fprintf(stderr, " "); + } + + fprintf(stderr, "x=%d y=%d width=%d height=%d class=%s map_state=%s " + "override_redirect=%s\n", attributes.x, attributes.y, + attributes.width, attributes.height, (attributes.class == 0) ? + "InputOutput" : "InputOnly", (attributes.map_state == 0) ? + "IsUnmapped" : (attributes.map_state == 1 ? + "IsUnviewable" : "IsViewable"), + (attributes.override_redirect == 0) ? + "No" : "Yes" ); + + if (newLine == TRUE) + { + fprintf(stderr, "\n"); + } +} + +/* + * Walk remote windows tree. + */ + +void nxagentRemoteWindowsTree(Window window, int level) +{ + int i, j; + Window rootWin, parentWin; + unsigned int numChildren; + Window *childList; + + if (!XQueryTree(nxagentDisplay, window, &rootWin, &parentWin, &childList, + &numChildren)) + { + fprintf(stderr, "nxagentRemoteWindowsTree - XQueryTree failed.\n"); + + return; + } + + if (level == 0) + { + fprintf(stderr, "\n"); + + fprintf(stderr, " Root Window ID: "); + nxagentRemoteWindowID(rootWin, TRUE); + + fprintf(stderr, " Parent window ID: "); + nxagentRemoteWindowID(parentWin, TRUE); + } + + if (level == 0 || numChildren > 0) + { + fprintf(stderr, " "); + + for (j = 0; j < level; j++) + { + fprintf(stderr, " "); + } + + fprintf(stderr, "%d child%s%s\n", numChildren, (numChildren == 1) ? "" : + "ren", (numChildren == 1) ? ":" : "."); + } + + for (i = (int) numChildren - 1; i >= 0; i--) + { + fprintf(stderr, " "); + + for (j = 0; j < level; j++) + { + fprintf(stderr, " "); + } + + nxagentRemoteWindowID(childList[i], TRUE); + + nxagentRemoteWindowInfo(childList[i], (level * 5) + 6, TRUE); + + nxagentRemoteWindowsTree(childList[i], level + 1); + } + + if (childList) + { + XFree((char *) childList); + } +} + +/* + * Print info about internal window. + */ + +void nxagentInternalWindowInfo(WindowPtr pWin, int indent, Bool newLine) +{ + int i; + int result; + unsigned long ulReturnItems; + unsigned long ulReturnBytesLeft; + Atom atomReturnType; + int iReturnFormat; + unsigned char *pszReturnData = NULL; + + fprintf(stderr, "Window ID=[0x%lx] Remote ID=[0x%lx] ", pWin -> drawable.id, + nxagentWindow(pWin)); + + result = GetWindowProperty(pWin, MakeAtom("WM_NAME", 7, False) , 0, + sizeof(CARD32), False, AnyPropertyType, + &atomReturnType, &iReturnFormat, + &ulReturnItems, &ulReturnBytesLeft, + &pszReturnData); + + fprintf(stderr, "Name: "); + + if (result == Success && pszReturnData != NULL) + { + pszReturnData[ulReturnItems] = '\0'; + + fprintf(stderr, "\"%s\"\n", (char *) pszReturnData); + } + else + { + fprintf(stderr, "%s\n", "( has no name )"); + } + + for (i = 0; i < indent; i++) + { + fprintf(stderr, " "); + } + + fprintf(stderr, "x=%d y=%d width=%d height=%d class=%s map_state=%s " + "override_redirect=%s", pWin -> drawable.x, pWin -> drawable.y, + pWin -> drawable.width, pWin -> drawable.height, + (pWin -> drawable.class == 0) ? "InputOutput" : + "InputOnly", (pWin -> mapped == 0) ? + "IsUnmapped" : (pWin -> mapped == 1 ? + "IsUnviewable" : "IsViewable"), + (pWin -> overrideRedirect == 0) ? + "No" : "Yes"); + + if (newLine == TRUE) + { + fprintf(stderr, "\n"); + } +} + +/* + * Walk internal windows tree. + */ + +void nxagentInternalWindowsTree(WindowPtr pWin, int indent) +{ + WindowPtr pChild; + int i; + + while (pWin) + { + pChild = pWin -> firstChild; + + for (i = 0; i < indent; i++) + { + fprintf(stderr, " "); + } + + nxagentInternalWindowInfo(pWin, indent, TRUE); + + fprintf(stderr, "\n"); + + nxagentInternalWindowsTree(pChild, indent + 4); + + pWin = pWin -> nextSib; + } +} + +#endif /* DEBUG_TREE */ + void nxagentSwitchResizeMode(ScreenPtr pScreen) { XSizeHints sizeHints; @@ -290,8 +578,11 @@ void nxagentSwitchResizeMode(ScreenPtr pScreen) nxagentLaunchDialog(DIALOG_DISABLE_DESKTOP_RESIZE_MODE); - sizeHints.max_width = nxagentOption(RootWidth); - sizeHints.max_height = nxagentOption(RootHeight); + if (nxagentOption(Fullscreen) == 0) + { + sizeHints.max_width = nxagentOption(RootWidth); + sizeHints.max_height = nxagentOption(RootHeight); + } } else { @@ -299,8 +590,6 @@ void nxagentSwitchResizeMode(ScreenPtr pScreen) nxagentLaunchDialog(DIALOG_ENABLE_DESKTOP_RESIZE_MODE); - nxagentRRSetScreenConfig(pScreen, nxagentOption(Width), nxagentOption(Height)); - if (nxagentOption(ClientOs) == ClientOsWinnt) { NXSetExposeParameters(nxagentDisplay, 0, 0, 0); @@ -655,6 +944,22 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) { break; } + + #ifdef DEBUG_TREE + + case doDebugTree: + { + fprintf(stderr, "\n ========== nxagentRemoteWindowsTree ==========\n"); + nxagentRemoteWindowsTree(nxagentWindow(WindowTable[0]), 0); + + fprintf(stderr, "\n========== nxagentInternalWindowsTree ==========\n"); + nxagentInternalWindowsTree(WindowTable[0], 0); + + break; + } + + #endif /* DEBUG_TREE */ + case doCloseSession: { closeSession = TRUE; @@ -797,7 +1102,8 @@ FIXME: Don't enqueue the KeyRelease event if the key was enqueued and to remove the KeyPress afterwards. */ - if (inputInfo.keyboard -> key -> down[X.xkey.keycode >> 3] & (1 << (X.xkey.keycode & 7))) + if (BitIsOn(inputInfo.keyboard -> key -> down, + nxagentConvertKeycode(X.xkey.keycode))) { sendKey = 1; } @@ -871,6 +1177,23 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentInputEvent = 1; + if (nxagentOption(ClientOs) == ClientOsMac && (X.xbutton.state & ControlMask) == ControlMask) + { + x.u.u.type = ButtonPress; + x.u.u.detail = inputInfo.pointer -> button -> map[3]; + x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); + + mieqEnqueue(&x); + + x.u.u.type = ButtonRelease; + x.u.u.detail = inputInfo.pointer -> button -> map[3]; + x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); + + mieqEnqueue(&x); + + break; + } + if (nxagentOption(Fullscreen)) { if (nxagentMagicPixelZone(X.xbutton.x, X.xbutton.y)) @@ -917,7 +1240,7 @@ FIXME: Don't enqueue the KeyRelease event if the key was X.xbutton.subwindow == None)) { x.u.u.type = ButtonPress; - x.u.u.detail = X.xbutton.button; + x.u.u.detail = inputInfo.pointer -> button -> map[nxagentReversePointerMap[X.xbutton.button - 1]]; x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); if (nxagentOption(Rootless)) @@ -974,6 +1297,11 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentInputEvent = 1; + if (nxagentOption(ClientOs) == ClientOsMac && (X.xbutton.state & ControlMask) == ControlMask) + { + break; + } + if (viewportCursor) { /* @@ -990,7 +1318,7 @@ FIXME: Don't enqueue the KeyRelease event if the key was if (minimize != True) { x.u.u.type = ButtonRelease; - x.u.u.detail = X.xbutton.button; + x.u.u.detail = inputInfo.pointer -> button -> map[nxagentReversePointerMap[X.xbutton.button - 1]]; x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); if (nxagentOption(Rootless)) @@ -1344,10 +1672,11 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentScreenTrap = 0; } - if (nxagentOption(Fullscreen)) + if (nxagentOption(Fullscreen) == 1) { - if (X.xcrossing.window == nxagentFullscreenWindow && - X.xcrossing.detail != NotifyInferior) + if (X.xcrossing.window == nxagentDefaultWindows[0] && + X.xcrossing.detail != NotifyInferior && + X.xcrossing.mode == NotifyNormal) { nxagentGrabPointerAndKeyboard(&X); } @@ -1399,9 +1728,9 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentLastEnteredWindow = NULL; } - if (nxagentOption(Fullscreen)) + if (nxagentPointerAndKeyboardGrabbed == 1) { - if (X.xcrossing.window == nxagentFullscreenWindow && + if (X.xcrossing.window == nxagentDefaultWindows[0] && X.xcrossing.detail != NotifyInferior && X.xcrossing.mode == NotifyNormal) { @@ -1660,7 +1989,7 @@ FIXME: Don't enqueue the KeyRelease event if the key was } if (nxagentUseNXTrans == 1 && nxagentOption(Rootless) == 0 && - nxagentOption(Nested) == 0 && X.xmap.window != nxagentIconWindow) + nxagentOption(Nested) == 0) { nxagentVisibility = VisibilityFullyObscured; } @@ -1701,12 +2030,6 @@ FIXME: Don't enqueue the KeyRelease event if the key was if (nxagentOption(Fullscreen) == 1) { - if (X.xmap.window == nxagentIconWindow) - { - pScreen = nxagentScreen(X.xmap.window); - nxagentMaximizeToFullScreen(pScreen); - } - nxagentVisibility = VisibilityUnobscured; nxagentVisibilityStop = False; nxagentVisibilityTimeout = GetTimeInMillis() + 2000; @@ -1716,10 +2039,17 @@ FIXME: Don't enqueue the KeyRelease event if the key was } case MappingNotify: { + XMappingEvent *mappingEvent = (XMappingEvent *) &X; + #ifdef DEBUG fprintf(stderr, "nxagentDispatchEvents: WARNING! Going to handle new MappingNotify event.\n"); #endif + if (mappingEvent -> request == MappingPointer) + { + nxagentInitPointerMap(); + } + break; } default: @@ -1959,8 +2289,16 @@ int nxagentHandleKeyPress(XEvent *X, enum HandleEventResult *result) return 1; } - nxagentLastEventTime = nxagentLastKeyPressTime = GetTimeInMillis(); + if (X -> xkey.keycode == 66) + { + nxagentXkbState.Caps = (~nxagentXkbState.Caps & 1); + } + else if (X -> xkey.keycode == 77) + { + nxagentXkbState.Num = (~nxagentXkbState.Num & 1); + } + nxagentLastEventTime = nxagentLastKeyPressTime = GetTimeInMillis(); x.u.u.type = KeyPress; x.u.u.detail = nxagentConvertKeycode(X -> xkey.keycode); @@ -2270,7 +2608,6 @@ int nxagentHandleGraphicsExposeEvent(XEvent *X) int nxagentHandleClientMessageEvent(XEvent *X, enum HandleEventResult *result) { - ScreenPtr pScreen; WindowPtr pWin; xEvent x; @@ -2386,19 +2723,8 @@ int nxagentHandleClientMessageEvent(XEvent *X, enum HandleEventResult *result) fprintf(stderr, "Events: WM_DELETE_WINDOW arrived Atom = %ld.\n", wmAtom); #endif - if (X -> xclient.window == nxagentIconWindow) - { - pScreen = nxagentScreen(X -> xmap.window); - - XMapRaised(nxagentDisplay, nxagentFullscreenWindow); - - XIconifyWindow(nxagentDisplay, nxagentIconWindow, - DefaultScreen(nxagentDisplay)); - - } - - if (X -> xclient.window == (nxagentOption(Fullscreen) ? - nxagentIconWindow : nxagentDefaultWindows[0])) + if (X -> xclient.window == nxagentDefaultWindows[0] || + nxagentWMIsRunning == 0) { *result = doCloseSession; } @@ -2995,85 +3321,110 @@ int nxagentHandleConfigureNotify(XEvent* X) if (X -> xconfigure.window == nxagentDefaultWindows[pScreen -> myNum]) { - if (nxagentOption(Fullscreen) == 0) + if (nxagentOption(DesktopResize) == 1) { - if (nxagentOption(DesktopResize) == 1) + if (nxagentOption(Width) != X -> xconfigure.width || + nxagentOption(Height) != X -> xconfigure.height) { - if (nxagentOption(Width) != X -> xconfigure.width || - nxagentOption(Height) != X -> xconfigure.height) - { - Bool newEvents = False; + Bool newEvents = False; - doRandR = True; + doRandR = True; - NXFlushDisplay(nxagentDisplay, NXFlushLink); + NXFlushDisplay(nxagentDisplay, NXFlushLink); - do - { - newEvents = False; + do + { + newEvents = False; - timeout.tv_sec = 0; - timeout.tv_usec = 500 * 1000; + timeout.tv_sec = 0; + timeout.tv_usec = 500 * 1000; - nxagentWaitEvents(nxagentDisplay, &timeout); + nxagentWaitEvents(nxagentDisplay, &timeout); - /* - * This should also flush - * the NX link for us. - */ + /* + * This should also flush + * the NX link for us. + */ - XSync(nxagentDisplay, 0); + XSync(nxagentDisplay, 0); - while (XCheckTypedWindowEvent(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], - ConfigureNotify, X)) - { - newEvents = True; - } + while (XCheckTypedWindowEvent(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], + ConfigureNotify, X)) + { + newEvents = True; + } - } while (newEvents); - } + } while (newEvents); } + } - if (nxagentWMIsRunning == 0 || X -> xconfigure.send_event) - { - nxagentChangeOption(X, X -> xconfigure.x); - nxagentChangeOption(Y, X -> xconfigure.y); - } + if (nxagentWMIsRunning == 0 || X -> xconfigure.send_event) + { + nxagentChangeOption(X, X -> xconfigure.x); + nxagentChangeOption(Y, X -> xconfigure.y); + } - if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1 && - (nxagentOption(Width) != X -> xconfigure.width || - nxagentOption(Height) != X -> xconfigure.height)) - { - nxagentShadowResize = 1; - } + if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1 && + (nxagentOption(Width) != X -> xconfigure.width || + nxagentOption(Height) != X -> xconfigure.height)) + { + nxagentShadowResize = 1; + } - nxagentChangeOption(Width, X -> xconfigure.width); - nxagentChangeOption(Height, X -> xconfigure.height); + nxagentChangeOption(Width, X -> xconfigure.width); + nxagentChangeOption(Height, X -> xconfigure.height); - nxagentChangeOption(ViewportXSpan, (int) X -> xconfigure.width - - (int) nxagentOption(RootWidth)); - nxagentChangeOption(ViewportYSpan, (int) X -> xconfigure.height - - (int) nxagentOption(RootHeight)); + nxagentChangeOption(ViewportXSpan, (int) X -> xconfigure.width - + (int) nxagentOption(RootWidth)); + nxagentChangeOption(ViewportYSpan, (int) X -> xconfigure.height - + (int) nxagentOption(RootHeight)); - nxagentMoveViewport(pScreen, 0, 0); + nxagentMoveViewport(pScreen, 0, 0); - if (nxagentOption(Shadow) == 1 || - (nxagentOption(Width) == nxagentOption(RootWidth) && - nxagentOption(Height) == nxagentOption(RootHeight))) - { - doRandR = 0; - } + if (nxagentOption(Shadow) == 1 || + (nxagentOption(Width) == nxagentOption(RootWidth) && + nxagentOption(Height) == nxagentOption(RootHeight))) + { + doRandR = 0; + } - if (doRandR) - { - #ifdef TEST - fprintf(stderr,"nxagentHandleConfigureNotify: Width %d Height %d.\n", - nxagentOption(Width), nxagentOption(Height)); - #endif + nxagentChangeOption(Width, X -> xconfigure.width); + nxagentChangeOption(Height, X -> xconfigure.height); - nxagentRRSetScreenConfig(screenInfo.screens[DefaultScreen(nxagentDisplay)], - nxagentOption(Width), nxagentOption(Height)); - } + XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, + X -> xconfigure.width, X -> xconfigure.height); + + if (nxagentOption(Fullscreen) == 0) + { + nxagentMoveViewport(pScreen, 0, 0); + } + else + { + nxagentChangeOption(RootX, (nxagentOption(Width) - + nxagentOption(RootWidth)) / 2); + nxagentChangeOption(RootY, (nxagentOption(Height) - + nxagentOption(RootHeight)) / 2); + nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - + nxagentOption(RootWidth)); + nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - + nxagentOption(RootHeight)); + + nxagentUpdateViewportFrame(0, 0, nxagentOption(RootWidth), + nxagentOption(RootHeight)); + + XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), + nxagentOption(RootX), nxagentOption(RootY)); + } + + if (doRandR) + { + #ifdef TEST + fprintf(stderr,"nxagentHandleConfigureNotify: Width %d Height %d.\n", + nxagentOption(Width), nxagentOption(Height)); + #endif + + nxagentRRSetScreenConfig(screenInfo.screens[DefaultScreen(nxagentDisplay)], + nxagentOption(Width), nxagentOption(Height)); } return 1; @@ -3085,8 +3436,6 @@ int nxagentHandleConfigureNotify(XEvent* X) int nxagentHandleReparentNotify(XEvent* X) { - ScreenPtr pScreen = nxagentScreen(X -> xreparent.window); - #ifdef TEST fprintf(stderr, "nxagentHandleReparentNotify: Going to handle a new reparent event.\n"); #endif @@ -3203,7 +3552,6 @@ int nxagentHandleReparentNotify(XEvent* X) XlibWindow *childrenReturn = NULL; unsigned int nchildrenReturn = 0; Status result; - XSizeHints hints; XWindowAttributes attributes; int x, y; int xParent, yParent; @@ -3464,6 +3812,15 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, True, GrabModeAsync, GrabModeAsync, now); + /* + * The smart scheduler could be stopped while + * waiting for the reply. In this case we need + * to yield explicitly to avoid to be stuck in + * the dispatch loop forever. + */ + + isItTimeToYield = 1; + #ifdef TEST fprintf(stderr, "nxagentGrabPointerAndKeyboard: Going to grab the pointer in context [B2].\n"); #endif @@ -3491,6 +3848,8 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) XSetInputFocus(nxagentDisplay, nxagentFullscreenWindow, RevertToParent, now); } + + nxagentPointerAndKeyboardGrabbed = 1; } void nxagentUngrabPointerAndKeyboard(XEvent *X) @@ -3522,6 +3881,8 @@ void nxagentUngrabPointerAndKeyboard(XEvent *X) #endif XUngrabPointer(nxagentDisplay, now); + + nxagentPointerAndKeyboardGrabbed = 0; } void nxagentDeactivatePointerGrab() diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.h b/nx-X11/programs/Xserver/hw/nxagent/Events.h index 238a229f9..109475c16 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.h @@ -29,6 +29,7 @@ enum HandleEventResult { doNothing = 0, doMinimize, + doDebugTree, doCloseSession, doStartKbd, doSwitchFullscreen, diff --git a/nx-X11/programs/Xserver/hw/nxagent/Imakefile b/nx-X11/programs/Xserver/hw/nxagent/Imakefile index 633e17a22..51173e410 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Imakefile +++ b/nx-X11/programs/Xserver/hw/nxagent/Imakefile @@ -206,7 +206,8 @@ DEFINES = -g $(OS_DEFINES) $(EXT_DEFINES) $(UPG_DEFINES) \ -DNXAGENT_SPLASH \ -DNXAGENT_ARTSD \ -UNX_DEBUG_INPUT \ - -UPANORAMIX + -UPANORAMIX \ + -UDEBUG_TREE all:: $(OBJS) diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c index a2e4fb06f..de1da8654 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c @@ -92,6 +92,18 @@ int nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) { switch (sym) { + #ifdef DEBUG_TREE + + case XK_q: + case XK_Q: + { + *result = doDebugTree; + + break; + } + + #endif /* DEBUG_TREE */ + case XK_t: case XK_T: { diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h index e046771cc..ea7c375ee 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h @@ -108,6 +108,12 @@ FIXME: The condition checking for the render avoid problems with the render composi- te on XFree86 remote server. */ +/* +FIXME: Changed macro: NXAGENT_SHOULD_DEFER_COMPOSITE + to handle situation, when pSrc -> pDrawable + is NULL. This case happens with gradients + and solid fill. + #define NXAGENT_SHOULD_DEFER_COMPOSITE(pSrc, pMask, pDst) \ ((nxagentRenderVersionMajor == 0 && \ nxagentRenderVersionMinor == 8 && \ @@ -118,6 +124,18 @@ FIXME: The condition checking for the render nxagentOption(DeferLevel) == 1) || \ (nxagentOption(DeferLevel) >= 2 && \ nxagentOption(LinkType) < LINK_TYPE_ADSL)) +*/ +#define NXAGENT_SHOULD_DEFER_COMPOSITE(pSrc, pMask, pDst) \ + ((nxagentRenderVersionMajor == 0 && \ + nxagentRenderVersionMinor == 8 && \ + (pDst) -> pDrawable -> type == DRAWABLE_PIXMAP) || \ + (nxagentOption(DeferLevel) >= 2 && \ + nxagentOption(LinkType) < LINK_TYPE_ADSL) || \ + (nxagentOption(DeferLevel) == 1 && \ + (pDst) -> pDrawable -> type == DRAWABLE_PIXMAP && \ + (((pSrc) -> pDrawable && nxagentDrawableStatus((pSrc) -> pDrawable) == NotSynchronized) || \ + ((pMask) && nxagentDrawableStatus((pMask) -> pDrawable) == NotSynchronized)))) + #define NXAGENT_SHOULD_DEFER_PUTIMAGE(pDrawable) \ (nxagentSplitTrap == 0 && \ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c index 34012d3d5..9c1bfaace 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c @@ -57,6 +57,13 @@ is" without express or implied warranty. #undef TEST #undef DEBUG +/* + * The nxagentReversePointerMap array is used to + * memorize remote display pointer map. + */ + +unsigned char nxagentReversePointerMap[MAXBUTTONS]; + void nxagentChangePointerControl(DeviceIntPtr pDev, PtrCtrl *ctrl) { /* @@ -125,6 +132,8 @@ int nxagentPointerProc(DeviceIntPtr pDev, int onoff) return Success; } + nxagentInitPointerMap(); + nxagentEnablePointerEvents(); break; @@ -155,3 +164,28 @@ int nxagentPointerProc(DeviceIntPtr pDev, int onoff) return Success; } + +void nxagentInitPointerMap(void) +{ + int numButtons; + + int i; + + unsigned char pointerMap[MAXBUTTONS]; + + #ifdef DEBUG + fprintf(stderr, "nxagentInitPointerMap: Going to retrieve the " + "pointer map from remote display.\n"); + #endif + + numButtons = XGetPointerMapping(nxagentDisplay, pointerMap, MAXBUTTONS); + + /* + * Computing revers pointer map. + */ + + for (i = 1; i <= numButtons; i++) + { + nxagentReversePointerMap[pointerMap[i - 1] - 1] = i; + } +} diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h index 0807b08ae..b0bb3f99c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h @@ -38,8 +38,17 @@ is" without express or implied warranty. (ButtonPressMask | ButtonReleaseMask | PointerMotionMask | \ EnterWindowMask | LeaveWindowMask) +/* + * The nxagentReversePointerMap array is used to + * memorize remote display pointer map. + */ + +extern unsigned char nxagentReversePointerMap[MAXBUTTONS]; + void nxagentChangePointerControl(DeviceIntPtr pDev, PtrCtrl *ctrl); int nxagentPointerProc(DeviceIntPtr pDev, int onoff); +void nxagentInitPointerMap(void); + #endif /* __Pointer_H__ */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c index 598ffc188..e63b481b2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c @@ -81,6 +81,8 @@ extern Bool nxagentUninstallFontServerPath(void); extern void nxagentRemoveXConnection(void); +extern void nxagentInitPointerMap(void); + static char *nxagentGetReconnectError(void); void nxagentInitializeRecLossyLevel(void); @@ -584,6 +586,8 @@ Bool nxagentReconnectSession(void) nxagentOldKeyboard = NULL; } + nxagentInitPointerMap(); + nxagentDeactivatePointerGrab(); nxagentWakeupByReconnect(); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.c b/nx-X11/programs/Xserver/hw/nxagent/Render.c index 6bc54c86e..4f0f76474 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.c @@ -147,8 +147,6 @@ void nxagentCursorPostSaveRenderInfo(CursorPtr pCursor, ScreenPtr pScreen, int nxagentCreatePicture(PicturePtr pPicture, Mask mask); -void nxagentDestroyPicture(PicturePtr pPicture); - int nxagentChangePictureClip(PicturePtr pPicture, int clipType, int nRects, xRectangle *rects, int xOrigin, int yOrigin); @@ -1010,12 +1008,15 @@ void nxagentComposite(CARD8 op, PicturePtr pSrc, PicturePtr pMask, PicturePtr pD #ifdef DEBUG - fprintf(stderr, "nxagentComposite: Source Picture [%lu][%p] with drawable [%s%s][%p].\n", - nxagentPicturePriv(pSrc) -> picture, (void *) pSrc, - (pSrc -> pDrawable -> type == DRAWABLE_PIXMAP && - nxagentIsShmPixmap((PixmapPtr) pSrc -> pDrawable)) ? "Shared " : "", - pSrc -> pDrawable -> type == DRAWABLE_PIXMAP ? "Pixmap" : "Window", - (void *) pSrc -> pDrawable); + if (pSrc -> pDrawable != NULL) + { + fprintf(stderr, "nxagentComposite: Source Picture [%lu][%p] with drawable [%s%s][%p].\n", + nxagentPicturePriv(pSrc) -> picture, (void *) pSrc, + (pSrc -> pDrawable -> type == DRAWABLE_PIXMAP && + nxagentIsShmPixmap((PixmapPtr) pSrc -> pDrawable)) ? "Shared " : "", + pSrc -> pDrawable -> type == DRAWABLE_PIXMAP ? "Pixmap" : "Window", + (void *) pSrc -> pDrawable); + } fprintf(stderr, "nxagentComposite: Destination Picture [%lu][%p] with drawable [%s%s][%p].\n", nxagentPicturePriv(pDst) -> picture, (void *) pDst, @@ -1064,16 +1065,19 @@ void nxagentComposite(CARD8 op, PicturePtr pSrc, PicturePtr pMask, PicturePtr pD * the wrong data. */ - nxagentSynchronizeShmPixmap(pSrc -> pDrawable, xSrc, ySrc, width, height); - - if (nxagentDrawableStatus(pSrc -> pDrawable) == NotSynchronized) + if (pSrc -> pDrawable != NULL) { - #ifdef TEST - fprintf(stderr, "nxagentComposite: Synchronizing the source drawable [%p].\n", - (void *) pSrc -> pDrawable); - #endif + nxagentSynchronizeShmPixmap(pSrc -> pDrawable, xSrc, ySrc, width, height); - nxagentSynchronizeDrawable(pSrc -> pDrawable, DO_WAIT, NEVER_BREAK, NULL); + if (nxagentDrawableStatus(pSrc -> pDrawable) == NotSynchronized) + { + #ifdef TEST + fprintf(stderr, "nxagentComposite: Synchronizing the source drawable [%p].\n", + (void *) pSrc -> pDrawable); + #endif + + nxagentSynchronizeDrawable(pSrc -> pDrawable, DO_WAIT, NEVER_BREAK, NULL); + } } if (pDst -> pDrawable != pSrc -> pDrawable) @@ -2811,3 +2815,248 @@ Bool nxagentDisconnectAllPicture() return True; } +void nxagentRenderCreateSolidFill(PicturePtr pPicture, xRenderColor *color) +{ + Picture id; + + if (nxagentRenderEnable == False) + { + return; + } + + #ifdef DEBUG + + fprintf(stderr, "nxagentRenderCreateSolidFill: Got called.\n"); + + if (pPicture == NULL) + { + fprintf(stderr, "nxagentRenderCreateSolidFill: WARNING! pPicture pointer is NULL.\n"); + } + + if (color == NULL) + { + fprintf(stderr, "nxagentRenderCreateSolidFill: WARNING! color pointer is NULL.\n"); + } + + #endif /* #ifdef DEBUG */ + + memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, + sizeof(XRenderPictureAttributes_)); + + id = XRenderCreateSolidFill(nxagentDisplay, (XRenderColor *) color); + + #ifdef DEBUG + XSync(nxagentDisplay, 0); + #endif + + #ifdef TEST + fprintf(stderr, "nxagentRenderCreateSolidFill: Created solid fill xid [%lu].\n", id); + #endif + + nxagentPicturePriv(pPicture) -> picture = id; +} + +void nxagentRenderCreateLinearGradient(PicturePtr pPicture, xPointFixed *p1, + xPointFixed *p2, int nStops, + xFixed *stops, + xRenderColor *colors) +{ + Picture id; + + XLinearGradient linearGradient; + + if (nxagentRenderEnable == False) + { + return; + } + + #ifdef DEBUG + + fprintf(stderr, "nxagentRenderCreateLinearGradient: Got called.\n"); + + if (pPicture == NULL) + { + fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! pPicture pointer is NULL.\n"); + } + + if (p1 == NULL) + { + fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! p1 pointer is NULL.\n"); + } + + if (p2 == NULL) + { + fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! p2 pointer is NULL.\n"); + } + + if (stops == NULL) + { + fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! stops pointer is NULL.\n"); + } + + if (colors == NULL) + { + fprintf(stderr, "nxagentRenderCreateLinearGradient: WARNING! colors pointer is NULL.\n"); + } + + #endif /* #ifdef DEBUG */ + + memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, + sizeof(XRenderPictureAttributes_)); + + linearGradient.p1.x = (XFixed) p1 -> x; + linearGradient.p1.y = (XFixed) p1 -> y; + linearGradient.p2.x = (XFixed) p2 -> x; + linearGradient.p2.y = (XFixed) p2 -> y; + + id = XRenderCreateLinearGradient(nxagentDisplay, &linearGradient, + (XFixed *) stops, + (XRenderColor *) colors, nStops); + + #ifdef DEBUG + XSync(nxagentDisplay, 0); + #endif + + #ifdef TEST + fprintf(stderr, "nxagentRenderCreateLinearGradient: Created linear gradient xid [%lu].\n", id); + #endif + + nxagentPicturePriv(pPicture) -> picture = id; +} + +void nxagentRenderCreateRadialGradient(PicturePtr pPicture, xPointFixed *inner, + xPointFixed *outer, + xFixed innerRadius, + xFixed outerRadius, + int nStops, + xFixed *stops, + xRenderColor *colors) +{ + Picture id; + + XRadialGradient radialGradient; + + if (nxagentRenderEnable == False) + { + return; + } + + #ifdef DEBUG + + fprintf(stderr, "nxagentRenderCreateRadialGradient: Got called.\n"); + + if (pPicture == NULL) + { + fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! pPicture pointer is NULL.\n"); + } + + if (inner == NULL) + { + fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! inner pointer is NULL.\n"); + } + + if (outer == NULL) + { + fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! outer pointer is NULL.\n"); + } + + if (stops == NULL) + { + fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! stops pointer is NULL.\n"); + } + + if (colors == NULL) + { + fprintf(stderr, "nxagentRenderCreateRadialGradient: WARNING! colors pointer is NULL.\n"); + } + + #endif /* #ifdef DEBUG */ + + memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, + sizeof(XRenderPictureAttributes_)); + + radialGradient.inner.x = (XFixed) inner -> x; + radialGradient.inner.y = (XFixed) inner -> y; + radialGradient.inner.radius = (XFixed) innerRadius; + radialGradient.outer.x = (XFixed) outer -> x; + radialGradient.outer.y = (XFixed) outer -> y; + radialGradient.outer.radius = (XFixed) outerRadius; + + id = XRenderCreateRadialGradient(nxagentDisplay, &radialGradient, + (XFixed *) stops, + (XRenderColor *) colors, nStops); + + #ifdef DEBUG + XSync(nxagentDisplay, 0); + #endif + + #ifdef TEST + fprintf(stderr, "nxagentRenderCreateRadialGradient: Created radial gradient xid [%lu].\n", id); + #endif + + nxagentPicturePriv(pPicture) -> picture = id; +} + +void nxagentRenderCreateConicalGradient(PicturePtr pPicture, + xPointFixed *center, + xFixed angle, int nStops, + xFixed *stops, + xRenderColor *colors) +{ + Picture id; + + XConicalGradient conicalGradient; + + if (nxagentRenderEnable == False) + { + return; + } + + #ifdef DEBUG + + fprintf(stderr, "nxagentRenderCreateConicalGradient: Got called.\n"); + + if (pPicture == NULL) + { + fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! pPicture pointer is NULL.\n"); + } + + if (center == NULL) + { + fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! center pointer is NULL.\n"); + } + + if (stops == NULL) + { + fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! stops pointer is NULL.\n"); + } + + if (colors == NULL) + { + fprintf(stderr, "nxagentRenderCreateConicalGradient: WARNING! colors pointer is NULL.\n"); + } + + #endif /* #ifdef DEBUG */ + + memset(&(nxagentPicturePriv(pPicture) -> lastServerValues), 0, + sizeof(XRenderPictureAttributes_)); + + conicalGradient.center.x = (XFixed) center -> x; + conicalGradient.center.y = (XFixed) center -> y; + conicalGradient.angle = (XFixed) angle; + + id = XRenderCreateConicalGradient(nxagentDisplay, &conicalGradient, + (XFixed *) stops, + (XRenderColor *) colors, nStops); + + #ifdef DEBUG + XSync(nxagentDisplay, 0); + #endif + + #ifdef TEST + fprintf(stderr, "nxagentRenderCreateConicalGradient: Created conical gradient xid [%lu].\n", id); + #endif + + nxagentPicturePriv(pPicture) -> picture = id; +} + diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.h b/nx-X11/programs/Xserver/hw/nxagent/Render.h index 81ba3369d..4346a4e1e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.h @@ -105,4 +105,6 @@ void nxagentDisconnectPicture(pointer p0, XID x1, void* p2); void nxagentReconnectGlyphSet(void* p0, XID x1, void *p2); +void nxagentDestroyPicture(PicturePtr pPicture); + #endif /* __Render_H__ */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c index a8ce4c7cd..612e71cf7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c @@ -626,6 +626,7 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) XlibAtom *atoms = malloc(nUnits * sizeof(*atoms)); Atom *input = value; int i; + int j = 0; freeMem = True; export = True; @@ -633,16 +634,40 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) for (i = 0; i < nUnits; i++) { - atoms[i] = nxagentLocalToRemoteAtom(input[i]); - - if (atoms[i] == None) - { - #ifdef WARNING - fprintf(stderr, "nxagentExportProperty: WARNING! Failed to convert local atom %ld [%s].\n", - (long int) input[i], validateString(NameForAtom(input[i]))); - #endif - } + /* + * Exporting the _NET_WM_PING property could + * result in rootless windows being grayed out + * when the compiz window manager is running. + * + * Better solution would probably be to handle + * the communication with the window manager + * instead of just getting rid of the property. + */ + + if (strcmp(NameForAtom(input[i]), "_NET_WM_PING") != 0) + { + atoms[j] = nxagentLocalToRemoteAtom(input[i]); + + if (atoms[j] == None) + { + #ifdef WARNING + fprintf(stderr, "nxagentExportProperty: WARNING! Failed to convert local atom %ld [%s].\n", + (long int) input[i], validateString(NameForAtom(input[i]))); + #endif + } + + j++; + } + #ifdef TEST + else + { + fprintf(stderr, "nxagentExportProperty: WARNING! " + "Not exporting the _NET_WM_PING property.\n"); + } + #endif } + + nUnits = j; } else if (strcmp(typeS, "WINDOW") == 0) { diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.c b/nx-X11/programs/Xserver/hw/nxagent/Screen.c index bdd30afee..3522d7e2e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.c @@ -160,7 +160,6 @@ void nxagentPropagateArtsdProperties(ScreenPtr pScreen, char *port); #endif -Window nxagentIconWindow = None; Window nxagentFullscreenWindow = None; #ifdef VIEWPORT_FRAME @@ -291,33 +290,16 @@ void nxagentSetPixmapFormats(ScreenInfo *screenInfo) void nxagentMinimizeFromFullScreen(ScreenPtr pScreen) { XUnmapWindow(nxagentDisplay, nxagentFullscreenWindow); - - if(nxagentIpaq) - { - XMapWindow(nxagentDisplay, nxagentIconWindow); - XIconifyWindow(nxagentDisplay, nxagentIconWindow, - DefaultScreen(nxagentDisplay)); - } - else - { - XIconifyWindow(nxagentDisplay, nxagentIconWindow, - DefaultScreen(nxagentDisplay)); - } } void nxagentMaximizeToFullScreen(ScreenPtr pScreen) { if(nxagentIpaq) { - XUnmapWindow(nxagentDisplay, nxagentIconWindow); - XMapWindow(nxagentDisplay, nxagentFullscreenWindow); } else { -/* - XUnmapWindow(nxagentDisplay, nxagentIconWindow); -*/ /* FIXME: We'll chech for ReparentNotify and LeaveNotify events after XReparentWindow() in order to avoid the session window is iconified. @@ -352,100 +334,8 @@ FIXME: We'll chech for ReparentNotify and LeaveNotify events after XReparentWind XMapRaised(nxagentDisplay, nxagentFullscreenWindow); - XIconifyWindow(nxagentDisplay, nxagentIconWindow, - DefaultScreen(nxagentDisplay)); - while (XCheckTypedWindowEvent(nxagentDisplay, nxagentFullscreenWindow, LeaveNotify, &e)); -/* - XMapWindow(nxagentDisplay, nxagentIconWindow); -*/ - } -} - -Window nxagentCreateIconWindow() -{ - XSetWindowAttributes attributes; - unsigned long valuemask; - char* window_name; - XTextProperty windowName; - XSizeHints sizeHints; - XWMHints wmHints; - Window w; - Mask mask; - - /* - * Create icon window. - */ - - attributes.override_redirect = False; - attributes.colormap = DefaultColormap(nxagentDisplay, DefaultScreen(nxagentDisplay)); - attributes.background_pixmap = nxagentScreenSaverPixmap; - valuemask = CWOverrideRedirect | CWBackPixmap | CWColormap; - - #ifdef TEST - fprintf(stderr, "nxagentCreateIconWindow: Going to create new icon window.\n"); - #endif - - w = XCreateWindow(nxagentDisplay, DefaultRootWindow(nxagentDisplay), - 0, 0, 1, 1, 0, - DefaultDepth(nxagentDisplay, DefaultScreen(nxagentDisplay)), - InputOutput, - DefaultVisual(nxagentDisplay, DefaultScreen(nxagentDisplay)), - valuemask, &attributes); - - #ifdef TEST - fprintf(stderr, "nxagentCreateIconWindow: Created new icon window with id [%ld].\n", - nxagentIconWindow); - #endif - - /* - * Set hints to the window manager for the icon window. - */ - - window_name = nxagentWindowName; - XStringListToTextProperty(&window_name, 1, &windowName); - sizeHints.flags = PMinSize | PMaxSize; - sizeHints.min_width = sizeHints.max_width = 1; - sizeHints.min_height = sizeHints.max_height = 1; - wmHints.flags = IconPixmapHint | IconMaskHint; - wmHints.initial_state = IconicState; - wmHints.icon_pixmap = nxagentIconPixmap; - - if (useXpmIcon) - { - wmHints.icon_mask = nxagentIconShape; - wmHints.flags = IconPixmapHint | IconMaskHint; } - else - { - wmHints.flags = StateHint | IconPixmapHint; - } - - XSetWMProperties(nxagentDisplay, w, - &windowName, &windowName, - NULL , 0 , &sizeHints, &wmHints, NULL); - - /* - * Enable events from the icon window. - */ - - nxagentGetDefaultEventMask(&mask); - - XSelectInput(nxagentDisplay, w, (mask & ~(KeyPressMask | - KeyReleaseMask)) | StructureNotifyMask); - - /* - * Notify to client if user closes icon window. - */ - - if (nxagentWMIsRunning && !nxagentOption(Rootless)) - { - XlibAtom deleteWMAtom = nxagentAtoms[2]; /* WM_DELETE_WINDOW */ - - XSetWMProtocols(nxagentDisplay, w, &deleteWMAtom, 1); - } - - return w; } Bool nxagentMagicPixelZone(int x, int y) @@ -977,6 +867,8 @@ Bool nxagentOpenScreen(int index, ScreenPtr pScreen, nxagentChangeOption(Fullscreen, False); + nxagentFullscreenWindow = 0; + resetAgentPosition = True; } @@ -1382,8 +1274,6 @@ N/A if (nxagentOption(Fullscreen)) { - attributes.override_redirect = True; - /* * We need to disable the host's screensaver or * it will otherwise grab the screen even if it @@ -1609,8 +1499,7 @@ N/A if (nxagentDoFullGeneration == 1 || nxagentReconnectTrap == 1) { - valuemask = CWBackPixel | CWEventMask | CWColormap | - (nxagentOption(Fullscreen) == 1 ? CWOverrideRedirect : 0); + valuemask = CWBackPixel | CWEventMask | CWColormap; attributes.background_pixel = nxagentBlackPixel; @@ -1620,8 +1509,6 @@ N/A if (nxagentOption(Fullscreen) == 1) { - attributes.override_redirect = True; - if (nxagentReconnectTrap) { /* @@ -1754,7 +1641,7 @@ N/A sizeHints.width = nxagentOption(RootWidth); sizeHints.height = nxagentOption(RootHeight); - if (nxagentOption(DesktopResize) == 1) + if (nxagentOption(DesktopResize) == 1 || nxagentOption(Fullscreen) == 1) { sizeHints.max_width = WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); sizeHints.max_height = HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); @@ -1799,37 +1686,6 @@ N/A XClearWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum]); - if (nxagentOption(Fullscreen)) - { - valuemask = CWBackPixmap | CWColormap | CWOverrideRedirect; - } - else - { - valuemask = CWBackPixmap | CWColormap; - } - - attributes.background_pixmap = nxagentScreenSaverPixmap; - attributes.colormap = DefaultColormap(nxagentDisplay, DefaultScreen(nxagentDisplay)); - - if (nxagentOption(Fullscreen)) - { - attributes.override_redirect = False; - if (nxagentReconnectTrap) - { - XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, True, GrabModeAsync, - GrabModeAsync, CurrentTime); - } - } - - if (nxagentOption(Fullscreen)) - { - nxagentIconWindow = nxagentCreateIconWindow(); - } - else - { - nxagentIconWindow = 0; - } - /* * When we don't have window manager we grab keyboard * to let nxagent get keyboard events. @@ -1880,13 +1736,6 @@ N/A */ XSetWMProtocols(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], &deleteWMatom, 1); - - /* - if (nxagentOption(Fullscreen)) - { - XSetWMProtocols(nxagentDisplay, nxagentIconWindow, &deleteWMatom, 1); - } - */ } else { @@ -2266,13 +2115,10 @@ FIXME: We should try to restore the previously if (nxagentOption(Fullscreen)) { - nxagentChangeOption(Width, WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - nxagentChangeOption(Height, HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - - nxagentChangeOption(RootX, (WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)) - - nxagentOption(RootWidth)) / 2); - nxagentChangeOption(RootY, (HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)) - - nxagentOption(RootHeight)) / 2); + nxagentChangeOption(RootX, (nxagentOption(Width) - + nxagentOption(RootWidth)) / 2); + nxagentChangeOption(RootY, (nxagentOption(Height) - + nxagentOption(RootHeight)) / 2); } else { @@ -2283,62 +2129,6 @@ FIXME: We should try to restore the previously nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - nxagentOption(RootWidth)); nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - nxagentOption(RootHeight)); - /* - * Change agent window size and size hints. - */ - - sizeHints.flags = PPosition | PMinSize | PMaxSize; - sizeHints.x = nxagentOption(X); - sizeHints.y = nxagentOption(Y); - - sizeHints.min_width = MIN_NXAGENT_WIDTH; - sizeHints.min_height = MIN_NXAGENT_HEIGHT; - sizeHints.width = width; - sizeHints.height = height; - - if (nxagentOption(DesktopResize) == 1) - { - sizeHints.max_width = WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); - sizeHints.max_height = HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); - } - else - { - sizeHints.max_width = nxagentOption(RootWidth); - sizeHints.max_height = nxagentOption(RootHeight); - } - - if (nxagentUserGeometry.flag & XValue || nxagentUserGeometry.flag & YValue) - { - sizeHints.flags |= USPosition; - } - - if (nxagentUserGeometry.flag & WidthValue || nxagentUserGeometry.flag & HeightValue) - { - sizeHints.flags |= USSize; - } - - XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], &sizeHints); - - if (nxagentOption(Fullscreen)) - { - XResizeWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], - WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)), - HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - - XResizeWindow(nxagentDisplay, nxagentInputWindows[pScreen -> myNum], - WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)), - HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - } - else - { - XResizeWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], width, height); - - if (nxagentOption(Rootless) == 0) - { - XResizeWindow(nxagentDisplay, nxagentInputWindows[pScreen -> myNum], width, height); - } - } - /* * Set properties for the agent root window. */ @@ -2360,8 +2150,6 @@ FIXME: We should try to restore the previously (*pScreen -> PositionWindow)(WindowTable[pScreen -> myNum], 0, 0); - pRootWinSize = &WindowTable[pScreen -> myNum] -> winSize; - nxagentSetRootClip(pScreen, 1); XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[0]), @@ -2369,6 +2157,12 @@ FIXME: We should try to restore the previously nxagentMoveViewport(pScreen, 0, 0); + /* + * Update pointer bounds. + */ + + ScreenRestructured(pScreen); + #ifdef TEST nxagentPrintAgentGeometry("After Resize Screen", "nxagentResizeScreen:"); #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.h b/nx-X11/programs/Xserver/hw/nxagent/Screen.h index 6ffebe0ea..3bf66b2f5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.h @@ -47,7 +47,6 @@ extern ScreenPtr nxagentDefaultScreen; extern Pixmap nxagentPixmapLogo; -extern Window nxagentIconWindow; extern Window nxagentFullscreenWindow; extern RegionRec nxagentShadowUpdateRegion; @@ -89,8 +88,6 @@ void nxagentSetScreenSaverTime(void); void nxagentMinimizeFromFullScreen(ScreenPtr pScreen); void nxagentMaximizeToFullScreen(ScreenPtr pScreen); -Window nxagentCreateIconWindow(void); - Bool nxagentMagicPixelZone(int x, int y); Bool nxagentResizeScreen(ScreenPtr pScreen, int width, int height, diff --git a/nx-X11/programs/Xserver/hw/nxagent/Window.c b/nx-X11/programs/Xserver/hw/nxagent/Window.c index 449458ade..2403390b8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Window.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Window.c @@ -692,235 +692,87 @@ void nxagentRestackWindow(WindowPtr pWin, WindowPtr pOldNextSib) void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn) { - Window w; - XSetWindowAttributes attributes; - unsigned long valuemask; + XEvent e; + XSizeHints sizeHints; - if (nxagentOption(Rootless)) + if (nxagentOption(Rootless) == 1) { return; } - if (!switchOn) + if (switchOn == 0) { nxagentWMDetect(); - if (!nxagentWMIsRunning) - { - #ifdef WARNING - fprintf(stderr, "Warning: Can't switch to window mode, no window manager has been detected.\n"); - #endif - - return; - } - } - - w = nxagentDefaultWindows[pScreen -> myNum]; - attributes.override_redirect = switchOn; - valuemask = CWOverrideRedirect; - XUnmapWindow(nxagentDisplay, w); - XChangeWindowAttributes(nxagentDisplay, w, valuemask, &attributes); - - if (switchOn) - { - /* - * Change to fullscreen mode. - */ - - struct timeval timeout; - int i; - XEvent e; - /* - * Wait for window manager reparenting the default window. + * The smart scheduler could be stopped while + * waiting for the reply. In this case we need + * to yield explicitly to avoid to be stuck in + * the dispatch loop forever. */ - for (i = 0; i < 100 && nxagentWMIsRunning; i++) - { - #ifdef TEST - fprintf(stderr, "nxagentSwitchFullscreen: WARNING! Going to wait for the ReparentNotify event.\n"); - #endif - - if (XCheckTypedWindowEvent(nxagentDisplay, w, ReparentNotify, &e)) - { - break; - } - - /* - * This should also flush - * the NX link for us. - */ - - XSync(nxagentDisplay, 0); - - timeout.tv_sec = 0; - timeout.tv_usec = 50 * 1000; - - nxagentWaitEvents(nxagentDisplay, &timeout); - } - - if (i < 100) - { - /* - * The window manager has done with the reparent - * operation. We can resize and map the window. - */ - - nxagentChangeOption(Fullscreen, True); - - /* - * Save the window-mode configuration. - */ - - nxagentChangeOption(SavedX, nxagentOption(X)); - nxagentChangeOption(SavedY, nxagentOption(Y)); - nxagentChangeOption(SavedWidth, nxagentOption(Width)); - nxagentChangeOption(SavedHeight, nxagentOption(Height)); - nxagentChangeOption(SavedRootWidth, nxagentOption(RootWidth)); - nxagentChangeOption(SavedRootHeight, nxagentOption(RootHeight)); - - /* - * Reconf the Default window. - */ - - nxagentChangeOption(X, 0); - nxagentChangeOption(Y, 0); - nxagentChangeOption(Width, WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - nxagentChangeOption(Height, HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - - /* - * Move the root window. - */ - - nxagentChangeOption(RootX, (nxagentOption(Width) - nxagentOption(RootWidth)) / 2); - nxagentChangeOption(RootY, (nxagentOption(Height) - nxagentOption(RootHeight)) / 2); - nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - nxagentOption(RootWidth)); - nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - nxagentOption(RootHeight)); - - XMoveResizeWindow(nxagentDisplay, w, nxagentOption(X), nxagentOption(Y), - nxagentOption(Width), nxagentOption(Height)); - - nxagentUpdateViewportFrame(0, 0, nxagentOption(RootWidth), nxagentOption(RootHeight)); - - XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), - nxagentOption(RootX), nxagentOption(RootY)); - - /* - * We disable the screensaver when changing - * mode to fullscreen. Is it really needed? - */ - - XSetScreenSaver(nxagentDisplay, 0, 0, DefaultExposures, DefaultBlanking); + isItTimeToYield = 1; - if (nxagentIconWindow == None) - { - nxagentIconWindow = nxagentCreateIconWindow(); - - XMapWindow(nxagentDisplay, nxagentIconWindow); - } - - XMapRaised(nxagentDisplay, w); - XSetInputFocus(nxagentDisplay, w, RevertToParent, CurrentTime); - XCheckTypedWindowEvent(nxagentDisplay, w, LeaveNotify, &e); - nxagentFullscreenWindow = w; - - if (nxagentOption(DesktopResize) == 1) - { - if (nxagentOption(Shadow) == 0) - { - nxagentRRSetScreenConfig(pScreen, WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)), - HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); - } - else - { - nxagentShadowAdaptToRatio(); - } - } - } - else + if (nxagentWMIsRunning == 0) { - /* - * We have waited for a reparent event unsuccessfully. - * Something happened to the window manager. - */ - #ifdef WARNING - fprintf(stderr, "nxagentSwitchFullscreen: WARNING! Expected ReparentNotify event missing.\n"); + fprintf(stderr, "Warning: Can't switch to window mode, no window manager " + "has been detected.\n"); #endif - nxagentWMIsRunning = False; - attributes.override_redirect = False; - XChangeWindowAttributes(nxagentDisplay, w, valuemask, &attributes); - XMapWindow(nxagentDisplay, w); + return; } } - else - { - /* - * FIXME: - * It could be necessary: - * - To restore screensaver. - * - To set or reset nxagentForceBackingStore flag. - * - To grab keyboard. - * - To propagate device settings to the X server if no WM is running. - */ - - /* - * Change to windowed mode. - */ - nxagentChangeOption(Fullscreen, False); - XDestroyWindow(nxagentDisplay, nxagentIconWindow); - nxagentIconWindow = nxagentFullscreenWindow = None; + #ifdef TEST + fprintf(stderr, "nxagentSwitchFullscreen: Switching to %s mode.\n", + switchOn ? "fullscreen" : "windowed"); + #endif - if (nxagentOption(DesktopResize) == 1) - { - nxagentChangeOption(RootWidth, nxagentOption(SavedRootWidth)); - nxagentChangeOption(RootHeight, nxagentOption(SavedRootHeight)); + nxagentChangeOption(Fullscreen, switchOn); - if (nxagentOption(Shadow) == 0) - { - nxagentRRSetScreenConfig(pScreen, nxagentOption(RootWidth), nxagentOption(RootHeight)); - } - } + if (nxagentOption(DesktopResize) == 1) + { + sizeHints.flags = PSize; - if (nxagentOption(WMBorderWidth) > 0 && nxagentOption(WMTitleHeight) > 0) + if (switchOn == 1) { - nxagentChangeOption(X, nxagentOption(SavedX) - - nxagentOption(WMBorderWidth)); - nxagentChangeOption(Y, nxagentOption(SavedY) - - nxagentOption(WMTitleHeight)); + sizeHints.width = + WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); + sizeHints.height = + HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); } else { - nxagentChangeOption(X, nxagentOption(SavedX)); - nxagentChangeOption(Y, nxagentOption(SavedY)); + sizeHints.width = nxagentOption(RootWidth); + sizeHints.height = nxagentOption(RootHeight); } - nxagentChangeOption(Width, nxagentOption(SavedWidth)); - nxagentChangeOption(Height, nxagentOption(SavedHeight)); - - if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1) - { - nxagentShadowAdaptToRatio(); - } + XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], + &sizeHints); + } - XMoveResizeWindow(nxagentDisplay, w, nxagentOption(X), nxagentOption(Y), - nxagentOption(Width), nxagentOption(Height)); + memset(&e, 0, sizeof(e)); - nxagentUpdateViewportFrame(0, 0, nxagentOption(Width), nxagentOption(Height)); + e.xclient.type = ClientMessage; + e.xclient.message_type = nxagentAtoms[13]; /* _NET_WM_STATE */ + e.xclient.display = nxagentDisplay; + e.xclient.window = nxagentDefaultWindows[pScreen -> myNum]; + e.xclient.format = 32; + e.xclient.data.l[0] = nxagentOption(Fullscreen) ? 1 : 0; + e.xclient.data.l[1] = nxagentAtoms[14]; /* _NET_WM_STATE_FULLSCREEN */ - XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), 0, 0); - XMapWindow(nxagentDisplay, w); + XSendEvent(nxagentDisplay, DefaultRootWindow(nxagentDisplay), False, + SubstructureRedirectMask, &e); - nxagentChangeOption(RootX, 0); - nxagentChangeOption(RootY, 0); + if (switchOn == 1) + { + nxagentFullscreenWindow = nxagentDefaultWindows[pScreen -> myNum]; } - - XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, - nxagentOption(Width), nxagentOption(Height)); - - nxagentSetPrintGeometry(pScreen -> myNum); + else + { + nxagentFullscreenWindow = None; + } } #ifdef VIEWPORT_FRAME @@ -2422,6 +2274,11 @@ void nxagentMapDefaultWindows() #endif XMapWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum]); + + if (nxagentOption(Fullscreen) == 1 && nxagentWMIsRunning == 1) + { + nxagentSwitchFullscreen(pScreen, 1); + } } /* @@ -2451,26 +2308,6 @@ void nxagentMapDefaultWindows() nxagentDefaultWindows[i], CurrentTime); } - /* - * Map the icon window. - */ - - if (nxagentIconWindow != 0) - { - #ifdef TEST - fprintf(stderr, "nxagentMapDefaultWindows: Mapping icon window id [%ld].\n", - nxagentIconWindow); - #endif - - XMapWindow(nxagentDisplay, nxagentIconWindow); - - if (nxagentIpaq != 0) - { - XIconifyWindow(nxagentDisplay, nxagentIconWindow, - DefaultScreen(nxagentDisplay)); - } - } - /* * Ensure that the fullscreen window gets the focus. */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c index 18697a576..be961c400 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c @@ -62,6 +62,7 @@ #include "Screen.h" #include "Pixmaps.h" #include "Drawable.h" +#include "Render.h" #define PANIC #define WARNING @@ -1063,7 +1064,47 @@ static void initGradient(SourcePictPtr pGradient, int stopCount, static PicturePtr createSourcePicture(void) { PicturePtr pPicture; - pPicture = (PicturePtr) xalloc(sizeof(PictureRec)); + + extern int nxagentPicturePrivateIndex; + + unsigned int totalPictureSize; + + DevUnion *ppriv; + + char *privPictureRecAddr; + + int i; + + /* + * Compute size of entire PictureRect, plus privates. + */ + + totalPictureSize = sizeof(PictureRec) + + picturePrivateCount * sizeof(DevUnion) + + sizeof(nxagentPrivPictureRec); + + pPicture = (PicturePtr) xalloc(totalPictureSize); + + if (pPicture != NULL) + { + ppriv = (DevUnion *) (pPicture + 1); + + for (i = 0; i < picturePrivateCount; ++i) + { + /* + * Other privates are inaccessible. + */ + + ppriv[i].ptr = NULL; + } + + privPictureRecAddr = (char *) &ppriv[picturePrivateCount]; + + ppriv[nxagentPicturePrivateIndex].ptr = (pointer) privPictureRecAddr; + + pPicture -> devPrivates = ppriv; + } + pPicture->pDrawable = 0; pPicture->pFormat = 0; pPicture->pNext = 0; @@ -1697,6 +1738,10 @@ FreePicture (pointer value, if (--pPicture->refcnt == 0) { +#ifdef NXAGENT_SERVER + nxagentDestroyPicture(pPicture); +#endif + if (pPicture->transform) xfree (pPicture->transform); if (!pPicture->pDrawable) { diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original index 18697a576..be961c400 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original @@ -62,6 +62,7 @@ #include "Screen.h" #include "Pixmaps.h" #include "Drawable.h" +#include "Render.h" #define PANIC #define WARNING @@ -1063,7 +1064,47 @@ static void initGradient(SourcePictPtr pGradient, int stopCount, static PicturePtr createSourcePicture(void) { PicturePtr pPicture; - pPicture = (PicturePtr) xalloc(sizeof(PictureRec)); + + extern int nxagentPicturePrivateIndex; + + unsigned int totalPictureSize; + + DevUnion *ppriv; + + char *privPictureRecAddr; + + int i; + + /* + * Compute size of entire PictureRect, plus privates. + */ + + totalPictureSize = sizeof(PictureRec) + + picturePrivateCount * sizeof(DevUnion) + + sizeof(nxagentPrivPictureRec); + + pPicture = (PicturePtr) xalloc(totalPictureSize); + + if (pPicture != NULL) + { + ppriv = (DevUnion *) (pPicture + 1); + + for (i = 0; i < picturePrivateCount; ++i) + { + /* + * Other privates are inaccessible. + */ + + ppriv[i].ptr = NULL; + } + + privPictureRecAddr = (char *) &ppriv[picturePrivateCount]; + + ppriv[nxagentPicturePrivateIndex].ptr = (pointer) privPictureRecAddr; + + pPicture -> devPrivates = ppriv; + } + pPicture->pDrawable = 0; pPicture->pFormat = 0; pPicture->pNext = 0; @@ -1697,6 +1738,10 @@ FreePicture (pointer value, if (--pPicture->refcnt == 0) { +#ifdef NXAGENT_SERVER + nxagentDestroyPicture(pPicture); +#endif + if (pPicture->transform) xfree (pPicture->transform); if (!pPicture->pDrawable) { diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c index ffc199704..562cd2c66 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c @@ -116,7 +116,6 @@ int nxagentCursorSaveRenderInfo(ScreenPtr, CursorPtr); void nxagentCursorPostSaveRenderInfo(CursorPtr, ScreenPtr, PicturePtr, int, int); int nxagentRenderRealizeCursor(ScreenPtr, CursorPtr); int nxagentCreatePicture(PicturePtr, Mask); -void nxagentDestroyPicture(PicturePtr pPicture); void nxagentChangePicture(PicturePtr, Mask); int nxagentChangePictureClip(PicturePtr, int, int, xRectangle *, int, int); void nxagentComposite(CARD8, PicturePtr, PicturePtr, PicturePtr, INT16, INT16, @@ -132,6 +131,28 @@ void nxagentSetPictureFilter(PicturePtr pPicture, char *filter, int name_size, void nxagentTrapezoids(CARD8 op, PicturePtr pSrc, PicturePtr pDst, PictFormatPtr maskFormat, INT16 xSrc, INT16 ySrc, int ntrap, xTrapezoid *traps); +void nxagentRenderCreateSolidFill(PicturePtr pPicture, xRenderColor *color); + +void nxagentRenderCreateLinearGradient(PicturePtr pPicture, xPointFixed *p1, + xPointFixed *p2, int nStops, + xFixed *stops, + xRenderColor *colors); + +void nxagentRenderCreateRadialGradient(PicturePtr pPicture, xPointFixed *inner, + xPointFixed *outer, + xFixed innerRadius, + xFixed outerRadius, + int nStops, + xFixed *stops, + xRenderColor *colors); + +void nxagentRenderCreateConicalGradient(PicturePtr pPicture, + xPointFixed *center, + xFixed angle, int nStops, + xFixed *stops, + xRenderColor *colors); + + /* * The void pointer is actually a XGlyphElt8. */ @@ -823,8 +844,6 @@ ProcRenderFreePicture (ClientPtr client) VERIFY_PICTURE (pPicture, stuff->picture, client, SecurityDestroyAccess, RenderErrBase + BadPicture); - nxagentDestroyPicture(pPicture); - FreeResource (stuff->picture, RT_NONE); return(client->noClientException); } @@ -926,9 +945,16 @@ ProcRenderComposite (ClientPtr client) RenderErrBase + BadPicture); VERIFY_ALPHA (pMask, stuff->mask, client, SecurityReadAccess, RenderErrBase + BadPicture); +/* +FIXME: Imported change from newest version of Xorg. Changed pSrc to pDst. + if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || (pMask && pMask->pDrawable && pSrc->pDrawable->pScreen != pMask->pDrawable->pScreen)) return BadMatch; +*/ + if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || + (pMask && pMask->pDrawable && pDst->pDrawable->pScreen != pMask->pDrawable->pScreen)) + return BadMatch; ValidatePicture (pSrc); if (pMask) @@ -2336,6 +2362,11 @@ static int ProcRenderCreateSolidFill(ClientPtr client) pPicture = CreateSolidPicture(stuff->pid, &stuff->color, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateSolidFill(pPicture, &stuff -> color); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2367,6 +2398,12 @@ static int ProcRenderCreateLinearGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateLinearGradient(pPicture, &stuff->p1, &stuff->p2, + stuff->nStops, stops, colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2397,6 +2434,14 @@ static int ProcRenderCreateRadialGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateRadialGradient(pPicture, &stuff->inner, &stuff->outer, + stuff->inner_radius, + stuff->outer_radius, + stuff->nStops, stops, colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2426,6 +2471,13 @@ static int ProcRenderCreateConicalGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateConicalGradient(pPicture, &stuff->center, + stuff->angle, stuff->nStops, stops, + colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original index ffc199704..562cd2c66 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original @@ -116,7 +116,6 @@ int nxagentCursorSaveRenderInfo(ScreenPtr, CursorPtr); void nxagentCursorPostSaveRenderInfo(CursorPtr, ScreenPtr, PicturePtr, int, int); int nxagentRenderRealizeCursor(ScreenPtr, CursorPtr); int nxagentCreatePicture(PicturePtr, Mask); -void nxagentDestroyPicture(PicturePtr pPicture); void nxagentChangePicture(PicturePtr, Mask); int nxagentChangePictureClip(PicturePtr, int, int, xRectangle *, int, int); void nxagentComposite(CARD8, PicturePtr, PicturePtr, PicturePtr, INT16, INT16, @@ -132,6 +131,28 @@ void nxagentSetPictureFilter(PicturePtr pPicture, char *filter, int name_size, void nxagentTrapezoids(CARD8 op, PicturePtr pSrc, PicturePtr pDst, PictFormatPtr maskFormat, INT16 xSrc, INT16 ySrc, int ntrap, xTrapezoid *traps); +void nxagentRenderCreateSolidFill(PicturePtr pPicture, xRenderColor *color); + +void nxagentRenderCreateLinearGradient(PicturePtr pPicture, xPointFixed *p1, + xPointFixed *p2, int nStops, + xFixed *stops, + xRenderColor *colors); + +void nxagentRenderCreateRadialGradient(PicturePtr pPicture, xPointFixed *inner, + xPointFixed *outer, + xFixed innerRadius, + xFixed outerRadius, + int nStops, + xFixed *stops, + xRenderColor *colors); + +void nxagentRenderCreateConicalGradient(PicturePtr pPicture, + xPointFixed *center, + xFixed angle, int nStops, + xFixed *stops, + xRenderColor *colors); + + /* * The void pointer is actually a XGlyphElt8. */ @@ -823,8 +844,6 @@ ProcRenderFreePicture (ClientPtr client) VERIFY_PICTURE (pPicture, stuff->picture, client, SecurityDestroyAccess, RenderErrBase + BadPicture); - nxagentDestroyPicture(pPicture); - FreeResource (stuff->picture, RT_NONE); return(client->noClientException); } @@ -926,9 +945,16 @@ ProcRenderComposite (ClientPtr client) RenderErrBase + BadPicture); VERIFY_ALPHA (pMask, stuff->mask, client, SecurityReadAccess, RenderErrBase + BadPicture); +/* +FIXME: Imported change from newest version of Xorg. Changed pSrc to pDst. + if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || (pMask && pMask->pDrawable && pSrc->pDrawable->pScreen != pMask->pDrawable->pScreen)) return BadMatch; +*/ + if ((pSrc->pDrawable && pSrc->pDrawable->pScreen != pDst->pDrawable->pScreen) || + (pMask && pMask->pDrawable && pDst->pDrawable->pScreen != pMask->pDrawable->pScreen)) + return BadMatch; ValidatePicture (pSrc); if (pMask) @@ -2336,6 +2362,11 @@ static int ProcRenderCreateSolidFill(ClientPtr client) pPicture = CreateSolidPicture(stuff->pid, &stuff->color, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateSolidFill(pPicture, &stuff -> color); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2367,6 +2398,12 @@ static int ProcRenderCreateLinearGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateLinearGradient(pPicture, &stuff->p1, &stuff->p2, + stuff->nStops, stops, colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2397,6 +2434,14 @@ static int ProcRenderCreateRadialGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateRadialGradient(pPicture, &stuff->inner, &stuff->outer, + stuff->inner_radius, + stuff->outer_radius, + stuff->nStops, stops, colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; @@ -2426,6 +2471,13 @@ static int ProcRenderCreateConicalGradient (ClientPtr client) stuff->nStops, stops, colors, &error); if (!pPicture) return error; + /* AGENT SERVER */ + + nxagentRenderCreateConicalGradient(pPicture, &stuff->center, + stuff->angle, stuff->nStops, stops, + colors); + + /* AGENT SERVER */ if (!AddResource (stuff->pid, PictureType, (pointer)pPicture)) return BadAlloc; return Success; -- cgit v1.2.3 From 39b738a67a14dde67b2a811d56ac84934fcef52d Mon Sep 17 00:00:00 2001 From: Reinhard Tartler Date: Mon, 10 Oct 2011 17:59:00 +0200 Subject: Imported nxagent-3.5.0-2.tar.gz Summary: Imported nxagent-3.5.0-2.tar.gz Keywords: Imported nxagent-3.5.0-2.tar.gz into Git repository --- nx-X11/programs/Xserver/hw/nxagent/Agent.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Args.c | 15 +- nx-X11/programs/Xserver/hw/nxagent/Args.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Atoms.c | 32 +-- nx-X11/programs/Xserver/hw/nxagent/Atoms.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Binder.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Binder.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/CHANGELOG | 88 ++++++ nx-X11/programs/Xserver/hw/nxagent/Client.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Client.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Clipboard.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Clipboard.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Colormap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Colormap.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Composite.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Composite.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Cursor.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Cursor.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Dialog.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Dialog.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Display.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Display.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Drawable.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Drawable.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Error.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Error.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Events.c | 317 ++++++++++++--------- nx-X11/programs/Xserver/hw/nxagent/Events.h | 3 +- nx-X11/programs/Xserver/hw/nxagent/Extensions.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Extensions.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Font.c | 4 +- nx-X11/programs/Xserver/hw/nxagent/Font.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/GC.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCOps.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCOps.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/GCs.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Handlers.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Handlers.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Holder.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Holder.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Icons.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Image.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Image.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Init.c | 6 +- nx-X11/programs/Xserver/hw/nxagent/Init.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keyboard.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keyboard.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Keystroke.c | 14 +- nx-X11/programs/Xserver/hw/nxagent/Keystroke.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/LICENSE | 2 +- nx-X11/programs/Xserver/hw/nxagent/Literals.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Millis.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Millis.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c | 2 +- .../Xserver/hw/nxagent/NXdispatch.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c | 2 +- .../Xserver/hw/nxagent/NXdixfonts.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXevents.c | 2 +- .../Xserver/hw/nxagent/NXevents.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXextension.c | 2 +- .../Xserver/hw/nxagent/NXextension.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyph.c | 2 +- .../Xserver/hw/nxagent/NXglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c | 2 +- .../Xserver/hw/nxagent/NXglyphcurs.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h | 2 +- .../Xserver/hw/nxagent/NXglyphstr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c | 2 +- .../Xserver/hw/nxagent/NXmiglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXpicture.c | 2 +- .../Xserver/hw/nxagent/NXpicture.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h | 2 +- .../Xserver/hw/nxagent/NXpicturestr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXproperty.c | 2 +- .../Xserver/hw/nxagent/NXproperty.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXrandr.c | 2 +- .../Xserver/hw/nxagent/NXrandr.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXrender.c | 2 +- .../Xserver/hw/nxagent/NXrender.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXwindow.c | 2 +- .../Xserver/hw/nxagent/NXwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Options.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Options.h | 9 +- nx-X11/programs/Xserver/hw/nxagent/Pixels.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pixels.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pixmap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pointer.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Pointer.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Reconnect.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Reconnect.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Render.c | 12 +- nx-X11/programs/Xserver/hw/nxagent/Render.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Rootless.c | 62 +++- nx-X11/programs/Xserver/hw/nxagent/Rootless.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Screen.c | 195 ++++++++++++- nx-X11/programs/Xserver/hw/nxagent/Screen.h | 10 +- nx-X11/programs/Xserver/hw/nxagent/Splash.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Splash.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Split.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Split.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/TestExt.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Trap.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Trap.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Utils.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Visual.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/Visual.h | 2 +- nx-X11/programs/Xserver/hw/nxagent/Window.c | 285 ++++++++++++++++-- nx-X11/programs/Xserver/hw/nxagent/Windows.h | 4 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c | 2 +- .../Xserver/hw/nxagent/X/NXdamage.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c | 2 +- .../Xserver/hw/nxagent/X/NXdispatch.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c | 2 +- .../Xserver/hw/nxagent/X/NXdixfonts.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c | 2 +- .../Xserver/hw/nxagent/X/NXevents.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c | 2 +- .../Xserver/hw/nxagent/X/NXextension.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c | 2 +- .../Xserver/hw/nxagent/X/NXglxext.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c | 2 +- .../Xserver/hw/nxagent/X/NXglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c | 2 +- .../Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h | 2 +- .../Xserver/hw/nxagent/X/NXglyphstr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c | 2 +- .../Xserver/hw/nxagent/X/NXmiexpose.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c | 2 +- .../Xserver/hw/nxagent/X/NXmiglyph.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c | 2 +- .../Xserver/hw/nxagent/X/NXmitrap.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c | 2 +- .../Xserver/hw/nxagent/X/NXmiwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c | 7 +- .../Xserver/hw/nxagent/X/NXpicture.c.NX.original | 7 +- .../programs/Xserver/hw/nxagent/X/NXpicturestr.h | 2 +- .../hw/nxagent/X/NXpicturestr.h.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c | 2 +- .../Xserver/hw/nxagent/X/NXproperty.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c | 2 +- .../Xserver/hw/nxagent/X/NXrandr.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c | 2 +- .../Xserver/hw/nxagent/X/NXrender.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c | 2 +- .../Xserver/hw/nxagent/X/NXresource.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c | 2 +- .../Xserver/hw/nxagent/X/NXshm.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c | 2 +- .../Xserver/hw/nxagent/X/NXwindow.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c | 2 +- .../Xserver/hw/nxagent/X/NXxvdisp.c.NX.original | 2 +- nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm | 2 +- nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm | 2 +- nx-X11/programs/Xserver/hw/nxagent/os2Stub.c | 2 +- nx-X11/programs/Xserver/hw/nxagent/screensaver | 2 +- 160 files changed, 1007 insertions(+), 349 deletions(-) (limited to 'nx-X11/programs/Xserver/hw/nxagent/Render.h') diff --git a/nx-X11/programs/Xserver/hw/nxagent/Agent.h b/nx-X11/programs/Xserver/hw/nxagent/Agent.h index 3f2c93fdb..dbed1e0d8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Agent.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Agent.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.c b/nx-X11/programs/Xserver/hw/nxagent/Args.c index c2e58bd58..8fbb275a6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Args.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Args.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -562,11 +562,15 @@ int ddxProcessArgument(int argc, char *argv[], int i) if (!strcmp(argv[i],"fullscreen")) { nxagentChangeOption(Fullscreen, True); + + nxagentChangeOption(AllScreens, True); } else if (!strcmp(argv[i],"ipaq")) { nxagentChangeOption(Fullscreen, True); + nxagentChangeOption(AllScreens, True); + nxagentIpaq = True; } else @@ -1071,10 +1075,14 @@ static void nxagentParseOptions(char *name, char *value) else if (!strcmp(value, "1")) { nxagentChangeOption(Fullscreen, True); + + nxagentChangeOption(AllScreens, True); } else if (!strcmp(value, "0")) { nxagentChangeOption(Fullscreen, False); + + nxagentChangeOption(AllScreens, False); } else { @@ -1680,6 +1688,11 @@ N/A nxagentChangeOption(Fullscreen, False); } + if (nxagentOption(AllScreens) == UNDEFINED) + { + nxagentChangeOption(AllScreens, False); + } + if (nxagentOption(Binder) == UNDEFINED) { nxagentChangeOption(Binder, False); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.h b/nx-X11/programs/Xserver/hw/nxagent/Args.h index 92650a4a0..9cb97ca03 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Args.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Args.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c index 171df95a9..578731f07 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -66,21 +66,21 @@ Atom nxagentAtoms[NXAGENT_NUMBER_OF_ATOMS]; static char *nxagentAtomNames[NXAGENT_NUMBER_OF_ATOMS + 1] = { - "NX_IDENTITY", /* 0 */ - "WM_PROTOCOLS", /* 1 */ - "WM_DELETE_WINDOW", /* 2 */ - "WM_NX_READY", /* 3 */ - "MCOPGLOBALS", /* 4 */ - "NX_CUT_BUFFER_SERVER", /* 5 */ - "TARGETS", /* 6 */ - "TEXT", /* 7 */ - "NX_AGENT_SIGNATURE", /* 8 */ - "NXDARWIN", /* 9 */ - "CLIPBOARD", /* 10 */ - "TIMESTAMP", /* 11 */ - "UTF8_STRING", /* 12 */ - "_NET_WM_STATE", /* 13 */ - "_NET_WM_STATE_FULLSCREEN", /* 14 */ + "NX_IDENTITY", /* 0 */ + "WM_PROTOCOLS", /* 1 */ + "WM_DELETE_WINDOW", /* 2 */ + "WM_NX_READY", /* 3 */ + "MCOPGLOBALS", /* 4 */ + "NX_CUT_BUFFER_SERVER", /* 5 */ + "TARGETS", /* 6 */ + "TEXT", /* 7 */ + "NX_AGENT_SIGNATURE", /* 8 */ + "NXDARWIN", /* 9 */ + "CLIPBOARD", /* 10 */ + "TIMESTAMP", /* 11 */ + "UTF8_STRING", /* 12 */ + "_NET_WM_STATE", /* 13 */ + "_NET_WM_STATE_FULLSCREEN", /* 14 */ NULL, NULL }; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h index f49f2751e..d5b7fe5aa 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Atoms.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Atoms.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.c b/nx-X11/programs/Xserver/hw/nxagent/Binder.c index 34433bd2b..d40aaebe6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Binder.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Binder.h b/nx-X11/programs/Xserver/hw/nxagent/Binder.h index e0da3e357..f28a82b9f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Binder.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Binder.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG index 7310959ef..5f4b561ca 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG +++ b/nx-X11/programs/Xserver/hw/nxagent/CHANGELOG @@ -1,5 +1,93 @@ ChangeLog: +nxagent-3.5.0-2 + +- Fixed TR0502449. Initialized font server path even if font server + connection fails. + +nxagent-3.5.0-1 + +- Opened the 3.5.0 branch based on nxagent-3.4.0-16. + +- Updated copyright to year 2009. + +- Fixed TR0302438. Added a check in function exporting property in + order to handle the case looking up an atom name returns a null + pointer. + +nxagent-3.4.0-16 + +- Updated copyright to year 2011. + +nxagent-3.4.0-15 + +- Added reference to fixed TR11H02405. + +nxagent-3.4.0-14 + +- Reverted fix for TR03H02335 implemented in nxagent-3.4.0-6. The + emulation of right click by Control key + left click introduces + issues for some applications changing the reaction to the left click + depending on the state of Control key. Issue reported in TR03H02335 + affects Apple laptop touchpads having a single button acting as + left button: on those devices the right button can be emulated by + a double-fingered tap (using two fingertips simultaneously). + +nxagent-3.4.0-13 + +- Fixed TR12H02414. Exported property must be split if ChangeProperty + request exceeds 262140 bytes. + +- Reset AllScreens option at reconnection time if full screen mode + have to be automatically turned off. + +nxagent-3.4.0-12 + +- If one of the two full screen modes is active ('one screen' or 'all + screens') both keystrokes Ctrl-Alt-F and Ctrl-Alt-Shift-F change the + mode back to 'windowed'. + +- Fixed TR11H02405. XRenderFreePicture is called only for pictures + that were actually created on the X server side. + +- Ctrl+Alt+f switch fullscreen to all monitors, while Ctrl+Alt+Shift+f + does it to one monitor only. + +- If the fullscreen option is enabled at the startup, session starts + in the fullscreen mode on all monitors. + +- Added a call to XReparentWindow in the nxagentSwitchAllScreens(). + +- Corrected focus and grab when switching to fullscreen on + all monitors. + +- Removed a compile warning e deleted some unused variables. + +- Removed nxagentPointerAndKeyboardGrabbed variable. + +- Use the override redirect attribute to switch to fullscreen to all + monitors instead of send _NET_WM_FULLSCREEN_MONITORS hint to the WM. + +- Added nxagentMinimizeFromFullScreen(), nxagentMaximizeToFullScreen() + and nxagentCreateIconWindow(). + +- Removed check on EnterNotify to grab the keyboard in fullscreen + mode not only if mode is 'NotifyNormal'. + +nxagent-3.4.0-11 + +- Corrected switching between viewport mode and resize mode. + +- Fixed TR04H02340. Keycode is correctly translated in shadow sessions + also if the remote X display is using evdev. + +nxagent-3.4.0-10 + +- Handled XGrabKeyboard() return value. + +- Fixed TR10D01512. NumLock and CapsLock keys are now synchronized + between local and remote. + nxagent-3.4.0-9 - Fixed TR06H02362. No icon was swown in the task bar. diff --git a/nx-X11/programs/Xserver/hw/nxagent/Client.c b/nx-X11/programs/Xserver/hw/nxagent/Client.c index acfaab7c0..63ed0e134 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Client.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Client.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Client.h b/nx-X11/programs/Xserver/hw/nxagent/Client.h index 45f87fc66..a9b06c845 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Client.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Client.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c index eb830234d..2742e147f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h index 2750ddfd2..43189df81 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Clipboard.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c index 259aa3b24..b0f0507b5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Colormap.h b/nx-X11/programs/Xserver/hw/nxagent/Colormap.h index 8321e8038..b2960590c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Colormap.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Colormap.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Composite.c b/nx-X11/programs/Xserver/hw/nxagent/Composite.c index b0640ff11..c79104fc1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Composite.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Composite.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Composite.h b/nx-X11/programs/Xserver/hw/nxagent/Composite.h index fb1d6d8e9..e875d0051 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Composite.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Composite.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Cursor.c b/nx-X11/programs/Xserver/hw/nxagent/Cursor.c index 141ba3a64..9ed7c233f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Cursor.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Cursor.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Cursor.h b/nx-X11/programs/Xserver/hw/nxagent/Cursor.h index 11e407efd..df7dc44f7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Cursor.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Cursor.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Dialog.c b/nx-X11/programs/Xserver/hw/nxagent/Dialog.c index 2f807b1dc..0fb9491a4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Dialog.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Dialog.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Dialog.h b/nx-X11/programs/Xserver/hw/nxagent/Dialog.h index aa845c7c2..bd12f3097 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Dialog.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Dialog.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.c b/nx-X11/programs/Xserver/hw/nxagent/Display.c index 1a57788e6..87be98116 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Display.h b/nx-X11/programs/Xserver/hw/nxagent/Display.h index 35b7857ad..454150d6e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Display.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Display.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Drawable.c b/nx-X11/programs/Xserver/hw/nxagent/Drawable.c index 75057097a..9c167743f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Drawable.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Drawable.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Drawable.h b/nx-X11/programs/Xserver/hw/nxagent/Drawable.h index 146610efb..c987fa119 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Drawable.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Drawable.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Error.c b/nx-X11/programs/Xserver/hw/nxagent/Error.c index 963cfa287..43bf85900 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Error.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Error.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Error.h b/nx-X11/programs/Xserver/hw/nxagent/Error.h index 2d6083d4e..e55fd71a5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Error.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Error.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.c b/nx-X11/programs/Xserver/hw/nxagent/Events.c index 40b30308c..b9da934d6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -205,8 +205,6 @@ CARD32 nxagentLastEventTime = 0; CARD32 nxagentLastKeyPressTime = 0; Time nxagentLastServerTime = 0; -int nxagentPointerAndKeyboardGrabbed = 0; - /* * Used for storing windows that need to * receive expose events from the agent. @@ -582,6 +580,9 @@ void nxagentSwitchResizeMode(ScreenPtr pScreen) { sizeHints.max_width = nxagentOption(RootWidth); sizeHints.max_height = nxagentOption(RootHeight); + + XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], + &sizeHints); } } else @@ -590,6 +591,9 @@ void nxagentSwitchResizeMode(ScreenPtr pScreen) nxagentLaunchDialog(DIALOG_ENABLE_DESKTOP_RESIZE_MODE); + nxagentRRSetScreenConfig(pScreen, nxagentOption(Width), + nxagentOption(Height)); + if (nxagentOption(ClientOs) == ClientOsWinnt) { NXSetExposeParameters(nxagentDisplay, 0, 0, 0); @@ -597,10 +601,10 @@ void nxagentSwitchResizeMode(ScreenPtr pScreen) sizeHints.max_width = WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); sizeHints.max_height = HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); - } - XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], - &sizeHints); + XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum], + &sizeHints); + } } void nxagentShadowSwitchResizeMode(ScreenPtr pScreen) @@ -800,6 +804,7 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) Bool startKbd = False; Bool closeSession = False; Bool switchFullscreen = False; + Bool switchAllScreens = False; /* * Last entered top level window. @@ -984,6 +989,12 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) break; } + case doSwitchAllScreens: + { + switchAllScreens = TRUE; + + break; + } case doViewportMoveUp: { nxagentMoveViewport(pScreen, 0, -nxagentOption(Height)); @@ -1084,6 +1095,8 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) if (nxagentOption(ViewOnly) == 0 && nxagentOption(Shadow) == 1 && result == doNothing) { + X.xkey.keycode = nxagentConvertKeycode(X.xkey.keycode); + NXShadowEvent(nxagentDisplay, X); } @@ -1094,6 +1107,13 @@ void nxagentDispatchEvents(PredicateFuncPtr predicate) enum HandleEventResult result; int sendKey = 0; +/* +FIXME: If we don't flush the queue here, it could happen + that the inputInfo structure will not be up to date + when we perform the following check on down keys. +*/ + ProcessInputEvents(); + /* FIXME: Don't enqueue the KeyRelease event if the key was not already pressed. This workaround avoids a fake @@ -1101,7 +1121,6 @@ FIXME: Don't enqueue the KeyRelease event if the key was Another solution would be to let the events are enqueued and to remove the KeyPress afterwards. */ - if (BitIsOn(inputInfo.keyboard -> key -> down, nxagentConvertKeycode(X.xkey.keycode))) { @@ -1160,6 +1179,8 @@ FIXME: Don't enqueue the KeyRelease event if the key was if (nxagentOption(ViewOnly) == 0 && nxagentOption(Shadow)) { + X.xkey.keycode = nxagentConvertKeycode(X.xkey.keycode); + NXShadowEvent(nxagentDisplay, X); } } @@ -1177,23 +1198,6 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentInputEvent = 1; - if (nxagentOption(ClientOs) == ClientOsMac && (X.xbutton.state & ControlMask) == ControlMask) - { - x.u.u.type = ButtonPress; - x.u.u.detail = inputInfo.pointer -> button -> map[3]; - x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); - - mieqEnqueue(&x); - - x.u.u.type = ButtonRelease; - x.u.u.detail = inputInfo.pointer -> button -> map[3]; - x.u.keyButtonPointer.time = nxagentLastEventTime = GetTimeInMillis(); - - mieqEnqueue(&x); - - break; - } - if (nxagentOption(Fullscreen)) { if (nxagentMagicPixelZone(X.xbutton.x, X.xbutton.y)) @@ -1297,11 +1301,6 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentInputEvent = 1; - if (nxagentOption(ClientOs) == ClientOsMac && (X.xbutton.state & ControlMask) == ControlMask) - { - break; - } - if (viewportCursor) { /* @@ -1672,14 +1671,11 @@ FIXME: Don't enqueue the KeyRelease event if the key was nxagentScreenTrap = 0; } - if (nxagentOption(Fullscreen) == 1) + if (nxagentOption(Fullscreen) == 1 && + X.xcrossing.window == nxagentFullscreenWindow && + X.xcrossing.detail != NotifyInferior) { - if (X.xcrossing.window == nxagentDefaultWindows[0] && - X.xcrossing.detail != NotifyInferior && - X.xcrossing.mode == NotifyNormal) - { - nxagentGrabPointerAndKeyboard(&X); - } + nxagentGrabPointerAndKeyboard(&X); } if (X.xcrossing.detail != NotifyInferior) @@ -1986,7 +1982,8 @@ FIXME: Don't enqueue the KeyRelease event if the key was } if (nxagentUseNXTrans == 1 && nxagentOption(Rootless) == 0 && - nxagentOption(Nested) == 0) + nxagentOption(Nested) == 0 && + X.xmap.window != nxagentIconWindow) { nxagentVisibility = VisibilityFullyObscured; } @@ -2025,6 +2022,15 @@ FIXME: Don't enqueue the KeyRelease event if the key was } } + if (nxagentOption(AllScreens) == 1) + { + if (X.xmap.window == nxagentIconWindow) + { + pScreen = nxagentScreen(X.xmap.window); + nxagentMaximizeToFullScreen(pScreen); + } + } + if (nxagentOption(Fullscreen) == 1) { nxagentVisibility = VisibilityUnobscured; @@ -2120,14 +2126,40 @@ FIXME: Don't enqueue the KeyRelease event if the key was if (nxagentWMIsRunning) { - XIconifyWindow(nxagentDisplay, nxagentDefaultWindows[0], - DefaultScreen(nxagentDisplay)); + if (nxagentOption(AllScreens)) + { + nxagentMinimizeFromFullScreen(pScreen); + } + else + { + XIconifyWindow(nxagentDisplay, nxagentDefaultWindows[0], + DefaultScreen(nxagentDisplay)); + } } } if (switchFullscreen) { - nxagentSwitchFullscreen(pScreen, !nxagentOption(Fullscreen)); + if (nxagentOption(AllScreens) == 1 && nxagentOption(Fullscreen) == 1) + { + nxagentSwitchAllScreens(pScreen, 0); + } + else + { + nxagentSwitchFullscreen(pScreen, !nxagentOption(Fullscreen)); + } + } + + if (switchAllScreens) + { + if (nxagentOption(AllScreens) == 0 && nxagentOption(Fullscreen) == 1) + { + nxagentSwitchFullscreen(pScreen, 0); + } + else + { + nxagentSwitchAllScreens(pScreen, !nxagentOption(AllScreens)); + } } if (startKbd) @@ -2599,6 +2631,7 @@ int nxagentHandleGraphicsExposeEvent(XEvent *X) int nxagentHandleClientMessageEvent(XEvent *X, enum HandleEventResult *result) { + ScreenPtr pScreen; WindowPtr pWin; xEvent x; @@ -2714,8 +2747,20 @@ int nxagentHandleClientMessageEvent(XEvent *X, enum HandleEventResult *result) fprintf(stderr, "Events: WM_DELETE_WINDOW arrived Atom = %ld.\n", wmAtom); #endif - if (X -> xclient.window == nxagentDefaultWindows[0] || - nxagentWMIsRunning == 0) + if (X -> xclient.window == nxagentIconWindow) + { + pScreen = nxagentScreen(X -> xmap.window); + + XMapRaised(nxagentDisplay, nxagentFullscreenWindow); + + XIconifyWindow(nxagentDisplay, nxagentIconWindow, + DefaultScreen(nxagentDisplay)); + + } + + if (X -> xclient.window == (nxagentOption(Fullscreen) ? + nxagentIconWindow : nxagentDefaultWindows[0]) || + nxagentWMIsRunning == 0) { *result = doCloseSession; } @@ -3312,110 +3357,113 @@ int nxagentHandleConfigureNotify(XEvent* X) if (X -> xconfigure.window == nxagentDefaultWindows[pScreen -> myNum]) { - if (nxagentOption(DesktopResize) == 1) + if (nxagentOption(AllScreens) == 0) { - if (nxagentOption(Width) != X -> xconfigure.width || - nxagentOption(Height) != X -> xconfigure.height) + if (nxagentOption(DesktopResize) == 1) { - Bool newEvents = False; + if (nxagentOption(Width) != X -> xconfigure.width || + nxagentOption(Height) != X -> xconfigure.height) + { + Bool newEvents = False; - doRandR = True; + doRandR = True; - NXFlushDisplay(nxagentDisplay, NXFlushLink); + NXFlushDisplay(nxagentDisplay, NXFlushLink); - do - { - newEvents = False; + do + { + newEvents = False; - timeout.tv_sec = 0; - timeout.tv_usec = 500 * 1000; + timeout.tv_sec = 0; + timeout.tv_usec = 500 * 1000; - nxagentWaitEvents(nxagentDisplay, &timeout); + nxagentWaitEvents(nxagentDisplay, &timeout); - /* - * This should also flush - * the NX link for us. - */ + /* + * This should also flush + * the NX link for us. + */ - XSync(nxagentDisplay, 0); + XSync(nxagentDisplay, 0); - while (XCheckTypedWindowEvent(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], - ConfigureNotify, X)) - { - newEvents = True; - } + while (XCheckTypedWindowEvent(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], + ConfigureNotify, X)) + { + newEvents = True; + } - } while (newEvents); + } while (newEvents); + } } - } - if (nxagentWMIsRunning == 0 || X -> xconfigure.send_event) - { - nxagentChangeOption(X, X -> xconfigure.x); - nxagentChangeOption(Y, X -> xconfigure.y); - } + if (nxagentWMIsRunning == 0 || X -> xconfigure.send_event) + { + nxagentChangeOption(X, X -> xconfigure.x); + nxagentChangeOption(Y, X -> xconfigure.y); + } - if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1 && - (nxagentOption(Width) != X -> xconfigure.width || - nxagentOption(Height) != X -> xconfigure.height)) - { - nxagentShadowResize = 1; - } + if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1 && + (nxagentOption(Width) != X -> xconfigure.width || + nxagentOption(Height) != X -> xconfigure.height)) + { + nxagentShadowResize = 1; + } - nxagentChangeOption(Width, X -> xconfigure.width); - nxagentChangeOption(Height, X -> xconfigure.height); + nxagentChangeOption(Width, X -> xconfigure.width); + nxagentChangeOption(Height, X -> xconfigure.height); - nxagentChangeOption(ViewportXSpan, (int) X -> xconfigure.width - - (int) nxagentOption(RootWidth)); - nxagentChangeOption(ViewportYSpan, (int) X -> xconfigure.height - - (int) nxagentOption(RootHeight)); + nxagentChangeOption(ViewportXSpan, (int) X -> xconfigure.width - + (int) nxagentOption(RootWidth)); + nxagentChangeOption(ViewportYSpan, (int) X -> xconfigure.height - + (int) nxagentOption(RootHeight)); - nxagentMoveViewport(pScreen, 0, 0); + nxagentMoveViewport(pScreen, 0, 0); - if (nxagentOption(Shadow) == 1 || - (nxagentOption(Width) == nxagentOption(RootWidth) && - nxagentOption(Height) == nxagentOption(RootHeight))) - { - doRandR = 0; - } + if (nxagentOption(Shadow) == 1 || + (nxagentOption(Width) == nxagentOption(RootWidth) && + nxagentOption(Height) == nxagentOption(RootHeight))) + { + doRandR = 0; + } - nxagentChangeOption(Width, X -> xconfigure.width); - nxagentChangeOption(Height, X -> xconfigure.height); + nxagentChangeOption(Width, X -> xconfigure.width); + nxagentChangeOption(Height, X -> xconfigure.height); - XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, - X -> xconfigure.width, X -> xconfigure.height); + XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, + X -> xconfigure.width, X -> xconfigure.height); - if (nxagentOption(Fullscreen) == 0) - { - nxagentMoveViewport(pScreen, 0, 0); - } - else - { - nxagentChangeOption(RootX, (nxagentOption(Width) - - nxagentOption(RootWidth)) / 2); - nxagentChangeOption(RootY, (nxagentOption(Height) - - nxagentOption(RootHeight)) / 2); - nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - - nxagentOption(RootWidth)); - nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - - nxagentOption(RootHeight)); - - nxagentUpdateViewportFrame(0, 0, nxagentOption(RootWidth), - nxagentOption(RootHeight)); - - XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), - nxagentOption(RootX), nxagentOption(RootY)); - } + if (nxagentOption(Fullscreen) == 0) + { + nxagentMoveViewport(pScreen, 0, 0); + } + else + { + nxagentChangeOption(RootX, (nxagentOption(Width) - + nxagentOption(RootWidth)) / 2); + nxagentChangeOption(RootY, (nxagentOption(Height) - + nxagentOption(RootHeight)) / 2); + nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - + nxagentOption(RootWidth)); + nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - + nxagentOption(RootHeight)); + + nxagentUpdateViewportFrame(0, 0, nxagentOption(RootWidth), + nxagentOption(RootHeight)); + + XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), + nxagentOption(RootX), nxagentOption(RootY)); + } - if (doRandR) - { - #ifdef TEST - fprintf(stderr,"nxagentHandleConfigureNotify: Width %d Height %d.\n", - nxagentOption(Width), nxagentOption(Height)); - #endif + if (doRandR) + { + #ifdef TEST + fprintf(stderr,"nxagentHandleConfigureNotify: Width %d Height %d.\n", + nxagentOption(Width), nxagentOption(Height)); + #endif - nxagentRRSetScreenConfig(screenInfo.screens[DefaultScreen(nxagentDisplay)], - nxagentOption(Width), nxagentOption(Height)); + nxagentRRSetScreenConfig(screenInfo.screens[DefaultScreen(nxagentDisplay)], + nxagentOption(Width), nxagentOption(Height)); + } } return 1; @@ -3782,10 +3830,7 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) int resource; - if (nxagentPointerAndKeyboardGrabbed == 1) - { - return; - } + int result; #ifdef TEST fprintf(stderr, "nxagentGrabPointerAndKeyboard: Grabbing pointer and keyboard with event at [%p].\n", @@ -3805,8 +3850,13 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) fprintf(stderr, "nxagentGrabPointerAndKeyboard: Going to grab the keyboard in context [B1].\n"); #endif - XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, - True, GrabModeAsync, GrabModeAsync, now); + result = XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, + True, GrabModeAsync, GrabModeAsync, now); + + if (result != GrabSuccess) + { + return; + } /* * The smart scheduler could be stopped while @@ -3844,19 +3894,12 @@ void nxagentGrabPointerAndKeyboard(XEvent *X) XSetInputFocus(nxagentDisplay, nxagentFullscreenWindow, RevertToParent, now); } - - nxagentPointerAndKeyboardGrabbed = 1; } void nxagentUngrabPointerAndKeyboard(XEvent *X) { unsigned long now; - if (nxagentPointerAndKeyboardGrabbed == 0) - { - return; - } - #ifdef TEST fprintf(stderr, "nxagentUngrabPointerAndKeyboard: Ungrabbing pointer and keyboard with event at [%p].\n", (void *) X); @@ -3882,8 +3925,6 @@ void nxagentUngrabPointerAndKeyboard(XEvent *X) #endif XUngrabPointer(nxagentDisplay, now); - - nxagentPointerAndKeyboardGrabbed = 0; } void nxagentDeactivatePointerGrab() diff --git a/nx-X11/programs/Xserver/hw/nxagent/Events.h b/nx-X11/programs/Xserver/hw/nxagent/Events.h index 109475c16..c74fa151f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Events.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Events.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -33,6 +33,7 @@ enum HandleEventResult doCloseSession, doStartKbd, doSwitchFullscreen, + doSwitchAllScreens, doViewportMoveUp, doViewportMoveLeft, doViewportMoveRight, diff --git a/nx-X11/programs/Xserver/hw/nxagent/Extensions.c b/nx-X11/programs/Xserver/hw/nxagent/Extensions.c index e76cbb4ad..aced24ff4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Extensions.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Extensions.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Extensions.h b/nx-X11/programs/Xserver/hw/nxagent/Extensions.h index 620645d00..5335cf87c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Extensions.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Extensions.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Font.c b/nx-X11/programs/Xserver/hw/nxagent/Font.c index 13b819322..178ed3cf7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Font.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Font.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -1269,7 +1269,7 @@ Bool nxagentReconnectFailedFonts(void *p0) const int maxAttempt = 5; char **fontPaths, **localFontPaths, **newFontPaths; - char fontServerPath[256]; + char fontServerPath[256] = ""; int nPaths = 0; Bool repeat = True; diff --git a/nx-X11/programs/Xserver/hw/nxagent/Font.h b/nx-X11/programs/Xserver/hw/nxagent/Font.h index 75ae3f6f5..63cb6aa24 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Font.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Font.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GC.c b/nx-X11/programs/Xserver/hw/nxagent/GC.c index c53e3b9f7..71562d999 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GC.c +++ b/nx-X11/programs/Xserver/hw/nxagent/GC.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCOps.c b/nx-X11/programs/Xserver/hw/nxagent/GCOps.c index 85730797e..e18b034eb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCOps.c +++ b/nx-X11/programs/Xserver/hw/nxagent/GCOps.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCOps.h b/nx-X11/programs/Xserver/hw/nxagent/GCOps.h index 7ae6d9923..fa4967aee 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCOps.h +++ b/nx-X11/programs/Xserver/hw/nxagent/GCOps.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/GCs.h b/nx-X11/programs/Xserver/hw/nxagent/GCs.h index bec290088..f7e13477a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/GCs.h +++ b/nx-X11/programs/Xserver/hw/nxagent/GCs.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Handlers.c b/nx-X11/programs/Xserver/hw/nxagent/Handlers.c index be407f160..310b572cc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Handlers.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Handlers.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Handlers.h b/nx-X11/programs/Xserver/hw/nxagent/Handlers.h index fe8aeef36..3d3b335c0 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Handlers.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Handlers.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Holder.c b/nx-X11/programs/Xserver/hw/nxagent/Holder.c index a9ac77c09..bfd907cde 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Holder.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Holder.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Holder.h b/nx-X11/programs/Xserver/hw/nxagent/Holder.h index 9896aeead..c39b98780 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Holder.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Holder.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Icons.h b/nx-X11/programs/Xserver/hw/nxagent/Icons.h index 4d0e216cd..0601584d4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Icons.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Icons.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Image.c b/nx-X11/programs/Xserver/hw/nxagent/Image.c index e8405ed3a..e499b7a11 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Image.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Image.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Image.h b/nx-X11/programs/Xserver/hw/nxagent/Image.h index 7805b0312..57272ab18 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Image.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Image.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Init.c b/nx-X11/programs/Xserver/hw/nxagent/Init.c index 64b6583bf..4f675a630 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Init.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Init.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -74,7 +74,7 @@ is" without express or implied warranty. #undef DEBUG #undef DUMP -#define NXAGENT_VERSION "3.4.0" +#define NXAGENT_VERSION "3.5.0" /* * ProcVector array defined in tables.c. @@ -193,7 +193,7 @@ void InitOutput(ScreenInfo *screenInfo, int argc, char *argv[]) if (serverGeneration <= 1) { fprintf(stderr, "\nNXAGENT - Version " NXAGENT_VERSION "\n\n"); - fprintf(stderr, "Copyright (C) 2001, 2010 NoMachine.\n"); + fprintf(stderr, "Copyright (C) 2001, 2011 NoMachine.\n"); fprintf(stderr, "See http://www.nomachine.com/ for more information.\n\n"); fprintf(stderr, "Info: Agent running with pid '%d'.\n", getpid()); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Init.h b/nx-X11/programs/Xserver/hw/nxagent/Init.h index 576c1a74d..cf154e86d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Init.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Init.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c index b0aeabeea..8db38892e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h index 1a953358a..0e11a8a13 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Keyboard.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c index de1da8654..6c6e477ab 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -116,7 +116,7 @@ int nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) { if (nxagentOption(Rootless) == False) { - *result = doSwitchFullscreen; + *result = doSwitchAllScreens; } break; @@ -282,6 +282,16 @@ int nxagentCheckSpecialKeystroke(XKeyEvent *X, enum HandleEventResult *result) { switch (sym) { + case XK_f: + case XK_F: + { + if (nxagentOption(Rootless) == 0) + { + *result = doSwitchFullscreen; + } + + break; + } case XK_Left: case XK_KP_Left: { diff --git a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h index e9ca59ff2..ef71a8851 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Keystroke.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/LICENSE b/nx-X11/programs/Xserver/hw/nxagent/LICENSE index 141ca13ea..8446e6f55 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/LICENSE +++ b/nx-X11/programs/Xserver/hw/nxagent/LICENSE @@ -1,4 +1,4 @@ -Copyright (c) 2001, 2010 NoMachine - http://www.nomachine.com/. +Copyright (c) 2001, 2011 NoMachine - http://www.nomachine.com/. NXAGENT and NX extensions to X are copyright of NoMachine. diff --git a/nx-X11/programs/Xserver/hw/nxagent/Literals.h b/nx-X11/programs/Xserver/hw/nxagent/Literals.h index 377dd7e25..aaa3430d6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Literals.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Literals.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Millis.c b/nx-X11/programs/Xserver/hw/nxagent/Millis.c index bde85f090..e9c739eeb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Millis.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Millis.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Millis.h b/nx-X11/programs/Xserver/hw/nxagent/Millis.h index 2125eca3e..69d247bbc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Millis.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Millis.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c index 5106ffa8c..4f59b8098 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original index 5106ffa8c..4f59b8098 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdispatch.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c index 0d8584218..1cccfd972 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original index 0d8584218..1cccfd972 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXdixfonts.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c index cd8ced7a6..f697cf3ca 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original index cd8ced7a6..f697cf3ca 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXevents.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c index 852ad1503..1d86bf870 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original index 852ad1503..1d86bf870 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXextension.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c index 55248195f..22483b3fd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original index 55248195f..22483b3fd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyph.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c index 614d2db39..9212bf438 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original index 614d2db39..9212bf438 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphcurs.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h index 08ffb35b0..0f122be4a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original index 08ffb35b0..0f122be4a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXglyphstr.h.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c index 806cf2900..09901ba9c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original index 806cf2900..09901ba9c 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXmiglyph.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c index a9c501b34..d32cdb6c4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original index a9c501b34..d32cdb6c4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicture.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h index 26a95fe9f..91eab0125 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original index 26a95fe9f..91eab0125 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXpicturestr.h.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c index 14b6136d4..20a6bd6dc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original index 14b6136d4..20a6bd6dc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXproperty.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c index b7039e1e0..d593fa6aa 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original index b7039e1e0..d593fa6aa 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrandr.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c index 0940a3602..43607ac08 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c @@ -31,7 +31,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original index 0940a3602..43607ac08 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXrender.c.NX.original @@ -31,7 +31,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c index 0954cf8ae..95ecde951 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original index 0954cf8ae..95ecde951 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/NXwindow.c.NX.original @@ -6,7 +6,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c index 8d05175ff..37b2c74fd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h index 4e800e96d..160dc6517 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h b/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h index ae3a03d86..97ae77e29 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h +++ b/nx-X11/programs/Xserver/hw/nxagent/NXxrandrint.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Options.c b/nx-X11/programs/Xserver/hw/nxagent/Options.c index 1f04b0daf..5d7855667 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Options.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Options.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Options.h b/nx-X11/programs/Xserver/hw/nxagent/Options.h index 1bc7eaa4c..7850a0586 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Options.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Options.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -102,6 +102,13 @@ typedef struct _AgentOptions int Fullscreen; + /* + * True if the fullscreen NX session will + * extend on all available screens. + */ + + int AllScreens; + /* * Set to the auto-disconnect timeout, if * the user activated this feature. diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixels.c b/nx-X11/programs/Xserver/hw/nxagent/Pixels.c index 10c705dfc..d3ab9dd2f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixels.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixels.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h index ea7c375ee..918d74dc7 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixels.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixels.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c index 1718c7363..ad7e9c313 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixmap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h b/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h index 234650dd4..98d5666d1 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pixmaps.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c index 9c1bfaace..a751974af 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h index b0bb3f99c..3b9ccce15 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Pointer.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Pointer.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c index e63b481b2..b78660240 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h index 12d0742df..c321bfada 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Reconnect.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.c b/nx-X11/programs/Xserver/hw/nxagent/Render.c index 4f0f76474..6c74c147f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -584,16 +584,16 @@ XRenderPictFormat *nxagentMatchingFormats(PictFormatPtr pFormat) void nxagentDestroyPicture(PicturePtr pPicture) { + if (pPicture == NULL || nxagentPicturePriv(pPicture) -> picture == 0) + { + return; + } + #ifdef TEST fprintf(stderr, "nxagentDestroyPicture: Going to destroy picture at [%p].\n", (void *) pPicture); #endif - if (pPicture == NULL) - { - return; - } - XRenderFreePicture(nxagentDisplay, nxagentPicturePriv(pPicture) -> picture); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Render.h b/nx-X11/programs/Xserver/hw/nxagent/Render.h index 4346a4e1e..6f61ca85f 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Render.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Render.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c index 612e71cf7..74d2d1fe5 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Rootless.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Rootless.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -625,6 +625,7 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) { XlibAtom *atoms = malloc(nUnits * sizeof(*atoms)); Atom *input = value; + char *atomName = NULL; int i; int j = 0; @@ -644,7 +645,8 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) * instead of just getting rid of the property. */ - if (strcmp(NameForAtom(input[i]), "_NET_WM_PING") != 0) + if ((atomName = NameForAtom(input[i])) != NULL && + strcmp(atomName, "_NET_WM_PING") != 0) { atoms[j] = nxagentLocalToRemoteAtom(input[i]); @@ -652,7 +654,7 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) { #ifdef WARNING fprintf(stderr, "nxagentExportProperty: WARNING! Failed to convert local atom %ld [%s].\n", - (long int) input[i], validateString(NameForAtom(input[i]))); + (long int) input[i], validateString(atomName)); #endif } @@ -725,7 +727,57 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) } else { - XChangeProperty(nxagentDisplay, nxagentWindow(pWin), propertyX, typeX, format, mode, (void*)output, nUnits); + #ifdef TEST + fprintf(stderr, "nxagentExportProperty: Property [%lu] format [%i] " + "units [%lu].\n", propertyX, format, nUnits); + #endif + + if ((format >> 3) * nUnits + sizeof(xChangePropertyReq) < + (MAX_REQUEST_SIZE << 2)) + { + XChangeProperty(nxagentDisplay, nxagentWindow(pWin), propertyX, typeX, + format, mode, (void*)output, nUnits); + } + else if (mode == PropModeReplace) + { + int n; + char *data; + + XDeleteProperty(nxagentDisplay, nxagentWindow(pWin), propertyX); + + data = (char *) output; + + while (nUnits > 0) + { + if ((format >> 3) * nUnits + sizeof(xChangePropertyReq) < + (MAX_REQUEST_SIZE << 2)) + { + n = nUnits; + } + else + { + n = ((MAX_REQUEST_SIZE << 2) - sizeof(xChangePropertyReq)) / + (format >> 3); + } + + XChangeProperty(nxagentDisplay, nxagentWindow(pWin), propertyX, + typeX, format, PropModeAppend, (void*) data, n); + + nUnits -= n; + + data = (char *) data + n * (format >> 3); + } + } + else + { + #ifdef WARNING + fprintf(stderr, "nxagentExportProperty: WARNING! " + "Property [%lu] too long.\n", propertyX); + #endif + + goto nxagentExportPropertyError; + } + nxagentAddPropertyToList(propertyX, pWin); } } @@ -740,6 +792,8 @@ int nxagentExportProperty(pWin, property, type, format, mode, nUnits, value) #endif } + nxagentExportPropertyError: + if (freeMem) { xfree(output); diff --git a/nx-X11/programs/Xserver/hw/nxagent/Rootless.h b/nx-X11/programs/Xserver/hw/nxagent/Rootless.h index ece4c9d31..1ea258db3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Rootless.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Rootless.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.c b/nx-X11/programs/Xserver/hw/nxagent/Screen.c index 2db7df8fe..0a0d409eb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -160,6 +160,7 @@ void nxagentPropagateArtsdProperties(ScreenPtr pScreen, char *port); #endif +Window nxagentIconWindow = None; Window nxagentFullscreenWindow = None; #ifdef VIEWPORT_FRAME @@ -287,6 +288,166 @@ void nxagentSetPixmapFormats(ScreenInfo *screenInfo) } } +void nxagentMinimizeFromFullScreen(ScreenPtr pScreen) +{ + XUnmapWindow(nxagentDisplay, nxagentFullscreenWindow); + + if (nxagentIpaq) + { + XMapWindow(nxagentDisplay, nxagentIconWindow); + XIconifyWindow(nxagentDisplay, nxagentIconWindow, + DefaultScreen(nxagentDisplay)); + } + else + { + XIconifyWindow(nxagentDisplay, nxagentIconWindow, + DefaultScreen(nxagentDisplay)); + } +} + +void nxagentMaximizeToFullScreen(ScreenPtr pScreen) +{ + if (nxagentIpaq) + { + XUnmapWindow(nxagentDisplay, nxagentIconWindow); + + XMapWindow(nxagentDisplay, nxagentFullscreenWindow); + } + else + { +/* + XUnmapWindow(nxagentDisplay, nxagentIconWindow); +*/ +/* +FIXME: We'll chech for ReparentNotify and LeaveNotify events after XReparentWindow() + in order to avoid the session window is iconified. + We could avoid the sesssion window is iconified when a LeaveNotify event is received, + so this check would be unnecessary. +*/ + struct timeval timeout; + int i; + XEvent e; + + XReparentWindow(nxagentDisplay, nxagentFullscreenWindow, + RootWindow(nxagentDisplay, DefaultScreen(nxagentDisplay)), 0, 0); + + for (i = 0; i < 100 && nxagentWMIsRunning; i++) + { + #ifdef TEST + fprintf(stderr, "nxagentMaximizeToFullscreen: WARNING! Going to wait for the ReparentNotify event.\n"); + #endif + + if (XCheckTypedWindowEvent(nxagentDisplay, nxagentFullscreenWindow, ReparentNotify, &e)) + { + break; + } + + XSync(nxagentDisplay, 0); + + timeout.tv_sec = 0; + timeout.tv_usec = 50 * 1000; + + nxagentWaitEvents(nxagentDisplay, &timeout); + } + + XMapRaised(nxagentDisplay, nxagentFullscreenWindow); + + XIconifyWindow(nxagentDisplay, nxagentIconWindow, + DefaultScreen(nxagentDisplay)); + + while (XCheckTypedWindowEvent(nxagentDisplay, nxagentFullscreenWindow, LeaveNotify, &e)); +/* + XMapWindow(nxagentDisplay, nxagentIconWindow); +*/ + } +} + +Window nxagentCreateIconWindow() +{ + XSetWindowAttributes attributes; + unsigned long valuemask; + char* window_name; + XTextProperty windowName; + XSizeHints sizeHints; + XWMHints wmHints; + Window w; + Mask mask; + + /* + * Create icon window. + */ + + attributes.override_redirect = False; + attributes.colormap = DefaultColormap(nxagentDisplay, DefaultScreen(nxagentDisplay)); + attributes.background_pixmap = nxagentScreenSaverPixmap; + valuemask = CWOverrideRedirect | CWBackPixmap | CWColormap; + + #ifdef TEST + fprintf(stderr, "nxagentCreateIconWindow: Going to create new icon window.\n"); + #endif + + w = XCreateWindow(nxagentDisplay, DefaultRootWindow(nxagentDisplay), + 0, 0, 1, 1, 0, + DefaultDepth(nxagentDisplay, DefaultScreen(nxagentDisplay)), + InputOutput, + DefaultVisual(nxagentDisplay, DefaultScreen(nxagentDisplay)), + valuemask, &attributes); + + #ifdef TEST + fprintf(stderr, "nxagentCreateIconWindow: Created new icon window with id [%ld].\n", + nxagentIconWindow); + #endif + + /* + * Set hints to the window manager for the icon window. + */ + + window_name = nxagentWindowName; + XStringListToTextProperty(&window_name, 1, &windowName); + sizeHints.flags = PMinSize | PMaxSize; + sizeHints.min_width = sizeHints.max_width = 1; + sizeHints.min_height = sizeHints.max_height = 1; + wmHints.flags = IconPixmapHint | IconMaskHint; + wmHints.initial_state = IconicState; + wmHints.icon_pixmap = nxagentIconPixmap; + + if (useXpmIcon) + { + wmHints.icon_mask = nxagentIconShape; + wmHints.flags = IconPixmapHint | IconMaskHint; + } + else + { + wmHints.flags = StateHint | IconPixmapHint; + } + + XSetWMProperties(nxagentDisplay, w, + &windowName, &windowName, + NULL , 0 , &sizeHints, &wmHints, NULL); + + /* + * Enable events from the icon window. + */ + + nxagentGetDefaultEventMask(&mask); + + XSelectInput(nxagentDisplay, w, (mask & ~(KeyPressMask | + KeyReleaseMask)) | StructureNotifyMask); + + /* + * Notify to client if user closes icon window. + */ + + if (nxagentWMIsRunning && !nxagentOption(Rootless)) + { + XlibAtom deleteWMAtom = nxagentAtoms[2]; /* WM_DELETE_WINDOW */ + + XSetWMProtocols(nxagentDisplay, w, &deleteWMAtom, 1); + } + + return w; +} + Bool nxagentMagicPixelZone(int x, int y) { return (x >= nxagentOption(Width) - 1 && y < 1); @@ -816,6 +977,8 @@ Bool nxagentOpenScreen(int index, ScreenPtr pScreen, nxagentChangeOption(Fullscreen, False); + nxagentChangeOption(AllScreens, False); + nxagentFullscreenWindow = 0; resetAgentPosition = True; @@ -1221,6 +1384,11 @@ N/A nxagentChangeOption(Height, gattributes.height); } + if (nxagentOption(AllScreens)) + { + attributes.override_redirect = True; + } + if (nxagentOption(Fullscreen)) { /* @@ -1448,7 +1616,8 @@ N/A if (nxagentDoFullGeneration == 1 || nxagentReconnectTrap == 1) { - valuemask = CWBackPixel | CWEventMask | CWColormap; + valuemask = CWBackPixel | CWEventMask | CWColormap | + (nxagentOption(AllScreens) == 1 ? CWOverrideRedirect : 0); attributes.background_pixel = nxagentBlackPixel; @@ -1456,6 +1625,11 @@ N/A attributes.colormap = nxagentDefaultVisualColormap(nxagentDefaultVisual(pScreen)); + if (nxagentOption(AllScreens) == 1) + { + attributes.override_redirect = True; + } + if (nxagentOption(Fullscreen) == 1) { if (nxagentReconnectTrap) @@ -1635,6 +1809,21 @@ N/A XClearWindow(nxagentDisplay, nxagentDefaultWindows[pScreen->myNum]); + if (nxagentOption(AllScreens)) + { + if (nxagentReconnectTrap) + { + XGrabKeyboard(nxagentDisplay, nxagentFullscreenWindow, True, GrabModeAsync, + GrabModeAsync, CurrentTime); + } + + nxagentIconWindow = nxagentCreateIconWindow(); + } + else + { + nxagentIconWindow = 0; + } + /* * When we don't have window manager we grab keyboard * to let nxagent get keyboard events. @@ -1983,8 +2172,6 @@ Bool nxagentResizeScreen(ScreenPtr pScreen, int width, int height, int oldMmWidth; int oldMmHeight; - RegionPtr pRootWinSize; - #ifdef TEST nxagentPrintAgentGeometry("Before Resize Screen", "nxagentResizeScreen:"); #endif diff --git a/nx-X11/programs/Xserver/hw/nxagent/Screen.h b/nx-X11/programs/Xserver/hw/nxagent/Screen.h index 1ab6caad2..5b1957755 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Screen.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Screen.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -47,6 +47,8 @@ extern ScreenPtr nxagentDefaultScreen; extern Pixmap nxagentPixmapLogo; +extern Window nxagentIconWindow; + extern Window nxagentFullscreenWindow; extern RegionRec nxagentShadowUpdateRegion; @@ -87,6 +89,12 @@ extern int nxagentBitsPerPixel(int depth); void nxagentSetScreenSaverTime(void); +void nxagentMinimizeFromFullScreen(ScreenPtr pScreen); + +void nxagentMaximizeToFullScreen(ScreenPtr pScreen); + +Window nxagentCreateIconWindow(void); + Bool nxagentMagicPixelZone(int x, int y); Bool nxagentResizeScreen(ScreenPtr pScreen, int width, int height, diff --git a/nx-X11/programs/Xserver/hw/nxagent/Splash.c b/nx-X11/programs/Xserver/hw/nxagent/Splash.c index 24dbf1413..235c48c23 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Splash.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Splash.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Splash.h b/nx-X11/programs/Xserver/hw/nxagent/Splash.h index 86920ad8b..f7ba6c2e2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Splash.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Splash.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Split.c b/nx-X11/programs/Xserver/hw/nxagent/Split.c index bf7f705b9..4cc2ea607 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Split.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Split.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Split.h b/nx-X11/programs/Xserver/hw/nxagent/Split.h index 60be29b39..2be449a18 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Split.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Split.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/TestExt.c b/nx-X11/programs/Xserver/hw/nxagent/TestExt.c index 1d5fdee20..6bce2eaeb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/TestExt.c +++ b/nx-X11/programs/Xserver/hw/nxagent/TestExt.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.c b/nx-X11/programs/Xserver/hw/nxagent/Trap.c index 22de3bc1b..f5e6bde0e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Trap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Trap.h b/nx-X11/programs/Xserver/hw/nxagent/Trap.h index aa6937e70..9258e3b67 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Trap.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Trap.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Utils.h b/nx-X11/programs/Xserver/hw/nxagent/Utils.h index 830b2753f..f5bd55d8b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Utils.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Utils.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Visual.c b/nx-X11/programs/Xserver/hw/nxagent/Visual.c index f38931677..b086c0e9a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Visual.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Visual.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Visual.h b/nx-X11/programs/Xserver/hw/nxagent/Visual.h index c682f92dd..8436f79ad 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Visual.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Visual.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Window.c b/nx-X11/programs/Xserver/hw/nxagent/Window.c index 2da21b91c..3e6d41d04 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Window.c +++ b/nx-X11/programs/Xserver/hw/nxagent/Window.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -693,7 +693,6 @@ void nxagentRestackWindow(WindowPtr pWin, WindowPtr pOldNextSib) void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn) { XEvent e; - XSizeHints sizeHints; if (nxagentOption(Rootless) == 1) { @@ -731,27 +730,6 @@ void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn) nxagentChangeOption(Fullscreen, switchOn); - if (nxagentOption(DesktopResize) == 1) - { - sizeHints.flags = PSize; - - if (switchOn == 1) - { - sizeHints.width = - WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); - sizeHints.height = - HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay)); - } - else - { - sizeHints.width = nxagentOption(RootWidth); - sizeHints.height = nxagentOption(RootHeight); - } - - XSetWMNormalHints(nxagentDisplay, nxagentDefaultWindows[pScreen -> myNum], - &sizeHints); - } - memset(&e, 0, sizeof(e)); e.xclient.type = ClientMessage; @@ -779,6 +757,245 @@ void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn) } } +void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn) +{ + Window w; + XSetWindowAttributes attributes; + unsigned long valuemask; + + if (nxagentOption(Rootless)) + { + return; + } + + if (!switchOn) + { + nxagentWMDetect(); + + if (!nxagentWMIsRunning) + { + #ifdef WARNING + fprintf(stderr, "Warning: Can't switch to window mode, no window manager has been detected.\n"); + #endif + + return; + } + } + + w = nxagentDefaultWindows[pScreen -> myNum]; + attributes.override_redirect = switchOn; + valuemask = CWOverrideRedirect; + XUnmapWindow(nxagentDisplay, w); + XChangeWindowAttributes(nxagentDisplay, w, valuemask, &attributes); + + XReparentWindow(nxagentDisplay, w, DefaultRootWindow(nxagentDisplay), 0, 0); + + if (switchOn) + { + /* + * Change to fullscreen mode. + */ + + struct timeval timeout; + int i; + XEvent e; + + /* + * Wait for window manager reparenting the default window. + */ + + for (i = 0; i < 100 && nxagentWMIsRunning; i++) + { + #ifdef TEST + fprintf(stderr, "nxagentSwitchAllScreens: WARNING! Going to wait for the ReparentNotify event.\n"); + #endif + + if (XCheckTypedWindowEvent(nxagentDisplay, w, ReparentNotify, &e)) + { + break; + } + + /* + * This should also flush + * the NX link for us. + */ + + XSync(nxagentDisplay, 0); + + timeout.tv_sec = 0; + timeout.tv_usec = 50 * 1000; + + nxagentWaitEvents(nxagentDisplay, &timeout); + } + + if (i < 100) + { + /* + * The window manager has done with the reparent + * operation. We can resize and map the window. + */ + + nxagentChangeOption(Fullscreen, True); + nxagentChangeOption(AllScreens, True); + + + /* + * Save the window-mode configuration. + */ + + nxagentChangeOption(SavedX, nxagentOption(X)); + nxagentChangeOption(SavedY, nxagentOption(Y)); + nxagentChangeOption(SavedWidth, nxagentOption(Width)); + nxagentChangeOption(SavedHeight, nxagentOption(Height)); + nxagentChangeOption(SavedRootWidth, nxagentOption(RootWidth)); + nxagentChangeOption(SavedRootHeight, nxagentOption(RootHeight)); + + /* + * Reconf the Default window. + */ + + nxagentChangeOption(X, 0); + nxagentChangeOption(Y, 0); + nxagentChangeOption(Width, WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); + nxagentChangeOption(Height, HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); + + /* + * Move the root window. + */ + + nxagentChangeOption(RootX, (nxagentOption(Width) - nxagentOption(RootWidth)) / 2); + nxagentChangeOption(RootY, (nxagentOption(Height) - nxagentOption(RootHeight)) / 2); + nxagentChangeOption(ViewportXSpan, nxagentOption(Width) - nxagentOption(RootWidth)); + nxagentChangeOption(ViewportYSpan, nxagentOption(Height) - nxagentOption(RootHeight)); + + XMoveResizeWindow(nxagentDisplay, w, nxagentOption(X), nxagentOption(Y), + nxagentOption(Width), nxagentOption(Height)); + + nxagentUpdateViewportFrame(0, 0, nxagentOption(RootWidth), nxagentOption(RootHeight)); + + XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), + nxagentOption(RootX), nxagentOption(RootY)); + + /* + * We disable the screensaver when changing + * mode to fullscreen. Is it really needed? + */ + + XSetScreenSaver(nxagentDisplay, 0, 0, DefaultExposures, DefaultBlanking); + + if (nxagentIconWindow == None) + { + nxagentIconWindow = nxagentCreateIconWindow(); + + XMapWindow(nxagentDisplay, nxagentIconWindow); + } + + XMapRaised(nxagentDisplay, w); + XSetInputFocus(nxagentDisplay, w, RevertToParent, CurrentTime); + XCheckTypedWindowEvent(nxagentDisplay, w, LeaveNotify, &e); + nxagentFullscreenWindow = w; + + if (nxagentOption(DesktopResize) == 1) + { + if (nxagentOption(Shadow) == 0) + { + nxagentRRSetScreenConfig(pScreen, WidthOfScreen(DefaultScreenOfDisplay(nxagentDisplay)), + HeightOfScreen(DefaultScreenOfDisplay(nxagentDisplay))); + } + else + { + nxagentShadowAdaptToRatio(); + } + } + } + else + { + /* + * We have waited for a reparent event unsuccessfully. + * Something happened to the window manager. + */ + + #ifdef WARNING + fprintf(stderr, "nxagentSwitchAllScreens: WARNING! Expected ReparentNotify event missing.\n"); + #endif + + nxagentWMIsRunning = False; + attributes.override_redirect = False; + XChangeWindowAttributes(nxagentDisplay, w, valuemask, &attributes); + XMapWindow(nxagentDisplay, w); + } + } + else + { + /* + * FIXME: + * It could be necessary: + * - To restore screensaver. + * - To set or reset nxagentForceBackingStore flag. + * - To propagate device settings to the X server if no WM is running. + */ + + /* + * Change to windowed mode. + */ + + nxagentChangeOption(Fullscreen, False); + nxagentChangeOption(AllScreens, False); + + XDestroyWindow(nxagentDisplay, nxagentIconWindow); + + nxagentIconWindow = nxagentFullscreenWindow = None; + + if (nxagentOption(DesktopResize) == 1) + { + nxagentChangeOption(RootWidth, nxagentOption(SavedRootWidth)); + nxagentChangeOption(RootHeight, nxagentOption(SavedRootHeight)); + + if (nxagentOption(Shadow) == 0) + { + nxagentRRSetScreenConfig(pScreen, nxagentOption(RootWidth), nxagentOption(RootHeight)); + } + } + + if (nxagentOption(WMBorderWidth) > 0 && nxagentOption(WMTitleHeight) > 0) + { + nxagentChangeOption(X, nxagentOption(SavedX) - + nxagentOption(WMBorderWidth)); + nxagentChangeOption(Y, nxagentOption(SavedY) - + nxagentOption(WMTitleHeight)); + } + else + { + nxagentChangeOption(X, nxagentOption(SavedX)); + nxagentChangeOption(Y, nxagentOption(SavedY)); + } + + nxagentChangeOption(Width, nxagentOption(SavedWidth)); + nxagentChangeOption(Height, nxagentOption(SavedHeight)); + + if (nxagentOption(Shadow) == 1 && nxagentOption(DesktopResize) == 1) + { + nxagentShadowAdaptToRatio(); + } + + XMoveResizeWindow(nxagentDisplay, w, nxagentOption(X), nxagentOption(Y), + nxagentOption(Width), nxagentOption(Height)); + + nxagentUpdateViewportFrame(0, 0, nxagentOption(Width), nxagentOption(Height)); + + XMoveWindow(nxagentDisplay, nxagentWindow(WindowTable[pScreen -> myNum]), 0, 0); + XMapWindow(nxagentDisplay, w); + + nxagentChangeOption(RootX, 0); + nxagentChangeOption(RootY, 0); + } + + XMoveResizeWindow(nxagentDisplay, nxagentInputWindows[0], 0, 0, + nxagentOption(Width), nxagentOption(Height)); + + nxagentSetPrintGeometry(pScreen -> myNum); +} + #ifdef VIEWPORT_FRAME void nxagentUpdateViewportFrame(int x, int y, int w, int h) @@ -2281,7 +2498,7 @@ void nxagentMapDefaultWindows() if (nxagentOption(Fullscreen) == 1 && nxagentWMIsRunning == 1) { - nxagentSwitchFullscreen(pScreen, 1); + nxagentMaximizeToFullScreen(pScreen); } } @@ -2312,6 +2529,26 @@ void nxagentMapDefaultWindows() nxagentDefaultWindows[i], CurrentTime); } + /* + * Map the icon window. + */ + + if (nxagentIconWindow != 0) + { + #ifdef TEST + fprintf(stderr, "nxagentMapDefaultWindows: Mapping icon window id [%ld].\n", + nxagentIconWindow); + #endif + + XMapWindow(nxagentDisplay, nxagentIconWindow); + + if (nxagentIpaq != 0) + { + XIconifyWindow(nxagentDisplay, nxagentIconWindow, + DefaultScreen(nxagentDisplay)); + } + } + /* * Ensure that the fullscreen window gets the focus. */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/Windows.h b/nx-X11/programs/Xserver/hw/nxagent/Windows.h index 6fc97b341..3ca74ba8e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/Windows.h +++ b/nx-X11/programs/Xserver/hw/nxagent/Windows.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -222,6 +222,8 @@ void nxagentSetTopLevelEventMask(WindowPtr pWin); void nxagentSwitchFullscreen(ScreenPtr pScreen, Bool switchOn); +void nxagentSwitchAllScreens(ScreenPtr pScreen, Bool switchOn); + void nxagentMoveViewport(ScreenPtr pScreen, int hShift, int vShift); #ifdef VIEWPORT_FRAME diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c index 7bc1c74cb..cf5d48ba2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original index 7bc1c74cb..cf5d48ba2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdamage.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c index ba4e1e662..69ad30d2d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original index ba4e1e662..69ad30d2d 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdispatch.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c index 225ecdaf8..04fc047fc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original index 225ecdaf8..04fc047fc 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXdixfonts.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c index 8e87d58c4..c5593adbb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original index 8e87d58c4..c5593adbb 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXevents.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c index 6e67b7ffe..ead9b9d28 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original index 6e67b7ffe..ead9b9d28 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXextension.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c index 172252b32..51c547984 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original index 172252b32..51c547984 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglxext.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c index 6340de537..cd65fdc0e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original index 6340de537..cd65fdc0e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyph.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c index d6cd96631..7a1d813b3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original index d6cd96631..7a1d813b3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphcurs.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h index e78a1bf14..fa6b5fb02 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original index e78a1bf14..fa6b5fb02 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXglyphstr.h.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c index c71ea8142..3fc73cf3b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original index c71ea8142..3fc73cf3b 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiexpose.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c index efb295861..5f32334ae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original index efb295861..5f32334ae 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiglyph.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c index d2bead0bc..f418654b4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original index d2bead0bc..f418654b4 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmitrap.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c index be1096c6c..190294979 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original index be1096c6c..190294979 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXmiwindow.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c index be961c400..d9054b4b6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -873,6 +873,9 @@ AllocatePicture (ScreenPtr pScreen) else ppriv->ptr = (pointer)NULL; } + + nxagentPicturePriv(pPicture) -> picture = 0; + return pPicture; } @@ -1103,6 +1106,8 @@ static PicturePtr createSourcePicture(void) ppriv[nxagentPicturePrivateIndex].ptr = (pointer) privPictureRecAddr; pPicture -> devPrivates = ppriv; + + nxagentPicturePriv(pPicture) -> picture = 0; } pPicture->pDrawable = 0; diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original index be961c400..d9054b4b6 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicture.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ @@ -873,6 +873,9 @@ AllocatePicture (ScreenPtr pScreen) else ppriv->ptr = (pointer)NULL; } + + nxagentPicturePriv(pPicture) -> picture = 0; + return pPicture; } @@ -1103,6 +1106,8 @@ static PicturePtr createSourcePicture(void) ppriv[nxagentPicturePrivateIndex].ptr = (pointer) privPictureRecAddr; pPicture -> devPrivates = ppriv; + + nxagentPicturePriv(pPicture) -> picture = 0; } pPicture->pDrawable = 0; diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h index b6cee91f1..0d1a8e1d8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original index b6cee91f1..0d1a8e1d8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXpicturestr.h.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c index d02f3f015..cd1ec6ddd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original index d02f3f015..cd1ec6ddd 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXproperty.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c index e1bb44148..5f460f23e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original index e1bb44148..5f460f23e 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrandr.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c index 562cd2c66..89e790135 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c @@ -26,7 +26,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original index 562cd2c66..89e790135 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXrender.c.NX.original @@ -26,7 +26,7 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c index 8c69217e7..d1c8325f2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original index 8c69217e7..d1c8325f2 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXresource.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c index b99cbe3e3..eaaa92041 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original index b99cbe3e3..eaaa92041 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXshm.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c index 4022bc397..76e86fd2a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original index 4022bc397..76e86fd2a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXwindow.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c index aa902226e..f6dad312a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original index aa902226e..f6dad312a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original +++ b/nx-X11/programs/Xserver/hw/nxagent/X/NXxvdisp.c.NX.original @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm b/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm index 5955f1705..dd8be6cb3 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm +++ b/nx-X11/programs/Xserver/hw/nxagent/nxagent.xpm @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm b/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm index e7dee27b1..854e0a611 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm +++ b/nx-X11/programs/Xserver/hw/nxagent/nxmissing.xpm @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c b/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c index 80419d871..9ec7e6bc8 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c +++ b/nx-X11/programs/Xserver/hw/nxagent/os2Stub.c @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ diff --git a/nx-X11/programs/Xserver/hw/nxagent/screensaver b/nx-X11/programs/Xserver/hw/nxagent/screensaver index 4c5c10620..ef7cd661a 100644 --- a/nx-X11/programs/Xserver/hw/nxagent/screensaver +++ b/nx-X11/programs/Xserver/hw/nxagent/screensaver @@ -1,6 +1,6 @@ /**************************************************************************/ /* */ -/* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */ +/* Copyright (c) 2001, 2011 NoMachine, http://www.nomachine.com/. */ /* */ /* NXAGENT, NX protocol compression and NX extensions to this software */ /* are copyright of NoMachine. Redistribution and use of the present */ -- cgit v1.2.3