--- a/usbuis/usbuinotif/inc/usbuinotifmsmmerror.h Sun May 02 21:57:48 2010 +0300
+++ b/usbuis/usbuinotif/inc/usbuinotifmsmmerror.h Mon May 17 11:03:15 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 <hb/hbwidgets/hbdevicemessageboxsymbian.h>
#include "usbnotifier.h" // Base class
-#include <AknQueryDialog.h> // 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<TInt> iStringIds;
- TInt iErrorId;
- };
+ CHbDeviceMessageBoxSymbian* iQuery;
+ CDesCArrayFlat* iStringIds;
+ };
#endif // USBUINOTIFMSMMERROR_H