# HG changeset patch # User qifeima <> # Date 1277099553 -28800 # Node ID e7871f3699e6d81fc6e0b4d502e45d0f15b0bc01 # Parent a5c0fe6456b2d1dff1902a3d8218dc94765a10a3 *m:Change the icons of doodle functionality diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/group/bld.inf --- a/imageeditor/group/bld.inf Thu Jun 03 19:58:47 2010 +0800 +++ b/imageeditor/group/bld.inf Mon Jun 21 13:52:33 2010 +0800 @@ -38,6 +38,7 @@ #include "../ImageEditorApp/group/bld.inf" /// Plugins +//#ifdef RD_IE_DRAW_PLUGIN #include "../plugins/BlackWhitePlugin/group/bld.inf" #include "../plugins/NegativePlugin/group/bld.inf" #include "../plugins/SepiaPlugin/group/bld.inf" @@ -54,9 +55,10 @@ #include "../plugins/RotateRPlugin/group/bld.inf" #include "../plugins/ResizePlugin/group/bld.inf" #include "../plugins/TextPlugin/group/bld.inf" -//#ifdef RD_IE_DRAW_PLUGIN +//#endif // RD_IE_DRAW_PLUGIN +// #include "../plugins/DrawPlugin/group/bld.inf" -//#endif // RD_IE_DRAW_PLUGIN +// // Editor AIW Provider #include "../EditorProvider/group/bld.inf" diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/imageeditorApp/help/data/xhtml.zip Binary file imageeditor/imageeditorApp/help/data/xhtml.zip has changed diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/imageeditorApp/help/inc/sie.hlp.hrh --- a/imageeditor/imageeditorApp/help/inc/sie.hlp.hrh Thu Jun 03 19:58:47 2010 +0800 +++ b/imageeditor/imageeditorApp/help/inc/sie.hlp.hrh Mon Jun 21 13:52:33 2010 +0800 @@ -14,5 +14,5 @@ _LIT(KSIE_HLP_REDEYE, "SIE_HLP_REDEYE"); // _LIT(KSIE_HLP_ZOOMING, "SIE_HLP_ZOOMING"); // _LIT(KSIE_HLP_MAIN, "SIE_HLP_MAIN"); // - -#endif \ No newline at end of file +_LIT(KSIE_HLP_EDIT_DRAW, "SIE_HLP_EDIT_DRAW"); +#endif diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/PenSize.svg --- a/imageeditor/plugins/DrawPlugin/data/PenSize.svg Thu Jun 03 19:58:47 2010 +0800 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,29 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/exit.svg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/imageeditor/plugins/DrawPlugin/data/exit.svg Mon Jun 21 13:52:33 2010 +0800 @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/info.svg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/imageeditor/plugins/DrawPlugin/data/info.svg Mon Jun 21 13:52:33 2010 +0800 @@ -0,0 +1,965 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/menu.svg --- a/imageeditor/plugins/DrawPlugin/data/menu.svg Thu Jun 03 19:58:47 2010 +0800 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,45 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/palette.svg --- a/imageeditor/plugins/DrawPlugin/data/palette.svg Thu Jun 03 19:58:47 2010 +0800 +++ b/imageeditor/plugins/DrawPlugin/data/palette.svg Mon Jun 21 13:52:33 2010 +0800 @@ -1,55 +1,40 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/palette_colored.svg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/imageeditor/plugins/DrawPlugin/data/palette_colored.svg Mon Jun 21 13:52:33 2010 +0800 @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/pen.svg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/imageeditor/plugins/DrawPlugin/data/pen.svg Mon Jun 21 13:52:33 2010 +0800 @@ -0,0 +1,960 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/qgn_indi_ai_nt_erotic.svg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/imageeditor/plugins/DrawPlugin/data/qgn_indi_ai_nt_erotic.svg Mon Jun 21 13:52:33 2010 +0800 @@ -0,0 +1,22 @@ + + + + + + + + + + + + + + + + + + diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/redo.svg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/imageeditor/plugins/DrawPlugin/data/redo.svg Mon Jun 21 13:52:33 2010 +0800 @@ -0,0 +1,13 @@ + + + + + + + + + + diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/save.svg --- a/imageeditor/plugins/DrawPlugin/data/save.svg Thu Jun 03 19:58:47 2010 +0800 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,51 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/save1.svg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/imageeditor/plugins/DrawPlugin/data/save1.svg Mon Jun 21 13:52:33 2010 +0800 @@ -0,0 +1,16 @@ + + + + + + + + + + + + + diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/save2.svg --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/imageeditor/plugins/DrawPlugin/data/save2.svg Mon Jun 21 13:52:33 2010 +0800 @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/data/undo.svg --- a/imageeditor/plugins/DrawPlugin/data/undo.svg Thu Jun 03 19:58:47 2010 +0800 +++ b/imageeditor/plugins/DrawPlugin/data/undo.svg Mon Jun 21 13:52:33 2010 +0800 @@ -1,14 +1,19 @@ - - - - - - - - - - - - - + + + + + + + + + + + + + + + diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/group/bld.inf --- a/imageeditor/plugins/DrawPlugin/group/bld.inf Thu Jun 03 19:58:47 2010 +0800 +++ b/imageeditor/plugins/DrawPlugin/group/bld.inf Mon Jun 21 13:52:33 2010 +0800 @@ -34,6 +34,10 @@ drawplugin.mmp gnumakefile icons_doodle.mk + +PRJ_EXPORTS +../data/qgn_indi_ai_nt_erotic.svg \epoc32\s60\icons\qgn_indi_ai_nt_erotic.svg + PRJ_EXTENSIONS START EXTENSION s60/mifconv OPTION TARGETFILE draw.mif diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/group/icons_doodle.mk --- a/imageeditor/plugins/DrawPlugin/group/icons_doodle.mk Thu Jun 03 19:58:47 2010 +0800 +++ b/imageeditor/plugins/DrawPlugin/group/icons_doodle.mk Mon Jun 21 13:52:33 2010 +0800 @@ -24,11 +24,14 @@ RESOURCE : mifconv $(ICONTARGETFILENAME) /h$(HEADERFILENAME) \ - /c32,8 ..\data\pensize.svg\ - /c32,8 ..\data\palette.svg\ + /c32,8 ..\data\palette_colored.svg\ /c32,8 ..\data\undo.svg\ - /c32,8 ..\data\save.svg\ - /c32,8 ..\data\menu.svg + /c32,8 ..\data\redo.svg\ + /c32,8 ..\data\exit.svg\ + /c32,8 ..\data\info.svg\ + /c32,8 ..\data\pen.svg\ + /c32,8 ..\data\save1.svg\ + /c32,8 ..\data\save2.svg FREEZE : do_nothing SAVESPACE : do_nothing diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/inc/imageeditordrawcontrol.h --- a/imageeditor/plugins/DrawPlugin/inc/imageeditordrawcontrol.h Thu Jun 03 19:58:47 2010 +0800 +++ b/imageeditor/plugins/DrawPlugin/inc/imageeditordrawcontrol.h Mon Jun 21 13:52:33 2010 +0800 @@ -320,52 +320,50 @@ private: - //@} + /** @name Members:*/ - /** @name Members:*/ - //@{ - /// Ref: to Editor view + // Ref: to Editor view CAknView* iEditorView; - /// Source image size + //Source image size const CSystemParameters* iSysPars; - /// Ref: to Plug-in info + // Ref: to Plug-in info CPluginInfo* iItem; - /// Own: Navigation pane text + //Own: Navigation pane text HBufC* iNaviPaneText; - /// X position + // X position TInt iX; - /// Y position + // Y position TInt iY; - /// Timer for fast key events + // Timer for fast key events CJPTimer* iTimer; TUint32 iKeyCode; - /// Pressed key event code + // Pressed key event code TInt iPressedKeyScanCode; - /// Number of ticks since timer start + // Number of ticks since timer start TInt iTickCount; - /// Multiplier to control the navigation movement speed + // Multiplier to control the navigation movement speed TInt iNaviStepMultiplier; - /// Showing Ok options menu, where some items are dimmed + // Showing Ok options menu, where some items are dimmed TBool iDisplayingOkOptionsMenu; - /// Own: State indicator glyph + // Own: State indicator glyph CFbsBitmap* iIndicator; CFbsBitmap* iIndicatorMask; - /// Ready to render + // Ready to render TBool iReadyToRender; - /// Parameter + // Parameter TBuf<256> iParam; // Popup controller @@ -378,42 +376,51 @@ // Multiplier to control the rotating speed by touch TInt iTouchAngleMultiplier; - /// Resource reader + // Resource reader RConeResourceLoader iResLoader; - /// Line size + // Line size TSize& iSize; - /// Color + // Color TRgb& iRgb; - /// Own: drawn paths + // Own: drawn paths RPointerArray &iPaths; //bitmap device CFbsBitmapDevice* iBitmapDev; CGraphicsContext* iGc; - //@} + private: - + //Get and set tool bar status display or hidden void SetToolBarStatus(); + //The self define component array for tool bar. RPointerArray iLabels; - + //The tool bar area. TRect iLoopMenuRect; + //Mark the button down event TPoint iButtonDownPoint; + //Mark the tool bar start drag point. TPoint iDragStartPoint; + //Prepare drag point. TPoint iDragPrePoint; + //Mark Button up point for stop drag event. TPoint iDragUpPoint; - + //The total of tool bar compoent TInt iTotalComponent; + //The param for drag tool bar event. TInt iDragOffset; + //The param for drag tool bar event. TInt iStartSpeed; - + //The Active Object for drag tool bar. CAnimationAO* iAnimationAO; + //The Active object for tool bar Automatic moving. CRollAO* iRollAo; + //whether the button down point in the tool bar area. + TBool iPointStartInLoopRect; + //Mark for iAnimationAO; + TBool iDragIsStart; + //Current screen layout. + TMainMenuLayout iMainMenuLayout; - TBool iPointStartInLoopRect; - TBool iDragIsStart; - TBool iEnableAnimationEffect; - TMainMenuLayout iMainMenuLayout; - ///implement undo and redo functions. private: @@ -421,17 +428,23 @@ TBool iUndo; TBool iRedo; TBool iCanRedo; - //ETrue: roll in - //EFalse:roll out + //The tool bar Automatic moving direction. TBool iRollDirection; private: - + //The compoent use for display and hidden tool bar. CCustomerComponet *iCustomComponet; + //whether the customer compoent was clicked. TBool iCustomComponetClick; + //Mark the customr compoent last pointer event. TBool iLastPointEventType; + //Mark the tool bar Automatic moving. TBool iRollflag; + //Mark the tool bar status display or hidden. TBool &iDisplayTool; + //Mark in the sizechanged function. TBool iSizeChangeFlag; + //Mark last tool bar event. + TBool iFlagDragToolBar; }; #endif diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/src/CImageLabel.cpp --- a/imageeditor/plugins/DrawPlugin/src/CImageLabel.cpp Thu Jun 03 19:58:47 2010 +0800 +++ b/imageeditor/plugins/DrawPlugin/src/CImageLabel.cpp Mon Jun 21 13:52:33 2010 +0800 @@ -274,14 +274,14 @@ void CImageLabel::CalculateImagePoint() { // landscape - if (iLabelLayout == ELabelHorizontal) + if (iLabelLayout == ELabelVertical) { iImageStartPoint.iX = Rect().iTl.iX + 2; iImageStartPoint.iY = Rect().iBr.iY - (Rect().iBr.iX - Rect().iTl.iX) + 2; } //portrait - else if (iLabelLayout == ELabelVertical) + else if (iLabelLayout ==ELabelHorizontal ) { iImageStartPoint.iX = Rect().iBr.iX - (Rect().iBr.iY - Rect().iTl.iY) + 2; @@ -296,14 +296,14 @@ void CImageLabel::CalculateBoundingRectStartPoint() { // landscape - if (iLabelLayout == ELabelHorizontal) + if (iLabelLayout == ELabelVertical) { iBoundingRectStartPoint.iX = Rect().iTl.iX + 1; iBoundingRectStartPoint.iY = Rect().iBr.iY - (Rect().iBr.iX - Rect().iTl.iX) + 1; } //portrait - else if (iLabelLayout == ELabelVertical) + else if (iLabelLayout == ELabelHorizontal) { iBoundingRectStartPoint.iX = Rect().iBr.iX - (Rect().iBr.iY - Rect().iTl.iY) + 1; @@ -319,7 +319,7 @@ void CImageLabel::CalculateTooltipPoint() { // landscape - if (iLabelLayout == ELabelHorizontal) + if (iLabelLayout == ELabelVertical) { CFont* pFont = NULL; TFontSpec fontSpec = iEikonEnv->TitleFont()->FontSpecInTwips(); @@ -331,9 +331,9 @@ iTooltipStartPoint.iX = Rect().iTl.iX + (Rect().Width() - tooltipLength) / 2; iTooltipStartPoint.iY = Rect().iBr.iY - (Rect().iBr.iX - Rect().iTl.iX); - } + } //portrait - else if (iLabelLayout == ELabelVertical) + else if (iLabelLayout ==ELabelHorizontal ) { CFont* pFont = NULL; TFontSpec fontSpec = iEikonEnv->TitleFont()->FontSpecInTwips(); @@ -357,7 +357,7 @@ void CImageLabel::CalculateZones() { // landscape - if (iLabelLayout == ELabelHorizontal) + if (iLabelLayout == ELabelVertical) { iBoundingSize.iHeight = Rect().iBr.iX - Rect().iTl.iX - 2; iBoundingSize.iWidth = iBoundingSize.iHeight - 2; @@ -366,7 +366,7 @@ iImageSize.iWidth = iBoundingSize.iWidth - 4; } //portrait - else if (iLabelLayout == ELabelVertical) + else if (iLabelLayout ==ELabelHorizontal) { iBoundingSize.iHeight = Rect().iBr.iY - Rect().iTl.iY - 2; iBoundingSize.iWidth = iBoundingSize.iHeight - 2; diff -r a5c0fe6456b2 -r e7871f3699e6 imageeditor/plugins/DrawPlugin/src/imageeditordrawcontrol.cpp --- a/imageeditor/plugins/DrawPlugin/src/imageeditordrawcontrol.cpp Thu Jun 03 19:58:47 2010 +0800 +++ b/imageeditor/plugins/DrawPlugin/src/imageeditordrawcontrol.cpp Mon Jun 21 13:52:33 2010 +0800 @@ -54,17 +54,16 @@ // CONSTANTS const TInt KWait = 1; const TInt KMainTextIndex = 0; -//#define HORIZ TPoint(0,72),TPoint(502,360) -//#define VERTICAL TPoint(0,92),TPoint(360,579) + // --------------------------------------------------------------------------- // NewL // --------------------------------------------------------------------------- -// + CImageEditorDrawControl* CImageEditorDrawControl::NewL(const TRect& aRect, CCoeControl* aParent, RPointerArray& aPaths, TRgb& aRgb, TSize& aSize, TBool &aDisplayTool) { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::NewL()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::NewL()"); CImageEditorDrawControl * self = new (ELeave) CImageEditorDrawControl( aPaths, aRgb, aSize, aDisplayTool); @@ -77,7 +76,6 @@ // --------------------------------------------------------------------------- // CImageEditorDrawControl // --------------------------------------------------------------------------- -// CImageEditorDrawControl::CImageEditorDrawControl( RPointerArray& aPaths, TRgb& aRgb, TSize& aSize, TBool& aDisplayTool) : @@ -92,11 +90,11 @@ // --------------------------------------------------------------------------- // ~CImageEditorDrawControl() // --------------------------------------------------------------------------- -// + CImageEditorDrawControl::~CImageEditorDrawControl() { - LOG(KDrawPluginLogFile, - "CImageEditorDrawControl::~CImageEditorDrawControl()"); + LOG(KDrawPluginLogFile, + "CImageEditorDrawControl::~CImageEditorDrawControl()"); delete iCustomComponet; delete iTimer; delete iIndicator; @@ -108,10 +106,10 @@ delete iGc; delete iBitmapDev; delete iAnimationAO; - + iUndoPaths.ResetAndDestroy(); iResLoader.Close(); - + for (int i = 0; i < iTotalComponent; i++) { CImageLabel* &temp = iLabels[i]; @@ -123,26 +121,23 @@ } iLabels.ResetAndDestroy(); - } // --------------------------------------------------------------------------- // ConstructL // --------------------------------------------------------------------------- -// void CImageEditorDrawControl::ConstructL(const TRect& aRect, CCoeControl* aParent) { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::ConstructL()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::ConstructL()"); CreateWindowL(); EnableDragEvents(); - //iRollDirection = EFalse; + iStatuspaneHeight = aRect.iTl.iY; iUndo = EFalse; iRedo = EFalse; iCanRedo = EFalse; - //iRollDirection = ETrue; // Create resource utility TFileName resFile; // resource file name @@ -162,20 +157,17 @@ iTooltipResize = ControlEnv()->AllocReadResourceL(R_TOOLTIP_TEXT_RESIZE); SetExtentToWholeScreen(); - // TRect a(HORIZ); - // iClientRectH = a; - // TRect b(VERTICAL); - // iClientRectV = b; + iCustomComponetClick = EFalse; TRect rect = Rect(); - //iDisplayTool=ETrue; + //judge the current screen status. if (rect.Width() < rect.Height()) { - InitializeMainMenu(EMainMenuHorizontal); + InitializeMainMenu(EMainMenuVertical); } else if (rect.Width() > rect.Height()) { - InitializeMainMenu(EMainMenuVertical); + InitializeMainMenu(EMainMenuHorizontal); } TRect Trect(TPoint(0, 0), TPoint(50, 50)); @@ -187,7 +179,10 @@ ActivateL(); } - +// --------------------------------------------------------------------------- +// CImageEditorDrawControl::InitializeMainMenu£¨£© +// initialize tool bar component. +// --------------------------------------------------------------------------- void CImageEditorDrawControl::InitializeMainMenu( TMainMenuLayout aMainMenuLayout) { @@ -197,7 +192,7 @@ User::LeaveIfError(CompleteWithAppPath(svgFile)); iTotalComponent = 7; TRect clipRect; - if (iMainMenuLayout == EMainMenuHorizontal) + if (iMainMenuLayout == EMainMenuVertical) { iLoopMenuRect = TRect(TPoint(0, Rect().iBr.iY - 87), TSize(360, 87)); @@ -219,12 +214,12 @@ } CImageLabel* label = CImageLabel::NewL(this, clipRect, - CImageLabel::ELabelHorizontal); + CImageLabel::ELabelVertical); label->SetHandlePointerObserver(this); iLabels.Append(label); } } - else if (iMainMenuLayout == EMainMenuVertical) + else if (iMainMenuLayout ==EMainMenuHorizontal ) { iLoopMenuRect = TRect(TPoint(Rect().iBr.iX - 87, 0), TSize(87, 360)); @@ -245,31 +240,31 @@ } CImageLabel* label = CImageLabel::NewL(this, clipRect, - CImageLabel::ELabelVertical); + CImageLabel::ELabelHorizontal); label->SetHandlePointerObserver(this); iLabels.Append(label); } } - iLabels[0]->SetImage(svgFile, EMbmIcons_doodlePensize); + iLabels[0]->SetImage(svgFile, EMbmIcons_doodlePen); iLabels[0]->SetTooltip(_L("Pensize")); - iLabels[1]->SetImage(svgFile, EMbmIcons_doodlePalette); + iLabels[1]->SetImage(svgFile, EMbmIcons_doodlePalette_colored); iLabels[1]->SetTooltip(_L("Palette")); iLabels[2]->SetImage(svgFile, EMbmIcons_doodleUndo); iLabels[2]->SetTooltip(_L("Undo")); - iLabels[3]->SetImage(svgFile, EMbmIcons_doodlePalette); + iLabels[3]->SetImage(svgFile, EMbmIcons_doodleRedo); iLabels[3]->SetTooltip(_L("Redo")); - - iLabels[4]->SetImage(svgFile, EMbmIcons_doodleSave); + + iLabels[4]->SetImage(svgFile, EMbmIcons_doodleSave1); iLabels[4]->SetTooltip(_L("Save")); - iLabels[5]->SetImage(svgFile, EMbmIcons_doodleMenu); + iLabels[5]->SetImage(svgFile, EMbmIcons_doodleInfo); iLabels[5]->SetTooltip(_L("About")); - iLabels[6]->SetImage(svgFile, EMbmIcons_doodlePensize); + iLabels[6]->SetImage(svgFile, EMbmIcons_doodleSave2); iLabels[6]->SetTooltip(_L("Null")); iAnimationAO = CAnimationAO::NewL(); @@ -284,7 +279,6 @@ iPointStartInLoopRect = EFalse; iDragIsStart = EFalse; - iEnableAnimationEffect = EFalse; iDragOffset = 0; } @@ -295,7 +289,7 @@ // void CImageEditorDrawControl::SetView(CAknView* aView) { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::SetView()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::SetView()"); ASSERT(aView); iEditorView = aView; } @@ -306,7 +300,7 @@ // void CImageEditorDrawControl::SetSelectedUiItemL(CPluginInfo* aItem) { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::SetSelectedUiItemL()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::SetSelectedUiItemL()"); ASSERT(aItem); iItem = aItem; delete iNaviPaneText; @@ -322,7 +316,7 @@ TKeyResponse CImageEditorDrawControl::OfferKeyEventL( const TKeyEvent& aKeyEvent, TEventCode aType) { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::OfferKeyEventL()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::OfferKeyEventL()"); TKeyResponse response = EKeyWasNotConsumed; @@ -459,7 +453,7 @@ } if (iDragIsStart) { - if (iMainMenuLayout == EMainMenuHorizontal) + if (iMainMenuLayout == EMainMenuVertical) { for (TInt i = 0; i < iTotalComponent; i++) { @@ -472,7 +466,7 @@ } } } - else if (iMainMenuLayout == EMainMenuVertical) + else if (iMainMenuLayout ==EMainMenuHorizontal ) { for (TInt i = 0; i < iTotalComponent; i++) { @@ -488,11 +482,19 @@ DrawNow(); } } - +// --------------------------------------------------------------------------- +// CImageEditorDrawControl::SetToolBarStatus() +// Set and get current status : display or hidden. +// --------------------------------------------------------------------------- +// void CImageEditorDrawControl::SetToolBarStatus() { - - if (iMainMenuLayout == EMainMenuHorizontal) + if (iFlagDragToolBar) + { + iDisplayTool = ETrue; + iFlagDragToolBar = EFalse; + } + if (iMainMenuLayout == EMainMenuVertical) { TInt leftX = iLabels[0]->Rect().iTl.iX; TInt rightX = iLabels[iTotalComponent - 1]->Rect().iBr.iX; @@ -501,7 +503,7 @@ else if (rightX == 0) iDisplayTool = EFalse; } - else if (iMainMenuLayout == EMainMenuVertical) + else if (iMainMenuLayout ==EMainMenuHorizontal ) { TInt topY = iLabels[0]->Rect().iTl.iY; TInt bottomY = iLabels[iTotalComponent - 1]->Rect().iBr.iY; @@ -519,8 +521,8 @@ // TDesC& CImageEditorDrawControl::GetParam() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::GetParam()"); - LOGDES(KDrawPluginLogFile, iParam); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::GetParam()"); + LOGDES(KDrawPluginLogFile, iParam); return iParam; } @@ -531,7 +533,7 @@ void CImageEditorDrawControl::SetSystemParameters( const CSystemParameters* aPars) { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::SetSystemParameters()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::SetSystemParameters()"); ASSERT(aPars); iSysPars = aPars; } @@ -542,7 +544,7 @@ // void CImageEditorDrawControl::HandlePluginCommandL(const TInt aCommand) { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::HandlePluginCommandL()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::HandlePluginCommandL()"); switch (aCommand) { @@ -633,7 +635,7 @@ // TInt CImageEditorDrawControl::GetSoftkeyIndexL() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::GetSoftkeyIndexL()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::GetSoftkeyIndexL()"); // : Check needed states TInt state(2); return state; @@ -654,7 +656,7 @@ // TBitField CImageEditorDrawControl::GetDimmedMenuItems() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::GetDimmedMenuItems()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::GetDimmedMenuItems()"); TBitField dimmedMenuItems; TInt count = iItem->MenuItems().Count(); @@ -694,7 +696,7 @@ TBool& aLeftNaviPaneScrollButtonVisibile, TBool& aRightNaviPaneScrollButtonVisible) { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::GetNaviPaneTextL()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::GetNaviPaneTextL()"); aLeftNaviPaneScrollButtonVisibile = EFalse; aRightNaviPaneScrollButtonVisible = EFalse; @@ -738,7 +740,7 @@ // void CImageEditorDrawControl::NaviDown() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::NaviDown()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::NaviDown()"); } // --------------------------------------------------------------------------- @@ -747,7 +749,7 @@ // void CImageEditorDrawControl::NaviUp() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::NaviUp()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::NaviUp()"); } // --------------------------------------------------------------------------- @@ -756,7 +758,7 @@ // void CImageEditorDrawControl::NaviRight() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::NaviRight()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::NaviRight()"); } // --------------------------------------------------------------------------- @@ -765,7 +767,7 @@ // void CImageEditorDrawControl::NaviLeft() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::NaviLeft()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::NaviLeft()"); } // --------------------------------------------------------------------------- @@ -774,7 +776,7 @@ // void CImageEditorDrawControl::SelectSizeL() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::SelectSizeL()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::SelectSizeL()"); // Symmetric line width / height TInt size(iSize.iWidth); CSelectionDialog::RunDlgLD(iPreview, Rect(), size, iRgb, @@ -788,9 +790,9 @@ // void CImageEditorDrawControl::StoreTempParams() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::StoreTempParams(" - "" - ")"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::StoreTempParams(" + "" + ")"); } // --------------------------------------------------------------------------- @@ -799,7 +801,7 @@ // void CImageEditorDrawControl::RestoreTempParams() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::RestoreTempParams()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::RestoreTempParams()"); } // --------------------------------------------------------------------------- @@ -808,10 +810,10 @@ // void CImageEditorDrawControl::GetHelpContext(TCoeHelpContext& aContext) const { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::GetHelpContext()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::GetHelpContext()"); aContext.iMajor = TUid::Uid(UID_IMAGE_EDITOR); - aContext.iContext = KSIE_HLP_EDIT_TEXT; + aContext.iContext = KSIE_HLP_EDIT_DRAW; } // --------------------------------------------------------------------------- @@ -820,7 +822,7 @@ // void CImageEditorDrawControl::PrepareL() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::PrepareL()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::PrepareL()"); // Get current view port TRect rect = iSysPars->VisibleImageRectPrev(); @@ -836,7 +838,7 @@ // void CImageEditorDrawControl::LoadIndicatorL(TInt aBitmapInd, TInt aMaskInd) { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::LoadIndicatorL()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::LoadIndicatorL()"); // Delete old indicator delete iIndicator; @@ -881,7 +883,7 @@ // TBool CImageEditorDrawControl::IsReadyToRender() const { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::IsReadyToRender()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::IsReadyToRender()"); return iReadyToRender; } @@ -891,9 +893,9 @@ // void CImageEditorDrawControl::StoreParameters(TBool aLastItem, TBool aDone) { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::StoreParameters()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::StoreParameters()"); RDebug::Print(_L("CImageEditorDrawControl::StoreParameters color[%d]"), - iRgb.Internal()); + iRgb.Internal()); iParam.Copy(_L("x ")); iParam.AppendNum(iX); @@ -931,7 +933,7 @@ // void CImageEditorDrawControl::TimerCallBack() { - LOG(KDrawPluginLogFile, "CImageEditorDrawControl::TimerCallBack()"); + LOG(KDrawPluginLogFile, "CImageEditorDrawControl::TimerCallBack()"); if (iTickCount > KDefaultFastKeyTimerMultiplyThresholdInTicks) { @@ -970,8 +972,8 @@ default: break; } - //StoreParameters(); - TRAP_IGNORE(iEditorView->HandleCommandL(EImageEditorCmdRender)); + //StoreParameters(); + TRAP_IGNORE(iEditorView->HandleCommandL(EImageEditorCmdRender)); iTimer->Call(KWait); } } @@ -982,8 +984,8 @@ // void CImageEditorDrawControl::StorePosAndScaleRelScreen() { - LOG(KDrawPluginLogFile, - "CImageEditorClipartControl::StorePosAndScaleRelScreen()"); + LOG(KDrawPluginLogFile, + "CImageEditorClipartControl::StorePosAndScaleRelScreen()"); iParam.Copy(_L("nop")); } @@ -993,8 +995,8 @@ // void CImageEditorDrawControl::RestorePosAndScaleRelScreen() { - LOG(KDrawPluginLogFile, - "CImageEditorClipartControl::RestorePosAndScaleRelScreen()"); + LOG(KDrawPluginLogFile, + "CImageEditorClipartControl::RestorePosAndScaleRelScreen()"); } // --------------------------------------------------------------------------- @@ -1004,9 +1006,9 @@ void CImageEditorDrawControl::StorePosAndScaleRelImage() { TReal relscale = iSysPars->RelScale(); - LOGFMT(KDrawPluginLogFile, - "CImageEditorClipartControl::StorePosAndScaleRelImage():%g", - relscale); + LOGFMT(KDrawPluginLogFile, + "CImageEditorClipartControl::StorePosAndScaleRelImage():%g", + relscale); } // --------------------------------------------------------------------------- @@ -1016,9 +1018,9 @@ void CImageEditorDrawControl::RestorePosAndScaleRelImage() { TReal relscale = iSysPars->RelScale(); - LOGFMT(KDrawPluginLogFile, - "CImageEditorClipartControl::RestorePosAndScaleRelImage():%g", - relscale); + LOGFMT(KDrawPluginLogFile, + "CImageEditorClipartControl::RestorePosAndScaleRelImage():%g", + relscale); } // --------------------------------------------------------------------------- @@ -1055,13 +1057,13 @@ { SetToolBarStatus(); RDebug::Print(_L("CImageEditorDrawControl::HandlePointerEventL pen[%d]"), - AknLayoutUtils::PenEnabled()); + AknLayoutUtils::PenEnabled()); if (iRollflag) return; if (AknLayoutUtils::PenEnabled() && !Busy()) { RDebug::Print(_L("CImageEditorDrawControl::iType [%d]"), - aPointerEvent.iType); + aPointerEvent.iType); TBool lastItem(EFalse); TPoint point = aPointerEvent.iPosition; @@ -1073,7 +1075,7 @@ iButtonDownPoint = point; iLastPointEventType = EFalse; CCoeControl::HandlePointerEventL(aPointerEvent); - + //Handle Drag tool bar event. if (iLoopMenuRect.Contains(point) && !iCustomComponetClick && iDisplayTool) @@ -1086,13 +1088,14 @@ } } + //Doodle event. else if ((!iLoopMenuRect.Contains(point) && !iCustomComponetClick && iDisplayTool) || (!iDisplayTool && !iCustomComponetClick)) { iPointStartInLoopRect = EFalse; //System dispose - iReadyToRender = EFalse; + iReadyToRender = EFalse; CDrawPath* lastPath = CDrawPath::NewL(); CleanupStack::PushL(lastPath); lastPath->SetColor(iRgb); @@ -1112,16 +1115,16 @@ iReadyToRender = ETrue; iCustomComponetClick = EFalse; lastItem = ETrue; + CCoeControl::HandlePointerEventL(aPointerEvent); HandleMainMenuButtonUp(point); - CCoeControl::HandlePointerEventL(aPointerEvent); DrawNow(); - + } break; case TPointerEvent::EDrag: { CCoeControl::HandlePointerEventL(aPointerEvent); - //System dispose + //Mark last event use for custompoent. iLastPointEventType = ETrue; if ((iDisplayTool && iPaths.Count() && !iCustomComponetClick @@ -1136,7 +1139,7 @@ SetPositionOnImage(aPointerEvent.iPosition); path->AddItemL(aPointerEvent.iPosition); } - //Self dispose + //Drag customcomponent event if (iCustomComponetClick) { TPoint con(aPointerEvent.iPosition.iX - 25, @@ -1144,10 +1147,11 @@ iCustomComponet->SetExtent(con, TSize(50, 50)); DrawNow(); } - + //Drag tool bar event if (iDisplayTool && iPointStartInLoopRect) { + iFlagDragToolBar = ETrue; HandleMainMenuButtonDrag(point); } } @@ -1172,12 +1176,13 @@ } // --------------------------------------------------------------------------- -// HandleMainMenuButtonUp +// CImageEditorDrawControl::HandleMainMenuButtonUp() +// // --------------------------------------------------------------------------- // void CImageEditorDrawControl::HandleMainMenuButtonUp(TPoint aPoint) { - if (iMainMenuLayout == EMainMenuHorizontal) + if (iMainMenuLayout == EMainMenuVertical) { if (iDragIsStart) { @@ -1193,7 +1198,7 @@ } } } - else if (iMainMenuLayout == EMainMenuVertical) + else if (iMainMenuLayout ==EMainMenuHorizontal ) { if (iDragIsStart) { @@ -1217,14 +1222,14 @@ // void CImageEditorDrawControl::HandleMainMenuButtonDrag(TPoint aPoint) { - if (iMainMenuLayout == EMainMenuHorizontal) + if (iMainMenuLayout == EMainMenuVertical) { if (iPointStartInLoopRect && !iDragIsStart && Abs(aPoint.iX - iButtonDownPoint.iX) >= DRAG_LENGTH) { iDragIsStart = ETrue; iDragStartPoint = aPoint; - + for (TInt i = 0; i < iTotalComponent; i++) { if (iLabels[i]->Rect().Contains(iButtonDownPoint)) @@ -1240,19 +1245,19 @@ iDragUpPoint = aPoint; iDragOffset = aPoint.iX - iDragStartPoint.iX; iDragStartPoint = aPoint; - + CalculateEffectiveOffset(); SizeChanged(); } } - else if (iMainMenuLayout == EMainMenuVertical) + else if (iMainMenuLayout ==EMainMenuHorizontal ) { if (iPointStartInLoopRect && !iDragIsStart && Abs(aPoint.iY - iButtonDownPoint.iY) >= DRAG_LENGTH) { iDragIsStart = ETrue; iDragStartPoint = aPoint; - + for (TInt i = 0; i < iTotalComponent; i++) { if (iLabels[i]->Rect().Contains(iButtonDownPoint)) @@ -1268,7 +1273,7 @@ iDragUpPoint = aPoint; iDragOffset = aPoint.iY - iDragStartPoint.iY; iDragStartPoint = aPoint; - + CalculateEffectiveOffset(); SizeChanged(); } @@ -1331,7 +1336,7 @@ iEditorView->HandleCommandL(EImageEditorCmdRender); iUndo = EFalse; } - //redo + //save and quit else if (iLabels[3] == dynamic_cast (aComponent)) { iRedo = ETrue; @@ -1340,7 +1345,6 @@ iEditorView->HandleCommandL(EImageEditorCmdRender); iRedo = EFalse; } - //save and exit else if (iLabels[4] == dynamic_cast (aComponent)) { iPopupController->HideInfoPopupNote(); @@ -1349,7 +1353,7 @@ } else if (iLabels[5] == dynamic_cast (aComponent)) { - + iEditorView->HandleCommandL(EImageEditorMenuCmdHelp); } else if (iLabels[6] == dynamic_cast (aComponent)) { @@ -1361,7 +1365,7 @@ { iCustomComponetClick = ETrue; } - + if ((!iCustomComponet->GetButtonType()) && (!iLastPointEventType)) { StartTheAnimation(); @@ -1385,10 +1389,10 @@ TInt xPosFactorDivider(visibleImageRectPrev.Width()); TInt yPosFactorDivider(visibleImageRectPrev.Height()); - LOGFMT2(KDrawPluginLogFile, "CImageEditorDrawControl::vir w:%d h:%d", - visibleImageRect.Width(), visibleImageRect.Height()); - LOGFMT2(KDrawPluginLogFile, "CImageEditorDrawControl::virp w:%d h:%d", - visibleImageRectPrev.Width(), visibleImageRectPrev.Height()); + LOGFMT2(KDrawPluginLogFile, "CImageEditorDrawControl::vir w:%d h:%d", + visibleImageRect.Width(), visibleImageRect.Height()); + LOGFMT2(KDrawPluginLogFile, "CImageEditorDrawControl::virp w:%d h:%d", + visibleImageRectPrev.Width(), visibleImageRectPrev.Height()); // Dividing by zero will cause panic -> check if (xPosFactorDivider == 0 || yPosFactorDivider == 0) @@ -1407,8 +1411,8 @@ // - visibleImageRectPrev.iTl.iY) / yPosFactorDivider); TReal yPositionFactor(TReal(aPointedPosition.iY - visibleImageRectPrev.iTl.iY) / yPosFactorDivider); - LOGFMT2(KDrawPluginLogFile, "CImageEditorDrawControl::pfx:%g pfy:%g", - xPositionFactor, yPositionFactor); + LOGFMT2(KDrawPluginLogFile, "CImageEditorDrawControl::pfx:%g pfy:%g", + xPositionFactor, yPositionFactor); // Calculate position on visible image iX = visibleImageRect.iTl.iX + visibleImageRect.Width() @@ -1418,9 +1422,9 @@ * yPositionFactor + 0.5; } - LOGFMT4(KDrawPluginLogFile, - "CImageEditorDrawControl::Draw x:%d iX:%d y:%d iY:%d", - aPointedPosition.iX, iX, aPointedPosition.iY, iY); + LOGFMT4(KDrawPluginLogFile, + "CImageEditorDrawControl::Draw x:%d iX:%d y:%d iY:%d", + aPointedPosition.iX, iX, aPointedPosition.iY, iY); // Check that not out of bounds //ClipPosition(); } @@ -1446,23 +1450,23 @@ TReal yPositionFactor(TReal(iY + visibleImageRectPrev.iTl.iY) / yPosFactorDivider); - LOGFMT2(KDrawPluginLogFile, - "CImageEditorDrawControl::GetPositionOnView xf:%g yf:%g", - xPositionFactor, yPositionFactor); + LOGFMT2(KDrawPluginLogFile, + "CImageEditorDrawControl::GetPositionOnView xf:%g yf:%g", + xPositionFactor, yPositionFactor); - LOGFMT2(KDrawPluginLogFile, - "CImageEditorDrawControl::GetPositionOnView xf:%d yf:%d", - xPosFactorDivider, yPosFactorDivider); + LOGFMT2(KDrawPluginLogFile, + "CImageEditorDrawControl::GetPositionOnView xf:%d yf:%d", + xPosFactorDivider, yPosFactorDivider); - LOGFMT2(KDrawPluginLogFile, - "CImageEditorDrawControl::GetPositionOnView w:%d h:%d", iX, iY); + LOGFMT2(KDrawPluginLogFile, + "CImageEditorDrawControl::GetPositionOnView w:%d h:%d", iX, iY); TInt xPosition(iX + visibleImageRectPrev.iTl.iX); TInt yPosition(iY + visibleImageRectPrev.iTl.iY); - LOGFMT3(KDrawPluginLogFile, - "CImageEditorDrawControl::GetPositionOnView w:%d h:%d S:%g", - xPosition, yPosition, iSysPars->RelScale()); + LOGFMT3(KDrawPluginLogFile, + "CImageEditorDrawControl::GetPositionOnView w:%d h:%d S:%g", + xPosition, yPosition, iSysPars->RelScale()); return TPoint(xPosition, yPosition); } @@ -1478,14 +1482,6 @@ TPoint iconPosition = ComputeIndicatorPosition(); TRect iconRect(iconPosition.iX, iconPosition.iY, iconPosition.iX, iconPosition.iY); - - /*SDrawUtils::ShowToolTip( iPopupController, - this, - iconPosition, - EHRightVTop, - *iTooltipResize ); - */ - } // --------------------------------------------------------------------------- @@ -1505,9 +1501,9 @@ sizeh++; } - LOGFMT3(KDrawPluginLogFile, - "CImageEditorDrawControl::ScaledLineSize w:%d h:%d S:%g", sizew, - sizeh, iSysPars->RelScale()); + LOGFMT3(KDrawPluginLogFile, + "CImageEditorDrawControl::ScaledLineSize w:%d h:%d S:%g", sizew, + sizeh, iSysPars->RelScale()); return TSize(sizew, sizeh); } @@ -1594,8 +1590,7 @@ void CImageEditorDrawControl::Roll() { SetToolBarStatus(); - //TInt leftX = iLabels[0]->Rect().iTl.iX; - //TInt rightX = iLabels[iTotalComponent - 1]->Rect().iBr.iX; + TInt offset = 0; iRollflag = ETrue; if (iDisplayTool) @@ -1603,7 +1598,6 @@ else iRollDirection = ETrue; - if (iRollDirection) { offset = 4; @@ -1612,8 +1606,8 @@ { offset = -4; } - - if (iMainMenuLayout == EMainMenuHorizontal) + + if (iMainMenuLayout == EMainMenuVertical) { for (TInt i = 0; i < iLabels.Count(); i++) { @@ -1625,7 +1619,7 @@ || iLabels[iLabels.Count() - 1]->Rect().iBr.iX == 0) iRollflag = EFalse; } - else if (iMainMenuLayout == EMainMenuVertical) + else if (iMainMenuLayout == EMainMenuHorizontal) { for (TInt i = 0; i < iLabels.Count(); i++) { @@ -1637,12 +1631,11 @@ || iLabels[iLabels.Count() - 1]->Rect().iBr.iY == 0) iRollflag = EFalse; } - + DrawNow(); - + if (!iRollflag) { - //iRollDirection = !iRollDirection; iRollAo->Cancel(); } } @@ -1653,7 +1646,7 @@ // void CImageEditorDrawControl::CalculateEffectiveOffset() { - if (iMainMenuLayout == EMainMenuHorizontal) + if (iMainMenuLayout == EMainMenuVertical) { TInt leftX = iLabels[0]->Rect().iTl.iX; TInt rightX = iLabels[iTotalComponent - 1]->Rect().iBr.iX; @@ -1668,7 +1661,7 @@ iDragOffset = -(rightX - 360); } } - else if (iMainMenuLayout == EMainMenuVertical) + else if (iMainMenuLayout ==EMainMenuHorizontal ) { TInt topY = iLabels[0]->Rect().iTl.iY; TInt bottomY = iLabels[iTotalComponent - 1]->Rect().iBr.iY;