diff -r 9d8b04ca6939 -r 218231f2b3b3 usbuis/usbuinotif/inc/usbuinotifmsmmerror.h --- a/usbuis/usbuinotif/inc/usbuinotifmsmmerror.h Fri Jun 04 10:27:39 2010 +0100 +++ b/usbuis/usbuinotif/inc/usbuinotifmsmmerror.h Fri Jun 11 14:38:00 2010 +0300 @@ -11,7 +11,7 @@ * * Contributors: * -* Description: Declares USB UI Queries notifier. +* Description: Declares MSMM error notifier. * */ @@ -20,10 +20,11 @@ #define USBUINOTIFMSMMERROR_H // INCLUDES - +#include #include "usbnotifier.h" // Base class -#include // AVKON component + #define KUsbUiNotifOtgGeneralQueryGranularity 3 + // CLASS DECLARATION /** @@ -32,19 +33,21 @@ * * @lib */ -NONSHARABLE_CLASS(CUsbUiNotifMSMMError) : public CUSBUINotifierBase +NONSHARABLE_CLASS(CUsbUiNotifMSMMError) : public CUSBUINotifierBase, + public MHbDeviceMessageBoxObserver { public: -/** - * Possible parameter values for KUsbUiNotifMSMMError - */ -enum TUsbUiNotifMSMMError - { - EUsbMSMMGeneralError, - EUsbMSMMUnknownFileSystem, - EUsbMSMMOutOfMemory - }; + /** + * Indexes for the strings used in KUsbUiNotifMSMMError which are mapped to 5 errors. + */ + enum TUsbUiNotifMSMMError + { + EUsbMSMMGeneralError, + EUsbMSMMUnknownFileSystem, + EUsbMSMMOutOfMemory + }; + // Constructors and destructor /** @@ -57,6 +60,14 @@ */ virtual ~CUsbUiNotifMSMMError(); + /** + * Call back function to observe device message box closing. + * @param aMessageBox Pointer to the closing message box instance. + * @param aButton Button that was pressed. + */ + void MessageBoxClosed(const CHbDeviceMessageBoxSymbian* aMessageBox, + CHbDeviceMessageBoxSymbian::TButtonId aButton); + protected: /** @@ -81,11 +92,6 @@ void Cancel(); /** - * From CUSBUINotifierBase Gets called when a request completes. - */ - void RunL(); - - /** * From CUSBUINotifierBase Used in asynchronous notifier launch to * store received parameters into members variables and * make needed initializations. @@ -93,7 +99,7 @@ * @param aReplySlot A reply slot. * @param aMessage Should be completed when the notifier is deactivated. */ - void GetParamsL(const TDesC8& aBuffer, TInt aReplySlot, + void StartDialogL(const TDesC8& aBuffer, TInt aReplySlot, const RMessagePtr2& aMessage); private: @@ -106,20 +112,9 @@ private: // New functions - /** - * Show query dialog - * @return KErrNone - accepted, KErrCancel - Cancel or End call key - */ - TInt QueryUserResponseL(); - private: // Data - /** - * Query - * Not own, destroys self when lauched. - */ - CAknQueryDialog* iQuery; - RArray iStringIds; - TInt iErrorId; - }; + CHbDeviceMessageBoxSymbian* iQuery; + CDesCArrayFlat* iStringIds; + }; #endif // USBUINOTIFMSMMERROR_H