imageeditor/inc/iepb.h
changeset 1 edfc90759b9f
equal deleted inserted replaced
0:57d4cdd99204 1:edfc90759b9f
       
     1 /*
       
     2 * Copyright (c) 2010 Ixonos Plc.
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of the "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 * Ixonos Plc
       
    14 *
       
    15 * Description: 
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 
       
    21 #ifndef IMAGEEDITORPLUGINBASE_H
       
    22 #define IMAGEEDITORPLUGINBASE_H
       
    23 
       
    24 ///	INCLUDES
       
    25 #include <e32base.h>
       
    26 #include <e32std.h>
       
    27 #include "pluginbase.h"
       
    28 
       
    29 ///	FORWARD DECLARATIONS
       
    30 class CCoeControl;
       
    31 class CEditorImage;
       
    32 
       
    33 
       
    34 /// CONSTANTS
       
    35 _LIT (KPgnResourcePath, "\\private\\101ffa91\\plugins\\");
       
    36 
       
    37 
       
    38 /*  CLASS: CImageEditorPluginBase
       
    39 *
       
    40 *	CImageEditorPluginBase is a plugin base class for all Image Editor
       
    41 *	plug-ins.
       
    42 */ 
       
    43 class CImageEditorPluginBase :	public CPluginBase
       
    44 {
       
    45 
       
    46 public:
       
    47 
       
    48 /** @name Methods:*/
       
    49 //@{
       
    50 
       
    51 	/** NewL factory method, pops cleanupstack
       
    52     *
       
    53 	*	@param aResourcePath - plug-in resource path
       
    54 	*	@param aResourceFile - plug-in resource file
       
    55 	*	@return CImageEditorPluginBase *, pointer to created CImageEditorPluginBase object
       
    56 	*/
       
    57 	IMPORT_C static CImageEditorPluginBase * NewL (
       
    58         const TDesC & aResourcePath,
       
    59         const TDesC & aResourceFile
       
    60         );
       
    61 
       
    62 	/** Default constructor, cannot leave.
       
    63     *
       
    64 	*	@param -
       
    65 	*	@return -
       
    66 	*/
       
    67 	IMPORT_C CImageEditorPluginBase ();
       
    68 
       
    69 	/** Second phase constructor, may leave
       
    70     *
       
    71 	*	@param aResourcePath - plug-in resource path
       
    72 	*	@param aResourceFile - plug-in resource file
       
    73     *   @return -
       
    74 	*/
       
    75 	IMPORT_C void ConstructL (
       
    76         const TDesC & aResourcePath,
       
    77         const TDesC & aResourceFile
       
    78         );
       
    79 
       
    80     /** Destructor
       
    81 	*	@param -
       
    82 	*	@return -
       
    83 	*/
       
    84 	IMPORT_C virtual ~CImageEditorPluginBase ();
       
    85 
       
    86 	/*	GetProperty
       
    87 	*
       
    88 	*	@see CPluginBase
       
    89 	*/
       
    90 	IMPORT_C virtual TInt SetProperty (
       
    91 		TInt		aPropertyId, 
       
    92 		TDesC &		aPropertyValue
       
    93 		);
       
    94 
       
    95 	/*	GetProperty
       
    96 	*
       
    97 	*	@see CPluginBase
       
    98 	*/
       
    99 	IMPORT_C virtual TInt GetProperty (
       
   100 		TInt		aPropertyId, 
       
   101 		TDes &		aPropertyValue
       
   102 		);
       
   103 
       
   104 	/*	ShowPopupNote
       
   105 	*
       
   106 	*   Shows plug-in related popup note.
       
   107 	*
       
   108 	*	@param -
       
   109 	*	@return -
       
   110 	*/
       
   111 	IMPORT_C virtual void ShowPopupNote ();
       
   112 
       
   113     /**	InitPluginL
       
   114 	*
       
   115 	*	Initializes image processing plug-in and returns CCoeControl.
       
   116 	*
       
   117 	*	@param aRect - control rectangle
       
   118 	*	@param aParent - parent control
       
   119 	*	@param aPluginControl - reference to the plug-in control
       
   120     *	@return CCoeControl - plugin drawing area
       
   121     */
       
   122 	IMPORT_C virtual TInt InitPluginL (
       
   123 		const TRect &		aRect,
       
   124 		CCoeControl *		aParent,
       
   125 		CCoeControl *&		aPluginControl
       
   126 		);
       
   127 
       
   128     /**	ProcessImageL
       
   129 	*
       
   130 	*	Sets the image to be processed.
       
   131 	*
       
   132 	*	@param CFbsBitmap - pointer to CMiaImage instance
       
   133     *	@return -
       
   134     */
       
   135     IMPORT_C virtual void ProcessImageL (CEditorImage * aImage);    
       
   136 
       
   137     /**	ReleasePlugin 
       
   138 	*
       
   139 	*	Releases plugin.
       
   140 	*
       
   141 	*	@param -
       
   142     *	@return -
       
   143     */
       
   144 	IMPORT_C virtual void ReleasePlugin ();    
       
   145 
       
   146 	/*	ReservedImageEditorBaseMethod1
       
   147 	*
       
   148 	*	@see CPluginBase
       
   149 	*/
       
   150 	IMPORT_C virtual void ReservedImageEditorBaseMethod1 ();
       
   151 
       
   152 	/*	ReservedImageEditorBaseMethod2
       
   153 	*
       
   154 	*	@see CPluginBase
       
   155 	*/
       
   156 	IMPORT_C virtual void ReservedImageEditorBaseMethod2 ();
       
   157 
       
   158 //@}
       
   159 
       
   160 protected:
       
   161 
       
   162 /** @name Methods:*/
       
   163 //@{
       
   164 
       
   165 //@}
       
   166 
       
   167 /** @name Members:*/
       
   168 //@{
       
   169 
       
   170 //@}
       
   171 
       
   172 private:
       
   173 
       
   174 /** @name Methods:*/
       
   175 //@{
       
   176 
       
   177 //@}
       
   178 
       
   179 /** @name Members:*/
       
   180 //@{
       
   181 	/*	
       
   182 	*	Internal representation pointer.
       
   183 	*
       
   184 	*	DO NOT add any other private members here, so that the size 
       
   185 	*	of the class stays constant.
       
   186 	*/
       
   187     void * iEditorPluginBaseInternalRepresentation;
       
   188 
       
   189 //@}
       
   190 
       
   191 };
       
   192 
       
   193 
       
   194 #endif
       
   195 
       
   196 // End of File