messagingapp/msgui/unifiededitor/inc/msgunieditorprocessimageoperation.h
changeset 37 518b245aa84c
parent 23 238255e8b033
child 67 fc91263aee62
equal deleted inserted replaced
25:84d9eb65b26f 37:518b245aa84c
    15 *
    15 *
    16 */
    16 */
    17 
    17 
    18 
    18 
    19 
    19 
    20 #ifndef __UNIEDITORPROCESSIMAGEOPERATION_H
    20 #ifndef MSG_UNIFIED_EDITOR_PROCESS_IMAGEOPERATION_H
    21 #define __UNIEDITORPROCESSIMAGEOPERATION_H
    21 #define MSG_UNIFIED_EDITOR_PROCESS_IMAGEOPERATION_H
    22 
    22 
    23 // INCLUDES
    23 // INCLUDES
    24 
    24 
    25 #include <e32base.h>
    25 #include <e32base.h>
       
    26 #include <f32file.h>
    26 #include <msvapi.h>
    27 #include <msvapi.h>
    27 #include <apmstd.h>
    28 #include <apmstd.h>
    28 
    29 
    29 #include <msgunieditorimageprocessor.h>
    30 #include <msgunieditorimageprocessor.h>
    30 #include <cmsvattachment.h>
    31 #include <cmsvattachment.h>
    31 
    32 #include <QObject>
    32 
    33 
    33 // FORWARD DECLARATIONS
    34 // FORWARD DECLARATIONS
    34 
    35 
    35 class CMsgImageInfo; 
    36 class CMsgImageInfo; 
    36 class CMsgImageControl;
    37 class CMsgImageControl;
    37 class CUniEditorDocument;
    38 class CUniEditorDocument;
    38 class MMsvAttachmentManager;
    39 class MMsvAttachmentManager;
    39 class CMsvStore;
    40 class CMsvStore;
    40 
    41 class HbAction;
    41 // DATA TYPES
    42 // DATA TYPES
    42 
    43 
    43 // CLASS DECLARATION
    44 // CLASS DECLARATION
    44 
    45 
    45 enum TUniEditorProcessImageOperationEvent
    46 enum TUniEditorProcessImageOperationEvent
    66 /**
    67 /**
    67 * CUniEditorProcessImageOperation
    68 * CUniEditorProcessImageOperation
    68 *
    69 *
    69 * @since 3.2
    70 * @since 3.2
    70 */
    71 */
    71 class CUniEditorProcessImageOperation : public CActive,
    72 class CUniEditorProcessImageOperation : public QObject,public CActive,
    72                                         public MUniImageProcessorCallback
    73                                         public MUniImageProcessorCallback
    73     {
    74     {
       
    75     Q_OBJECT
       
    76     
    74     public: // new operations
    77     public: // new operations
    75 
    78 
    76         /**
    79         /**
    77         * Factory method
    80         * Factory method
    78         */
    81         */
    79         static CUniEditorProcessImageOperation* NewL( 
    82         static CUniEditorProcessImageOperation* NewL( 
    80             MUniEditorProcessImageOperationObserver &aObserver,
    83             MUniEditorProcessImageOperationObserver &aObserver);
    81             RFs& aFs );
       
    82 
    84 
    83         /**
    85         /**
    84         * Start image process operation
    86         * Start image process operation
    85         *
    87         *
    86         * @param aImageInfo
    88         * @param aImageInfo
   131 
   133 
   132         /**
   134         /**
   133         * C++ constructor
   135         * C++ constructor
   134         */
   136         */
   135         CUniEditorProcessImageOperation( 
   137         CUniEditorProcessImageOperation( 
   136             MUniEditorProcessImageOperationObserver &aObserver,
   138             MUniEditorProcessImageOperationObserver &aObserver);
   137             RFs& aFs );
       
   138 
   139 
   139         /**
   140         /**
   140         * 2nd phase constructor.
   141         * 2nd phase constructor.
   141         */
   142         */
   142         void ConstructL();
   143         void ConstructL();
   204         /**
   205         /**
   205         * Completes operation
   206         * Completes operation
   206         */
   207         */
   207         void CompleteOperation( TInt aError );
   208         void CompleteOperation( TInt aError );
   208         
   209         
       
   210 		/**
       
   211 		* Check image size
       
   212 		*/
       
   213         void checkLargeImage();
       
   214         
       
   215     private slots:
       
   216     
       
   217 		/**
       
   218      	* This slot is called when large image insertion query dialog is launched.
       
   219      	* @param action selected action (yes or no).
       
   220      	*/
       
   221     	void onDialogLargeImage(HbAction* action);
       
   222     
   209     private: // data
   223     private: // data
   210 
   224 
   211         enum TUniProcessStates
   225         enum TUniProcessStates
   212             {
   226             {
   213             EUniProcessImgCheck,
   227             EUniProcessImgCheck,
   242         MUniEditorProcessImageOperationObserver &iObserver;
   256         MUniEditorProcessImageOperationObserver &iObserver;
   243         TInt                        iMaxMmsSize;
   257         TInt                        iMaxMmsSize;
   244         TInt                        iMaxImageWidth;
   258         TInt                        iMaxImageWidth;
   245         TInt                        iMaxImageHeight;
   259         TInt                        iMaxImageHeight;
   246         TInt                        iMmsCreationMode;
   260         TInt                        iMmsCreationMode;
   247         RFs&                        iFs;
   261         RFs                         iFs;
       
   262         TBool largeImageQuery;
   248     };
   263     };
   249 
   264 
   250 #endif //__UNIEDITORPROCESSIMAGEOPERATION_H
   265 #endif //MSG_UNIFIED_EDITOR_PROCESS_IMAGEOPERATION_H