phonebookui/Phonebook2/CommandsExtension/inc/CPbk2SetThumbnailCmd.h
changeset 0 e686773b3f54
equal deleted inserted replaced
-1:000000000000 0:e686773b3f54
       
     1 /*
       
     2 * Copyright (c) 2005-2007 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: 
       
    15 *     Set thumbnail command event handling class.
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 #ifndef CPBK2SETTHUMBNAILCMD_H
       
    21 #define CPBK2SETTHUMBNAILCMD_H
       
    22 
       
    23 //  INCLUDES
       
    24 #include "CPbk2ThumbnailCmdBase.h"
       
    25 #include <MPbk2ImageOperationObservers.h> // MPbk2ImageSetObserver
       
    26 #include <MMGFetchVerifier.h>
       
    27 
       
    28 
       
    29 // FORWARD DECLARATIONS
       
    30 class CAknWaitDialog;
       
    31 class CPbk2DrmManager;
       
    32 
       
    33 // CLASS DECLARATION
       
    34 
       
    35 /**
       
    36  * Thumbnail command event handling class.
       
    37  */
       
    38 NONSHARABLE_CLASS(CPbk2SetThumbnailCmd) : 
       
    39         public CPbk2ThumbnailCmdBase,
       
    40         private MPbk2ImageSetObserver,
       
    41         private MMGFetchVerifier
       
    42     {
       
    43     public:  // Constructors and destructor
       
    44         /**
       
    45          * Creates a new instance of this class.
       
    46          * @param aUiControl 	A related ui control
       
    47          * @return a new instance of this class.
       
    48          */
       
    49         static CPbk2SetThumbnailCmd* NewL
       
    50             (MPbk2ContactUiControl& aUiControl);
       
    51         
       
    52         /**
       
    53          * Destructor.
       
    54          */
       
    55         ~CPbk2SetThumbnailCmd();
       
    56         
       
    57     private: // from CPbk2ThumbnailCmdBase
       
    58         TBool ExecuteCommandL();
       
    59         
       
    60 	private: // from MPbkThumbnailSetObserver
       
    61         void Pbk2ImageSetComplete(MPbk2ImageOperation& aOperation);
       
    62         void Pbk2ImageSetFailed(MPbk2ImageOperation& aOperation, TInt aError);
       
    63 
       
    64     private: // from MMGFetchVerifier
       
    65         TBool VerifySelectionL(const MDesCArray* aSelectedFiles);
       
    66         
       
    67     private:  // Implementation
       
    68         CPbk2SetThumbnailCmd
       
    69             (MPbk2ContactUiControl& aUiControl);
       
    70         void ConstructL();
       
    71         void Cancel();
       
    72         void DismissWaitNote();
       
    73         
       
    74     private:    // Data
       
    75         /// Own: thumbnail set operation
       
    76         MPbk2ImageOperation* iThumbOperation;
       
    77         /// Own: wait note dialog
       
    78         CAknWaitDialog* iWaitNote;
       
    79         /// Own: DRM support
       
    80         CPbk2DrmManager* iDrmManager;
       
    81     };
       
    82 
       
    83 #endif // CPBK2SETTHUMBNAILCMD_H
       
    84             
       
    85 // End of File