os/graphics/windowing/windowserver/test/tauto/TGWHANDLE.H
changeset 0 bde4ae8d615e
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/os/graphics/windowing/windowserver/test/tauto/TGWHANDLE.H	Fri Jun 15 03:10:57 2012 +0200
     1.3 @@ -0,0 +1,94 @@
     1.4 +
     1.5 +// Copyright (c) 1996-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.6 +// All rights reserved.
     1.7 +// This component and the accompanying materials are made available
     1.8 +// under the terms of "Eclipse Public License v1.0"
     1.9 +// which accompanies this distribution, and is available
    1.10 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
    1.11 +//
    1.12 +// Initial Contributors:
    1.13 +// Nokia Corporation - initial contribution.
    1.14 +//
    1.15 +// Contributors:
    1.16 +//
    1.17 +// Description:
    1.18 +//
    1.19 +
    1.20 +/**
    1.21 + @file
    1.22 + @test
    1.23 + @internalComponent - Internal Symbian test code
    1.24 +*/
    1.25 +
    1.26 +#ifndef __TGWHANDLE_H__
    1.27 +#define __TGWHANDLE_H__
    1.28 +
    1.29 +#include <e32std.h>
    1.30 +#include <w32std.h>
    1.31 +#include "../tlib/testbase.h"
    1.32 +#include "AUTO.H"
    1.33 +#include "TGraphicsHarness.h"
    1.34 +
    1.35 +class CTGwHandle : public CTWsGraphicsBase
    1.36 +	{
    1.37 +public:
    1.38 +	CTGwHandle(CTestStep* aStep);
    1.39 +	~CTGwHandle();
    1.40 +	void ConstructL();
    1.41 +	TInt NumberOfWndGroupsWithZeroPriority(TInt aScreenNumber);
    1.42 +	void GetGwListL(CArrayFixFlat<TInt> *aWindowHandles);
    1.43 +	void GetGwListL(CArrayFixFlat<TInt> *aWindowHandles, TInt aScreenNumber);
    1.44 +	void GetGwListL(TInt aPriority, CArrayFixFlat<TInt> *aWindowHandles);
    1.45 +	void GetGwListL(RArray<RWsSession::TWindowGroupChainInfo>* aWindowHandles);
    1.46 +	void GetGwListL(TInt aPriority, RArray<RWsSession::TWindowGroupChainInfo>* aWindowHandles);
    1.47 +	void GwNamesL();
    1.48 +	void GwIdentifierTestL();
    1.49 +	void OwnerToForegroundL();
    1.50 +	void FindWindowGroupIdentifierTestL();
    1.51 +	void IdentifierWrapAroundTestL();
    1.52 +	void DefaultOwningWindowL();
    1.53 +	void DefaultOwningWindow2L();
    1.54 +	void WindowGroupChaining();
    1.55 +	void WindowGroupChaining2();
    1.56 +	void UnchainWindowGroupsL();
    1.57 +	void TestclosingclientL();
    1.58 +	void TestClearingAndSettingChildGroupsL();
    1.59 +protected:
    1.60 +//from 	CTGraphicsStep
    1.61 +	virtual void RunTestCaseL(TInt aCurTestCase);
    1.62 +private:
    1.63 +	enum {ENumGroups=10,ENumChained=5};
    1.64 +private:
    1.65 +	RWindowGroup* CreateWindowGroupLC(RWsSession& aWs,TUint32 aClientHandle,TInt aParentId=0);
    1.66 +	void CreateGroupWindowsLC(RWsSession& aWs);
    1.67 +	void CreateChainedGroupWindowsLC(RWsSession& aWs,TBool aSecondChain = EFalse);
    1.68 +	void TestAgainstLoopsWhenAddingChildGroupsL();
    1.69 +	void MoveGroups(RWindowGroup** aGroups,TInt aGp,TInt aNum,TInt aPos,TInt aInc=2);
    1.70 +	void TestGroups(TInt aPos);
    1.71 +	void TestGroupsBefore(TInt aPos);
    1.72 +	void TestOrdinalPositionL();
    1.73 +	void TestOrdinalPositionNoDebugL();
    1.74 +	void TestOrdinalPos(TInt awndPos);
    1.75 +	void TestOrdinalPosNoDebug(TInt awndPos);
    1.76 +	TInt ChainedWindowCount(RArray<RWsSession::TWindowGroupChainInfo>*);
    1.77 +private:
    1.78 +	TFullName iFullName;
    1.79 +	TSize iWinSize;
    1.80 +	RWindowGroup* iGroups[ENumGroups];
    1.81 +	RWindowGroup* iChained[ENumChained];
    1.82 +	RWindowGroup* iChained2[ENumChained];
    1.83 +	};
    1.84 +
    1.85 +class CTGwHandleStep : public CTGraphicsStep
    1.86 +	{
    1.87 +public:
    1.88 +	CTGwHandleStep();
    1.89 +protected:
    1.90 +	//from CTGraphicsStep
    1.91 +	virtual CTGraphicsBase* CreateTestL();
    1.92 +	};
    1.93 +
    1.94 +_LIT(KTGwHandleStep,"TGwHandle");
    1.95 +
    1.96 +
    1.97 +#endif