|
1 /* |
|
2 * Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: Interface class for showing Events Global Query. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef EVTGLOBALQUERY_H |
|
21 #define EVTGLOBALQUERY_H |
|
22 |
|
23 // System Includes |
|
24 #include <e32base.h> //CActive |
|
25 |
|
26 // User Includes |
|
27 #include "evttoneplayer.h" |
|
28 |
|
29 //Forward Declaration |
|
30 class CAknGlobalMsgQuery; |
|
31 class CEvtInfoNoteInputParam; |
|
32 class CEvtTonePlayer; |
|
33 class CEvtKeyLockHandler; |
|
34 |
|
35 // CLASS DECLARATION |
|
36 |
|
37 /** |
|
38 * Global Query class which handles the pop up of the global query. |
|
39 * |
|
40 * @since Series 60 9.1 |
|
41 */ |
|
42 class CEvtGlobalQuery : public CActive, |
|
43 public MEvtTonePlayObserver |
|
44 { |
|
45 public: |
|
46 /** |
|
47 * Destructor |
|
48 */ |
|
49 IMPORT_C virtual ~CEvtGlobalQuery(); |
|
50 |
|
51 /** |
|
52 * Constructs a new instance of Global Query. |
|
53 * |
|
54 * @return The new instance of Global Query object. |
|
55 * @leave System wide error code if the object creation fails. |
|
56 */ |
|
57 IMPORT_C static CEvtGlobalQuery* NewL( CEvtInfoNoteInputParam& aInputParam ); |
|
58 |
|
59 /** |
|
60 * Constructs a new instance of Global Query. |
|
61 * Leaves the created instance on the cleanup stack. |
|
62 * |
|
63 * @return The new instance of Global Query object. |
|
64 * @leave System wide error code if the object creation fails. |
|
65 */ |
|
66 IMPORT_C static CEvtGlobalQuery* NewLC( CEvtInfoNoteInputParam& aInputParam ); |
|
67 |
|
68 public: |
|
69 /** |
|
70 * Starts the Global Query. |
|
71 * |
|
72 * @since S60 v9.1 |
|
73 * @param[in] aStatus Asynchronous request status |
|
74 * @param[in] aRetBuffer Buffer which holds the return value |
|
75 */ |
|
76 IMPORT_C void StartGlobalQueryL(TRequestStatus& aStatus, TDes8& aRetBuffer); |
|
77 |
|
78 /** |
|
79 * Cancels the currently outstanding Global Query. |
|
80 * |
|
81 * @since S60 v9.1 |
|
82 */ |
|
83 IMPORT_C void CancelDialog(); |
|
84 |
|
85 // Inherited from MEvtTonePlayObserver |
|
86 void TonePlayCompleteL( TBool aTimeout ); |
|
87 |
|
88 private: |
|
89 /** |
|
90 * Gets the Icon details from the Icon File. |
|
91 */ |
|
92 void GetIconDetailsL( TFileName& aFileName, TInt& aBmpID, TInt& aBmpMaskID ); |
|
93 |
|
94 private: |
|
95 /** |
|
96 * Default C++ Constructor. |
|
97 */ |
|
98 CEvtGlobalQuery( CEvtInfoNoteInputParam& aInputParam ); |
|
99 |
|
100 /** |
|
101 * Second phase of the two phase constructor. |
|
102 */ |
|
103 void ConstructL(); |
|
104 |
|
105 private: // from CActive |
|
106 void RunL(); |
|
107 void DoCancel(); |
|
108 TInt RunError( TInt aError ); |
|
109 |
|
110 private: // data |
|
111 /** |
|
112 * Asynchronous return status |
|
113 */ |
|
114 TRequestStatus* iReturnStatus; |
|
115 |
|
116 /** |
|
117 * Buffer value which holds the return value |
|
118 * NOT Own: |
|
119 */ |
|
120 TDes8* iReturnBuffer; |
|
121 |
|
122 /** |
|
123 * Avkon's Global Message Query |
|
124 * Owns: |
|
125 */ |
|
126 CAknGlobalMsgQuery* iGlobalMsgQuery; |
|
127 |
|
128 /** |
|
129 * Event Info Note parameters |
|
130 */ |
|
131 CEvtInfoNoteInputParam& iInputParam ; |
|
132 |
|
133 /** |
|
134 * Tone player |
|
135 * Owns |
|
136 */ |
|
137 CEvtTonePlayer* iTonePlayer; |
|
138 |
|
139 /** |
|
140 * Key Lock Handler |
|
141 * Owns |
|
142 */ |
|
143 CEvtKeyLockHandler* iKeyLockHandler; |
|
144 }; |
|
145 |
|
146 #endif // EVTGLOBALQUERY_H |