lafagnosticuifoundation/cone/tef/tconemultiptrcompoundstep.h
changeset 0 2f259fa3e83a
equal deleted inserted replaced
-1:000000000000 0:2f259fa3e83a
       
     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 #ifndef TCONEMULTIPTRCOMPOUNDSTEP_H_
       
    17 #define TCONEMULTIPTRCOMPOUNDSTEP_H_
       
    18 
       
    19 #include <coemain.h>
       
    20 #include <coecntrl.h>
       
    21 #include <coeaui.h>
       
    22 #include <test/testexecutestepbase.h>
       
    23 #include "TConeTestServer.h"
       
    24 #include "appfwk_test_AppUi.h"
       
    25 #include "tmultiptrtestcontrol.h"
       
    26 
       
    27 
       
    28 // TConeMultiPtrCompound Test Step Name.\n
       
    29 _LIT( KTConeMultiPtrCompoundStep,"TConeMultiPtrCompound" );
       
    30 
       
    31 
       
    32 class CTConeMultiPtrCompoundStep : public CTmsTestStep
       
    33 	{
       
    34 public:
       
    35 	CTConeMultiPtrCompoundStep();
       
    36 	~CTConeMultiPtrCompoundStep();
       
    37 	virtual TVerdict doTestStepL();
       
    38 	TVerdict doTestStepPreambleL();
       
    39 	TVerdict doTestStepPostambleL();
       
    40 	
       
    41 	void ConstructConeMultiPtrAppL( CCoeEnv* aCoe );
       
    42 	
       
    43 public:
       
    44 	TTimeIntervalMicroSeconds32 iDoubleClickMaxInterval;
       
    45 	TInt iDoubleClickMaxDistance;
       
    46 	};
       
    47 
       
    48 
       
    49 
       
    50 class CMultPtrTestCompoundControlContainer;
       
    51 class CConeMultiPtrCompoundTestAppUi : public CTestCoeAppUi
       
    52     {
       
    53 public:
       
    54 	CConeMultiPtrCompoundTestAppUi( CTmsTestStep* aStep );
       
    55 	~CConeMultiPtrCompoundTestAppUi();
       
    56 	
       
    57 public:	
       
    58 	// from CCoeAppUi
       
    59 	void ConstructL();
       
    60 	
       
    61 	void NextSetOfEventsL();
       
    62 	
       
    63 	// The tests
       
    64 	void PreliminaryStimuliL();
       
    65 	void SinglePtrProximityAndPressureL();
       
    66 	void MultiplePtrProximityAndPressureL();
       
    67 	void PointerGrabbingL();
       
    68 	void ClaimPointerGrabbingL();
       
    69 	void ClaimPointerGrabbingTwoWindowsL();
       
    70 	void CapturePointerCycleL();
       
    71 	void CapturePointerNotDeliveredToChildL();
       
    72 	void CycleToOutOfRangeL();
       
    73 	TBool ConfigurationSupportsPointerEventTesting() const;
       
    74 	// The infrastructural methods
       
    75 	void SimulatePointer( TRawEvent::TType aType, TInt aX, TInt aY, TInt aZ, TUint8 aPointerNumber );
       
    76 	void SimulatePointerDownUp( TInt aX, TInt aY, TInt aZ, TUint8 aPointerNumber );
       
    77 	void AddExpectedPointer( TAdvancedPointerEvent::TType aType, TPoint aPos, TInt aZ, TUint8 aPointerNumber, CMultiPtrTestControlBase* aControl );
       
    78 	void AddExpectedPointerDownUp( TPoint aPos, TInt aZ, TUint8 aPointerNumber, CMultiPtrTestControlBase* aControl );
       
    79 	void Failed();
       
    80 	
       
    81 private:
       
    82 	void RunTestStepL( TInt aStepNum );
       
    83 
       
    84 	void RunTestsSingleClusterL();
       
    85 	void RunTestsDualClusterL();
       
    86 	void RunTestsClusterPlusSimpleL();
       
    87 	void RunTestsSimpleL();
       
    88 	void InstantiateControlClusterOneL();
       
    89 	void DeleteControlClusterOne();
       
    90 	void InstantiateControlClusterTwoL();
       
    91 	void DeleteControlClusterTwo();
       
    92 	
       
    93 public:
       
    94 	CMultPtrTestCompoundControlContainer* iControlCluster_1;
       
    95 	CMultPtrTestCompoundControlContainer* iControlCluster_2;
       
    96 	CMultiPtrTestCompoundAppUiControl* iControlSimple;
       
    97 	
       
    98 private:	
       
    99 	TInt iTestCase;
       
   100 	TInt iEventCount;
       
   101 	TBool iFailed;
       
   102 	TInt iEventSet;
       
   103 	TInt iNumberOfPointers;
       
   104 	TRect iNormalPointerCursorArea;
       
   105     };
       
   106 
       
   107 
       
   108 #endif // TCONEMULTIPTRCOMPOUNDSTEP_H_
       
   109