equal
deleted
inserted
replaced
18 @internalComponent |
18 @internalComponent |
19 */ |
19 */ |
20 |
20 |
21 #ifndef CMTPDEVICEDP_H |
21 #ifndef CMTPDEVICEDP_H |
22 #define CMTPDEVICEDP_H |
22 #define CMTPDEVICEDP_H |
23 |
23 #include <e32base.h> |
|
24 #include <d32usbc.h> |
24 #include <mtp/cmtpdataproviderplugin.h> |
25 #include <mtp/cmtpdataproviderplugin.h> |
25 #include "mtpdebug.h" |
26 #include "mtpdebug.h" |
26 #include "mmtpenumerationcallback.h" |
27 #include "mmtpenumerationcallback.h" |
27 #include "rmtpdevicedpsingletons.h" |
28 #include "rmtpdevicedpsingletons.h" |
28 #include "rmtpdpsingletons.h" |
29 #include "rmtpdpsingletons.h" |
29 #include "mextndevplugincallback.h" |
30 #include "mextndevplugincallback.h" |
30 #include "mmtpdevdpextn.h" |
31 #include "mmtpdevdpextn.h" |
|
32 #include "rmtpframework.h" |
31 |
33 |
32 #include "cmtpgetdevicepropdesc.h" |
34 #include "cmtpgetdevicepropdesc.h" |
33 #include "cmtpdevicedatastore.h" |
35 #include "cmtpdevicedatastore.h" |
34 #include "cmtpdevdpextnmap.h" |
36 #include "cmtpdevdpextnmap.h" |
35 #include <mtp/tmtptypeevent.h> |
37 #include <mtp/tmtptypeevent.h> |
38 class CMTPFSEnumerator; |
40 class CMTPFSEnumerator; |
39 class CMTPStorageWatcher; |
41 class CMTPStorageWatcher; |
40 class MMTPRequestProcessor; |
42 class MMTPRequestProcessor; |
41 class CMtpExtnDevicePropPlugin; |
43 class CMtpExtnDevicePropPlugin; |
42 class CMTPDeviceDataStore; |
44 class CMTPDeviceDataStore; |
43 |
45 class CMTPDeviceInfoTimer; |
44 /** |
46 /** |
45 Implements the MTP device data provider plug-in. |
47 Implements the MTP device data provider plug-in. |
46 @internalComponent |
48 @internalComponent |
47 */ |
49 */ |
48 class CMTPDeviceDataProvider : |
50 class CMTPDeviceDataProvider : |
60 |
62 |
61 public: |
63 public: |
62 |
64 |
63 static TAny* NewL(TAny* aParams); |
65 static TAny* NewL(TAny* aParams); |
64 ~CMTPDeviceDataProvider(); |
66 ~CMTPDeviceDataProvider(); |
65 |
67 void SetConnectMac(); |
66 private: // From CMTPDataProviderPlugin |
68 private: // From CMTPDataProviderPlugin |
67 |
69 |
68 void Cancel(); |
70 void Cancel(); |
69 void ProcessEventL(const TMTPTypeEvent& aEvent, MMTPConnection& aConnection); |
71 void ProcessEventL(const TMTPTypeEvent& aEvent, MMTPConnection& aConnection); |
70 void ProcessNotificationL(TMTPNotification aNotification, const TAny* aParams); |
72 void ProcessNotificationL(TMTPNotification aNotification, const TAny* aParams); |
164 CMTPDeviceDataStore *iPtrDataStore; |
166 CMTPDeviceDataStore *iPtrDataStore; |
165 |
167 |
166 TInt iActiveProcessor; |
168 TInt iActiveProcessor; |
167 TBool iActiveProcessorRemoved; |
169 TBool iActiveProcessorRemoved; |
168 |
170 |
|
171 //Timer for DeviceInfo |
|
172 CMTPDeviceInfoTimer* iDeviceInfoTimer; |
|
173 RMTPFramework iFrameWork; |
|
174 enum TCommandState |
|
175 { |
|
176 EIdle, |
|
177 EOpenSession, |
|
178 EStartDeviceInfoTimer, |
|
179 ESetIsMac |
|
180 }; |
|
181 TCommandState iCommandState; |
|
182 |
|
183 |
169 }; |
184 }; |
170 |
185 /** |
|
186 Implements the MTP GetDeviceinfo timer. |
|
187 @internalComponent |
|
188 */ |
|
189 class CMTPDeviceInfoTimer : public CTimer |
|
190 { |
|
191 public: |
|
192 |
|
193 static CMTPDeviceInfoTimer* NewL(CMTPDeviceDataProvider& aDeviceProvider); |
|
194 virtual ~CMTPDeviceInfoTimer(); |
|
195 void Start(); |
|
196 |
|
197 private: // From CTimer |
|
198 |
|
199 void RunL(); |
|
200 |
|
201 private: |
|
202 |
|
203 CMTPDeviceInfoTimer(CMTPDeviceDataProvider& aDeviceProvider); |
|
204 void ConstructL(); |
|
205 |
|
206 private: |
|
207 /** |
|
208 FLOGGER debug trace member variable. |
|
209 */ |
|
210 __FLOG_DECLARATION_MEMBER_MUTABLE; |
|
211 |
|
212 CMTPDeviceDataProvider& iDeviceProvider; |
|
213 RDevUsbcClient iLdd; |
|
214 |
|
215 enum TTimerState |
|
216 { |
|
217 EIdle, |
|
218 EStartTimer, |
|
219 EUSBReEnumerate |
|
220 }; |
|
221 TTimerState iState; |
|
222 }; |
171 #endif // CMTPDEVICEDP_H |
223 #endif // CMTPDEVICEDP_H |