22 #include <e32base.h> |
22 #include <e32base.h> |
23 #include <e32property.h> |
23 #include <e32property.h> |
24 #include <w32std.h> |
24 #include <w32std.h> |
25 #include <hwrmdomainpskeys.h> |
25 #include <hwrmdomainpskeys.h> |
26 |
26 |
27 //CONSTANTS |
27 class MAutolockAppUiInterface; |
28 const TInt KCancelKeyCode( 165 ); |
|
29 |
|
30 class MAutolockGripStatusObserver |
|
31 { |
|
32 public: |
|
33 /** |
|
34 * Implement this method to be notified when grip status |
|
35 * changes. |
|
36 */ |
|
37 IMPORT_C virtual TInt DeviceLockQueryStatus() = 0; |
|
38 IMPORT_C virtual TInt DeviceLockStatus() = 0; |
|
39 }; |
|
40 |
28 |
41 class CAutolockGripStatusObserver : public CActive |
29 class CAutolockGripStatusObserver : public CActive |
42 { |
30 { |
43 public: |
31 public: |
44 IMPORT_C static CAutolockGripStatusObserver* NewL( MAutolockGripStatusObserver* aObserver, RWsSession& aSession ); |
32 IMPORT_C static CAutolockGripStatusObserver* NewL( MAutolockAppUiInterface* aObserver, RWsSession& aSession ); |
45 |
33 |
46 void RunL(); |
34 void RunL(); |
47 void DoCancel(); |
35 void DoCancel(); |
48 ~CAutolockGripStatusObserver(); |
36 ~CAutolockGripStatusObserver(); |
49 |
37 |
50 private: |
38 private: |
51 void ConstructL( MAutolockGripStatusObserver* aObserver ); |
39 void ConstructL( MAutolockAppUiInterface* aObserver ); |
52 CAutolockGripStatusObserver( RWsSession& aSession ); |
40 CAutolockGripStatusObserver( RWsSession& aSession ); |
53 void GripStatusChangedL( TInt aGripStatus ); |
41 void GripStatusChangedL( TInt aGripStatus ); |
54 |
42 |
55 private: |
43 private: |
56 MAutolockGripStatusObserver* iObserver; |
44 MAutolockAppUiInterface* iObserver; |
57 RProperty iGripStatus; |
45 RProperty iGripStatus; |
58 RWsSession& iSession; |
46 RWsSession& iSession; |
59 }; |
47 }; |
60 |
48 |
61 |
49 |