os/graphics/windowing/windowserver/SERVER/w32cmd.h
author sl@SLION-WIN7.fritz.box
Fri, 15 Jun 2012 03:10:57 +0200
changeset 0 bde4ae8d615e
permissions -rw-r--r--
First public contribution.
     1 // Copyright (c) 1999-2010 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     4 // under the terms of "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     7 //
     8 // Initial Contributors:
     9 // Nokia Corporation - initial contribution.
    10 //
    11 // Contributors:
    12 //
    13 // Description:
    14 // Command numbers and structures for client to window server communications.
    15 // 
    16 //
    17 
    18 #ifndef __W32CMD_H__
    19 #define __W32CMD_H__
    20 
    21 #include <e32std.h>
    22 #include <w32std.h>
    23 #include <gdi.h>
    24 #if defined(SYMBIAN_GRAPHICS_GCE)
    25 #include <graphics/surfaceconfiguration.h>
    26 #include <graphics/sgresource.h>
    27 #endif
    28 
    29 #include <graphics/displayconfiguration.h>
    30 #include <graphics/displaymapping.h>
    31 
    32 const TUint KWservMajorVersionNumber=1;
    33 const TUint KWservMinorVersionNumber=0;
    34 const TUint KWservBuildVersionNumber=151;
    35 
    36 const TUint KWservLoggingDllUidValue8=268435925;
    37 const TUid KWservLoggingDllUid8={KWservLoggingDllUidValue8};
    38 const TUint KWservLoggingDllUidValue16=268450595;
    39 const TUid KWservLoggingDllUid16={KWservLoggingDllUidValue16};
    40 //const TUint KUidWservLoggingCommon=268439591;
    41 const TUint KWservLoggingDllUidValue=KWservLoggingDllUidValue16;
    42 const TUid KWservLoggingDllUid={KWservLoggingDllUidValue};
    43 const TInt KDummyScreenNumber = -1;
    44 class CClickMaker;
    45 class CAnimDll;
    46 class CDebugLogBase;
    47 class TSurfaceId;
    48 
    49 /** Creates an interface object for Shell
    50 
    51 @publishedPartner
    52 @released
    53 */
    54 typedef TInt (*ShellEntryPoint)(TAny *);
    55 
    56 /** Creates the key or pointer click plug-in provider interface.
    57 
    58 When a key is pressed, a key auto repeats or when the screen is tapped with a pointer, 
    59 the window server informs the plug-in DLL, which can then make the sound.
    60 
    61 @publishedAll
    62 @released
    63 */
    64 typedef CClickMaker *(*CreateCClickHandler)();
    65 
    66 /** Creates the animation dll factory interface object.
    67 
    68 Animation DLL objects are created by the CreateCAnimDllL() function,
    69 which is called by the window server at the request of the client.
    70 
    71 @publishedAll
    72 @released
    73 */
    74 typedef CAnimDll* (*CreateCAnimDll)();
    75 
    76 
    77 class WservEncoding
    78 	{
    79 public:
    80 	static inline TUint Encode8BitValues(TUint8 aFirst,TUint8 aSecond);
    81 	static inline TUint Encode8BitValues(TUint8 aFirst,TUint8 aSecond,TUint8 aThird);
    82 	static inline TUint8 ExtractFirst8BitValue(TUint aUint);
    83 	static inline TUint8 ExtractSecond8BitValue(TUint aUint);
    84 	static inline TUint8 ExtractThird8BitValue(TUint aUint);
    85 	};
    86 
    87 struct SKeyRepeatSettings
    88 	{
    89 	SKeyRepeatSettings();
    90 	TTimeIntervalMicroSeconds32 iInitialTime;
    91 	TTimeIntervalMicroSeconds32 iTime;
    92 	};
    93 struct SDoubleClickSettings
    94 	{
    95 	SDoubleClickSettings();
    96 	TTimeIntervalMicroSeconds32 iInterval;
    97 	TInt iDistance;
    98 	};
    99 //struct SMaxNumColors
   100 struct SDefModeMaxNumColors
   101 	{
   102 	SDefModeMaxNumColors();
   103 	TInt iColors;
   104 	TInt iGrays;
   105 	TDisplayMode iDisplayMode;
   106 	};
   107 struct SEventMessageReady
   108 	{
   109 	TInt iWindowGroupIdentifier;
   110 	TUid iMessageUid;
   111 	TInt iMessageParametersSize;
   112 	};
   113 class TCmdSpriteMember
   114 	{
   115 public:
   116 	inline TCmdSpriteMember();
   117 	TCmdSpriteMember(const TSpriteMember &aSpriteMember);
   118 public:
   119 	TInt iBitmap;
   120 	TInt iMaskBitmap;
   121 	TBool iInvertMask;
   122 	CGraphicsContext::TDrawMode iDrawMode;
   123 	TPoint iOffset;			// Offset from sprites central position
   124 	TTimeIntervalMicroSeconds32 iInterval;
   125 	};
   126 
   127 enum {EClientBufferSize=640};		// default buffer size
   128 enum {EClientBufferMaxSize=0x4000};	// 16K is max buffer size
   129 
   130 enum {EWsOpcodeHandle=0x8000};	// Indicates a new handle is included in the message header
   131 
   132 enum {EMaxPolygonPoints=50}; // Max size polygon that can be drawn without allocing
   133 enum {EMaxPolylinePoints=50}; // Max size polygon that can be drawn without allocing
   134 
   135 enum {EClickLoaded=0x01, EClickLoadable=0x02};
   136 
   137 ////////////////////////
   138 // Opcodes
   139 ////////////////////////
   140 
   141 // Client opcodes
   142 
   143 enum TWsClientOpcodes
   144 	{
   145 	EWsClOpDisconnect, //Keep this as the first enum value - used by test code
   146 	EWsClOpClearHotKeys,
   147 	EWsClOpSetHotKey,
   148 	EWsClOpRestoreDefaultHotKey,
   149 	EWsClOpComputeMode,
   150 	EWsClOpEventReady,
   151 	EWsClOpEventReadyCancel,
   152 	EWsClOpGetEvent,
   153 	EWsClOpPurgePointerEvents,
   154 	EWsClOpRedrawReady,
   155 	EWsClOpRedrawReadyCancel,
   156 	EWsClOpGetRedraw,
   157 	EWsClOpPriorityKeyReady,
   158 	EWsClOpPriorityKeyReadyCancel,
   159 	EWsClOpGetPriorityKey,
   160 	EWsClOpSetShadowVector,
   161 	EWsClOpShadowVector,
   162 	EWsClOpSetKeyboardRepeatRate,
   163 	EWsClOpGetKeyboardRepeatRate,
   164 	EWsClOpSetDoubleClick,
   165 	EWsClOpGetDoubleClickSettings,
   166 	EWsClOpCreateWindowGroup,
   167 	EWsClOpCreateWindow,
   168 	EWsClOpCreateGc,
   169 	EWsClOpCreateAnimDll,
   170 	EWsClOpCreateScreenDevice,
   171 	EWsClOpCreateSprite,
   172 	EWsClOpCreatePointerCursor,
   173 	EWsClOpStartSetCustomTextCursor,
   174 	EWsClOpCompleteSetCustomTextCursor,
   175 	EWsClOpCreateBitmap,
   176 	EWsClOpNumWindowGroups,
   177 	EWsClOpNumWindowGroupsAllPriorities,
   178 	EWsClOpWindowGroupList,
   179 	EWsClOpWindowGroupListAllPriorities,
   180 	EWsClOpSetWindowGroupOrdinalPosition,
   181 	EWsClOpGetWindowGroupHandle,
   182 	EWsClOpGetWindowGroupOrdinalPriority,
   183 	EWsClOpGetWindowGroupClientThreadId,
   184 	EWsClOpGetWindowGroupNameFromIdentifier,
   185 	EWsClOpGetFocusWindowGroup,
   186 	EWsClOpGetDefaultOwningWindow,
   187 	EWsClOpSendEventToWindowGroup,
   188 	EWsClOpFindWindowGroupIdentifier,
   189 	EWsClOpFindWindowGroupIdentifierThread,
   190 	EWsClOpSetBackgroundColor,
   191 	EWsClOpGetBackgroundColor,
   192 	EWsClOpSetSystemPointerCursor,
   193 	EWsClOpClearSystemPointerCursor,
   194 	EWsClOpClaimSystemPointerCursorList,
   195 	EWsClOpFreeSystemPointerCursorList,
   196 	EWsClOpGetModifierState,
   197 	EWsClOpSetModifierState,
   198 	EWsClOpHeapCount,
   199 	EWsClOpResourceCount,
   200 	EWsClOpTestInvariant,
   201 	EWsClOpHeapSetFail,
   202 	EWsClOpRawEvent,
   203 	EWsClOpSystemInfo,
   204 	EWsClOpLogMessage,
   205 	EWsClOpPasswordEntered,
   206 	EWsClOpSendMessageToWindowGroup,
   207 	EWsClOpSendOffEventsToShell,
   208 	EWsClOpGetDefModeMaxNumColors,
   209 	EWsClOpGetColorModeList,
   210 	EWsClOpKeyEvent,
   211 	EWsClOpSendEventToAllWindowGroup,
   212 	EWsClOpSendEventToAllWindowGroupPriority,
   213 	EWsClOpSetPointerCursorArea,
   214 	EWsClOpPointerCursorArea,
   215 	EWsClOpSetPointerCursorMode,
   216 	EWsClOpPointerCursorMode,
   217 	EWsClOpSetDefaultSystemPointerCursor,
   218 	EWsClOpClearDefaultSystemPointerCursor,
   219 	EWsClOpSetPointerCursorPosition,
   220 	EWsClOpPointerCursorPosition,
   221 	EWsClOpSetDefaultFadingParams,
   222 	EWsClOpSendMessageToAllWindowGroups,
   223 	EWsClOpSendMessageToAllWindowGroupsPriority,
   224 	EWsClOpFetchMessage,
   225 	EWsClOpPrepareForSwitchOff,
   226 	EWsClOpCreateDirectScreenAccess,
   227 	EWsClOpSetFaded,
   228 	EWsClOpLogCommand,
   229 	EWsClOpCreateClick,
   230 	EWsClOpSendEventToOneWindowGroupPerClient,
   231 #if defined(__WINS__)
   232 	EWsClOpRemoveKeyCode,
   233 	EWsClOpSimulateXyInput,
   234 #endif
   235 	EWsClOpNoFlickerFree,
   236 	EWsClOpSetFocusScreen,
   237 	EWsClOpGetFocusScreen,
   238 	EWsClOpWindowGroupListAndChain,
   239 	EWsClOpWindowGroupListAndChainAllPriorities,
   240 	EWsClOpSetClientCursorMode,
   241 	EWsClOpClearAllRedrawStores,
   242 	EWsClOpCreateGraphic,
   243 	EWsClOpGraphicMessageReady,
   244 	EWsClOpGetGraphicMessage,
   245 	EWsClOpGraphicMessageCancel,
   246 	EWsClOpNumWindowGroupsOnScreen,
   247 	EWsClOpGetNumberOfScreens, 
   248 	EWsClOpGraphicAbortMessage,
   249 	EWsClOpGraphicFetchHeaderMessage,
   250 	EWsClOpDebugInfo,
   251 	EWsClOpDebugInfoReplyBuf,
   252 	EWsClOpRegisterSurface,
   253 	EWsClOpUnregisterSurface,
   254 	EWsClOpSetCloseProximityThresholds,
   255 	EWsClOpSetHighPressureThresholds,
   256 	EWsClOpGetEnterCloseProximityThreshold,
   257 	EWsClOpGetExitCloseProximityThreshold,
   258 	EWsClOpGetEnterHighPressureThreshold,
   259 	EWsClOpGetExitHighPressureThreshold,
   260 	EWsClOpCreateDrawableSource,
   261 	EWsClOpCreateDirectScreenAccessRegionTrackingOnly,
   262 	EWsClOpSendEffectCommand,
   263 	EWsClOpRegisterTFXEffectBuf,
   264 	EWsClOpRegisterTFXEffectIPC,
   265 	EWsClOpUnregisterTFXEffect,
   266 	EWsClOpUnregisterAllTFXEffect,
   267 	EWsClOpOverrideEffectBuf,
   268 	EWsClOpOverrideEffectIPC,
   269 	EWsClOpIndicateAppOrientation,
   270 	EWsClOpLastEnumValue //Keep this at the end - used by test code
   271 	};
   272 	
   273 // Graphic Drawer opcodes
   274 
   275 enum TWsGraphicDrawerOpcodes
   276 	{
   277 	EWsGdOpFree = 0x0000,
   278 	EWsGdOpSendMsg,
   279 	EWsGdOpGetGraphicId,
   280 	EWsGdOpShareGlobally,
   281 	EWsGdOpUnShareGlobally,
   282 	EWsGdOpShare,
   283 	EWsGdOpUnShare,
   284 	EWsGdOpSendSynchronMsg,
   285 	};
   286 	
   287 // types of Graphic Drawer messages to be passed from the Graphic Drawer to the client
   288 	
   289 enum TWsGraphicMessageType
   290 	{
   291 	EWsGraphMessageTypeUser = 0x00
   292 	// max 0x03 as packed into lower two bits of client handle
   293 	};
   294 
   295 // Window opcodes
   296 
   297 enum TWsWindowOpcodes
   298 	{
   299 	EWsWinOpFree=0x0000,
   300 	EWsWinOpSetExtent,
   301 	EWsWinOpSetExtentErr,
   302 	EWsWinOpOrdinalPosition,
   303 	EWsWinOpFullOrdinalPosition,
   304 	EWsWinOpSetOrdinalPosition,
   305 	EWsWinOpSetOrdinalPositionPri,
   306 	EWsWinOpSetOrdinalPriorityAdjust,
   307 	EWsWinOpSetPos,
   308 	EWsWinOpSetSize,
   309 	EWsWinOpSetSizeErr,
   310 	EWsWinOpPosition,
   311 	EWsWinOpAbsPosition,
   312 	EWsWinOpSize,
   313 	EWsWinOpActivate,
   314 	EWsWinOpInvalidate,
   315 	EWsWinOpInvalidateFull,
   316 	EWsWinOpBeginRedraw,
   317 	EWsWinOpBeginRedrawFull,
   318 	EWsWinOpEndRedraw,
   319 	EWsWinOpTestInvariant,
   320 	EWsWinOpParent,
   321 	EWsWinOpPrevSibling,
   322 	EWsWinOpNextSibling,
   323 	EWsWinOpChild,
   324 	EWsWinOpInquireOffset,
   325 	EWsWinOpPointerFilter,
   326 	EWsWinOpSetPointerCapture,
   327 	EWsWinOpSetPointerGrab,
   328 	EWsWinOpClaimPointerGrab,
   329 	EWsWinOpSetBackgroundColor,
   330 	EWsWinOpSetOrdinalPositionErr,
   331 	EWsWinOpSetVisible,
   332 	EWsWinOpScroll,
   333 	EWsWinOpScrollClip,
   334 	EWsWinOpScrollRect,
   335 	EWsWinOpScrollClipRect,
   336 	EWsWinOpReceiveFocus,
   337 	EWsWinOpAutoForeground,
   338 	EWsWinOpSetNoBackgroundColor,
   339 	EWsWinOpCaptureKey,
   340 	EWsWinOpCancelCaptureKey,
   341 	EWsWinOpCaptureKeyUpsAndDowns,
   342 	EWsWinOpCancelCaptureKeyUpsAndDowns,
   343 	EWsWinOpAddPriorityKey,
   344 	EWsWinOpRemovePriorityKey,
   345 	EWsWinOpSetTextCursor,
   346 	EWsWinOpSetTextCursorClipped,
   347 	EWsWinOpCancelTextCursor,
   348 	EWsWinOpSetShadowHeight,
   349 	EWsWinOpShadowDisabled,
   350 	EWsWinOpGetInvalidRegion,
   351 	EWsWinOpGetInvalidRegionCount,
   352 	EWsWinOpSetColor,
   353 	EWsWinOpSetCornerType,
   354 	EWsWinOpSetShape,
   355 	EWsWinOpBitmapHandle,
   356 	EWsWinOpUpdateScreen,
   357 	EWsWinOpUpdateScreenRegion,
   358 	EWsWinOpUpdateBackupBitmap,
   359 	EWsWinOpMaintainBackup,
   360 	EWsWinOpName,
   361 	EWsWinOpSetName,
   362 	EWsWinOpSetOwningWindowGroup,
   363 	EWsWinOpDefaultOwningWindow,
   364 	EWsWinOpRequiredDisplayMode,
   365 	EWsWinOpEnableOnEvents,
   366 	EWsWinOpDisableOnEvents,
   367 	EWsWinOpEnableGroupChangeEvents,
   368 	EWsWinOpDisableGroupChangeEvents,
   369 	EWsWinOpSetPointerCursor,
   370 	EWsWinOpSetCustomPointerCursor,
   371 	EWsWinOpRequestPointerRepeatEvent,
   372 	EWsWinOpCancelPointerRepeatEventRequest,
   373 	EWsWinOpAllocPointerMoveBuffer,
   374 	EWsWinOpFreePointerMoveBuffer,
   375 	EWsWinOpEnablePointerMoveBuffer,
   376 	EWsWinOpDisablePointerMoveBuffer,
   377 	EWsWinOpRetrievePointerMoveBuffer,
   378 	EWsWinOpDiscardPointerMoveBuffer,		//Tested to here %%%
   379 	EWsWinOpEnableModifierChangedEvents,
   380 	EWsWinOpDisableModifierChangedEvents,
   381 	EWsWinOpEnableErrorMessages,
   382 	EWsWinOpDisableErrorMessages,
   383 	EWsWinOpAddKeyRect,
   384 	EWsWinOpRemoveAllKeyRects,
   385 	EWsWinOpPasswordWindow,
   386 	EWsWinOpEnableBackup,
   387 	EWsWinOpIdentifier,
   388 	EWsWinOpDisableKeyClick,
   389 	EWsWinOpSetFade=EWsWinOpDisableKeyClick+3,	//Two messages removed
   390 	EWsWinOpSetNonFading,
   391 	EWsWinOpFadeBehind,
   392 	EWsWinOpEnableScreenChangeEvents,
   393 	EWsWinOpDisableScreenChangeEvents,
   394 	EWsWinOpSendPointerEvent,
   395 	EWsWinOpSendAdvancedPointerEvent,
   396 	EWsWinOpGetDisplayMode,
   397 	EWsWinOpGetIsFaded,
   398 	EWsWinOpGetIsNonFading,
   399 	EWsWinOpOrdinalPriority,
   400 	EWsWinOpClearPointerCursor,
   401 	EWsWinOpMoveToGroup,
   402 	EWsWinOpEnableFocusChangeEvents,
   403 	EWsWinOpDisableFocusChangeEvents,
   404 	EWsWinOpEnableGroupListChangeEvents,
   405 	EWsWinOpDisableGroupListChangeEvents,
   406 	EWsWinOpCaptureLongKey,
   407 	EWsWinOpCancelCaptureLongKey,
   408 	EWsWinOpStoreDrawCommands,
   409 	EWsWinOpHandleTransparencyUpdate,
   410 	EWsWinOpSetTransparencyFactor,
   411 	EWsWinOpSetTransparencyBitmap,
   412 	EWsWinOpAllowChildWindowGroup,
   413 	EWsWinOpSetTransparencyBitmapCWs, 
   414 	EWsWinOpEnableVisibilityChangeEvents,
   415 	EWsWinOpDisableVisibilityChangeEvents,
   416 	EWsWinOpSetTransparencyAlphaChannel,
   417 	EWsWinOpWindowGroupId,
   418 	EWsWinOpSetPointerCapturePriority,
   419 	EWsWinOpGetPointerCapturePriority,
   420 	EWsWinOpSetTransparentRegion,
   421 	EWsWinOpSetTransparencyPolicy,
   422 	EWsWinOpIsRedrawStoreEnabled,
   423 	EWsWinOpEnableOSB,
   424 	EWsWinOpDisableOSB,
   425 	EWsWinOpClearChildGroup,
   426 	EWsWinOpSetChildGroup,
   427 	EWsWinOpClientHandle,
   428 	EWsWinOpSetBackgroundSurface,
   429 	EWsWinOpKeyColor=EWsWinOpSetBackgroundSurface+2, 	//One message removed
   430 	EWsWinOpSetBackgroundSurfaceConfig=EWsWinOpKeyColor+5,	//Four messages removed
   431 	EWsWinOpRemoveBackgroundSurface=EWsWinOpSetBackgroundSurfaceConfig+2,	//One message removed
   432 	EWsWinOpGetBackgroundSurfaceConfig=EWsWinOpRemoveBackgroundSurface+2,	//One message removed
   433 	EWsWinOpClearRedrawStore=EWsWinOpGetBackgroundSurfaceConfig+2,	//One message removed
   434 	EWsWinOpScreenNumber,
   435 	EWsWinOpEnableAdvancedPointers,
   436 #ifdef SYMBIAN_GRAPHICS_WSERV_QT_EFFECTS	
   437 	EWsWinOpSetSurfaceTransparency,
   438 #endif
   439 	EWsWinOpSetPurpose,
   440 	EWsWinOpSendEffectCommand,
   441 	EWsWinOpOverrideEffectBuf,
   442 	EWsWinOpOverrideEffectIPC,
   443 	EWsWinOpTestLowPriorityRedraw=0x2000,  //Specific opcode for testing redraw queue priorities
   444 	};
   445 
   446 // GC opcodes
   447 
   448 enum TWsGcOpcodes
   449 	{
   450 	EWsGcOpFree=0x0000,
   451 	EWsGcOpActivate,
   452 	EWsGcOpDeactivate,
   453 	EWsGcOpSetClippingRegion,
   454 	EWsGcOpSetClippingRect,
   455 	EWsGcOpCancelClippingRegion,
   456 	EWsGcOpCancelClippingRect,
   457 	EWsGcOpSetWordJustification,
   458 	EWsGcOpSetCharJustification,
   459 	EWsGcOpSetPenColor,
   460 	EWsGcOpSetPenStyle,
   461 	EWsGcOpSetPenSize,
   462 	EWsGcOpSetBrushColor,
   463 	EWsGcOpSetBrushStyle,
   464 	EWsGcOpSetBrushOrigin,
   465 	EWsGcOpUseBrushPattern,
   466 	EWsGcOpDiscardBrushPattern,
   467 	EWsGcOpDrawArc,
   468 	EWsGcOpDrawLine,
   469 	EWsGcOpPlot,
   470 	EWsGcOpDrawTo,
   471 	EWsGcOpDrawBy,
   472 	EWsGcOpDrawPolyLine,
   473 	EWsGcOpDrawPolyLineContinued,   //Quater Way
   474 
   475 	EWsGcOpDrawPie,
   476 	EWsGcOpDrawRoundRect,
   477 	EWsGcOpDrawPolygon,
   478 	EWsGcOpStartSegmentedDrawPolygon,
   479 	EWsGcOpSegmentedDrawPolygonData,
   480 	EWsGcOpDrawSegmentedPolygon,
   481 	EWsGcOpDrawBitmap,
   482 	EWsGcOpDrawBitmap2,
   483 	EWsGcOpDrawBitmap3,
   484 	EWsGcOpDrawBitmapMasked,
   485 	EWsGcOpWsDrawBitmapMasked,
   486 	EWsGcOpDrawText,
   487 	EWsGcOpDrawTextPtr,
   488 	EWsGcOpDrawTextInContextPtr,
   489 	EWsGcOpDrawTextInContext,
   490 	EWsGcOpDrawTextVertical,
   491 	EWsGcOpDrawTextInContextVertical,
   492 	EWsGcOpDrawTextInContextVerticalPtr,
   493 	EWsGcOpDrawTextVerticalPtr,
   494 	EWsGcOpDrawBoxTextOptimised1,
   495 	EWsGcOpDrawBoxTextOptimised2,
   496 	EWsGcOpDrawBoxTextInContextOptimised1,
   497 	EWsGcOpDrawBoxTextInContextOptimised2,
   498 	EWsGcOpDrawBoxText,
   499 	EWsGcOpDrawBoxTextInContext,
   500 	EWsGcOpDrawBoxTextPtr,
   501 	EWsGcOpDrawBoxTextInContextPtr,
   502 	EWsGcOpDrawBoxTextVertical,
   503 	EWsGcOpDrawBoxTextInContextVertical,
   504 	EWsGcOpDrawBoxTextVerticalPtr,
   505 	EWsGcOpDrawBoxTextInContextVerticalPtr,
   506 	EWsGcOpMoveBy,
   507 	EWsGcOpMoveTo,
   508 	EWsGcOpSetOrigin,
   509 	EWsGcOpCopyRect,
   510 	EWsGcOpDrawRect,
   511 	EWsGcOpDrawEllipse,		//Half Way
   512 
   513 	EWsGcOpGdiBlt2,
   514 	EWsGcOpGdiBlt3,
   515 	EWsGcOpGdiBltMasked,
   516 	EWsGcOpGdiWsBlt2,
   517 	EWsGcOpGdiWsBlt3,
   518 	EWsGcOpGdiWsBltMasked,
   519 	EWsGcOpSize,
   520 	EWsGcOpUseFont,
   521 	//Two unused codes deleted
   522 	EWsGcOpDiscardFont=EWsGcOpUseFont+3,
   523 	EWsGcOpSetUnderlineStyle,
   524 	EWsGcOpSetStrikethroughStyle,
   525 	EWsGcOpSetDrawMode,
   526 	EWsGcOpTestInvariant,
   527 	EWsGcOpClearRect,
   528 	EWsGcOpClear,
   529 	EWsGcOpReset,
   530 	EWsGcOpSetDitherOrigin,
   531 	EWsGcOpMapColors,
   532 	EWsGcOpDrawWsGraphic, //PREQ1246 Bravo
   533 	EWsGcOpDrawWsGraphicPtr,
   534 //
   535 // Local opcodes used internally access GC drawing code
   536 //
   537 	EWsGcOpDrawPolyLineLocal,
   538 	EWsGcOpDrawPolyLineLocalBufLen,
   539 	EWsGcOpDrawPolygonLocal,
   540 	EWsGcOpDrawPolygonLocalBufLen,
   541 	EWsGcOpDrawTextLocal,
   542 	EWsGcOpDrawTextInContextLocal,
   543 	EWsGcOpDrawBoxTextLocal,
   544 	EWsGcOpDrawBoxTextInContextLocal,
   545 	EWsGcOpDrawBitmapLocal,
   546 	EWsGcOpDrawBitmap2Local,
   547 	EWsGcOpDrawBitmap3Local,
   548 	EWsGcOpDrawBitmapMaskedLocal,
   549 	EWsGcOpGdiBlt2Local,
   550 	EWsGcOpGdiBlt3Local,
   551 	EWsGcOpGdiBltMaskedLocal,
   552 
   553 //
   554 // Local opcodes used when reading long strings
   555 //
   556 	EWsGcOpDrawTextPtr1,
   557 	EWsGcOpDrawTextInContextPtr1,
   558 	EWsGcOpDrawTextVerticalPtr1,
   559 	EWsGcOpDrawTextInContextVerticalPtr1,
   560 	EWsGcOpDrawBoxTextPtr1,
   561 	EWsGcOpDrawBoxTextInContextPtr1,
   562 	EWsGcOpDrawBoxTextVerticalPtr1,
   563 	EWsGcOpDrawBoxTextInContextVerticalPtr1,
   564 			
   565 //
   566 // New functions added leaving a space just in case it may be useful
   567 //
   568 	EWsGcOpSetFaded=200,
   569 	EWsGcOpSetFadeParams,
   570 	EWsGcOpGdiAlphaBlendBitmaps,
   571 	EWsGcOpGdiWsAlphaBlendBitmaps,
   572 	EWsGcOpSetOpaque,
   573 	EWsGcOpMapColorsLocal,	
   574 	EWsGcOpAlphaBlendBitmapsLocal,
   575 	EWsGcOpSetShadowColor,
   576 	EWsGcOpSetDrawTextInContext,
   577 	EWsGcOpDrawResourceToPos,
   578 	EWsGcOpDrawResourceToRect,
   579 	EWsGcOpDrawResourceFromRectToRect,
   580 	EWsGcOpDrawResourceWithData,
   581 //
   582 // Codes for internal use only
   583 //
   584 	EWsStoreAllGcAttributes=1000,
   585 	EWsStoreClippingRegion,
   586 	EWsGcOpFlagDrawOp=0x8000,
   587 	};
   588 
   589 enum TWsAnimDllOpcode
   590 	{
   591 	EWsAnimDllOpCreateInstance=0x0000,
   592 	EWsAnimDllOpCommand,
   593 	EWsAnimDllOpCommandReply,
   594 	EWsAnimDllOpDestroyInstance,
   595 	EWsAnimDllOpFree,
   596 	EWsAnimDllOpCreateInstanceSprite,
   597 	};
   598 
   599 enum TWsScreenDeviceOpcodes
   600 	{
   601 	EWsSdSetableBitFlag=0x80000000,
   602 	EWsSdOpGetScanLine=0x0000,
   603 	EWsSdOpPixel,
   604 	EWsSdOpTwipsSize,
   605 	EWsSdOpPixelSize,
   606 	EWsSdOpFree,
   607 	EWsSdOpHorizontalTwipsToPixels,
   608 	EWsSdOpVerticalTwipsToPixels,
   609 	EWsSdOpHorizontalPixelsToTwips,
   610 	EWsSdOpVerticalPixelsToTwips,
   611 	EWsSdOpDisplayMode,
   612 	EWsSdOpRectCompare,
   613 	EWsSdOpPointerRect,
   614 	EWsSdOpCopyScreenToBitmap,
   615 	EWsSdOpCopyScreenToBitmap2,
   616 	EWsSdOpSetScreenSizeAndRotation,
   617 	EWsSdOpSetScreenSizeAndRotation2,
   618 	EWsSdOpGetDefaultScreenSizeAndRotation,
   619 	EWsSdOpGetDefaultScreenSizeAndRotation2,
   620 	EWsSdOpGetNumScreenModes,
   621 	EWsSdOpSetScreenMode,
   622 	EWsSdOpGetScreenModeSizeAndRotation,
   623 	EWsSdOpGetScreenModeSizeAndRotation2,
   624 	EWsSdOpSetScreenModeEnforcement,
   625 	EWsSdOpScreenModeEnforcement,
   626 	EWsSdOpSetModeRotation,
   627 	EWsSdOpGetRotationList,
   628 	EWsSdOpPaletteAttributes,
   629 	EWsSdOpSetPalette,
   630 	EWsSdOpGetPalette,
   631 	EWsSdOpGetScreenMode,
   632 	EWsSdOpGetDefaultScreenModeOrigin,
   633 	EWsSdOpGetScreenModeOrigin,
   634 	EWsSdOpGetScreenModeScale,
   635 	EWsSdOpGetCurrentScreenModeScale,
   636 	EWsSdOpSetAppScreenMode,
   637 	EWsSdOpGetScreenModeScaledOrigin,
   638 	EWsSdOpGetCurrentScreenModeScaledOrigin,
   639 	EWsSdOpSetCurrentScreenModeAttributes,
   640 	EWsSdOpGetCurrentScreenModeAttributes,
   641 	EWsSdOpGetScreenNumber,
   642 	EWsSdOpGetScreenSizeModeList,
   643 	EWsSdOpGetScreenModeDisplayMode,
   644 	EWsClOpSetBackLight,
   645 	EWsSdOpExtensionsSupported,
   646 	EWsSdOpXDcGetNumberOfResolutions,
   647 	EWsSdOpXDcGetResolutionsList,
   648 	EWsSdOpXDcGetConfiguration,
   649 	EWsSdOpXDcSetConfiguration,
   650 	EWsSdOpXDcGetPreferredDisplayVersion,
   651 	EWsSdOpXDcNotifyOnDisplayChange,
   652 	EWsSdOpXDcNotifyOnDisplayChangeCancel,
   653 	EWsSdOpXDcDisplayChangeEventEnabled,
   654 	EWsSdOpXDmMapExtent,
   655 	EWsSdOpXTestScreenCapture,
   656 	EWsSdOpIsScreenModeDynamic,
   657 	EWsSdOpXTestScreenCaptureSize,
   658 	};
   659 
   660 /**	Bitfield of interface extensions explicitly supported.
   661  * 	The client interface is welcome to group functionality in  different ways, if desired.
   662  * 	Operations classified as inside extensions can be called and fail safely on an individual basis.
   663  * 	Note that to distinguish versions, new bits may need to be used.
   664  *  The top bit is reserved so that error value returns can be distinguished. 
   665  **/    
   666 enum TWsInterfaceExtensions
   667 	{
   668 	TWsSdXDisplayControl	=	0x00000001,
   669 	TWsSdXDisplayMapping	=	0x00000002,
   670 	TWsSdXDebugComposition	=	0x00000004,
   671 	
   672 	
   673 	TWsSdXReservedErrorFlag	=	0x80000000
   674 	};
   675 
   676 enum TWsSpriteOpcodes
   677 	{
   678 	EWsSpriteOpFree=0x0000,
   679 	EWsSpriteOpSetPosition,
   680 	EWsSpriteOpUpdateMember,
   681 	EWsSpriteOpUpdateMember2,
   682 	EWsSpriteOpActivate,
   683 	EWsSpriteOpAppendMember,
   684 	};
   685 
   686 enum TWsBitmapOpcodes
   687 	{
   688 	EWsBitmapOpFree=0x0000,
   689 	};
   690 
   691 enum TWsDirectOpcodes
   692 	{
   693 	EWsDirectOpFree=0x0000,
   694 	EWsDirectOpRequest,
   695 	EWsDirectOpInitFailed,
   696 	EWsDirectOpGetRegion,
   697 	EWsDirectOpCancel,
   698 	EWsDirectOpGetSendQueue,
   699 	EWsDirectOpGetRecQueue,
   700 	};
   701 
   702 enum TWsClickOpcodes
   703 	{
   704 	EWsClickOpFree=0x0000,
   705 	EWsClickOpIsLoaded,
   706 	EWsClickOpUnLoad,
   707 	EWsClickOpLoad,
   708 	EWsClickOpCommandReply,
   709 	EWsClickOpSetKeyClick,
   710 	EWsClickOpSetPenClick,
   711 	EWsClickOpKeyClickEnabled,
   712 	EWsClickOpPenClickEnabled,
   713 	};
   714 	
   715 enum TWsGraphicBitFlags
   716 	{
   717 	EWsGraphicIdUid			= 0x01,
   718 	EWsGraphicIdTransient	= 0x02,
   719 	EWsGraphicReplace		= 0x04
   720 	};
   721 
   722 enum TWsDrawableSourceOpcodes
   723 	{
   724 	EWsDrawableSourceOpFree=0x0000,
   725 	};
   726 
   727 ////////////////////////
   728 // Command structures
   729 ////////////////////////
   730 
   731 /** Structure used to pass commands between the client and the server.
   732 
   733 @internalComponent
   734 @released
   735 @see RWsBuffer::DoWrite()
   736 @see CWsClient::DoCommandBufL()
   737 */
   738 struct TWsCmdHeaderBase
   739 	{
   740 	TUint16 iOpcode;
   741 	TInt16 iCmdLength;
   742 	};
   743 
   744 /** Structure used to pass commands between the client and the server.
   745 
   746 @internalComponent
   747 @released
   748 @see RWsBuffer::DoWrite()
   749 @see CWsClient::DoCommandBufL()
   750 */
   751 struct TWsCmdHeader
   752 	{
   753 	TWsCmdHeaderBase iBase;
   754 	TInt32 iDestHandle;
   755 	};
   756 
   757 //
   758 // Command structures
   759 //
   760 
   761 // Client command structures
   762 
   763 enum TWinTypes
   764 	{
   765 	EWinRedraw,
   766 	EWinBackedUp,
   767 	EWinBlank,
   768 	};
   769 
   770 struct TWsClCmdCreateWindow
   771 	{
   772 	TInt parent;
   773 	TUint32 clientHandle;
   774 	TWinTypes type;
   775 	TDisplayMode displayMode;	// Only used for backed up windows
   776 	};
   777 struct TWsClCmdCreateWindowGroup
   778 	{
   779 	TUint32 clientHandle;
   780 	TBool focus;
   781 	TInt parentId;
   782 	TInt32 screenDeviceHandle;
   783 	};
   784 struct TWsClCmdLoadAnimDll
   785 	{
   786 	TInt length;
   787 	};
   788 struct TWsClCmdCreatePointerCursor
   789 	{
   790 	TUint flags;
   791 	};
   792 struct TWsClCmdCustomTextCursorData
   793 	{
   794 	TInt identifier;
   795 	TUint flags;
   796 	RWsSession::TCustomTextCursorAlignment alignment;
   797 	};
   798 struct TWsClCmdCreateSprite
   799 	{
   800 	inline TWsClCmdCreateSprite(TInt aWindow, const TPoint &aPos, TUint aFlags);
   801 	TInt window;
   802 	TPoint pos;
   803 	TUint flags;
   804 	};
   805 struct TWsClCmdCreateBitmap
   806 	{
   807 	TInt handle;
   808 	};
   809 struct TWsClCmdSetHotKey
   810 	{
   811 	TUint type;
   812 	TUint modifiers;
   813 	TUint modifierMask;
   814 	TUint16 keycode;
   815 	TUint16 filler;
   816 	};
   817 struct TWsClCmdWindowGroupList
   818 	{
   819 	TInt priority;
   820 	TInt count;
   821 	TInt screenNumber;
   822 	};
   823 struct TWsClCmdSetWindowGroupOrdinalPosition
   824 	{
   825 	inline TWsClCmdSetWindowGroupOrdinalPosition(TInt aIdentifier, TInt aPosition);
   826 	TInt identifier;
   827 	TInt position;
   828 	};
   829 struct TWsClCmdSetKeyboardRepeatRate
   830 	{
   831 	inline TWsClCmdSetKeyboardRepeatRate(const TTimeIntervalMicroSeconds32 &aInitial,const TTimeIntervalMicroSeconds32 &aTime);
   832 	TTimeIntervalMicroSeconds32 initial;
   833 	TTimeIntervalMicroSeconds32 time;
   834 	};
   835 struct TWsClCmdSetDoubleClick
   836 	{
   837 	inline TWsClCmdSetDoubleClick(const TTimeIntervalMicroSeconds32 &aInterval,TInt aDistance);
   838 	TTimeIntervalMicroSeconds32 interval;
   839 	TInt distance;
   840 	};
   841 struct TWsClCmdSetSystemPointerCursor
   842 	{
   843 	TInt handle;
   844 	TInt number;
   845 	};
   846 struct TWsClCmdHeapSetFail
   847 	{
   848 	RHeap::TAllocFail type;
   849 	TInt value;
   850 	TInt burst;
   851 	};
   852 struct TWsClCmdSendEventToWindowGroup
   853 	{
   854 	inline TWsClCmdSendEventToWindowGroup(TInt aParameter, const TWsEvent &aEvent);
   855 	TInt parameter;
   856 	TWsEvent event;
   857 	};
   858 struct TWsClCmdFindWindowGroupIdentifier
   859 	{
   860 	inline TWsClCmdFindWindowGroupIdentifier(TInt aPreviousIdentifier,TInt aOffset, TInt aLength);
   861 	TInt identifier;
   862 	TInt offset;
   863 	TInt length;
   864 	};
   865 struct TWsClCmdSendMessageToWindowGroup
   866 	{
   867 	inline TWsClCmdSendMessageToWindowGroup(TInt aIdentifier, TUid aUid, TInt aDataLength, const TDesC8 *aPtr);
   868 	TInt identifierOrPriority; // identifier in case of EWsClOpSendMessageToWindowGroup, not used in case of EWsClOpSendMessageToAllWindowGroup, priority in case of EWsClOpSendMessageToAllWindowGroupPriority
   869 	TUid uid;
   870 	TInt dataLength;
   871 	const TDesC8 *ptr;
   872 	};
   873 struct TWsClCmdFetchMessage
   874 	{
   875 	inline TWsClCmdFetchMessage(TInt aWindowGroupIdentifier);
   876 	TInt windowGroupIdentifier;
   877 	};
   878 struct TWsClCmdFindWindowGroupIdentifierThread
   879 	{
   880 	inline TWsClCmdFindWindowGroupIdentifierThread(TInt aPreviousIdentifier,TThreadId aThreadId);
   881 	TInt identifier;
   882 	TThreadId threadId;
   883 	};
   884 struct TWsClCmdGetWindowGroupNameFromIdentifier
   885 	{
   886 	inline TWsClCmdGetWindowGroupNameFromIdentifier(TInt aIdentifier,TInt aMaxLength);
   887 	TInt identifier;
   888 	TInt maxLength;
   889 	};
   890 struct TWsClCmdOffEventsToShell
   891 	{
   892 	inline TWsClCmdOffEventsToShell(TBool aOn,TUint32 aWindow);
   893 	TBool on;
   894 	TUint32 window;
   895 	};
   896 struct TWsClCmdSetModifierState
   897 	{
   898 	TEventModifier modifier;
   899 	TModifierState state;
   900 	};
   901 struct TWsClCmdSetPointerCursorArea
   902 	{
   903 	inline TWsClCmdSetPointerCursorArea(TInt aMode,TRect aArea);
   904 	TInt mode;
   905 	TRect area;
   906 	};
   907 struct TWsClCmdSetSystemFaded
   908 	{
   909 	enum {EFaded=0x01,EUseDefaultMap=0x02};
   910 	inline TWsClCmdSetSystemFaded(TBool aFaded,TBool aUseDefaults=ETrue,TUint8 aBlackMap=0,TUint8 aWhiteMap=0);
   911 	inline TBool Faded() const;
   912 	inline TBool UseDefaultMap() const;
   913 	inline void GetFadingParams(TUint8& aBlackMap,TUint8& aWhiteMap) const;
   914 	TUint params;
   915 	};
   916 struct TWsClCmdCreateGraphic
   917 	{
   918 	TUint iFlags; // TWsGraphicBitFlags
   919 	TInt iClientHandle;
   920 	TInt iId;
   921 	TUid iType;
   922 	TInt iDataLen;
   923 	TBool iRemoteReadData;
   924 	};
   925 struct TWsClCmdGdSendMessage
   926 	{
   927 	TInt iDataLen;
   928 	TBool iRemoteReadData;
   929 	};
   930 struct TWsClCmdGdGetId
   931 	{
   932 	TInt iId;
   933 	TBool iIsUid;
   934 	};
   935 struct TWsClCmdDebugInfo
   936 	{
   937 	inline TWsClCmdDebugInfo(TInt aFunction, TInt aParam);
   938 	TInt iFunction;
   939 	TInt iParam;
   940 	};
   941 struct TWsClCmdCreateDrawableSource;
   942 struct TWsClCmdSurfaceRegister;
   943 #if defined(SYMBIAN_GRAPHICS_GCE)
   944 struct TWsClCmdCreateDrawableSource
   945 	{
   946 	inline TWsClCmdCreateDrawableSource(const TSgDrawableId& aDrawableId, TInt aScreenNumber);
   947 	TSgDrawableId iDrawableId;
   948 	TInt iScreenNumber;
   949 	};
   950 struct TWsClCmdSurfaceRegister
   951 	{
   952 	inline TWsClCmdSurfaceRegister(TInt aScreenNumber, const TSurfaceId& aSurface);
   953 	TInt screenNumber;
   954 	TSurfaceId surfaceId;
   955 	};
   956 #endif
   957 struct TWsClCmdNumWindowGroups
   958 	{
   959 	TInt screenNumber;
   960 	TInt priority;	
   961 	};
   962 struct TWsClCmdCreateScreenDevice
   963 	{
   964 	TInt screenNumber;	
   965 	TUint clientScreenDevicePointer;
   966 	};
   967 struct TWsClCmdZThresholdPair
   968 	{
   969 	inline TWsClCmdZThresholdPair(const TInt aEnterThreshold, const TInt aExitThreshold);
   970 	TInt enterThreshold;
   971 	TInt exitThreshold;
   972 	};
   973 struct TWsClCmdSendEffectCommand
   974 	{
   975 	inline TWsClCmdSendEffectCommand(TInt aTfxCmd,TInt aTfxCmdDataLength, TInt aWinHandle);
   976 	TInt tfxCmd;
   977 	TInt tfxCmdDataLength;
   978 	TInt windowHandle;
   979 	};
   980 struct TWsClCmdRegisterEffect
   981     {
   982     inline TWsClCmdRegisterEffect(TInt aAction, TInt aPurpose, TInt aDirStrSize, TInt aPhase1StrSize, TInt aPhase2StrSize, TUint aAppUid, TBitFlags aFlags);
   983     TInt tfxAction;
   984     TInt tfxPurpose;
   985     TInt tfxDirStrSize;
   986     TInt tfxPhase1StrSize;
   987     TInt tfxPhase2StrSize;
   988     TUint tfxAppUid;
   989     TBitFlags tfxFlags;
   990     };
   991 struct TWsClCmdUnRegisterEffect
   992     {
   993     inline TWsClCmdUnRegisterEffect(TInt aAction, TInt aPurpose, TUint aAppUid);
   994     TInt tfxAction;
   995     TInt tfxPurpose;
   996     TUint tfxAppUid;
   997     };
   998 struct TWsClCmdOverrideEffect
   999     {
  1000     inline TWsClCmdOverrideEffect(TInt aAction, TInt aPurpose, TInt aDirStrSize, TInt aPhase1StrSize, TInt aPhase2StrSize, TBitFlags aFlags);
  1001     TInt tfxAction;
  1002     TInt tfxPurpose;
  1003     TInt tfxDirStrSize;
  1004     TInt tfxPhase1StrSize;
  1005     TInt tfxPhase2StrSize;
  1006     TBitFlags tfxFlags;
  1007     };
  1008 typedef TRequestStatus *RqStatPtr;
  1009 union TWsClCmdUnion
  1010 	{
  1011 	const TAny* any;
  1012 	const TAny** pAny;
  1013 	const TInt* Int;
  1014 	const TUint* UInt;
  1015 	const TBool* Bool;
  1016 	const TUid* Uid;
  1017 	const TPointerCursorMode* Mode;
  1018     const TInt *XyInput;
  1019 	const TPoint* Point;
  1020 	const TRgb* rgb;
  1021 	const RqStatPtr* RequestStatus;
  1022 	const TRawEvent* RawEvent;
  1023 	const TKeyEvent* KeyEvent;
  1024 	const RWsSession::TComputeMode* ComputeMode;
  1025 	const RWsSession::TLoggingCommand* LogCommand;
  1026 	const TWsClCmdCreateWindow* CreateWindow;
  1027 	const TWsClCmdCreateWindowGroup* CreateWindowGroup;
  1028 	const TWsClCmdLoadAnimDll* LoadAnimDll;
  1029 	const TWsClCmdCreatePointerCursor* CreatePointerCursor;
  1030 	const TWsClCmdCustomTextCursorData* CustomTextCursorData;
  1031 	const TWsClCmdCreateSprite* CreateSprite;
  1032 	const TWsClCmdCreateBitmap* CreateBitmap;
  1033 	const TWsClCmdSetHotKey* SetHotKey;
  1034 	const TWsClCmdWindowGroupList* WindowGroupList;
  1035 	const TWsClCmdSetWindowGroupOrdinalPosition* SetWindowGroupOrdinalPosition;
  1036 	const TWsClCmdSetKeyboardRepeatRate* SetKeyboardRepeatRate;
  1037 	const TWsClCmdHeapSetFail* HeapSetFail;
  1038 	const TWsClCmdSetDoubleClick* SetDoubleClick;
  1039 	const TWsClCmdSetSystemPointerCursor* SetSystemPointerCursor;
  1040 	const TWsClCmdSendEventToWindowGroup* SendEventToWindowGroup;
  1041 	const TWsClCmdSendMessageToWindowGroup* SendMessageToWindowGroup;
  1042 	const TWsClCmdFetchMessage* FetchMessage;
  1043 	const TWsClCmdFindWindowGroupIdentifier* FindWindowGroupIdentifier;
  1044 	const TWsClCmdFindWindowGroupIdentifierThread* FindWindowGroupIdentifierThread;
  1045 	const TWsClCmdGetWindowGroupNameFromIdentifier* GetWindowGroupNameFromIdentifier;
  1046 	const TWsClCmdOffEventsToShell* OffEventsToShell;
  1047 	const TWsClCmdSetModifierState* SetModifierState;
  1048 	const TWsClCmdSetPointerCursorArea* SetPointerCursorArea;
  1049 	const TWsClCmdSetSystemFaded* SetSystemFaded;
  1050 	const TWsClCmdCreateGraphic* CreateGraphic;
  1051 	const TWsClCmdGdSendMessage* GraphicSendMessage;
  1052 	const TWsClCmdGdGetId* GetGraphicId;
  1053 	const TWsClCmdDebugInfo* DebugInfo;
  1054 	const TWsClCmdSurfaceRegister* SurfaceRegister;
  1055 	const TWsClCmdNumWindowGroups* NumWinGroups;
  1056 	const TWsClCmdCreateScreenDevice* CreateScreenDevice;
  1057 	const TWsClCmdZThresholdPair* ZThresholdPair;
  1058 	const TWsClCmdCreateDrawableSource* CreateDrawableSource;
  1059 	const TWsClCmdSendEffectCommand* SendEffectCommand;
  1060 	const TWsClCmdRegisterEffect* RegisterEffect;
  1061 	const TWsClCmdUnRegisterEffect* UnRegisterEffect; 
  1062 	const TWsClCmdOverrideEffect* OverrideEffect;
  1063 	const TRenderOrientation* Orientation;
  1064 	};
  1065 
  1066 // Window command structures
  1067 
  1068 struct TWsWinCmdSetExtent
  1069 	{
  1070 	inline TWsWinCmdSetExtent(const TPoint &aPos,const TSize &aSize);
  1071 	TPoint pos;
  1072 	TSize size;
  1073 	};
  1074 struct TWsWinCmdOrdinalPos
  1075 	{
  1076 	TInt pos;
  1077 	TInt ordinalPriority;
  1078 	};
  1079 struct TWsWinCmdScroll
  1080 	{
  1081 	inline TWsWinCmdScroll(const TRect &aClip,const TPoint &aOffset,const TRect &aRect);
  1082 	TRect clip;
  1083 	TPoint offset;
  1084 	TRect rect;
  1085 	};
  1086 struct TWsWinCmdCaptureKey
  1087 	{
  1088 	TUint modifiers;
  1089 	TUint modifierMask;
  1090 	TUint key;
  1091 	TInt priority;
  1092 	};
  1093 struct TWsWinCmdCaptureLongKey
  1094 	{
  1095 	inline TWsWinCmdCaptureLongKey();
  1096 	inline TWsWinCmdCaptureLongKey(TUint aModifiers,TUint aModifierMask,TUint aInputKey,TUint aOutputKey
  1097 																	,TTimeIntervalMicroSeconds32 aDelay,TInt aPriority,TUint aFlags);
  1098 	TUint modifiers;
  1099 	TUint modifierMask;
  1100 	TUint inputKey;
  1101 	TUint outputKey;
  1102 	TTimeIntervalMicroSeconds32 delay;
  1103 	TInt priority;
  1104 	TUint flags;
  1105 	};
  1106 struct TWsWinCmdPriorityKey
  1107 	{
  1108 	TUint modifiers;
  1109 	TUint modifierMask;
  1110 	TUint keycode;
  1111 	};
  1112 struct TWsWinCmdSetTextCursor
  1113 	{
  1114 	inline TWsWinCmdSetTextCursor(TUint32 aWindow, const TPoint &aPos, const TTextCursor &aCursor, const TRect &aRect);
  1115 	inline TWsWinCmdSetTextCursor(TUint32 aWindow, const TPoint &aPos, const TTextCursor &aCursor);
  1116 	TUint32 window;
  1117 	TPoint pos;
  1118 	TTextCursor cursor;
  1119 	TRect rect;
  1120 	};
  1121 struct TWsWinCmdPointerFilter
  1122 	{
  1123 	TUint32 mask;
  1124 	TUint32 flags;
  1125 	};
  1126 struct TWsWinCmdSetCornerType
  1127 	{
  1128 	TCornerType type;
  1129 	TInt flags;
  1130 	};
  1131 struct TWsWinCmdSetShape
  1132 	{
  1133 	TPtrC8 *ptr;
  1134 	TInt count;
  1135 	};
  1136 struct TWsWinCmdUpdateScreen
  1137 	{
  1138 	TPtrC8 *ptr;
  1139 	TInt count;
  1140 	};
  1141 struct TWsWinCmdGrabControl
  1142 	{
  1143 	enum TWsWinCmdGrabControlFlags
  1144 		{
  1145 		ENone=0,
  1146 		ESendUpEvent=0x2,
  1147 		ESendReply=0x4
  1148 		};
  1149 	inline TWsWinCmdGrabControl(const TUint aGrabControlFlags);
  1150 	inline TWsWinCmdGrabControl(const TUint8 aPointerNumber, const TUint aGrabControlFlags);
  1151 	inline TBool CheckFlags(TUint aFlags) const;
  1152 	inline TBool HasPointerNumber() const;
  1153 	
  1154 	// integer to ensure passed in unsigned TUint8 can't get confused with
  1155 	// signed negative values that are used internally.
  1156 	// The signed int member will be "promoted" to unsigned for the assignement in the constructor.
  1157 	TInt pointerNumber;
  1158 	TUint flags;	
  1159 	};
  1160 
  1161 struct TWsWinCmdCancelPointerRepeatEventRequest
  1162 	{
  1163 	enum TCancelRepeatFlags
  1164 		{
  1165 		ECancelRepeatFlagsNone=0,
  1166 		ECancelRepeatFlagsSendReply=0x2
  1167 		};	
  1168 	
  1169 	inline TWsWinCmdCancelPointerRepeatEventRequest();
  1170 	inline TWsWinCmdCancelPointerRepeatEventRequest(const TUint8 aPointerNumber);	
  1171 	inline TWsWinCmdCancelPointerRepeatEventRequest(const TUint8 aPointerNumber, const TUint aFlags);
  1172 	inline TBool HasPointerNumber() const;
  1173 	TInt pointerNumber;
  1174 	TUint flags;
  1175 	};
  1176 
  1177 struct TWsWinCmdRequestPointerRepeatEvent
  1178 	{
  1179 	enum TRepeatFlags
  1180 		{
  1181 		ERepeatFlagsNone=0,
  1182 		ERepeatFlagsSendReply=0x2
  1183 		};
  1184 	
  1185 	inline TWsWinCmdRequestPointerRepeatEvent(const TTimeIntervalMicroSeconds32 &aTime,const TRect &aRect);
  1186 	inline TWsWinCmdRequestPointerRepeatEvent(const TTimeIntervalMicroSeconds32 &aTime,const TRect &aRect,const TUint8 aPointerNumber, const TUint aRepeatFlags);
  1187 	inline TBool HasPointerNumber() const;
  1188 	TTimeIntervalMicroSeconds32 time;
  1189 	TRect rect;
  1190 	TInt pointerNumber;
  1191 	TUint repeatFlags;
  1192 	};
  1193 struct TWsWinCmdAllocPointerMoveBuffer
  1194 	{
  1195 	TInt maxNumPoints;
  1196 	TInt flags;
  1197 	};
  1198 struct TWsWinCmdSetName
  1199 	{
  1200 	TInt length;
  1201 	const TDesC *ptr;
  1202 	};
  1203 struct TWsWinCmdAddKeyRect
  1204 	{
  1205 	inline TWsWinCmdAddKeyRect(const TRect &aRect,TInt aScanCodea, TBool aActivatedByPointerSwitchOn);
  1206 	TRect rect;
  1207 	TInt scanCode;
  1208 	TBool activatedByPointerSwitchOn;
  1209 	};
  1210 struct TWsWinOpSetBackgroundSurfaceConfig;
  1211 #if defined(SYMBIAN_GRAPHICS_GCE)
  1212 struct TWsWinOpSetBackgroundSurfaceConfig
  1213 	{
  1214 	inline TWsWinOpSetBackgroundSurfaceConfig(const TSurfaceConfiguration& aConfiguration, TBool aTriggerRedraw);
  1215 	TSurfaceConfiguration surfaceConfig;
  1216 	TBool triggerRedraw;
  1217 	};
  1218 #endif
  1219 struct TWsWinCmdEnableModifierChangedEvents
  1220 	{
  1221 	inline TWsWinCmdEnableModifierChangedEvents(TUint aModifierMask, TEventControl aCircumstances);
  1222 	TInt modifierMask;
  1223 	TEventControl circumstances;
  1224 	};
  1225 struct TWsWinCmdSetFaded
  1226 	{
  1227 	enum {EFaded=0x01,EIncludeChildren=0x02,EUseDefaultMap=0x04};
  1228 	inline TWsWinCmdSetFaded(TBool aFaded, TBool aIncludeChildren
  1229 														,TBool aUseDefaults=ETrue,TUint8 aBlackMap=0,TUint8 aWhiteMap=0);
  1230 	inline TBool Faded() const;
  1231 	inline TBool IncludeChildren() const;
  1232 	inline TBool UseDefaultMap() const;
  1233 	inline void GetFadingParams(TUint8& aBlackMap,TUint8& aWhiteMap) const;
  1234 	TUint params;
  1235 	};
  1236 
  1237 union TWsWinCmdUnion
  1238 	{
  1239 	const TAny *any;
  1240 	const TAny **pAny;
  1241 	const TRect *rect;
  1242 	const TPoint *pos;
  1243 	const TSize *size;
  1244 	const TInt *Int;
  1245 	const TUint *UInt;
  1246 	const TBool *Bool;
  1247 	const TEventControl *EventControl;
  1248 	const TRgb *rgb;
  1249 	const TDisplayMode *DisplayMode;
  1250 	const TPasswordMode *PasswordMode;
  1251 	const TRawEvent *RawEvent;
  1252 	const TSurfaceConfiguration *SurfaceConfiguration;
  1253 	const TWsWinCmdSetExtent *SetEx;
  1254 	const TWsWinCmdOrdinalPos *OrdinalPos;
  1255 	const TWsWinCmdScroll *ScrollRect;
  1256 	const TWsWinCmdCaptureKey *CaptureKey;
  1257 	const TWsWinCmdCaptureLongKey *CaptureLongKey;
  1258 	const TWsWinCmdPriorityKey *PriorityKey;
  1259 	const TWsWinCmdSetTextCursor *SetTextCursor;
  1260 	const TWsWinCmdPointerFilter *PointerFilter;
  1261 	const TWsWinCmdSetCornerType *SetCornerType;
  1262 	const TWsWinCmdSetShape *SetShape;
  1263 	const TWsWinCmdUpdateScreen *UpdateScreen;
  1264 	const TWsWinCmdRequestPointerRepeatEvent *RequestPointerRepeatEvent;
  1265 	const TWsWinCmdAllocPointerMoveBuffer *AllocPointerMoveBuffer;
  1266 	const TWsWinCmdSetName *SetName;
  1267 	const TWsWinCmdAddKeyRect *AddKeyRect;
  1268 	const TWsWinOpSetBackgroundSurfaceConfig *SurfaceConfigurationAndTrigger;
  1269 	const TWsWinCmdEnableModifierChangedEvents *EnableModifierChangedEvents;
  1270 	const TWsWinCmdSetFaded *SetFaded;
  1271 	const TSurfaceId *Surface;
  1272 	const TWsWinCmdCancelPointerRepeatEventRequest *CancelPointerRepeatEventRequest;
  1273 	const TWsWinCmdGrabControl *GrabControl;
  1274 	const TWsClCmdSendEffectCommand *SendEffectCommand;
  1275 	const TWsClCmdOverrideEffect* OverrideEffect;
  1276 	};
  1277 
  1278 // GC command structures
  1279 
  1280 struct TWsGcLargeStruct
  1281 	{
  1282 	TInt int1;
  1283 	TInt int2;
  1284 	TInt int3;
  1285 	TInt int4;
  1286 	TInt int5;
  1287 	TInt int6;
  1288 	TInt int7;
  1289 	TInt int8;
  1290 	TInt int9;
  1291 	TBool tbool;
  1292 	CGraphicsContext::TTextAlign align;
  1293 	TAny* ptr;
  1294 	};
  1295 struct TWsGcCmdSetClippingRegion
  1296 	{
  1297 	TPtrC8 *ptr;
  1298 	TInt count;
  1299 	};
  1300 struct TWsGcCmdSetJustification
  1301 	{
  1302 	TInt excessWidth;
  1303 	TInt numGaps;
  1304 	};
  1305 struct TWsGcCmdDrawText
  1306 	{
  1307 	inline TWsGcCmdDrawText(const TPoint &aPos, TInt aLength);
  1308 	TPoint pos;
  1309 	TInt length;
  1310 	};
  1311 struct TWsGcCmdDrawTextPtr
  1312 	{
  1313 	TPoint pos;
  1314 	TDesC *text;
  1315 	};
  1316 
  1317 
  1318 struct TWsGcCmdDrawTextVertical
  1319 	{
  1320 	inline TWsGcCmdDrawTextVertical(const TPoint &aPos, TInt aLength, TBool aUp);
  1321 	TPoint pos;
  1322 	TInt length;
  1323 	TBool up;
  1324 	};
  1325 
  1326 struct TWsGcCmdDrawTextVerticalPtr
  1327 	{
  1328 	TPoint pos;
  1329 	TBool up;
  1330 	TDesC *text;
  1331 	inline TWsGcCmdDrawTextVerticalPtr(const TDesC *aDesc, const TPoint& aPos, const TBool aUp);
  1332 	};
  1333 
  1334 struct TWsGcCmdDrawTextLocal
  1335 	{
  1336 	inline TWsGcCmdDrawTextLocal(const TPoint &aPos,const TDesC *aDesc);
  1337 	TPoint pos;
  1338 	const TDesC *desc;
  1339 	};
  1340 
  1341 struct TWsGcCmdBoxTextOptimised1
  1342 	{
  1343 	inline TWsGcCmdBoxTextOptimised1(const TRect &aRect,TInt aBaselineOffset,TInt alength);
  1344 	TRect box;
  1345 	TInt baselineOffset;
  1346 	TInt length;
  1347 	};
  1348 struct TWsGcCmdBoxTextOptimised2
  1349 	{
  1350 	inline TWsGcCmdBoxTextOptimised2(const TRect &aRect,TInt aBaselineOffset,CGraphicsContext::TTextAlign aHoriz,TInt aLeftMrg,TInt aLength);
  1351 	TRect box;
  1352 	TInt baselineOffset;
  1353 	CGraphicsContext::TTextAlign horiz;
  1354 	TInt leftMrg;
  1355 	TInt length;
  1356 	};
  1357 
  1358 struct TWsGcCmdBoxText
  1359 	{
  1360 	inline TWsGcCmdBoxText(const TRect &aRect,TInt aBaselineOffset,CGraphicsContext::TTextAlign aHoriz,TInt aLeftMrg,TInt aLength,TInt aWidth);
  1361 	TRect box;
  1362 	TInt baselineOffset;
  1363 	CGraphicsContext::TTextAlign horiz;
  1364 	TInt leftMrg;
  1365 	TInt length;
  1366 	TInt width;
  1367 	};
  1368 
  1369 struct TWsGcCmdBoxTextPtr
  1370 	{
  1371 	TRect box;
  1372 	TInt baselineOffset;
  1373 	CGraphicsContext::TTextAlign horiz;
  1374 	TInt leftMrg;
  1375 	TInt width;
  1376 	TDesC *text;
  1377 	};
  1378 
  1379 struct TWsGcCmdBoxTextVertical
  1380 	{
  1381 	inline TWsGcCmdBoxTextVertical(const TRect& aBox);
  1382 	TRect box;
  1383 	TInt baselineOffset;
  1384 	TBool up;
  1385 	CGraphicsContext::TTextAlign vert;
  1386 	TInt margin;
  1387 	TInt length;
  1388 	TInt width;
  1389 	};
  1390 
  1391 struct TWsGcCmdBoxTextVerticalPtr
  1392 	{
  1393 	TRect box;
  1394 	TInt baselineOffset;
  1395 	TBool up;
  1396 	CGraphicsContext::TTextAlign vert;
  1397 	TInt margin;
  1398 	TInt width;
  1399 	TDesC *text;
  1400 	};
  1401 
  1402 struct TWsGcCmdBoxTextLocal
  1403 	{
  1404 	inline TWsGcCmdBoxTextLocal(const TRect &aBox);
  1405 	TRect box;
  1406 	TInt baselineOffset;
  1407 	CGraphicsContext::TTextAlign horiz;
  1408 	TInt leftMrg;
  1409 	const TDesC *desc;
  1410 	};
  1411 
  1412 struct TWsGcCmdDrawLine
  1413 	{
  1414 	inline TWsGcCmdDrawLine(const TPoint &aPnt1,const TPoint &aPnt2);
  1415 	TPoint pnt1;
  1416 	TPoint pnt2;
  1417 	};
  1418 struct TWsGcCmdDrawPolyLine
  1419 	{
  1420 	TInt numPoints;
  1421 	TInt more;
  1422 	TPoint last;
  1423 	};
  1424 struct TWsGcCmdDrawArcOrPie
  1425 	{
  1426 	inline TWsGcCmdDrawArcOrPie(const TRect &aRect,const TPoint &aStart,const TPoint &aEnd);
  1427 	TRect rect;
  1428 	TPoint start;
  1429 	TPoint end;
  1430 	};
  1431 struct TWsGcCmdDrawRoundRect
  1432 	{
  1433 	inline TWsGcCmdDrawRoundRect(const TRect &aRect,const TSize &aEllipse);
  1434 	TRect rect;
  1435 	TSize ellipse;
  1436 	};
  1437 struct TWsGcCmdDrawPolygon
  1438 	{
  1439 	TInt numPoints;
  1440 	CGraphicsContext::TFillRule fillRule;
  1441 	};
  1442 struct TWsGcCmdStartSegmentedDrawPolygon
  1443 	{
  1444 	TInt totalNumPoints;
  1445 	};
  1446 struct TWsGcCmdSegmentedDrawPolygonData
  1447 	{
  1448 	const TDesC8 *points;
  1449 	TInt index;
  1450 	TInt numPoints;
  1451 	};
  1452 struct TWsGcCmdDrawSegmentedPolygon
  1453 	{
  1454 	CGraphicsContext::TFillRule fillRule;
  1455 	};
  1456 struct TWsGcCmdDrawPolygonLocal
  1457 	{
  1458 	const CArrayFix<TPoint> *pointList;
  1459 	CGraphicsContext::TFillRule fillRule;
  1460 	};
  1461 struct TWsGcCmdDrawPolygonLocalBufLen
  1462 	{
  1463 	inline TWsGcCmdDrawPolygonLocalBufLen(const TPoint *aPointList,TInt aNumPoints, CGraphicsContext::TFillRule aFillRule);
  1464 	const TPoint *points;
  1465 	TInt length;
  1466 	CGraphicsContext::TFillRule fillRule;
  1467 	};
  1468 struct TWsGcCmdDrawPolyLineLocalBufLen
  1469 	{
  1470 	inline TWsGcCmdDrawPolyLineLocalBufLen(const TPoint *aPointList,TInt aNumPoints);
  1471 	const TPoint *points;
  1472 	TInt length;
  1473 	};
  1474 struct TWsGcCmdDrawBitmap
  1475 	{
  1476 	inline TWsGcCmdDrawBitmap(const TPoint &aPoint,TInt aHandle);
  1477 	TInt handle;
  1478 	TPoint pos;
  1479 	};
  1480 struct TWsGcCmdDrawBitmap2
  1481 	{
  1482 	inline TWsGcCmdDrawBitmap2(const TRect &aRect,TInt aHandle);
  1483 	TInt handle;
  1484 	TRect rect;
  1485 	};
  1486 struct TWsGcCmdDrawBitmap3
  1487 	{
  1488 	inline TWsGcCmdDrawBitmap3(const TRect &aRect,TInt aHandle,const TRect &aSrcRect);
  1489 	TInt handle;
  1490 	TRect rect;
  1491 	TRect srcRect;
  1492 	};
  1493 struct TWsGcCmdDrawBitmapMasked
  1494 	{
  1495 	inline TWsGcCmdDrawBitmapMasked(const TRect &aDestRect,TInt aHandle,const TRect& aSrcRect,TInt aMaskHandle,TBool aInvertMask);
  1496 	TInt iHandle;
  1497 	TInt iMaskHandle;
  1498 	TRect iRect;
  1499 	TRect iSrcRect;
  1500 	TBool iInvertMask;
  1501 	};
  1502 struct TWsGcCmdDrawBitmapLocal
  1503 	{
  1504 	inline TWsGcCmdDrawBitmapLocal(const TPoint &aPos,const CFbsBitmap *aBitmap);
  1505 	const CFbsBitmap *bitmap;
  1506 	TPoint pos;
  1507 	};
  1508 struct TWsGcCmdDrawBitmap2Local
  1509 	{
  1510 	inline TWsGcCmdDrawBitmap2Local(const TRect &aRect,const CFbsBitmap *aBitmap);
  1511 	const CFbsBitmap *bitmap;
  1512 	TRect rect;
  1513 	};
  1514 struct TWsGcCmdDrawBitmap3Local
  1515 	{
  1516 	inline TWsGcCmdDrawBitmap3Local(const TRect &aRect,const CFbsBitmap *aBitmap, const TRect &aSrcRect);
  1517 	const CFbsBitmap *bitmap;
  1518 	TRect rect;
  1519 	TRect srcRect;
  1520 	};
  1521 struct TWsGcCmdDrawBitmapMaskedLocal
  1522 	{
  1523 	inline TWsGcCmdDrawBitmapMaskedLocal(const TRect &aDestRect,const CFbsBitmap* aBitmap,const TRect& aSrcRect,const CFbsBitmap* aMaskBitmap,TBool aInvertMask);
  1524 	const CFbsBitmap* iBitmap;
  1525 	const CFbsBitmap* iMaskBitmap;
  1526 	TRect iRect;
  1527 	TRect iSrcRect;
  1528 	TBool iInvertMask;
  1529 	};
  1530 struct TWsGcCmdCopyRect
  1531 	{
  1532 	inline TWsGcCmdCopyRect(const TPoint &anOffset,const TRect &aRect);
  1533 	TRect rect;		// Must be first
  1534 	TPoint pos;
  1535 	};
  1536 struct TWsGcCmdGdiBlt2
  1537 	{
  1538 	inline TWsGcCmdGdiBlt2(const TPoint &aPoint, TInt aHandle);
  1539 	TInt handle;
  1540 	TPoint pos;
  1541 	};
  1542 struct TWsGcCmdGdiBlt3
  1543 	{
  1544 	inline TWsGcCmdGdiBlt3(const TPoint &aPoint, TInt aHandle, const TRect &aSrcRect);
  1545 	TInt handle;
  1546 	TPoint pos;
  1547 	TRect rect;
  1548 	};
  1549 struct TWsGcCmdGdiBlt2Local
  1550 	{
  1551 	inline TWsGcCmdGdiBlt2Local(const TPoint &aPoint,const CFbsBitmap *aBitmap);
  1552 	const CFbsBitmap *bitmap;
  1553 	TPoint pos;
  1554 	};
  1555 struct TWsGcCmdGdiBlt3Local
  1556 	{
  1557 	inline TWsGcCmdGdiBlt3Local(const TPoint &aDestination,const CFbsBitmap *aBitmap,const TRect &aSource);
  1558 	const CFbsBitmap *bitmap;
  1559 	TPoint pos;
  1560 	TRect rect;
  1561 	};
  1562 struct TWsGcCmdGdiBltMaskedLocal
  1563 	{
  1564 	inline TWsGcCmdGdiBltMaskedLocal(const TPoint& aPoint,const CFbsBitmap* aBitmap,const TRect& aSourceRect,const CFbsBitmap* aMaskBitmap,TBool aInvertMask);
  1565 	const CFbsBitmap *bitmap;
  1566 	const CFbsBitmap *maskBitmap;
  1567 	TBool invertMask;
  1568 	TPoint pos;
  1569 	TRect rect;
  1570 	};
  1571 struct TWsGcCmdUsePatternBrush
  1572     {
  1573     TRgb *pdata;
  1574     TInt width;
  1575     TInt height;
  1576     TBool color;
  1577 	};
  1578 struct TWsGcCmdBltMasked
  1579 	{
  1580 	inline TWsGcCmdBltMasked();
  1581 	inline TWsGcCmdBltMasked(const TPoint& aPoint,TInt aBitmap,const TRect& aSourceRect,TInt aMaskBitmap,TBool aInvertMask);
  1582 	TPoint destination;
  1583 	TInt handle;
  1584 	TRect source;
  1585 	TInt maskHandle;
  1586 	TBool invertMask;
  1587 	};
  1588 struct TWsGcCmdAlphaBlendBitmaps
  1589 	{
  1590 	inline TWsGcCmdAlphaBlendBitmaps();
  1591 	inline TWsGcCmdAlphaBlendBitmaps(const TPoint& aPoint, TInt aBitmap,const TRect& aSourceRect,TInt aAlpha,const TPoint& aAlphaPoint);
  1592 	TPoint point;
  1593 	TInt bitmapHandle;
  1594 	TRect source;
  1595 	TInt alphaHandle;
  1596 	TPoint alphaPoint;
  1597 	};
  1598 
  1599 struct TWsGcCmdAlphaBlendBitmapsLocal
  1600 	{
  1601 	inline TWsGcCmdAlphaBlendBitmapsLocal(const TPoint& aPoint, const CFbsBitmap* aBitmap, const TRect& aSourceRect, const CFbsBitmap* aAlpha, const TPoint& aAlphaPoint);
  1602 	TPoint point;
  1603 	const CFbsBitmap *iBitmap;
  1604 	TRect source;
  1605 	const CFbsBitmap *iAlpha;
  1606 	TPoint alphaPoint;
  1607 	};
  1608 	
  1609 struct TWsGcCmdMapColors
  1610 	{
  1611 	inline TWsGcCmdMapColors(const TRect &aRect, TInt aNumPairs, TBool aMapForwards);
  1612 	TRect rect;
  1613 	TInt numPairs;
  1614 	TBool mapForwards;
  1615 	};
  1616 	
  1617 struct TWsGcCmdMapColorsLocal
  1618 	{
  1619 	inline TWsGcCmdMapColorsLocal(const TRect &aRect, const TRgb* aColors, TInt aNumPairs, TBool aMapForwards);
  1620 	TRect rect;
  1621 	const TRgb *colors;
  1622 	TInt numPairs;
  1623 	TBool mapForwards;
  1624 	};
  1625 	
  1626 struct TWsGcCmdDrawWsGraphic
  1627 	{
  1628 	inline TWsGcCmdDrawWsGraphic(const TWsGraphicId& aId,const TRect& aRect);
  1629 	TUint iFlags; // TWsGraphicBitFlags
  1630 	TInt iId;
  1631 	TRect iRect;
  1632 	TInt iDataLen;
  1633 	};
  1634 struct TWsGcCmdDrawTextInContext
  1635 	{
  1636 	inline TWsGcCmdDrawTextInContext(const TPoint &aPos, TInt aLength, TInt aStart, TInt aEnd);
  1637 	TPoint pos;
  1638 	TInt length;
  1639 	TInt start;
  1640 	TInt end;
  1641 	};
  1642 struct TWsGcCmdDrawTextInContextPtr
  1643 	{
  1644 	TPoint pos;
  1645 	TDesC *text;
  1646 	TInt start;
  1647 	TInt end;
  1648 	};
  1649 struct TWsGcCmdDrawTextInContextVertical
  1650 	{
  1651 	inline TWsGcCmdDrawTextInContextVertical(const TPoint &aPos, TInt aLength, TBool aUp, TInt aStart, TInt aEnd);
  1652 	TPoint pos;
  1653 	TInt length;
  1654 	TBool up;
  1655 	TInt start;
  1656 	TInt end;
  1657 	};
  1658 struct TWsGcCmdDrawTextInContextVerticalPtr
  1659 	{
  1660 	TPoint pos;
  1661 	TBool up;
  1662 	TDesC *text;
  1663 	TInt start;
  1664 	TInt end;
  1665 	inline TWsGcCmdDrawTextInContextVerticalPtr(const TDesC *aDesc, const TPoint& aPos, const TBool aUp, const TInt aStart, const TInt aEnd);
  1666 	};
  1667 struct TWsGcCmdDrawTextInContextLocal
  1668 	{
  1669 	inline TWsGcCmdDrawTextInContextLocal(const TPoint &aPos,const TDesC *aDesc,const TInt aStart,const TInt aEnd);
  1670 	TPoint pos;
  1671 	const TDesC *desc;
  1672 	TInt start;
  1673 	TInt end;
  1674 	};
  1675 struct TWsGcCmdBoxTextInContextOptimised1
  1676 	{
  1677 	inline TWsGcCmdBoxTextInContextOptimised1(const TRect &aRect,TInt aBaselineOffset,TInt alength, TInt aStart, TInt aEnd);
  1678 	TRect box;
  1679 	TInt baselineOffset;
  1680 	TInt length;
  1681 	TInt start;
  1682 	TInt end;
  1683 	};
  1684 struct TWsGcCmdBoxTextInContextOptimised2
  1685 	{
  1686 	inline TWsGcCmdBoxTextInContextOptimised2(const TRect &aRect,TInt aBaselineOffset,CGraphicsContext::TTextAlign aHoriz,TInt aLeftMrg,TInt aLength, TInt aStart, TInt aEnd);
  1687 	TRect box;
  1688 	TInt baselineOffset;
  1689 	CGraphicsContext::TTextAlign horiz;
  1690 	TInt leftMrg;
  1691 	TInt length;
  1692 	TInt start;
  1693 	TInt end;
  1694 	};
  1695 struct TWsGcCmdBoxTextInContext
  1696 	{
  1697 	inline TWsGcCmdBoxTextInContext(const TRect &aRect,TInt aBaselineOffset,CGraphicsContext::TTextAlign aHoriz,TInt aLeftMrg,TInt aLength,TInt aWidth, TInt aStart, TInt aEnd);
  1698 	TRect box;
  1699 	TInt baselineOffset;
  1700 	CGraphicsContext::TTextAlign horiz;
  1701 	TInt leftMrg;
  1702 	TInt length;
  1703 	TInt width;
  1704 	TInt start;
  1705 	TInt end;
  1706 	};
  1707 struct TWsGcCmdBoxTextInContextPtr
  1708 	{
  1709 	TRect box;
  1710 	TInt baselineOffset;
  1711 	CGraphicsContext::TTextAlign horiz;
  1712 	TInt leftMrg;
  1713 	TInt width;
  1714 	TDesC *text;
  1715 	TInt start;
  1716 	TInt end;
  1717 	};
  1718 struct TWsGcCmdBoxTextInContextVertical
  1719 	{
  1720 	inline TWsGcCmdBoxTextInContextVertical(const TRect& aBox);
  1721 	TRect box;
  1722 	TInt baselineOffset;
  1723 	TBool up;
  1724 	CGraphicsContext::TTextAlign vert;
  1725 	TInt margin;
  1726 	TInt length;
  1727 	TInt width;
  1728 	TInt start;
  1729 	TInt end;
  1730 	};
  1731 struct TWsGcCmdBoxTextInContextVerticalPtr
  1732 	{
  1733 	TRect box;
  1734 	TInt baselineOffset;
  1735 	TBool up;
  1736 	CGraphicsContext::TTextAlign vert;
  1737 	TInt margin;
  1738 	TInt width;
  1739 	TInt start;
  1740 	TInt end;
  1741 	TDesC *text;
  1742 	};
  1743 struct TWsGcCmdBoxTextInContextLocal
  1744 	{
  1745 	inline TWsGcCmdBoxTextInContextLocal(const TRect &aBox,TInt aStart,TInt aEnd);
  1746 	TRect box;
  1747 	TInt baselineOffset;
  1748 	CGraphicsContext::TTextAlign horiz;
  1749 	TInt leftMrg;
  1750 	TInt start;
  1751 	TInt end;
  1752 	const TDesC *desc;
  1753 	};
  1754 struct TWsGcCmdDrawResourceToPos
  1755 	{
  1756 	inline TWsGcCmdDrawResourceToPos(TInt aWsHandle, const TPoint &aPos, CWindowGc::TGraphicsRotation aRotation);
  1757 	TInt wsHandle;
  1758 	TPoint pos;
  1759 	CWindowGc::TGraphicsRotation rotation;
  1760 	};
  1761 struct TWsGcCmdDrawResourceToRect
  1762 	{
  1763 	inline TWsGcCmdDrawResourceToRect(TInt aWsHandle, const TRect &aRect, CWindowGc::TGraphicsRotation aRotation);
  1764 	TInt wsHandle;
  1765 	TRect rect;
  1766 	CWindowGc::TGraphicsRotation rotation;
  1767 	};
  1768 struct TWsGcCmdDrawResourceFromRectToRect
  1769 	{
  1770 	inline TWsGcCmdDrawResourceFromRectToRect(TInt aWsHandle, const TRect &aRectDest, const TRect &aRectSrc, CWindowGc::TGraphicsRotation aRotation);
  1771 	TInt wsHandle;
  1772 	TRect rectDest;
  1773 	TRect rectSrc;
  1774 	CWindowGc::TGraphicsRotation rotation;
  1775 	};
  1776 struct TWsGcCmdDrawResourceWithData
  1777 	{
  1778 	inline TWsGcCmdDrawResourceWithData(TInt aWsHandle, const TRect &aRect, const TDesC8* aDesc);
  1779 	TInt wsHandle;
  1780 	TRect rect;
  1781 	const TDesC8* desc;
  1782 	};
  1783 
  1784 union TWsGcCmdUnion
  1785 	{
  1786 	const TAny *any;
  1787 	const TAny **pAny;
  1788 	const TRect *Rect;
  1789 	const TUint *UInt;
  1790 	const TInt *Int;
  1791 	const TInt *handle;
  1792 	const TBool *Bool;
  1793 	const TRgb *rgb;
  1794 	const TPoint *Point;
  1795 	const TSize *Size;
  1796 	const TFontUnderline *SetUnderlineStyle;
  1797 	const TFontStrikethrough *SetStrikethroughStyle;
  1798 	const TWsGcCmdDrawText *DrawText;
  1799 	const TWsGcCmdDrawTextInContext *DrawTextInContext;
  1800 	const TWsGcCmdDrawTextVertical *DrawTextVertical;
  1801 	const TWsGcCmdDrawTextInContextVertical *DrawTextInContextVertical;
  1802 	const TWsGcCmdDrawLine *DrawLine;
  1803 	const TWsGcCmdDrawPolyLine *PolyLine;
  1804 	const TWsGcCmdStartSegmentedDrawPolygon *StartSegmentedDrawPolygon;
  1805 	const TWsGcCmdSegmentedDrawPolygonData *SegmentedDrawPolygonData;
  1806 	const TWsGcCmdDrawSegmentedPolygon *DrawSegmentedPolygon;
  1807 	const TWsGcCmdDrawPolygonLocal *DrawPolygonLocal;
  1808 	const TWsGcCmdDrawPolygonLocalBufLen *DrawPolygonLocalBufLen;
  1809 	const TWsGcCmdDrawPolyLineLocalBufLen *DrawPolyLineLocalBufLen;
  1810 	const TWsGcCmdDrawArcOrPie *ArcOrPie;
  1811 	const TWsGcCmdDrawRoundRect *RoundRect;
  1812 	const TWsGcCmdDrawPolygon *Polygon;
  1813 	const TWsGcCmdDrawBitmap *Bitmap;
  1814 	const TWsGcCmdDrawBitmap2 *Bitmap2;
  1815 	const TWsGcCmdDrawBitmap3 *Bitmap3;
  1816 	const TWsGcCmdDrawBitmapMasked* iBitmapMasked;
  1817 	const TWsGcCmdCopyRect *CopyRect;
  1818 	const TWsGcCmdGdiBlt2 *GdiBlt2;
  1819 	const TWsGcCmdGdiBlt3 *GdiBlt3;
  1820 	const TWsGcCmdUsePatternBrush *UsePatternBrush;
  1821 	const TWsGcCmdBltMasked *GdiBltMasked;
  1822 	const TWsGcCmdSetClippingRegion *SetClippingRegion;
  1823 	const TWsGcCmdBoxText *BoxText;
  1824 	const TWsGcCmdBoxTextInContext *BoxTextInContext;
  1825 	const TWsGcCmdBoxTextOptimised1 *BoxTextO1;
  1826 	const TWsGcCmdBoxTextOptimised2 *BoxTextO2;
  1827 	const TWsGcCmdBoxTextInContextOptimised1 *BoxTextInContextO1;
  1828 	const TWsGcCmdBoxTextInContextOptimised2 *BoxTextInContextO2;
  1829 	const TWsGcCmdDrawTextLocal *DrawTextLocal;
  1830 	const TWsGcCmdDrawTextInContextLocal *DrawTextInContextLocal;
  1831 	const TWsGcCmdBoxTextVertical *DrawBoxTextVertical;
  1832 	const TWsGcCmdBoxTextInContextVertical *DrawBoxTextInContextVertical;
  1833 	const TWsGcCmdBoxTextLocal *BoxTextLocal;
  1834 	const TWsGcCmdBoxTextInContextLocal *BoxTextInContextLocal;
  1835 	const TWsGcCmdGdiBlt2Local *GdiBlt2Local;
  1836 	const TWsGcCmdGdiBlt3Local *GdiBlt3Local;
  1837 	const TWsGcCmdGdiBltMaskedLocal *GdiBltMaskedLocal;
  1838 	const TWsGcCmdDrawBitmapLocal *BitmapLocal;
  1839 	const TWsGcCmdDrawBitmap2Local *Bitmap2Local;
  1840 	const TWsGcCmdDrawBitmap3Local *Bitmap3Local;
  1841 	const TWsGcCmdDrawBitmapMaskedLocal* iBitmapMaskedLocal;
  1842 	const CArrayFix<TPoint> *PointList;
  1843 	const TWsGcCmdSetJustification *SetJustification;
  1844 	const TWsGcCmdMapColors *MapColors;
  1845 	TWsGcCmdDrawTextPtr *DrawTextPtr;
  1846 	TWsGcCmdDrawTextVerticalPtr *DrawTextVerticalPtr;
  1847 	TWsGcCmdDrawTextInContextVerticalPtr *DrawTextInContextVerticalPtr;
  1848 	TWsGcCmdBoxTextPtr *DrawBoxTextPtr;
  1849 	TWsGcCmdBoxTextInContextPtr *DrawBoxTextInContextPtr;
  1850 	TWsGcCmdBoxTextVerticalPtr *DrawBoxTextVerticalPtr;
  1851 	TWsGcCmdBoxTextInContextVerticalPtr *DrawBoxTextInContextVerticalPtr;
  1852 	TWsGcCmdDrawTextInContextPtr *DrawTextInContextPtr;
  1853 	const TWsGcLargeStruct *LargeStruct;
  1854 	const TWsGcCmdAlphaBlendBitmaps *AlphaBlendBitmaps;
  1855 	const TWsGcCmdAlphaBlendBitmapsLocal *AlphaBlendBitmapsLocal;
  1856 	const TWsGcCmdMapColorsLocal *MapColorsLocal;
  1857 	const TWsGcCmdDrawWsGraphic* WsGraphic;
  1858 	const TWsGcCmdDrawResourceToPos* DrawWsResourceToPos;
  1859 	const TWsGcCmdDrawResourceToRect* DrawWsResourceToRect;
  1860 	const TWsGcCmdDrawResourceFromRectToRect* DrawWsResourceFromRectToRect;
  1861 	const TWsGcCmdDrawResourceWithData* DrawWsResourceWithData;
  1862 	};
  1863 
  1864 struct TWsSdCmdSetScreenRotation
  1865 	{
  1866 	inline TWsSdCmdSetScreenRotation(TInt aMode, CFbsBitGc::TGraphicsOrientation aRotation);
  1867 	TInt mode;
  1868 	CFbsBitGc::TGraphicsOrientation rotation;
  1869 	};
  1870 struct TWsSdCmdGetScanLine
  1871 	{
  1872 	inline TWsSdCmdGetScanLine(const TPoint &aPos, TInt aLen, TDisplayMode aDispMode);
  1873 	TPoint pos;
  1874 	TInt len;
  1875 	TDisplayMode dispMode;
  1876 	};
  1877 struct TWsSdCmdRectCompare
  1878 	{
  1879 	inline TWsSdCmdRectCompare(const TRect &aRect1,const TRect &aRect2,TUint aFlags);
  1880 	TRect rect1;
  1881 	TRect rect2;
  1882 	TUint flags;
  1883 	};
  1884 struct TWsSdCmdCopyScreenToBitmap
  1885 	{
  1886 	inline TWsSdCmdCopyScreenToBitmap(TInt aHandle);
  1887 	TInt handle;
  1888 	};
  1889 struct TWsSdCmdCopyScreenToBitmap2
  1890 	{
  1891 	inline TWsSdCmdCopyScreenToBitmap2(const TRect &aRect, TInt aHandle);
  1892 	TRect rect;
  1893 	TInt handle;
  1894 	};
  1895 struct TWsSdCmdSetPalette
  1896 	{
  1897 	inline TWsSdCmdSetPalette(TPtr8& aPtr);
  1898 	TPtr8* ptr;
  1899 	TInt length;
  1900 	};
  1901 struct TWsSdCmdMapCoordinates
  1902 	{
  1903 	inline TWsSdCmdMapCoordinates(const TRect &aSource, TCoordinateSpace aSourceSpace, TCoordinateSpace aTargetSpace);
  1904 	TRect sourceRect;
  1905 	TCoordinateSpace sourceSpace;
  1906 	TCoordinateSpace targetSpace;
  1907 	};
  1908 union TWsSdCmdUnion
  1909 	{
  1910 	const TAny *any;
  1911 	const TAny **pAny;
  1912 	const TUint *UInt;
  1913 	const TInt *Int;
  1914 	const TPoint *Point;
  1915 	const TPixelsTwipsAndRotation *PixelsTwipsAndRotation;
  1916 	const TPixelsAndRotation *PixelsAndRotation;
  1917 	const TWsSdCmdSetScreenRotation *SetScreenRotation;
  1918 	const TWsSdCmdGetScanLine *GetScanLine;
  1919 	const TWsSdCmdRectCompare *RectCompare;
  1920 	const TWsSdCmdCopyScreenToBitmap *CopyScreenToBitmap;
  1921 	const TWsSdCmdCopyScreenToBitmap2 *CopyScreenToBitmap2;
  1922 	const TWsSdCmdSetPalette *SetPalette;
  1923 	const TSizeMode *ScreenSizeMode;
  1924 	const TDisplayConfiguration *DisplayConfiguration;
  1925 	const TWsSdCmdMapCoordinates *MapCoordinates;
  1926 	};
  1927 
  1928 union TWsAnimDllCmdUnion 
  1929 	{
  1930 	const TAny *any;
  1931 	const TUint *UInt;
  1932 	};
  1933 
  1934 struct TWsSpriteCmdUpdateMember
  1935 	{
  1936 	inline TWsSpriteCmdUpdateMember(TInt aIndex,const TSpriteMember &aData);
  1937 	TInt index;
  1938 	TCmdSpriteMember data;
  1939 	};
  1940 union TWsSpriteCmdUnion
  1941 	{
  1942 	const TAny *any;
  1943 	const TPoint *Point;
  1944 	const TCmdSpriteMember *SpriteMember;
  1945 	const TWsSpriteCmdUpdateMember *UpdateMember;
  1946 	};
  1947 
  1948 struct TWsDirectCmdRequestReply
  1949 	{
  1950 	inline TWsDirectCmdRequestReply();
  1951 	inline TWsDirectCmdRequestReply(TThreadId aId,TRequestStatus* aRequest);
  1952 	TThreadId id;
  1953 	TRequestStatus* request;
  1954 	};
  1955 union TWsDirectCmdUnion
  1956 	{
  1957 	const TAny *any;
  1958 	const TInt *Int;
  1959 	};
  1960 
  1961 union TWsClickCmdUnion
  1962 	{
  1963 	const TAny *any;
  1964 	const TInt *Int;
  1965 	const TBool *Bool;
  1966 	};
  1967 
  1968 // Client side Panics and asserts
  1969 
  1970 enum TW32Assert	// used for w32 code errors
  1971 	{
  1972 	EW32AssertOddLengthData,
  1973 	EW32AssertNotImplemented,
  1974 	EW32AssertIllegalOpcode,
  1975 	EW32AssertDirectMisuse,
  1976 	EW32AssertBufferLogic,
  1977 	EW32AssertUnexpectedOutOfRangePointerNumber, // Used for an out-of-range pointer number error within the old API's which doesn't take a pointer number.
  1978 	EW32AssertWindowSizeCacheFailure,
  1979 	};
  1980 
  1981 enum TW32Panic // used for application errors
  1982 	{
  1983 	EW32PanicReConnect,		//An attempt was made to reconnect to the window server using RWsSession::Connect() without having closed the existing one first
  1984 	EW32PanicWindowAlreadyClosed,		//Not used
  1985 	EW32PanicGcAlreadyClosed,		//Not used
  1986 	EW32PanicPaletteAlreadyClosed,		//Not used
  1987 	EW32PanicMapColorsTooManyPairs,		//Raised by CWindowGc::MapColors() when its aNumPairs argument has a value greater than 16.
  1988 	EW32PanicDataExceedsBufferLength,		//A single string is too long to fit into the buffer.
  1989 	EW32PanicNullPalette,		//CWsScreenDevice::SetCustomPalette() was called with a NULL pointer.
  1990 	EW32PanicSilentFail,		//The caller would not know that the function was not successful
  1991 	EW32PanicDirectMisuse,		//A direct screen access function is being called out of turn
  1992 	EW32PanicInvalidRegion,        //An attempt to pass an invalid region to window server
  1993 	EW32PanicUsingReservedIpcSlot,		//Raised when the Client is trying to use a wrong IpcSlot. The first slot if raised by: RAnim::CommandReply or RAnimDll::Construct. Either the first or the second if raised by RAnim::AsyncCommandReply
  1994 	EW32PanicNullArray,        //A Function has been called with a NULL array pointer when it should not be
  1995 	EW32PanicGraphicAlreadyConstructed,        //Not used
  1996 	EW32PanicGraphicOrphaned,		//The CWsGraphic::CManager's RPointerArray<CWsGraphic> has still pointers to CWsGraphic left inside when it should be empty
  1997 	EW32PanicGraphicInternal,		//Raised when one of the CWsGraphic::CManager's member has an inconsistent value (i.e. NULL when it should not be and viceversa)
  1998 	EW32PanicGraphicBadBuffer,		//Raised if RWsGraphicMsgBuf has been passed an out of bounds index or an incorret type message
  1999 	EW32PanicGraphicNullData,		//Raised when trying to send an empty TWsClCmdGdSendMessage
  2000 	EW32PanicFunctionNotSupported,	//Operation not supported in the current OS distribution
  2001 	EW32PanicInvalidParameter,		// Raised when an invalid parameter is passed to a function 
  2002 	EW32PanicGraphicDoubleConstruction,		//Raised when Construct() is called on an already constructed client-side object
  2003 	EW32PanicBadClientInterface,	//Debug: Trying to use an interface that is not initialised 
  2004 	EW32PanicSizeNotExpected,		//Debug: Returned data does not match expected sizes or granularity
  2005 	EW32PanicStringTooLong,			//A string is longer than it is allowed to be
  2006 	};
  2007 
  2008 enum WservShutdown
  2009 	{EWservShutdownCheck=0x13572468};	// Parameter to EWservMessShutdown to stop accidental shutdowns
  2010 
  2011 enum WservMessages
  2012 	{
  2013 	EWservMessCommandBuffer,
  2014 	EWservMessShutdown,
  2015 	EWservMessInit,
  2016 	EWservMessFinish,	
  2017 	EWservMessSyncMsgBuf,
  2018 	EWservMessAsynchronousService=0x010000,
  2019 	EWservMessAnimDllAsyncCommand=0x100000,
  2020 	};
  2021 
  2022 enum WH_HANDLES
  2023 	{
  2024 	WS_HANDLE_ROOT_WINDOW,
  2025 	WS_HANDLE_CLIENT,
  2026 	WS_HANDLE_WINDOW,
  2027 	WS_HANDLE_GROUP_WINDOW,
  2028 	WS_HANDLE_GC,
  2029 	WS_HANDLE_CAPTURE_KEY,
  2030 	WS_HANDLE_ANIM_DLL,
  2031 	WS_HANDLE_SCREEN_DEVICE,
  2032 	WS_HANDLE_SPRITE,
  2033 	WS_HANDLE_POINTER_CURSOR,
  2034 	WS_HANDLE_BITMAP,
  2035 	WS_HANDLE_DIRECT,
  2036 	WS_HANDLE_CLICK,
  2037 	WS_HANDLE_TEXT_CURSOR,
  2038 	WS_HANDLE_GRAPHIC_DRAWER,
  2039 	WS_HANDLE_DRAWABLE_SOURCE,
  2040 	WS_HANDLE_CAPTURE_KEY_UPDOWNS,
  2041 	WS_HANDLE_CAPTURE_LONG_KEY,
  2042 	};
  2043 
  2044 enum TClientPanic
  2045 	{
  2046 	EWservNoPanic=0,						// Dummy Value used to indicate no panic
  2047 	EWservPanicOpcode=1,					// Out of range opcode
  2048 	EWservPanicBuffer=2,					// Invalid command buffer
  2049 	EWservPanicHandle=3,					// Invalid handle
  2050 	EWservPanicNullHandle=4,				// Null handle given as a handle value
  2051 	EWservPanicDrawable=5,					// Invalid drawable handle
  2052 	EWservPanicWindow=6,					// Invalid window handle
  2053 	EWservPanicBitmap=7,					// Invalid bitmap handle
  2054 	EWservPanicReadOutstanding=8,			// Event read already outstanding
  2055 	EWservPanicGcNotActive=9,				// Tried use a non-active GC
  2056 	EWservPanicGcActive=10,					// Tried to activate an already active GC
  2057 	EWservPanicWindowActive=11,				// Window already active
  2058 	EWservPanicRedrawActive=12,				// Already inside a begin/end redraw pair
  2059 	EWservPanicFont=13,						// Invalid font handle
  2060 	EWservPanicNoFont=14,					// Printing with no active font
  2061 	EWservPanicInvalidTextCursor=15,		// Tried to set invalid text cursor type
  2062 	EWservPanicReadOnlyDrawable=16,			// Attempted to write to a read only drawable
  2063 	EWservPanicInvalidRgb=17,				// Invalid RGB passed to window server
  2064 	EWservPanicPatternBrush=18,				// Invalid pattern brush
  2065 	EWservPanicNoBrush=19,					// Trying to paint without a brush
  2066 	EWservPanicUninitialisedBitmap=20,		// Trying to use an uninitialised bitmap
  2067 	EWservPanicDestroy=21,					// Trying to do a client destroy function on an illegal handle
  2068 	EWservPanicAnimDll=22,					// Panic from Animator DLL
  2069 	EWservPanicAnim=23,						// Invalid Anim object handle
  2070 	EWservPanicAnimLeave=24,				// Leave from a non-leaving anim function
  2071 	EWservPanicKeyOfDeath=25,				// Killed by the key of death!!!!
  2072 	EWservPanicTmpFont=26,					// Tried to reuse tmp font
  2073 	EWservPanicNoTmpFont=27,				// Tried to free tmp font when not allocated
  2074 	EWservPanicBadPolyData=28,				// Inconsistent polygon/polyline data
  2075 	EWservPanicNegativeShadowHeight=29,		// Tried to set a negative shadow height
  2076 	EWservPanicRedrawToNonRedrawWindow=30,	// Tried to redraw a non-redrawable window
  2077 	EWservPanicRedrawType=31,				// Init message contained invalid redraw type
  2078 	EWservPanicInvalidRegionCount=32,		// InvalidRegion was passed a zero count
  2079 	EWservPanicNoReplyBuffer=33,			// No reply buffer was passed to a function that requires one
  2080 	EWservPanicBackedUpWindowGcActive=34,	// Attempting to reactive a backed up window's GC
  2081 	EWservPanicCornerParams=35,				// Invalid corner type or flags
  2082 	EWservPanicBitmapAccess=36,				// Bitmap access not enabled on a backed up window
  2083 	EWservPanicDescriptor=37,				// Bad descriptor passed
  2084 	EWservPanicWindowDestroyed=38,			// Accessing a sprite after it's window has been destroyed
  2085 	EWservPanicUnsignalledEventData=39,		// A request for event data without a signal for that data being made
  2086 	EWservPanicMaskSize=40,					// The mask for a sprite is smaller then the bitmap
  2087 	EWservPanicSprite=41,					// bad sprite handle
  2088 	EWservPanicNotSystemPointerCursorListOwner=42,	 // Trying to set/clear a system pointer cursor when not owning the list
  2089 	EWservPanicNoPointerBuffer=43,			// Enabling the pointer buffer when there isn't one allocated
  2090 	EWservPanicBufferPtr=44,				// Invalid Buf,Len in the window server command buffer
  2091 	EWservPanicHotKey=45,					// Invalid hot key type
  2092 	EWservPanicPassword=46,					// Invalid call to PasswordEntered()
  2093 	EWservPanicSetComputeMode=47,			// Invalid value in call to SetComputeMode()
  2094 	EWservPanicBackupDisplayMode=48,		// Trying to set the display mode of a backed up window
  2095 	EWservPanicFetchMessage=49,				// Trying to fetch a message when one has not been signalled
  2096 	EWservPanicReInitialise=50,				// Client sent a second Init() message
  2097 	EWservPanicNoWindowSpecifed=51,			// Trying to get off messages without specifing a window to send them to
  2098 	EWservPanicParentDeleted=52,			// Setting size, pos or extent of a window whose parent or ancestor has been deleted
  2099 	EWservPanicResetingDefaultOwner=53,		// Calling the function RWindowGroup::DefaultOwningWindow() twice on the same group window
  2100 	EWservPanicScreenModeNumber=54,			// Calling an API function with an illegal screen size mode index
  2101 	EWservPanicScreenEnforcementMode=55,	// Illegal screen mode enforcement mode
  2102 	EWservPanicEventType=56,				// Must be a pointer event
  2103 	EWservPanicRotation=57,					// Not valid rotation
  2104 	EWservPanicNotTopClient=58,				// Can only call this on a window whoes parent is a group window
  2105 	EWservPanicDirectMisuse=59,				// Trying to do things to a Direct Screen Access object in the wrong order
  2106 	EWservPanicDuplicateHandle=60,			// Client Handle already in use
  2107 	EWservPanicNoCustomTextCursor=61,		// The custom text cursor has not been set
  2108 	EWservPanicCustomTextCursorAlign=62,	// Illegal custom text cursor allignment used
  2109 	EWservPanicNoSpriteMember=63,			// Use of a sprite that does not have any member set.
  2110 	EWservPanicTransparencyObjNotCreated=64,// Trying to set a transparency operation to a window that has not been enabled to be transparent.
  2111 	EWservPanicScreenNumber=65,				// Calling an multiple screen API function with an illegal screen number
  2112 	EWservPanicPermissionDenied=66,
  2113 	EWservPanicFunctionLeave=67,			// A leave occured while processing command in the middle of the buffer
  2114 	EWservPanicGroupWinScreenDeviceDeleted=68,	//Trying to use a group window with a deleted Screen Device
  2115 	EWservPanicDrawCommandsInvalidState=69,	//Redraw storing cannot be disabled for transparent window
  2116 	EWservPanicWsGraphic=70,				// Bad internal state in CWsGraphic code
  2117 	EWservPanicUninitialisedClient=71,	 	// Tried to use an uninitialised CWsClient
  2118 	EWservPanicNullMessageFromClient=72,		// Client IPC message is NULL
  2119 	EWservPanicTransparencyMisuse=73,		// Incompatible use of window transparency and background surface
  2120 	EWservPanic_Removed1=74,	// Panic removed in CR1489, can be reused
  2121 	EWservPanicInvalidSurface=75,			// An incorrect surface type has been used
  2122 	EWservPanicInvalidSurfaceConfiguration=76,	// Use of a surface configuration without valid members
  2123 	EWservPanic_Removed2=77,	// Panic removed in CR1489, can be reused
  2124 	EwservPanicIllegalDisplayMode=78,           // Illegal display mode is used
  2125 	EWservPanicWindowBeginRedrawNotCalled=79,   // A draw operation was performed on the CWindowGc outside a RWindow::BeginRedraw() / EndRedraw() pair. Enable AutoFlush to debug.
  2126 	EWservPanicInvalidParameter=80,             // General invalid parameter code for invariant checking
  2127 	EWservPanicDrawableSource=81,               // Invalid drawable source handle
  2128 	EWservPanicWrongScreen=82,                  // Child apps can only be constructed on the same screen as their parent. See RWindowGroup::ConstructChildApp
  2129 	EWservPanicScreenCaptureInvalidRequest=83,  // With Screen Capture disabled, an unexpected invalid request has been received
  2130 	EWservPanicInvalidDisplayConfiguration=84,  // Use of a display configuration without valid members
  2131 	EWservPanicUnableToEnableAdvPointer=85,     // Use when advanced pointers are enabled after an RWindow is activated
  2132 	};
  2133 
  2134 #if defined(__WINS__)
  2135 	// Under WINS character code is passed in as HIWORD of the scan code,
  2136 	// and will need to be removed in some situations
  2137 	#define __REMOVE_WINS_CHARCODE &0x0000FFFF
  2138 	#define __WINS_CHARCODE(c)	((c) & 0xFFFF0000)
  2139 #else
  2140 	#define __REMOVE_WINS_CHARCODE
  2141 #endif
  2142 
  2143 class CDebugLogBase: public CBase
  2144 	{
  2145 public:
  2146 	enum {EDummyConnectionId=0};		//This value is used to mean WSERV itself
  2147 	enum
  2148 		{
  2149 		ELogEverything=1,	// Gives the complete WSERV client server interaction along with client logging.
  2150 		ELogIntermediate=5,	// Gives the important WSERV client server interaction along with client logging.
  2151 		ELogImportant=9,	// Gives logging of panics and client logging.
  2152 		};
  2153 public:
  2154 	virtual void CommandBuf(TInt aApp)=0;
  2155 	virtual void Command(TInt aClass, TInt aOpcode, const TAny *aCmdData, TInt aHandle)=0;
  2156 	virtual void NewClient(TUint aConnectionHandle)=0;
  2157 	virtual void Reply(TInt aData)=0;
  2158 	virtual void ReplyBuf(const TDesC8 &aDes)=0;
  2159 	virtual void ReplyBuf(const TDesC16 &aDes)=0;
  2160 	virtual void SignalEvent(TInt aApp)=0;
  2161 	virtual void Panic(TInt aApp, TInt aReason)=0;
  2162 	virtual void MiscMessage(TInt aPriority,const TDesC &aFmt,TInt aParam=0)=0;
  2163 	virtual void HeapDump()=0;
  2164 	virtual void SetLoggingLevel(TInt aLevel)=0;
  2165 	virtual void IniFileSettingRead(TInt aScreen, const TDesC& aVarName, TBool aFound, const TDesC& aResult)=0;
  2166 	};
  2167 
  2168 inline TUint WservEncoding::Encode8BitValues(TUint8 aFirst,TUint8 aSecond)
  2169 	{return aSecond<<8|aFirst;}
  2170 inline TUint WservEncoding::Encode8BitValues(TUint8 aFirst,TUint8 aSecond,TUint8 aThird)
  2171 	{return aThird<<16|Encode8BitValues(aFirst,aSecond);}
  2172 inline TUint8 WservEncoding::ExtractFirst8BitValue(TUint aUint)
  2173 	{return STATIC_CAST(TUint8,aUint&KMaxTUint8);}
  2174 inline TUint8 WservEncoding::ExtractSecond8BitValue(TUint aUint)
  2175 	{return STATIC_CAST(TUint8,aUint>>8&KMaxTUint8);}
  2176 inline TUint8 WservEncoding::ExtractThird8BitValue(TUint aUint)
  2177 	{return STATIC_CAST(TUint8,aUint>>16);}
  2178 //
  2179 inline TWsClCmdCreateSprite::TWsClCmdCreateSprite(TInt aWindow, const TPoint &aPos, TUint aFlags) :
  2180 	window(aWindow),pos(aPos),flags(aFlags)
  2181 	{}
  2182 inline TWsClCmdSetWindowGroupOrdinalPosition::TWsClCmdSetWindowGroupOrdinalPosition(TInt aIdentifier, TInt aPosition) :
  2183 	identifier(aIdentifier),position(aPosition)
  2184 	{}
  2185 inline TWsClCmdSetKeyboardRepeatRate::TWsClCmdSetKeyboardRepeatRate(const TTimeIntervalMicroSeconds32 &aInitial,const TTimeIntervalMicroSeconds32 &aTime) :
  2186 	initial(aInitial), time(aTime)
  2187 	{}
  2188 inline TWsClCmdSetDoubleClick::TWsClCmdSetDoubleClick(const TTimeIntervalMicroSeconds32 &aInterval,TInt aDistance) :
  2189 	interval(aInterval), distance(aDistance)
  2190 	{}
  2191 inline TWsClCmdSendEventToWindowGroup::TWsClCmdSendEventToWindowGroup(TInt aParameter, const TWsEvent &aEvent) :
  2192 	parameter(aParameter), event(aEvent)
  2193 	{}
  2194 inline TWsClCmdFindWindowGroupIdentifier::TWsClCmdFindWindowGroupIdentifier(TInt aPreviousIdentifier,TInt aOffset,TInt aLength) :
  2195 	identifier(aPreviousIdentifier),offset(aOffset),length(aLength)
  2196 	{}
  2197 inline TWsClCmdSendMessageToWindowGroup::TWsClCmdSendMessageToWindowGroup(TInt aIdentifier, TUid aUid, TInt aDataLength, const TDesC8 *aPtr) :
  2198 	identifierOrPriority(aIdentifier), uid(aUid), dataLength(aDataLength), ptr(aPtr)
  2199 	{}
  2200 inline TWsClCmdFetchMessage::TWsClCmdFetchMessage(TInt aWindowGroupIdentifier) :
  2201 	windowGroupIdentifier(aWindowGroupIdentifier)
  2202 	{}
  2203 inline TWsClCmdFindWindowGroupIdentifierThread::TWsClCmdFindWindowGroupIdentifierThread(TInt aPreviousIdentifier,TThreadId aThreadId) :
  2204 	identifier(aPreviousIdentifier),threadId(aThreadId)
  2205 	{}
  2206 inline TWsClCmdGetWindowGroupNameFromIdentifier::TWsClCmdGetWindowGroupNameFromIdentifier(TInt aIdentifier,TInt aMaxLength) :
  2207 	identifier(aIdentifier),maxLength(aMaxLength)
  2208 	{}
  2209 inline TWsClCmdOffEventsToShell::TWsClCmdOffEventsToShell(TBool aOn,TUint32 aWindow) :
  2210 	on(aOn),window(aWindow)
  2211 	{}
  2212 inline TWsClCmdSetPointerCursorArea::TWsClCmdSetPointerCursorArea(TInt aMode,TRect aArea) :
  2213 	mode(aMode),area(aArea)
  2214 	{}
  2215 inline TWsClCmdSetSystemFaded::TWsClCmdSetSystemFaded(TBool aFaded, TBool aUseDefaults/*=ETrue*/, TUint8 aBlackMap/*=0*/, TUint8 aWhiteMap/*=0*/)
  2216 	{params=WservEncoding::Encode8BitValues(aBlackMap,aWhiteMap
  2217 			,STATIC_CAST(TUint8,(aFaded?EFaded:0)|(aUseDefaults?EUseDefaultMap:0)));}
  2218 inline TBool TWsClCmdSetSystemFaded::Faded() const
  2219 	{return WservEncoding::ExtractThird8BitValue(params)&EFaded;}
  2220 inline TBool TWsClCmdSetSystemFaded::UseDefaultMap() const
  2221 	{return WservEncoding::ExtractThird8BitValue(params)&EUseDefaultMap;}
  2222 inline void TWsClCmdSetSystemFaded::GetFadingParams(TUint8& aBlackMap,TUint8& aWhiteMap) const
  2223 	{aBlackMap=WservEncoding::ExtractFirst8BitValue(params);aWhiteMap=WservEncoding::ExtractSecond8BitValue(params);}
  2224 inline TWsClCmdDebugInfo::TWsClCmdDebugInfo(TInt aFunction, TInt aParam) : iFunction(aFunction), iParam(aParam)
  2225 	{}
  2226 #if defined(SYMBIAN_GRAPHICS_GCE)
  2227 inline TWsClCmdCreateDrawableSource::TWsClCmdCreateDrawableSource(const TSgDrawableId& aDrawableId, TInt aScreenNumber)
  2228 	: iDrawableId(aDrawableId), iScreenNumber(aScreenNumber)
  2229 	{}
  2230 inline TWsClCmdSurfaceRegister::TWsClCmdSurfaceRegister(TInt aScreenNumber, const TSurfaceId& aSurface):
  2231 	screenNumber(aScreenNumber), surfaceId(aSurface)
  2232 	{}
  2233 #endif
  2234 inline TWsWinCmdSetExtent::TWsWinCmdSetExtent(const TPoint &aPos,const TSize &aSize) :
  2235 	pos(aPos),size(aSize)
  2236 	{}
  2237 inline TWsWinCmdCaptureLongKey::TWsWinCmdCaptureLongKey()
  2238 	{}
  2239 inline TWsWinCmdCaptureLongKey::TWsWinCmdCaptureLongKey(TUint aModifiers,TUint aModifierMask,TUint aInputKey,TUint aOutputKey
  2240 																	,TTimeIntervalMicroSeconds32 aDelay,TInt aPriority,TUint aFlags) :
  2241 	modifiers(aModifiers),modifierMask(aModifierMask),inputKey(aInputKey),outputKey(aOutputKey)
  2242 																						,delay(aDelay),priority(aPriority),flags(aFlags)
  2243 	{}
  2244 inline TWsWinCmdScroll::TWsWinCmdScroll(const TRect &aClip,const TPoint &aOffset,const TRect &aRect) :
  2245 	clip(aClip), offset(aOffset), rect(aRect)
  2246 	{}
  2247 inline TWsWinCmdSetTextCursor::TWsWinCmdSetTextCursor(TUint32 aWindow, const TPoint &aPos, const TTextCursor &aCursor, const TRect &aRect) :
  2248 	window(aWindow), pos(aPos), cursor(aCursor), rect(aRect)
  2249 	{}
  2250 inline TWsWinCmdSetTextCursor::TWsWinCmdSetTextCursor(TUint32 aWindow, const TPoint &aPos, const TTextCursor &aCursor) :
  2251 	window(aWindow), pos(aPos), cursor(aCursor)
  2252 	{}
  2253 inline TWsWinCmdGrabControl::TWsWinCmdGrabControl(const TUint aGrabControlFlags)
  2254 : pointerNumber(KErrNotFound), flags(aGrabControlFlags)
  2255 	{}
  2256 inline TWsWinCmdGrabControl::TWsWinCmdGrabControl(const TUint8 aPointerNumber, const TUint aGrabControlFlags)
  2257 : pointerNumber(aPointerNumber), flags(aGrabControlFlags)
  2258 	{}
  2259 inline TBool TWsWinCmdGrabControl::CheckFlags(TUint aFlags) const
  2260 	{return (flags&aFlags)==aFlags;}
  2261 inline TBool TWsWinCmdGrabControl::HasPointerNumber() const
  2262 	{return KErrNotFound!=pointerNumber;}
  2263 
  2264 inline TWsWinCmdCancelPointerRepeatEventRequest::TWsWinCmdCancelPointerRepeatEventRequest()
  2265 :	pointerNumber(KErrNotFound), flags(TWsWinCmdCancelPointerRepeatEventRequest::ECancelRepeatFlagsNone)
  2266 	{}
  2267 inline TWsWinCmdCancelPointerRepeatEventRequest::TWsWinCmdCancelPointerRepeatEventRequest(const TUint8 aPointerNumber)
  2268 :	pointerNumber(aPointerNumber), flags(TWsWinCmdCancelPointerRepeatEventRequest::ECancelRepeatFlagsNone)
  2269 	{}
  2270 inline TWsWinCmdCancelPointerRepeatEventRequest::TWsWinCmdCancelPointerRepeatEventRequest(const TUint8 aPointerNumber, const TUint aFlags)
  2271 :	pointerNumber(aPointerNumber), flags(aFlags)
  2272 	{}
  2273 inline TBool TWsWinCmdCancelPointerRepeatEventRequest::HasPointerNumber() const
  2274 	{return KErrNotFound!=pointerNumber;}
  2275 inline TWsWinCmdRequestPointerRepeatEvent::TWsWinCmdRequestPointerRepeatEvent(const TTimeIntervalMicroSeconds32 &aTime,const TRect &aRect)
  2276 :	time(aTime),rect(aRect),pointerNumber(KErrNotFound),repeatFlags(ERepeatFlagsNone)
  2277 	{}
  2278 inline TWsWinCmdRequestPointerRepeatEvent::TWsWinCmdRequestPointerRepeatEvent(const TTimeIntervalMicroSeconds32 &aTime,const TRect &aRect,const TUint8 aPointerNumber, const TUint aRepeatFlags)
  2279 :	time(aTime),rect(aRect),pointerNumber(aPointerNumber),repeatFlags(aRepeatFlags)
  2280 	{}
  2281 inline TBool TWsWinCmdRequestPointerRepeatEvent::HasPointerNumber() const
  2282 	{return KErrNotFound!=pointerNumber;}
  2283 inline TWsClCmdZThresholdPair::TWsClCmdZThresholdPair(const TInt aEnterThreshold, const TInt aExitThreshold)
  2284 :	enterThreshold(aEnterThreshold),exitThreshold(aExitThreshold)
  2285 	{}
  2286 inline TWsClCmdSendEffectCommand::TWsClCmdSendEffectCommand(TInt aTfxCmd,TInt aTfxCmdDataLength, TInt aWinHandle) :
  2287     tfxCmd(aTfxCmd), tfxCmdDataLength(aTfxCmdDataLength), windowHandle(aWinHandle)
  2288 	{}
  2289 inline TWsClCmdRegisterEffect::TWsClCmdRegisterEffect(TInt aAction, TInt aPurpose, TInt aDirStrSize, TInt aPhase1StrSize, TInt aPhase2StrSize, TUint aAppUid, TBitFlags aFlags) :
  2290 	tfxAction(aAction), tfxPurpose(aPurpose), tfxDirStrSize(aDirStrSize), tfxPhase1StrSize(aPhase1StrSize), tfxPhase2StrSize(aPhase2StrSize), tfxAppUid(aAppUid), tfxFlags(aFlags) 
  2291 	{}
  2292 inline TWsClCmdUnRegisterEffect::TWsClCmdUnRegisterEffect(TInt aAction, TInt aPurpose, TUint aAppUid) :
  2293 	tfxAction(aAction), tfxPurpose(aPurpose), tfxAppUid(aAppUid)
  2294 	{}
  2295 inline TWsClCmdOverrideEffect::TWsClCmdOverrideEffect(TInt aAction, TInt aPurpose, TInt aDirStrSize, TInt aPhase1StrSize, TInt aPhase2StrSize, TBitFlags aFlags) :
  2296 	tfxAction(aAction), tfxPurpose(aPurpose), tfxDirStrSize(aDirStrSize), tfxPhase1StrSize(aPhase1StrSize), tfxPhase2StrSize(aPhase2StrSize), tfxFlags(aFlags)
  2297 	{}
  2298 inline TWsWinCmdAddKeyRect::TWsWinCmdAddKeyRect(const TRect &aRect,TInt aScanCode, TBool aActivatedByPointerSwitchOn) :
  2299 	rect(aRect), scanCode(aScanCode), activatedByPointerSwitchOn(aActivatedByPointerSwitchOn)
  2300 	{}
  2301 #if defined(SYMBIAN_GRAPHICS_GCE)
  2302 inline TWsWinOpSetBackgroundSurfaceConfig::TWsWinOpSetBackgroundSurfaceConfig(const TSurfaceConfiguration& aConfiguration, TBool aTriggerRedraw) :
  2303 	surfaceConfig(aConfiguration), triggerRedraw(aTriggerRedraw)
  2304 	{}
  2305 #endif
  2306 inline TWsWinCmdEnableModifierChangedEvents::TWsWinCmdEnableModifierChangedEvents(TUint aModifierMask, TEventControl aCircumstances) :
  2307 	modifierMask(aModifierMask), circumstances(aCircumstances)
  2308 	{}
  2309 inline TWsWinCmdSetFaded::TWsWinCmdSetFaded(TBool aFaded, TBool aIncludeChildren, TBool aUseDefaults/*=ETrue*/, TUint8 aBlackMap/*=0*/, TUint8 aWhiteMap/*=0*/)
  2310 	{params=WservEncoding::Encode8BitValues(aBlackMap,aWhiteMap
  2311 			,STATIC_CAST(TUint8,(aFaded?EFaded:0)|(aIncludeChildren?EIncludeChildren:0)|(aUseDefaults?EUseDefaultMap:0)));}
  2312 inline TBool TWsWinCmdSetFaded::Faded() const
  2313 	{return WservEncoding::ExtractThird8BitValue(params)&EFaded;}
  2314 inline TBool TWsWinCmdSetFaded::IncludeChildren() const
  2315 	{return WservEncoding::ExtractThird8BitValue(params)&EIncludeChildren;}
  2316 inline TBool TWsWinCmdSetFaded::UseDefaultMap() const
  2317 	{return WservEncoding::ExtractThird8BitValue(params)&EUseDefaultMap;}
  2318 inline void TWsWinCmdSetFaded::GetFadingParams(TUint8& aBlackMap,TUint8& aWhiteMap) const
  2319 	{aBlackMap=WservEncoding::ExtractFirst8BitValue(params);aWhiteMap=WservEncoding::ExtractSecond8BitValue(params);}
  2320 //
  2321 inline TWsGcCmdBoxTextVertical::TWsGcCmdBoxTextVertical(const TRect& aBox) : box(aBox)
  2322 	{}
  2323 inline TWsGcCmdBoxTextLocal::TWsGcCmdBoxTextLocal(const TRect &aBox) : box(aBox)
  2324 	{}
  2325 inline TWsGcCmdDrawTextLocal::TWsGcCmdDrawTextLocal(const TPoint &aPos,const TDesC *aDesc) :
  2326 	pos(aPos), desc(aDesc)
  2327 	{}
  2328 inline TWsGcCmdDrawLine::TWsGcCmdDrawLine(const TPoint &aPnt1,const TPoint &aPnt2) : pnt1(aPnt1),pnt2(aPnt2)
  2329 	{}
  2330 inline TWsGcCmdDrawArcOrPie::TWsGcCmdDrawArcOrPie(const TRect &aRect,const TPoint &aStart,const TPoint &aEnd) :
  2331 	rect(aRect),start(aStart),end(aEnd)
  2332 	{}
  2333 inline TWsGcCmdDrawText::TWsGcCmdDrawText(const TPoint &aPos, TInt aLength) : 
  2334 	pos(aPos),length(aLength)
  2335 	{}
  2336 inline TWsGcCmdDrawTextVertical::TWsGcCmdDrawTextVertical(const TPoint &aPos, TInt aLength, TBool aUp) : 
  2337 	pos(aPos),length(aLength),up(aUp)
  2338 	{}
  2339 inline TWsGcCmdBoxTextOptimised1::TWsGcCmdBoxTextOptimised1(const TRect &aRect, TInt aBaselineOffset,TInt aLength) :
  2340 	box(aRect),baselineOffset(aBaselineOffset),length(aLength)
  2341 	{}
  2342 inline TWsGcCmdBoxTextOptimised2::TWsGcCmdBoxTextOptimised2(const TRect &aRect,TInt aBaselineOffset,CGraphicsContext::TTextAlign aHoriz,TInt aLeftMrg,TInt aLength) :
  2343 	box(aRect),baselineOffset(aBaselineOffset),horiz(aHoriz),leftMrg(aLeftMrg),length(aLength)
  2344 	{}
  2345 inline TWsGcCmdBoxText::TWsGcCmdBoxText(const TRect &aRect,TInt aBaselineOffset,CGraphicsContext::TTextAlign aHoriz,TInt aLeftMrg,TInt aLength,TInt aWidth) :
  2346 	box(aRect),baselineOffset(aBaselineOffset),horiz(aHoriz),leftMrg(aLeftMrg),length(aLength),width(aWidth)
  2347 	{}
  2348 inline TWsGcCmdDrawRoundRect::TWsGcCmdDrawRoundRect(const TRect &aRect,const TSize &aEllipse) : rect(aRect), ellipse(aEllipse)
  2349 	{}
  2350 inline TWsGcCmdDrawPolygonLocalBufLen::TWsGcCmdDrawPolygonLocalBufLen(const TPoint *aPointList,TInt aNumPoints, CGraphicsContext::TFillRule aFillRule) :
  2351 	points(aPointList),length(aNumPoints),fillRule(aFillRule)
  2352 	{}
  2353 inline TWsGcCmdDrawPolyLineLocalBufLen::TWsGcCmdDrawPolyLineLocalBufLen(const TPoint *aPointList,TInt aNumPoints) :
  2354 	points(aPointList),length(aNumPoints)
  2355 	{}
  2356 inline TWsGcCmdDrawBitmap::TWsGcCmdDrawBitmap(const TPoint &aPoint,TInt aHandle) : handle(aHandle), pos(aPoint)
  2357 	{}
  2358 inline TWsGcCmdDrawBitmap2::TWsGcCmdDrawBitmap2(const TRect &aRect,TInt aHandle) : handle(aHandle), rect(aRect)
  2359 	{}
  2360 inline TWsGcCmdDrawBitmap3::TWsGcCmdDrawBitmap3(const TRect &aRect,TInt aHandle,const TRect &aSrcRect) :
  2361 	 handle(aHandle), rect(aRect), srcRect(aSrcRect)
  2362 	{}
  2363 inline TWsGcCmdDrawBitmapMasked::TWsGcCmdDrawBitmapMasked(const TRect &aDestRect,TInt aHandle,const TRect& aSrcRect,TInt aMaskHandle,TBool aInvertMask) :
  2364 	 iHandle(aHandle),iMaskHandle(aMaskHandle),iRect(aDestRect),iSrcRect(aSrcRect),iInvertMask(aInvertMask)
  2365 	 {}
  2366 inline TWsGcCmdDrawBitmapLocal::TWsGcCmdDrawBitmapLocal(const TPoint &aPos,const CFbsBitmap *aBitmap) :
  2367 	bitmap(aBitmap), pos(aPos)
  2368 	{}
  2369 inline TWsGcCmdDrawBitmap2Local::TWsGcCmdDrawBitmap2Local(const TRect &aRect,const CFbsBitmap *aBitmap) :
  2370 	bitmap(aBitmap), rect(aRect)
  2371 	{}
  2372 inline TWsGcCmdDrawBitmap3Local::TWsGcCmdDrawBitmap3Local(const TRect &aRect,const CFbsBitmap *aBitmap,const TRect &aSrcRect) :
  2373 	bitmap(aBitmap), rect(aRect), srcRect(aSrcRect)
  2374 	{}
  2375 inline TWsGcCmdDrawBitmapMaskedLocal::TWsGcCmdDrawBitmapMaskedLocal(const TRect &aDestRect,const CFbsBitmap* aBitmap,const TRect& aSrcRect,const CFbsBitmap* aMaskBitmap,TBool aInvertMask) :
  2376 	iBitmap(aBitmap),iMaskBitmap(aMaskBitmap),iRect(aDestRect),iSrcRect(aSrcRect),iInvertMask(aInvertMask)
  2377 	{}
  2378 inline TWsGcCmdCopyRect::TWsGcCmdCopyRect(const TPoint &anOffset,const TRect &aRect) :
  2379 	rect(aRect),pos(anOffset)
  2380 	{}
  2381 inline TWsGcCmdGdiBlt2::TWsGcCmdGdiBlt2(const TPoint &aPoint, TInt aHandle) :
  2382 	handle(aHandle), pos(aPoint)
  2383 	{}
  2384 inline TWsGcCmdGdiBlt3::TWsGcCmdGdiBlt3(const TPoint &aPoint, TInt aHandle, const TRect &aSrcRect) :
  2385 	handle(aHandle),pos(aPoint),rect(aSrcRect)
  2386 	{}
  2387 inline TWsGcCmdGdiBlt2Local::TWsGcCmdGdiBlt2Local(const TPoint &aPoint,const CFbsBitmap *aBitmap) :
  2388 	bitmap(aBitmap), pos(aPoint)
  2389 	{}
  2390 inline TWsGcCmdGdiBlt3Local::TWsGcCmdGdiBlt3Local(const TPoint &aDestination,const CFbsBitmap *aBitmap,const TRect &aSource) :
  2391 	bitmap(aBitmap), pos(aDestination), rect(aSource)
  2392 	{}
  2393 inline TWsGcCmdGdiBltMaskedLocal::TWsGcCmdGdiBltMaskedLocal(const TPoint& aPoint,const CFbsBitmap* aBitmap,const TRect &aSourceRect,const CFbsBitmap* aMaskBitmap,TBool aInvertMask) :
  2394 	bitmap(aBitmap), maskBitmap(aMaskBitmap), invertMask(aInvertMask), pos(aPoint), rect(aSourceRect)
  2395 	{}
  2396 	inline TWsGcCmdBltMasked::TWsGcCmdBltMasked()
  2397 	{}
  2398 inline TWsGcCmdBltMasked::TWsGcCmdBltMasked(const TPoint& aPoint,TInt aBitmap,const TRect& aSourceRect,TInt aMaskBitmap,TBool aInvertMask) :
  2399 	destination(aPoint), handle(aBitmap), source(aSourceRect), maskHandle(aMaskBitmap), invertMask(aInvertMask)
  2400 	{}
  2401 inline TWsGcCmdMapColors::TWsGcCmdMapColors(const TRect &aRect, TInt aNumPairs, TBool aMapForwards) :
  2402 	rect(aRect), numPairs(aNumPairs), mapForwards(aMapForwards)
  2403 	{}
  2404 inline TWsGcCmdMapColorsLocal::TWsGcCmdMapColorsLocal(const TRect &aRect, const TRgb *aColors, TInt aNumPairs, TBool aMapForwards) :
  2405 	rect(aRect), colors(aColors), numPairs(aNumPairs), mapForwards(aMapForwards)
  2406 	{}	
  2407 inline TWsGcCmdAlphaBlendBitmaps::TWsGcCmdAlphaBlendBitmaps()
  2408 	{}
  2409 inline TWsGcCmdAlphaBlendBitmaps::TWsGcCmdAlphaBlendBitmaps(const TPoint& aPoint, TInt aBitmap,const TRect& aSourceRect,TInt aAlpha,const TPoint& aAlphaPoint) :
  2410 	point(aPoint), bitmapHandle(aBitmap), source(aSourceRect), alphaHandle(aAlpha), alphaPoint(aAlphaPoint)
  2411 	{}
  2412 inline TWsGcCmdAlphaBlendBitmapsLocal::TWsGcCmdAlphaBlendBitmapsLocal(const TPoint& aPoint, const CFbsBitmap *aBitmap, const TRect& aSourceRect, const CFbsBitmap *aAlpha, const TPoint& aAlphaPoint) :
  2413 	point(aPoint), iBitmap(aBitmap), source(aSourceRect), iAlpha(aAlpha), alphaPoint(aAlphaPoint)
  2414 	{}
  2415 
  2416 //
  2417 inline TWsSdCmdSetScreenRotation::TWsSdCmdSetScreenRotation(TInt aMode, CFbsBitGc::TGraphicsOrientation aRotation) :
  2418 	mode(aMode), rotation(aRotation)
  2419 	{}
  2420 inline TWsSdCmdGetScanLine::TWsSdCmdGetScanLine(const TPoint &aPos, TInt aLen, TDisplayMode aDispMode) :
  2421 	pos(aPos), len(aLen), dispMode(aDispMode)
  2422 	{}
  2423 inline TWsSdCmdRectCompare::TWsSdCmdRectCompare(const TRect &aRect1,const TRect &aRect2,TUint aFlags) :
  2424 	rect1(aRect1), rect2(aRect2), flags(aFlags)
  2425 	{}
  2426 inline TWsSdCmdCopyScreenToBitmap::TWsSdCmdCopyScreenToBitmap(TInt aHandle) :
  2427 	handle(aHandle)
  2428 	{}
  2429 inline TWsSdCmdCopyScreenToBitmap2::TWsSdCmdCopyScreenToBitmap2(const TRect &aRect, TInt aHandle) :
  2430 	rect(aRect), handle(aHandle)
  2431 	{}
  2432 inline TWsSdCmdSetPalette::TWsSdCmdSetPalette(TPtr8& aPtr) :
  2433 	ptr(&aPtr), length(aPtr.Length())
  2434 	{}
  2435 inline TWsSdCmdMapCoordinates::TWsSdCmdMapCoordinates(const TRect &aSource, TCoordinateSpace aSourceSpace, TCoordinateSpace aTargetSpace):
  2436 	sourceRect(aSource), sourceSpace(aSourceSpace), targetSpace(aTargetSpace)
  2437 	{}
  2438 //
  2439 inline TWsSpriteCmdUpdateMember::TWsSpriteCmdUpdateMember(TInt aIndex,const TSpriteMember &aData) :
  2440 	index(aIndex), data(aData)
  2441 	{}
  2442 //
  2443 inline TWsDirectCmdRequestReply::TWsDirectCmdRequestReply()
  2444 	{}
  2445 inline TWsDirectCmdRequestReply::TWsDirectCmdRequestReply(TThreadId aId,TRequestStatus* aRequest) :
  2446 	id(aId), request(aRequest)
  2447 	{}
  2448 //
  2449 inline SKeyRepeatSettings::SKeyRepeatSettings()
  2450 	{}
  2451 inline SDoubleClickSettings::SDoubleClickSettings()
  2452 	{}
  2453 inline SDefModeMaxNumColors::SDefModeMaxNumColors()
  2454 	{}
  2455 //
  2456 inline TCmdSpriteMember::TCmdSpriteMember()
  2457 	{}
  2458 	
  2459 inline TWsGcCmdDrawTextVerticalPtr::TWsGcCmdDrawTextVerticalPtr(const TDesC *aDesc, const TPoint& aPos, const TBool aUp) : pos(aPos), up(aUp), text(const_cast<TDesC*>(aDesc))
  2460 	{}
  2461 	
  2462 inline TWsGcCmdDrawWsGraphic::TWsGcCmdDrawWsGraphic(const TWsGraphicId& aId,const TRect& aRect):
  2463 	iRect(aRect), iDataLen(0)
  2464 	{
  2465 	if(aId.IsUid())
  2466 		{
  2467 		iId = aId.Uid().iUid;
  2468 		iFlags = EWsGraphicIdUid;
  2469 		}
  2470 	else
  2471 		{
  2472 		iId = aId.Id();
  2473 		iFlags = EWsGraphicIdTransient;
  2474 		}
  2475 	}
  2476 inline TWsGcCmdDrawTextInContext::TWsGcCmdDrawTextInContext(const TPoint &aPos, TInt aLength, TInt aStart, TInt aEnd) : 
  2477 	pos(aPos),length(aLength),start(aStart),end(aEnd)
  2478 	{}
  2479 inline TWsGcCmdDrawTextInContextVertical::TWsGcCmdDrawTextInContextVertical(const TPoint &aPos, TInt aLength, TBool aUp,TInt aStart,TInt aEnd) : 
  2480 	pos(aPos),length(aLength),up(aUp),start(aStart),end(aEnd)
  2481 	{}
  2482 inline TWsGcCmdDrawTextInContextVerticalPtr::TWsGcCmdDrawTextInContextVerticalPtr(const TDesC *aDesc, const TPoint& aPos, const TBool aUp,TInt aStart,TInt aEnd) : pos(aPos), up(aUp), text(const_cast<TDesC*>(aDesc)),start(aStart),end(aEnd)
  2483 	{}
  2484 inline TWsGcCmdBoxTextInContextLocal::TWsGcCmdBoxTextInContextLocal(const TRect &aBox,const TInt aStart,const TInt aEnd) : box(aBox),start(aStart),end(aEnd)
  2485 	{}
  2486 inline TWsGcCmdBoxTextInContextOptimised1::TWsGcCmdBoxTextInContextOptimised1(const TRect &aRect, TInt aBaselineOffset,TInt aLength,TInt aStart,TInt aEnd) :
  2487 	box(aRect),baselineOffset(aBaselineOffset),length(aLength),start(aStart),end(aEnd)
  2488 	{}
  2489 inline TWsGcCmdBoxTextInContextOptimised2::TWsGcCmdBoxTextInContextOptimised2(const TRect &aRect,TInt aBaselineOffset,CGraphicsContext::TTextAlign aHoriz,TInt aLeftMrg,TInt aLength,TInt aStart,TInt aEnd) :
  2490 	box(aRect),baselineOffset(aBaselineOffset),horiz(aHoriz),leftMrg(aLeftMrg),length(aLength),start(aStart),end(aEnd)
  2491 	{}
  2492 inline TWsGcCmdBoxTextInContext::TWsGcCmdBoxTextInContext(const TRect &aRect,TInt aBaselineOffset,CGraphicsContext::TTextAlign aHoriz,TInt aLeftMrg,TInt aLength,TInt aWidth,TInt aStart,TInt aEnd) :
  2493 	box(aRect),baselineOffset(aBaselineOffset),horiz(aHoriz),leftMrg(aLeftMrg),length(aLength),width(aWidth),start(aStart),end(aEnd)
  2494 	{}
  2495 inline TWsGcCmdBoxTextInContextVertical::TWsGcCmdBoxTextInContextVertical(const TRect& aBox) : box(aBox)
  2496 	{}
  2497 inline TWsGcCmdDrawTextInContextLocal::TWsGcCmdDrawTextInContextLocal(const TPoint &aPos,const TDesC *aDesc,TInt aStart,TInt aEnd) :
  2498 	pos(aPos), desc(aDesc),start(aStart),end(aEnd)
  2499 	{}
  2500 inline TWsGcCmdDrawResourceToPos::TWsGcCmdDrawResourceToPos(TInt aWsHandle, const TPoint &aPos, CWindowGc::TGraphicsRotation aRotation) : 
  2501 	wsHandle(aWsHandle), pos(aPos), rotation(aRotation) 
  2502 	{}
  2503 inline TWsGcCmdDrawResourceToRect::TWsGcCmdDrawResourceToRect(TInt aWsHandle, const TRect &aRect, CWindowGc::TGraphicsRotation aRotation) : 
  2504 	wsHandle(aWsHandle), rect(aRect), rotation(aRotation)
  2505 	{}
  2506 inline TWsGcCmdDrawResourceFromRectToRect::TWsGcCmdDrawResourceFromRectToRect(TInt aWsHandle, const TRect &aRectDest, const TRect &aRectSrc, CWindowGc::TGraphicsRotation aRotation) :
  2507 	wsHandle(aWsHandle), rectDest(aRectDest), rectSrc(aRectSrc), rotation(aRotation)
  2508 	{}
  2509 inline TWsGcCmdDrawResourceWithData::TWsGcCmdDrawResourceWithData(TInt aWsHandle, const TRect &aRect, const TDesC8* aDesc) :
  2510 	wsHandle(aWsHandle), rect(aRect), desc(aDesc)
  2511 	{}
  2512 #endif