aboutsummaryrefslogtreecommitdiff
path: root/nxcomp/ServerCache.h
diff options
context:
space:
mode:
authorReinhard Tartler <siretart@tauware.de>2011-11-13 09:27:51 +0100
committerReinhard Tartler <siretart@tauware.de>2011-11-13 09:27:51 +0100
commit3e924126b56c4d421e8263d25f6b14aa4ceed047 (patch)
tree921403de7b834fb1ac89f97d84ce105e0b487051 /nxcomp/ServerCache.h
parenta840692edc9c6d19cd7c057f68e39c7d95eb767d (diff)
downloadnx-libs-3e924126b56c4d421e8263d25f6b14aa4ceed047.tar.gz
nx-libs-3e924126b56c4d421e8263d25f6b14aa4ceed047.tar.bz2
nx-libs-3e924126b56c4d421e8263d25f6b14aa4ceed047.zip
Imported nxcomp-3.1.0-4.tar.gznxcomp/3.1.0-4
Summary: Imported nxcomp-3.1.0-4.tar.gz Keywords: Imported nxcomp-3.1.0-4.tar.gz into Git repository
Diffstat (limited to 'nxcomp/ServerCache.h')
-rwxr-xr-xnxcomp/ServerCache.h305
1 files changed, 305 insertions, 0 deletions
diff --git a/nxcomp/ServerCache.h b/nxcomp/ServerCache.h
new file mode 100755
index 000000000..1f3ad3e8e
--- /dev/null
+++ b/nxcomp/ServerCache.h
@@ -0,0 +1,305 @@
+/**************************************************************************/
+/* */
+/* Copyright (c) 2001, 2007 NoMachine, http://www.nomachine.com/. */
+/* */
+/* NXCOMP, 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 ServerCache_H
+#define ServerCache_H
+
+#include "Misc.h"
+
+#include "IntCache.h"
+#include "CharCache.h"
+#include "OpcodeCache.h"
+#include "TextCompressor.h"
+#include "BlockCache.h"
+#include "BlockCacheSet.h"
+
+#include "ChannelCache.h"
+
+class ServerCache : public ChannelCache
+{
+ public:
+
+ ServerCache();
+
+ ~ServerCache();
+
+ //
+ // Opcode prediction caches.
+ //
+
+ OpcodeCache opcodeCache;
+
+ //
+ // General-purpose caches.
+ //
+
+ CharCache textCache[SERVER_TEXT_CACHE_SIZE];
+ IntCache replySequenceCache;
+ IntCache eventSequenceCache;
+ unsigned int lastTimestamp;
+ CharCache depthCache;
+ IntCache visualCache;
+ IntCache colormapCache;
+ CharCache resourceCache;
+
+ //
+ // X connection startup.
+ //
+
+ static BlockCache lastInitReply;
+
+ //
+ // X errors.
+ //
+
+ CharCache errorCodeCache;
+ IntCache errorMinorCache;
+ CharCache errorMajorCache;
+
+ //
+ // ButtonPress and ButtonRelease events.
+ //
+
+ CharCache buttonCache;
+
+ //
+ // ColormapNotify event.
+ //
+
+ IntCache colormapNotifyWindowCache;
+ IntCache colormapNotifyColormapCache;
+
+ //
+ // ConfigureNotify event.
+ //
+
+ IntCache *configureNotifyWindowCache[3];
+ IntCache *configureNotifyGeomCache[5];
+
+ //
+ // CreateNotify event.
+ //
+
+ IntCache createNotifyWindowCache;
+ unsigned int createNotifyLastWindow;
+
+ //
+ // Expose event.
+ //
+
+ IntCache exposeWindowCache;
+ IntCache *exposeGeomCache[5];
+
+ //
+ // FocusIn event (also used for FocusOut).
+ //
+
+ IntCache focusInWindowCache;
+
+ //
+ // KeymapNotify event.
+ //
+
+ static BlockCache lastKeymap;
+
+ //
+ // KeyPress event.
+ //
+
+ unsigned char keyPressLastKey;
+ unsigned char keyPressCache[23];
+
+ //
+ // MapNotify event (also used for UnmapNotify).
+ //
+
+ IntCache mapNotifyEventCache;
+ IntCache mapNotifyWindowCache;
+
+ //
+ // MotionNotify event (also used for KeyPress,
+ // KeyRelease, ButtonPress, ButtonRelease,
+ // EnterNotify, and LeaveNotify events and
+ // QueryPointer reply).
+ //
+
+ IntCache motionNotifyTimestampCache;
+ unsigned int motionNotifyLastRootX;
+ unsigned int motionNotifyLastRootY;
+ IntCache motionNotifyRootXCache;
+ IntCache motionNotifyRootYCache;
+ IntCache motionNotifyEventXCache;
+ IntCache motionNotifyEventYCache;
+ IntCache motionNotifyStateCache;
+ IntCache *motionNotifyWindowCache[3];
+
+ //
+ // NoExpose event.
+ //
+
+ IntCache noExposeDrawableCache;
+ IntCache noExposeMinorCache;
+ CharCache noExposeMajorCache;
+
+ //
+ // PropertyNotify event.
+ //
+
+ IntCache propertyNotifyWindowCache;
+ IntCache propertyNotifyAtomCache;
+
+ //
+ // ReparentNotify event.
+ //
+
+ IntCache reparentNotifyWindowCache;
+
+ //
+ // SelectionClear event.
+ //
+
+ IntCache selectionClearWindowCache;
+ IntCache selectionClearAtomCache;
+
+ //
+ // VisibilityNotify event.
+ //
+
+ IntCache visibilityNotifyWindowCache;
+
+ //
+ // GetGeometry reply.
+ //
+
+ IntCache getGeometryRootCache;
+ IntCache *getGeometryGeomCache[5];
+
+ //
+ // GetInputFocus reply.
+ //
+
+ IntCache getInputFocusWindowCache;
+
+ //
+ // GetKeyboardMapping reply.
+ //
+
+ static unsigned char getKeyboardMappingLastKeysymsPerKeycode;
+ static BlockCache getKeyboardMappingLastMap;
+ IntCache getKeyboardMappingKeysymCache;
+ CharCache getKeyboardMappingLastByteCache;
+
+ //
+ // GetModifierMapping reply.
+ //
+
+ static BlockCache getModifierMappingLastMap;
+
+ //
+ // GetProperty reply.
+ //
+
+ CharCache getPropertyFormatCache;
+ IntCache getPropertyTypeCache;
+ TextCompressor getPropertyTextCompressor;
+ static BlockCache xResources;
+
+ //
+ // GetSelection reply.
+ //
+
+ IntCache getSelectionOwnerCache;
+
+ //
+ // GetWindowAttributes reply.
+ //
+
+ IntCache getWindowAttributesClassCache;
+ CharCache getWindowAttributesBitGravityCache;
+ CharCache getWindowAttributesWinGravityCache;
+ IntCache getWindowAttributesPlanesCache;
+ IntCache getWindowAttributesPixelCache;
+ IntCache getWindowAttributesAllEventsCache;
+ IntCache getWindowAttributesYourEventsCache;
+ IntCache getWindowAttributesDontPropagateCache;
+
+ //
+ // QueryColors reply.
+ //
+
+ BlockCache queryColorsLastReply;
+
+ //
+ // QueryFont reply.
+ //
+
+ static BlockCacheSet queryFontFontCache;
+ IntCache *queryFontCharInfoCache[6];
+ unsigned int queryFontLastCharInfo[6];
+
+ //
+ // QueryPointer reply.
+ //
+
+ IntCache queryPointerRootCache;
+ IntCache queryPointerChildCache;
+
+ //
+ // TranslateCoords reply.
+ //
+
+ IntCache translateCoordsChildCache;
+ IntCache translateCoordsXCache;
+ IntCache translateCoordsYCache;
+
+ //
+ // QueryTree reply.
+ //
+
+ IntCache queryTreeWindowCache;
+
+ //
+ // GetAtomName reply in protocol
+ // versions >= 3.
+ //
+
+ TextCompressor getAtomNameTextCompressor;
+
+ //
+ // Generic reply. Use short data
+ // in protocol versions >= 3.
+ //
+
+ CharCache genericReplyCharCache;
+ IntCache *genericReplyIntCache[12];
+
+ //
+ // Generic event. Only in protocol
+ // versions >= 3.
+ //
+
+ CharCache genericEventCharCache;
+ IntCache *genericEventIntCache[14];
+
+ //
+ // Used in the abort split events.
+ //
+
+ OpcodeCache abortOpcodeCache;
+};
+
+#endif /* ServerCache_H */