windowing/windowserver/test/t_stress/inc/backedupwin.h
changeset 0 5d03bc08d59c
equal deleted inserted replaced
-1:000000000000 0:5d03bc08d59c
       
     1 // Copyright (c) 2008-2009 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 //
       
    15 
       
    16 /**
       
    17  @file
       
    18  @test
       
    19  @internalComponent
       
    20 */
       
    21 
       
    22 #ifndef BACKEDUPWIN_H
       
    23 #define BACKEDUPWIN_H
       
    24 
       
    25 #include <w32std.h>
       
    26 #include "compwin.h"
       
    27 
       
    28 /*******************************************************************************
       
    29 These are backedup windows and draw a simple cross shape
       
    30 *******************************************************************************/
       
    31 _LIT8(KBackedupWindowType, "Backed up");
       
    32 class CBackedupWin : public CCompWin
       
    33 	{
       
    34 public:
       
    35 	static CBackedupWin* NewLC(RWsSession& aWs, RWindowGroup* aGroup, CCompWin* aParent, CWindowGc& aGc);
       
    36 	static void LoadConfiguration(const MTestStepConfigurationContext* aContext);
       
    37 	static TBool IsEnabled() { return iEnabled; }
       
    38 	~CBackedupWin();
       
    39 	
       
    40 	void Redraw(const TRect& aRect);
       
    41 	void DrawBitmap(CFbsBitGc* aGc, TRect& aClip, TPoint& aOrigin);
       
    42 	void SetSize(const TSize & aSize);
       
    43 	virtual const TDesC8& TypeName() { return KBackedupWindowType; }
       
    44 	void DumpDetails(RFile & aFile, TInt aDepth);
       
    45 	
       
    46 protected:
       
    47 	CBackedupWin(RWsSession& aWs, RWindowGroup* aGroup, CCompWin* aParent, CWindowGc& aGc);
       
    48 	void ConstructL();
       
    49 	
       
    50 private:
       
    51 	static TBool iEnabled;
       
    52 	static TBool iRandomizePenStyle;
       
    53 	static TBool iRandomizeBrushStyle;
       
    54 	TRgb iBgColor;
       
    55 	TRgb iFgColor;
       
    56 	CGraphicsContext::TPenStyle iPenStyle;
       
    57 	CGraphicsContext::TBrushStyle iBrushStyle;
       
    58 	CWindowGc * iBkWsGc;
       
    59 	};
       
    60 
       
    61 
       
    62 #endif // BACKEDUPWIN_H