phonebookui/Phonebook2/CommandsExtension/inc/CPbk2SetImageCmd.h
branchRCL_3
changeset 6 e8e3147d53eb
parent 0 e686773b3f54
equal deleted inserted replaced
5:81f8547efd4f 6:e8e3147d53eb
    24 #include "CPbk2ImageCmdBase.h"
    24 #include "CPbk2ImageCmdBase.h"
    25 #include <MPbk2ImageOperationObservers.h> // MPbk2ImageSetObserver
    25 #include <MPbk2ImageOperationObservers.h> // MPbk2ImageSetObserver
    26 #include <MMGFetchVerifier.h>             // MMGFetchVerifier
    26 #include <MMGFetchVerifier.h>             // MMGFetchVerifier
    27 #include <MediaFileTypes.hrh>
    27 #include <MediaFileTypes.hrh>
    28 #include <badesca.h>
    28 #include <badesca.h>
       
    29 #include <AknProgressDialog.h>
    29 
    30 
    30 
    31 
    31 // FORWARD DECLARATIONS
    32 // FORWARD DECLARATIONS
    32 class CAknWaitDialog;
    33 class CAknWaitDialog;
    33 class CPbk2DrmManager;
    34 class CPbk2DrmManager;
    37 /**
    38 /**
    38  * Set image command event handling class.
    39  * Set image command event handling class.
    39  */
    40  */
    40 NONSHARABLE_CLASS(CPbk2SetImageCmd) : 
    41 NONSHARABLE_CLASS(CPbk2SetImageCmd) : 
    41         public CPbk2ImageCmdBase,
    42         public CPbk2ImageCmdBase,
       
    43         public MProgressDialogCallback,
    42         private MPbk2ImageSetObserver,
    44         private MPbk2ImageSetObserver,
    43         private MMGFetchVerifier
    45         private MMGFetchVerifier        
    44     {
    46     {
    45     public:  // Constructors and destructor
    47     public:  // Constructors and destructor
    46         /**
    48         /**
    47          * Creates a new instance of this class.
    49          * Creates a new instance of this class.
    48          * @param aUiControl 	A related ui control
    50          * @param aUiControl 	A related ui control
    72                 MPbk2ImageOperation& aOperation);
    74                 MPbk2ImageOperation& aOperation);
    73         void Pbk2ImageSetFailed(
    75         void Pbk2ImageSetFailed(
    74                 MPbk2ImageOperation& aOperation,
    76                 MPbk2ImageOperation& aOperation,
    75                 TInt aError);
    77                 TInt aError);
    76 
    78 
       
    79     private: // from MProgressDialogCallback
       
    80         void DialogDismissedL( TInt aButtonId );
       
    81         
    77     private: // from MMGFetchVerifier
    82     private: // from MMGFetchVerifier
    78         TBool VerifySelectionL(
    83         TBool VerifySelectionL(
    79                 const MDesCArray* aSelectedFiles);
    84                 const MDesCArray* aSelectedFiles);        
    80         
       
    81     private:  // Implementation
    85     private:  // Implementation
    82         CPbk2SetImageCmd(
    86         CPbk2SetImageCmd(
    83                 MPbk2ContactUiControl& aUiControl);
    87                 MPbk2ContactUiControl& aUiControl);
    84         void ConstructL();
    88         void ConstructL();
    85         void Cancel();
    89         void Cancel();
    86         void DismissWaitNote();
    90         void DismissWaitNote();
    87         void SetImageRefL(
    91         void SetImageRefL(
    88                 const TDesC& aFileName);
    92                 const TDesC& aFileName);
    89         
    93         
       
    94         TBool DoVerifySelectionL(
       
    95                 const MDesCArray* aSelectedFiles);
       
    96         void ShowErrorNoteL();
       
    97         
    90     private:    // Data
    98     private:    // Data
    91         /// Own: image set operation
    99         /// Own: image set operation
    92         MPbk2ImageOperation* iImageOperation;
   100         MPbk2ImageOperation* iImageOperation;
    93         /// Own: wait note dialog
   101         /// Own: wait note dialog
    94         CAknWaitDialog* iWaitNote;
   102         CAknWaitDialog* iWaitNote;
    95         /// Own: DRM support
   103         /// Own: DRM support
    96         CPbk2DrmManager* iDrmManager;
   104         CPbk2DrmManager* iDrmManager;        
       
   105         TBool iVerificationFailed;
       
   106         TBool iImageSetFailed;
       
   107         TInt iImageSetError;
    97     };
   108     };
    98 
   109 
    99 #endif // CPBK2SETIMAGECMD_H
   110 #endif // CPBK2SETIMAGECMD_H
   100             
   111             
   101 // End of File
   112 // End of File