# HG changeset patch # User Dremov Kirill (Nokia-D-MSW/Tampere) # Date 1266612157 -7200 # Node ID f966699dea193979355709c21b51ec1153caaf12 # Parent c743ef5928baffb5cb752d14d4c83c1289d00fee Revision: 201003 Kit: 201007 diff -r c743ef5928ba -r f966699dea19 homescreen_plat/hs_content_control_ui/inc/hscontentcontrolui.h --- a/homescreen_plat/hs_content_control_ui/inc/hscontentcontrolui.h Tue Feb 02 00:04:13 2010 +0200 +++ b/homescreen_plat/hs_content_control_ui/inc/hscontentcontrolui.h Fri Feb 19 22:42:37 2010 +0200 @@ -24,6 +24,7 @@ // Forward declarations class MHsContentController; +class CAknView; /** * Content control UI interface @@ -47,6 +48,16 @@ /** * */ + virtual void DeActivate() = 0; + + /** + * + */ + virtual void Views( RPointerArray& aViews ) = 0; + + /** + * + */ virtual void NotifyWidgetListChanged() = 0; /** @@ -100,6 +111,16 @@ /** * */ + inline void DeActivate(); + + /** + * + */ + inline void Views( RPointerArray& aViews ); + + /** + * + */ inline void NotifyWidgetListChanged(); /** @@ -173,6 +194,15 @@ { // Default implementation of MHsContentControlUi method } +inline void CHsContentControlUi::DeActivate() + { + // Default implementation of MHsContentControlUi method + } +inline void CHsContentControlUi::Views( + RPointerArray& /*aViews*/ ) + { + // Default implementation of MHsContentControlUi method + } inline void CHsContentControlUi::NotifyWidgetListChanged() { // Default implementation of MHsContentControlUi method diff -r c743ef5928ba -r f966699dea19 homescreen_plat/hs_renderingplugin_api/group/bld.inf --- a/homescreen_plat/hs_renderingplugin_api/group/bld.inf Tue Feb 02 00:04:13 2010 +0200 +++ b/homescreen_plat/hs_renderingplugin_api/group/bld.inf Fri Feb 19 22:42:37 2010 +0200 @@ -22,3 +22,4 @@ PRJ_EXPORTS ../inc/xnextrenderingpluginadapter.h APP_LAYER_PLATFORM_EXPORT_PATH(xnextrenderingpluginadapter.h) +../inc/xnexteventhandler.h APP_LAYER_PLATFORM_EXPORT_PATH(xnexteventhandler.h) diff -r c743ef5928ba -r f966699dea19 homescreen_plat/hs_renderingplugin_api/inc/xnexteventhandler.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/homescreen_plat/hs_renderingplugin_api/inc/xnexteventhandler.h Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,42 @@ +/* + * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). + * All rights reserved. + * This component and the accompanying materials are made available + * under the terms of "Eclipse Public License v1.0" + * which accompanies this distribution, and is available + * at the URL "http://www.eclipse.org/legal/epl-v10.html". + * + * Initial Contributors: + * Nokia Corporation - initial contribution. + * + * Contributors: + * + * Description: + * + */ + +#ifndef XNEXTEVENTHANDLER_H +#define XNEXTEVENTHANDLER_H + +// System includes +#include + +/** + * External event hadler interface for routing events from external + * rendering plug-ins to content plug-ins + * + * @since S60 v5.2 + */ +class MXnExtEventHandler + { +public: + /** + * Routes the events from the external rendering plug-ins to content plug-ins + * @since Series 60 5.2 + * @param aEvent Event string + * @param aDestination Destination content plug-in. + */ + virtual void HandleEventL( const TDesC& aEvent, const TDesC8& aDestination ) = 0; + }; + +#endif //XNEXTEVENTHANDLER_H diff -r c743ef5928ba -r f966699dea19 homescreen_plat/hs_renderingplugin_api/inc/xnextrenderingpluginadapter.h --- a/homescreen_plat/hs_renderingplugin_api/inc/xnextrenderingpluginadapter.h Tue Feb 02 00:04:13 2010 +0200 +++ b/homescreen_plat/hs_renderingplugin_api/inc/xnextrenderingpluginadapter.h Fri Feb 19 22:42:37 2010 +0200 @@ -25,6 +25,8 @@ // User includes +class MXnExtEventHandler; + /** * CXnExtRenderingPluginAdapter class * @@ -91,6 +93,24 @@ * Informs size change. */ IMPORT_C virtual void SizeChanged(); + + /** + * Sets the external event handler interface. + * + * @since Series 60 5.2 + * @param aEventHandler Event handler interface. + */ + IMPORT_C virtual void SetEventHandler( MXnExtEventHandler* aEventHandler ); + + /** + * Routes the data stream for the external rendering plugin. + * + * @since Series 60 5.2 + * @param aData Data stream. + * @param aType Type of the stream. + * @param aIndex Index of the data. + */ + IMPORT_C virtual void SetDataL( const TDesC8& aData, const TDesC& aType, TInt aIndex ); private: // Data diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/desktop_20026f4f/hsps/00/widgetconfiguration.xml --- a/idlehomescreen/data/qhd_tch/desktop_20026f4f/hsps/00/widgetconfiguration.xml Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/desktop_20026f4f/hsps/00/widgetconfiguration.xml Fri Feb 19 22:42:37 2010 +0200 @@ -25,7 +25,7 @@ - + diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/00/profile.css --- a/idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/00/profile.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/00/profile.css Fri Feb 19 22:42:37 2010 +0200 @@ -23,13 +23,13 @@ _s60-ampm-font-size: 16px; _s60-digital-font-size: 56px; color: "SKIN(268458534 13056 74)"; - background-color: "SKIN(268458534 9886)"; + background-color: "SKIN(268458534 9916)"; nav-index: appearance; } box.clock_profile { - background-color: "SKIN(268458534 9886)"; + background-color: "SKIN(268458534 9916)"; nav-index: appearance; } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/37/profile.css --- a/idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/37/profile.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/37/profile.css Fri Feb 19 22:42:37 2010 +0200 @@ -23,13 +23,14 @@ _s60-ampm-font-size: 16px; _s60-digital-font-size: 56px; color: "SKIN(268458534 13056 74)"; - background-color: "SKIN(268458534 9886)"; + background-color: "SKIN(268458534 9916)"; nav-index: appearance; } box.clock_profile { - background-color: "SKIN(268458534 9886)"; + background-color: "SKIN(268458534 9916)"; + nav-index: appearance; } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/50/profile.css --- a/idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/50/profile.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/50/profile.css Fri Feb 19 22:42:37 2010 +0200 @@ -23,13 +23,14 @@ _s60-ampm-font-size: 16px; _s60-digital-font-size: 56px; color: "SKIN(268458534 13056 74)"; - background-color: "SKIN(268458534 9886)"; + background-color: "SKIN(268458534 9916)"; nav-index: appearance; } box.clock_profile { - background-color: "SKIN(268458534 9886)"; + background-color: "SKIN(268458534 9916)"; + nav-index: appearance; } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/57/profile.css --- a/idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/57/profile.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/57/profile.css Fri Feb 19 22:42:37 2010 +0200 @@ -23,13 +23,14 @@ _s60-ampm-font-size: 16px; _s60-digital-font-size: 56px; color: "SKIN(268458534 13056 74)"; - background-color: "SKIN(268458534 9886)"; + background-color: "SKIN(268458534 9916)"; nav-index: appearance; } box.clock_profile { - background-color: "SKIN(268458534 9886)"; + background-color: "SKIN(268458534 9916)"; + nav-index: appearance; } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/94/profile.css --- a/idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/94/profile.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/profile_2001cb7c/xuikon/94/profile.css Fri Feb 19 22:42:37 2010 +0200 @@ -23,13 +23,14 @@ _s60-ampm-font-size: 16px; _s60-digital-font-size: 56px; color: "SKIN(268458534 13056 74)"; - background-color: "SKIN(268458534 9886)"; + background-color: "SKIN(268458534 9916)"; nav-index: appearance; } box.clock_profile { - background-color: "SKIN(268458534 9886)"; + background-color: "SKIN(268458534 9916)"; + nav-index: appearance; } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/root_2001f482/conf/root2001f482.confml Binary file idlehomescreen/data/qhd_tch/root_2001f482/conf/root2001f482.confml has changed diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/root_2001f482/group/bld.inf --- a/idlehomescreen/data/qhd_tch/root_2001f482/group/bld.inf Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/root_2001f482/group/bld.inf Fri Feb 19 22:42:37 2010 +0200 @@ -25,7 +25,7 @@ // Support for productization and Carbide.Ui customization //******************************************************** ../hsps/00/manifest.dat /epoc32/data/Z/resource/homescreen/root_2001f482/hsps/manifest.dat -../hsps/00/rootconfiguration.xml /epoc32/data/Z/resource/homescreen/root_2001f482/hsps/rootconfiguration.xml +//../hsps/00/rootconfiguration.xml /epoc32/data/Z/resource/homescreen/root_2001f482/hsps/rootconfiguration.xml ../xuikon/00/Root.dat /epoc32/data/Z/resource/homescreen/root_2001f482/xuikon/root_2001f482.dat ../xuikon/00/Root.css /epoc32/data/Z/resource/homescreen/root_2001f482/xuikon/root.css ../xuikon/00/Root.xml /epoc32/data/Z/resource/homescreen/root_2001f482/xuikon/root.xml @@ -35,8 +35,8 @@ //Confml and cfgml files for the customization // starting use confml it is need to remove root_configuration.xml direct exporting (root_2001f482_variant.iby) //*********************************** -//../conf/root2001f482.confml APP_LAYER_CONFML(root2001f482.confml) -//../conf/root2001f482.gcfml APP_LAYER_GCFML(root2001f482.gcfml) +../conf/root2001f482.confml APP_LAYER_CONFML(root2001f482.confml) +../conf/root2001f482.gcfml APP_LAYER_GCFML(root2001f482.gcfml) // Support for S60 localization //***************************** @@ -46,7 +46,7 @@ //*********************** ../rom/root_resources.iby LANGUAGE_APP_LAYER_IBY_EXPORT_PATH(root_2001f482_resources.iby) ../rom/root_customer.iby CUSTOMER_APP_LAYER_IBY_EXPORT_PATH(root_2001f482_customer.iby) -../rom/root_variant.iby CUSTOMER_APP_LAYER_IBY_EXPORT_PATH(root_2001f482_variant.iby) +//../rom/root_variant.iby CUSTOMER_APP_LAYER_IBY_EXPORT_PATH(root_2001f482_variant.iby) ../rom/root.iby CORE_APP_LAYER_IBY_EXPORT_PATH(root_2001f482.iby) diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/root_2001f482/rom/root_variant.iby --- a/idlehomescreen/data/qhd_tch/root_2001f482/rom/root_variant.iby Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/root_2001f482/rom/root_variant.iby Fri Feb 19 22:42:37 2010 +0200 @@ -22,7 +22,7 @@ #if defined(__LAYOUT_360_640_TOUCH) || defined(__LAYOUT_640_360_TOUCH) // Enabled by variation tools, variant specific -data=ZPRIVATE\200159c0\install\root_2001f482\hsps\00\rootconfiguration.xml \private\200159c0\install\root_2001f482\hsps\00\rootconfiguration.xml +//data=ZPRIVATE\200159c0\install\root_2001f482\hsps\00\rootconfiguration.xml \private\200159c0\install\root_2001f482\hsps\00\rootconfiguration.xml #endif // __LAYOUT_360_640_TOUCH || __LAYOUT_640_360_TOUCH diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/00/templateview.css --- a/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/00/templateview.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/00/templateview.css Fri Feb 19 22:42:37 2010 +0200 @@ -34,6 +34,28 @@ background-color:"SKIN(270501603 8582)"; } +image.widget_indication +{ + display: none; + position: absolute; + + left: auto; + right: 3px; + top: 5px; + + height: 26px; + width: 26px; + + path: "SKIN(270501603 9252)"; + _s60-aspect-ratio: preserve; + z-index: 2; +} + +image.widget_indication:edit +{ + display: block; +} + trigger#hs_popup_open_hold:edit { display: none; @@ -54,3 +76,13 @@ _s60-longtap: true; _s60-aspect-ratio: preserve; } + +softkey#msk_ltr +{ + display: block; +} + +softkey#msk_rtl +{ + display: none; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/00/templateview.xml --- a/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/00/templateview.xml Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/00/templateview.xml Fri Feb 19 22:42:37 2010 +0200 @@ -21,7 +21,8 @@ - + + @@ -33,18 +34,17 @@ - + + - - + - - + @@ -76,38 +76,28 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + @@ -115,23 +105,13 @@ - - + - - - - - - - - - @@ -151,7 +131,7 @@ - + @@ -184,14 +164,6 @@ - - - - - - - - @@ -209,8 +181,7 @@ - - + @@ -227,8 +198,7 @@ - - + @@ -236,8 +206,7 @@ - - + @@ -301,17 +270,24 @@ - - + - + - - + + + + + + + + + + diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/37/templateview.css --- a/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/37/templateview.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/37/templateview.css Fri Feb 19 22:42:37 2010 +0200 @@ -35,6 +35,28 @@ background-color:"SKIN(270501603 8582)"; } +image.widget_indication +{ + display: none; + position: absolute; + + right: auto; + left: 3px; + top: 5px; + + height: 26px; + width: 26px; + + path: "SKIN(270501603 9252)"; + _s60-aspect-ratio: preserve; + z-index: 2; +} + +image.widget_indication:edit +{ + display: block; +} + trigger#hs_popup_open_hold:edit { display: none; @@ -55,3 +77,13 @@ _s60-longtap: true; _s60-aspect-ratio: preserve; } + +softkey#msk_ltr +{ + display: none; +} + +softkey#msk_rtl +{ + display: block; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/50/templateview.css --- a/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/50/templateview.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/50/templateview.css Fri Feb 19 22:42:37 2010 +0200 @@ -35,6 +35,28 @@ background-color:"SKIN(270501603 8582)"; } +image.widget_indication +{ + display: none; + position: absolute; + + right: auto; + left: 3px; + top: 5px; + + height: 26px; + width: 26px; + + path: "SKIN(270501603 9252)"; + _s60-aspect-ratio: preserve; + z-index: 2; +} + +image.widget_indication:edit +{ + display: block; +} + trigger#hs_popup_open_hold:edit { display: none; @@ -55,3 +77,13 @@ _s60-longtap: true; _s60-aspect-ratio: preserve; } + +softkey#msk_ltr +{ + display: none; +} + +softkey#msk_rtl +{ + display: block; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/57/templateview.css --- a/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/57/templateview.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/57/templateview.css Fri Feb 19 22:42:37 2010 +0200 @@ -35,6 +35,28 @@ background-color:"SKIN(270501603 8582)"; } +image.widget_indication +{ + display: none; + position: absolute; + + right: auto; + left: 3px; + top: 5px; + + height: 26px; + width: 26px; + + path: "SKIN(270501603 9252)"; + _s60-aspect-ratio: preserve; + z-index: 2; +} + +image.widget_indication:edit +{ + display: block; +} + trigger#hs_popup_open_hold:edit { display: none; @@ -55,3 +77,13 @@ _s60-longtap: true; _s60-aspect-ratio: preserve; } + +softkey#msk_ltr +{ + display: none; +} + +softkey#msk_rtl +{ + display: block; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/94/templateview.css --- a/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/94/templateview.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/templateview_20026f50/xuikon/94/templateview.css Fri Feb 19 22:42:37 2010 +0200 @@ -35,6 +35,28 @@ background-color:"SKIN(270501603 8582)"; } +image.widget_indication +{ + display: none; + position: absolute; + + right: auto; + left: 3px; + top: 5px; + + height: 26px; + width: 26px; + + path: "SKIN(270501603 9252)"; + _s60-aspect-ratio: preserve; + z-index: 2; +} + +image.widget_indication:edit +{ + display: block; +} + trigger#hs_popup_open_hold:edit { display: none; @@ -55,3 +77,13 @@ _s60-longtap: true; _s60-aspect-ratio: preserve; } + +softkey#msk_ltr +{ + display: none; +} + +softkey#msk_rtl +{ + display: block; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/conf/view2001f486.confml Binary file idlehomescreen/data/qhd_tch/view_2001f48b/conf/view2001f486.confml has changed diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/conf/view2001f486.gcfml --- a/idlehomescreen/data/qhd_tch/view_2001f48b/conf/view2001f486.gcfml Tue Feb 02 00:04:13 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,99 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/conf/view2001f48b.confml Binary file idlehomescreen/data/qhd_tch/view_2001f48b/conf/view2001f48b.confml has changed diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/conf/view2001f48b.gcfml --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlehomescreen/data/qhd_tch/view_2001f48b/conf/view2001f48b.gcfml Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,138 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/group/bld.inf --- a/idlehomescreen/data/qhd_tch/view_2001f48b/group/bld.inf Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/view_2001f48b/group/bld.inf Fri Feb 19 22:42:37 2010 +0200 @@ -25,7 +25,7 @@ // Support for productization and Carbide.Ui customization //******************************************************** ../hsps/00/manifest.dat /epoc32/data/Z/resource/homescreen/view_2001f48b/hsps/manifest.dat -../hsps/00/viewconfiguration.xml /epoc32/data/Z/resource/homescreen/view_2001f48b/hsps/viewconfiguration.xml +//../hsps/00/viewconfiguration.xml /epoc32/data/Z/resource/homescreen/view_2001f48b/hsps/viewconfiguration.xml ../xuikon/00/View.dat /epoc32/data/Z/resource/homescreen/view_2001f48b/xuikon/view_2001f48b.dat ../xuikon/00/View.css /epoc32/data/Z/resource/homescreen/view_2001f48b/xuikon/view.css @@ -41,10 +41,9 @@ //Confml and cfgml files for the customization -// starting use confml it is need to remove root_configuration.xml direct exporting (view_2001f48b_variant.iby) //*********************************** -//../conf/view2001f486.confml APP_LAYER_CONFML(view2001f486.confml) -//../conf/view2001f486.gcfml APP_LAYER_GCFML(view2001f486.gcfml) +../conf/view2001f48b.confml APP_LAYER_CONFML(view2001f48b.confml) +../conf/view2001f48b.gcfml APP_LAYER_GCFML(view2001f48b.gcfml) // Support for S60 localization //***************************** @@ -57,7 +56,7 @@ //*********************** ../rom/view_resources.iby LANGUAGE_APP_LAYER_IBY_EXPORT_PATH(view_2001f48b_resources.iby) ../rom/view_customer.iby CUSTOMER_APP_LAYER_IBY_EXPORT_PATH(view_2001f48b_customer.iby) -../rom/view_variant.iby CUSTOMER_APP_LAYER_IBY_EXPORT_PATH(view_2001f48b_variant.iby) +//../rom/view_variant.iby CUSTOMER_APP_LAYER_IBY_EXPORT_PATH(view_2001f48b_variant.iby) ../rom/view.iby CORE_APP_LAYER_IBY_EXPORT_PATH(view_2001f48b.iby) diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/hsps/00/viewconfiguration.xml --- a/idlehomescreen/data/qhd_tch/view_2001f48b/hsps/00/viewconfiguration.xml Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/view_2001f48b/hsps/00/viewconfiguration.xml Fri Feb 19 22:42:37 2010 +0200 @@ -1,22 +1,22 @@ - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + + + diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/rom/view_variant.iby --- a/idlehomescreen/data/qhd_tch/view_2001f48b/rom/view_variant.iby Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/view_2001f48b/rom/view_variant.iby Fri Feb 19 22:42:37 2010 +0200 @@ -22,7 +22,7 @@ #if defined(__LAYOUT_360_640_TOUCH) || defined(__LAYOUT_640_360_TOUCH) // Enabled by variation tools, variant specific -data=ZPRIVATE\200159c0\install\view_2001f48b\hsps\00\viewconfiguration.xml \private\200159c0\install\view_2001f48b\hsps\00\viewconfiguration.xml +//data=ZPRIVATE\200159c0\install\view_2001f48b\hsps\00\viewconfiguration.xml \private\200159c0\install\view_2001f48b\hsps\00\viewconfiguration.xml #endif // __LAYOUT_360_640_TOUCH || __LAYOUT_640_360_TOUCH diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/00/View.css --- a/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/00/View.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/00/View.css Fri Feb 19 22:42:37 2010 +0200 @@ -34,6 +34,28 @@ background-color:"SKIN(270501603 8582)"; } +image.widget_indication +{ + display: none; + position: absolute; + + left: auto; + right: 3px; + top: 5px; + + height: 26px; + width: 26px; + + path: "SKIN(270501603 9252)"; + _s60-aspect-ratio: preserve; + z-index: 2; +} + +image.widget_indication:edit +{ + display: block; +} + trigger#hs_popup_open_hold:edit { display: none; @@ -53,4 +75,15 @@ { _s60-longtap: true; _s60-aspect-ratio: preserve; -} +} + +softkey#msk_ltr +{ + display: block; +} + +softkey#msk_rtl +{ + display: none; +} + diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/00/View.xml --- a/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/00/View.xml Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/00/View.xml Fri Feb 19 22:42:37 2010 +0200 @@ -21,7 +21,8 @@ - + + @@ -33,18 +34,17 @@ - + + - - + - - + @@ -76,38 +76,28 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - + + + + + + + + + + + + + + + + + + @@ -115,23 +105,13 @@ - - + - - - - - - - - - @@ -151,7 +131,7 @@ - + @@ -184,14 +164,6 @@ - - - - - - - - @@ -209,8 +181,7 @@ - - + @@ -227,8 +198,7 @@ - - + @@ -236,8 +206,7 @@ - - + @@ -301,17 +270,24 @@ - - + - + - - + + + + + + + + + + diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/37/View.css --- a/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/37/View.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/37/View.css Fri Feb 19 22:42:37 2010 +0200 @@ -23,10 +23,7 @@ margin-bottom: 4px; margin-right: 5px; margin-left: 5px; - background-color: "SKIN(268458534 9916)"; - _s60-longtap: true; - nav-index: appearance; } @@ -35,6 +32,28 @@ background-color:"SKIN(270501603 8582)"; } +image.widget_indication +{ + display: none; + position: absolute; + + right: auto; + left: 3px; + top: 5px; + + height: 26px; + width: 26px; + + path: "SKIN(270501603 9252)"; + _s60-aspect-ratio: preserve; + z-index: 2; +} + +image.widget_indication:edit +{ + display: block; +} + trigger#hs_popup_open_hold:edit { display: none; @@ -55,3 +74,13 @@ _s60-longtap: true; _s60-aspect-ratio: preserve; } + +softkey#msk_ltr +{ + display: none; +} + +softkey#msk_rtl +{ + display: block; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/50/View.css --- a/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/50/View.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/50/View.css Fri Feb 19 22:42:37 2010 +0200 @@ -23,10 +23,7 @@ margin-bottom: 4px; margin-right: 5px; margin-left: 5px; - background-color: "SKIN(268458534 9916)"; - _s60-longtap: true; - nav-index: appearance; } @@ -35,6 +32,28 @@ background-color:"SKIN(270501603 8582)"; } +image.widget_indication +{ + display: none; + position: absolute; + + right: auto; + left: 3px; + top: 5px; + + height: 26px; + width: 26px; + + path: "SKIN(270501603 9252)"; + _s60-aspect-ratio: preserve; + z-index: 2; +} + +image.widget_indication:edit +{ + display: block; +} + trigger#hs_popup_open_hold:edit { display: none; @@ -55,3 +74,13 @@ _s60-longtap: true; _s60-aspect-ratio: preserve; } + +softkey#msk_ltr +{ + display: none; +} + +softkey#msk_rtl +{ + display: block; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/57/View.css --- a/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/57/View.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/57/View.css Fri Feb 19 22:42:37 2010 +0200 @@ -23,10 +23,7 @@ margin-bottom: 4px; margin-right: 5px; margin-left: 5px; - background-color: "SKIN(268458534 9916)"; - _s60-longtap: true; - nav-index: appearance; } @@ -35,6 +32,28 @@ background-color:"SKIN(270501603 8582)"; } +image.widget_indication +{ + display: none; + position: absolute; + + right: auto; + left: 3px; + top: 5px; + + height: 26px; + width: 26px; + + path: "SKIN(270501603 9252)"; + _s60-aspect-ratio: preserve; + z-index: 2; +} + +image.widget_indication:edit +{ + display: block; +} + trigger#hs_popup_open_hold:edit { display: none; @@ -55,3 +74,13 @@ _s60-longtap: true; _s60-aspect-ratio: preserve; } + +softkey#msk_ltr +{ + display: none; +} + +softkey#msk_rtl +{ + display: block; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/94/View.css --- a/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/94/View.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/view_2001f48b/xuikon/94/View.css Fri Feb 19 22:42:37 2010 +0200 @@ -23,10 +23,7 @@ margin-bottom: 4px; margin-right: 5px; margin-left: 5px; - background-color: "SKIN(268458534 9916)"; - _s60-longtap: true; - nav-index: appearance; } @@ -35,6 +32,28 @@ background-color:"SKIN(270501603 8582)"; } +image.widget_indication +{ + display: none; + position: absolute; + + right: auto; + left: 3px; + top: 5px; + + height: 26px; + width: 26px; + + path: "SKIN(270501603 9252)"; + _s60-aspect-ratio: preserve; + z-index: 2; +} + +image.widget_indication:edit +{ + display: block; +} + trigger#hs_popup_open_hold:edit { display: none; @@ -55,3 +74,13 @@ _s60-longtap: true; _s60-aspect-ratio: preserve; } + +softkey#msk_ltr +{ + display: none; +} + +softkey#msk_rtl +{ + display: block; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/wideimage_2001f489/group/bld.inf --- a/idlehomescreen/data/qhd_tch/wideimage_2001f489/group/bld.inf Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/wideimage_2001f489/group/bld.inf Fri Feb 19 22:42:37 2010 +0200 @@ -26,11 +26,16 @@ //******************************************************** ../hsps/00/manifest.dat /epoc32/data/Z/resource/homescreen/wideimage_2001f489/hsps/manifest.dat ../hsps/00/widgetconfiguration.xml /epoc32/data/Z/resource/homescreen/wideimage_2001f489/hsps/widgetconfiguration.xml - ../xuikon/00/wideimage.dat /epoc32/data/Z/resource/homescreen/wideimage_2001f489/xuikon/wideimage_2001f489.dat ../xuikon/00/wideimage.css /epoc32/data/Z/resource/homescreen/wideimage_2001f489/xuikon/wideimage.css ../xuikon/00/wideimage.xml /epoc32/data/Z/resource/homescreen/wideimage_2001f489/xuikon/wideimage.xml +// Arabic languages +//***************** +../xuikon/37/wideimage.css /epoc32/data/Z/resource/homescreen/wideimage_2001f489/xuikon/37/wideimage.css +../xuikon/50/wideimage.css /epoc32/data/Z/resource/homescreen/wideimage_2001f489/xuikon/50/wideimage.css +../xuikon/57/wideimage.css /epoc32/data/Z/resource/homescreen/wideimage_2001f489/xuikon/57/wideimage.css +../xuikon/94/wideimage.css /epoc32/data/Z/resource/homescreen/wideimage_2001f489/xuikon/94/wideimage.css // Support for S60 builds //*********************** diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/wideimage_2001f489/xuikon/00/wideimage.css --- a/idlehomescreen/data/qhd_tch/wideimage_2001f489/xuikon/00/wideimage.css Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/data/qhd_tch/wideimage_2001f489/xuikon/00/wideimage.css Fri Feb 19 22:42:37 2010 +0200 @@ -2,6 +2,7 @@ { nav-index: appearance; block-progression:rl; + direction: ltr; } box#image_container @@ -12,8 +13,6 @@ box#default_container { /* Will be updated by content policy */ - block-progression: rl; - direction:ltr; display: block; } @@ -27,6 +26,20 @@ width: 64px; } +text#default_text +{ + padding-left:9px; + padding-right:9px; + height : 10u; + font-line-space: 15; + direction: ltr; + text-align:left; + text-overflow-mode: wrap; + font-family: EAknLogicalFontSecondaryFont; + font-size: 4u; + color: "SKIN(268458534 13056 74)"; +} + animation#loading { position: absolute; @@ -38,16 +51,3 @@ /* Will be updated by dataplugin */ display: none; } - -text -{ - padding-left:9px; - padding-right:9px; - height : 10u; - font-line-space: 15; - text-align:left; - text-overflow-mode: wrap; - font-family: EAknLogicalFontSecondaryFont; - font-size: 4u; - color: "SKIN(268458534 13056 74)"; -} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/wideimage_2001f489/xuikon/37/wideimage.css --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlehomescreen/data/qhd_tch/wideimage_2001f489/xuikon/37/wideimage.css Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,53 @@ +widget#wideimage_template +{ + nav-index: appearance; + block-progression:rl; + direction: rtl; +} + +box#image_container +{ + /* Will be updated by content policy */ + display: none; +} +box#default_container +{ + /* Will be updated by content policy */ + display: block; +} + +image#default_image +{ + padding-top:9px; + padding-bottom:9px; + padding-left:9px; + padding-right:9px; + height: 64px; + width: 64px; +} + +text#default_text +{ + padding-left:9px; + padding-right:9px; + height : 10u; + font-line-space: 15; + direction: ltr; + text-align: right; + text-overflow-mode: wrap; + font-family: EAknLogicalFontSecondaryFont; + font-size: 4u; + color: "SKIN(268458534 13056 74)"; +} + +animation#loading +{ + position: absolute; + top:9px; + left:9px; + right:273px; + width:30px; + height:30px; + /* Will be updated by dataplugin */ + display: none; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/wideimage_2001f489/xuikon/50/wideimage.css --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlehomescreen/data/qhd_tch/wideimage_2001f489/xuikon/50/wideimage.css Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,53 @@ +widget#wideimage_template +{ + nav-index: appearance; + block-progression:rl; + direction: rtl; +} + +box#image_container +{ + /* Will be updated by content policy */ + display: none; +} +box#default_container +{ + /* Will be updated by content policy */ + display: block; +} + +image#default_image +{ + padding-top:9px; + padding-bottom:9px; + padding-left:9px; + padding-right:9px; + height: 64px; + width: 64px; +} + +text#default_text +{ + padding-left:9px; + padding-right:9px; + height : 10u; + font-line-space: 15; + direction: ltr; + text-align: right; + text-overflow-mode: wrap; + font-family: EAknLogicalFontSecondaryFont; + font-size: 4u; + color: "SKIN(268458534 13056 74)"; +} + +animation#loading +{ + position: absolute; + top:9px; + left:9px; + right:273px; + width:30px; + height:30px; + /* Will be updated by dataplugin */ + display: none; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/wideimage_2001f489/xuikon/57/wideimage.css --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlehomescreen/data/qhd_tch/wideimage_2001f489/xuikon/57/wideimage.css Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,53 @@ +widget#wideimage_template +{ + nav-index: appearance; + block-progression:rl; + direction: rtl; +} + +box#image_container +{ + /* Will be updated by content policy */ + display: none; +} +box#default_container +{ + /* Will be updated by content policy */ + display: block; +} + +image#default_image +{ + padding-top:9px; + padding-bottom:9px; + padding-left:9px; + padding-right:9px; + height: 64px; + width: 64px; +} + +text#default_text +{ + padding-left:9px; + padding-right:9px; + height : 10u; + font-line-space: 15; + direction: ltr; + text-align: right; + text-overflow-mode: wrap; + font-family: EAknLogicalFontSecondaryFont; + font-size: 4u; + color: "SKIN(268458534 13056 74)"; +} + +animation#loading +{ + position: absolute; + top:9px; + left:9px; + right:273px; + width:30px; + height:30px; + /* Will be updated by dataplugin */ + display: none; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/data/qhd_tch/wideimage_2001f489/xuikon/94/wideimage.css --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlehomescreen/data/qhd_tch/wideimage_2001f489/xuikon/94/wideimage.css Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,53 @@ +widget#wideimage_template +{ + nav-index: appearance; + block-progression:rl; + direction: rtl; +} + +box#image_container +{ + /* Will be updated by content policy */ + display: none; +} +box#default_container +{ + /* Will be updated by content policy */ + display: block; +} + +image#default_image +{ + padding-top:9px; + padding-bottom:9px; + padding-left:9px; + padding-right:9px; + height: 64px; + width: 64px; +} + +text#default_text +{ + padding-left:9px; + padding-right:9px; + height : 10u; + font-line-space: 15; + direction: ltr; + text-align: right; + text-overflow-mode: wrap; + font-family: EAknLogicalFontSecondaryFont; + font-size: 4u; + color: "SKIN(268458534 13056 74)"; +} + +animation#loading +{ + position: absolute; + top:9px; + left:9px; + right:273px; + width:30px; + height:30px; + /* Will be updated by dataplugin */ + display: none; +} diff -r c743ef5928ba -r f966699dea19 idlehomescreen/help/data/xhtml.zip Binary file idlehomescreen/help/data/xhtml.zip has changed diff -r c743ef5928ba -r f966699dea19 idlehomescreen/help/inc/hmsc.hlp.hrh --- a/idlehomescreen/help/inc/hmsc.hlp.hrh Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/help/inc/hmsc.hlp.hrh Fri Feb 19 22:42:37 2010 +0200 @@ -1,5 +1,5 @@ /* -* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). +* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). * All rights reserved. * This component and the accompanying materials are made available * under the terms of "Eclipse Public License v1.0" diff -r c743ef5928ba -r f966699dea19 idlehomescreen/hscontentcontrol/bwins/hscontentcontrol.def --- a/idlehomescreen/hscontentcontrol/bwins/hscontentcontrol.def Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/hscontentcontrol/bwins/hscontentcontrol.def Fri Feb 19 22:42:37 2010 +0200 @@ -1,6 +1,6 @@ EXPORTS ?NewL@CHsContentControlUi@@SAPAV1@VTUid@@@Z @ 1 NONAME ; class CHsContentControlUi * CHsContentControlUi::NewL(class TUid) ?GetHsContentController@CHsContentControlFactory@@QAEPAVMHsContentControlUi@@ABVTDesC8@@@Z @ 2 NONAME ; class MHsContentControlUi * CHsContentControlFactory::GetHsContentController(class TDesC8 const &) - ?NewL@CHsContentControlFactory@@SAPAV1@XZ @ 3 NONAME ; class CHsContentControlFactory * CHsContentControlFactory::NewL(void) - ??1CHsContentControlFactory@@UAE@XZ @ 4 NONAME ; CHsContentControlFactory::~CHsContentControlFactory(void) + ??1CHsContentControlFactory@@UAE@XZ @ 3 NONAME ; CHsContentControlFactory::~CHsContentControlFactory(void) + ?NewL@CHsContentControlFactory@@SAPAV1@AAVCXnAppUiAdapter@@@Z @ 4 NONAME ; class CHsContentControlFactory * CHsContentControlFactory::NewL(class CXnAppUiAdapter &) diff -r c743ef5928ba -r f966699dea19 idlehomescreen/hscontentcontrol/eabi/hscontentcontrol.def --- a/idlehomescreen/hscontentcontrol/eabi/hscontentcontrol.def Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/hscontentcontrol/eabi/hscontentcontrol.def Fri Feb 19 22:42:37 2010 +0200 @@ -1,7 +1,7 @@ EXPORTS _ZN19CHsContentControlUi4NewLE4TUid @ 1 NONAME _ZN24CHsContentControlFactory22GetHsContentControllerERK6TDesC8 @ 2 NONAME - _ZN24CHsContentControlFactory4NewLEv @ 3 NONAME + _ZN24CHsContentControlFactory4NewLER15CXnAppUiAdapter @ 3 NONAME _ZN24CHsContentControlFactoryD0Ev @ 4 NONAME _ZN24CHsContentControlFactoryD1Ev @ 5 NONAME _ZN24CHsContentControlFactoryD2Ev @ 6 NONAME diff -r c743ef5928ba -r f966699dea19 idlehomescreen/hscontentcontrol/group/hscontentcontrol.mmp --- a/idlehomescreen/hscontentcontrol/group/hscontentcontrol.mmp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/hscontentcontrol/group/hscontentcontrol.mmp Fri Feb 19 22:42:37 2010 +0200 @@ -24,6 +24,7 @@ VENDORID VID_DEFAULT USERINCLUDE ../inc +USERINCLUDE ../../inc APP_LAYER_SYSTEMINCLUDE @@ -59,7 +60,7 @@ LIBRARY estor.lib LIBRARY ecom.lib LIBRARY charconv.lib - +LIBRARY xn3layoutengine.lib #ifdef ENABLE_ABIV2_MODE DEBUGGABLE diff -r c743ef5928ba -r f966699dea19 idlehomescreen/hscontentcontrol/inc/hscontentcontrolfactory.h --- a/idlehomescreen/hscontentcontrol/inc/hscontentcontrolfactory.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/hscontentcontrol/inc/hscontentcontrolfactory.h Fri Feb 19 22:42:37 2010 +0200 @@ -29,6 +29,7 @@ // Forward declarations class CHsContentControlEComListener; class CHsContentControlUninstallMonitor; +class CXnAppUiAdapter; /** * Content control UI base class @@ -49,7 +50,7 @@ /** * Two-phased constructor. */ - IMPORT_C static CHsContentControlFactory* NewL(); + IMPORT_C static CHsContentControlFactory* NewL( CXnAppUiAdapter& aAdapter ); /** * Destructor. @@ -70,17 +71,16 @@ * @param aPkgUid The package UID which is being uninstalled. */ void HandleUninstallEvent( const TUid& aPkgUid ); - + private: // Constructors /** * Constructor */ - CHsContentControlFactory(); + CHsContentControlFactory( CXnAppUiAdapter& aAdapter ); /** Second phase constructor */ void ConstructL(); - public: // New functions /** * @@ -89,6 +89,12 @@ const TDesC8& aControllerType ); private: + + /** + * Deregisters/Removes/Deletes plugin's views from AppUi. + */ + void ReleaseHsCcUi( CHsContentControlUi* aHsContentControlUi ); + /** * Finds and returns loaded ContentControlUi object from array. */ @@ -119,6 +125,11 @@ private: // Data /** + * Reference to XnAppUiAdapter. + */ + CXnAppUiAdapter& iAdapter; + + /** * An array of type CHsContentControlUi ( Owned ). */ RPointerArray< CHsContentControlUi > iHsContentControlUis; diff -r c743ef5928ba -r f966699dea19 idlehomescreen/hscontentcontrol/src/hscontentcontrolfactory.cpp --- a/idlehomescreen/hscontentcontrol/src/hscontentcontrolfactory.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/hscontentcontrol/src/hscontentcontrolfactory.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -18,8 +18,10 @@ // System include files #include #include +#include // User include files +#include "xnappuiadapter.h" #include "hscontentcontrolfactory.h" #include "hscontentcontrolecomlistener.h" #include "hscontentcontroluninstallmonitor.h" @@ -60,9 +62,11 @@ // CHsContentControlFactory::NewL() // ---------------------------------------------------------------------------- // -EXPORT_C CHsContentControlFactory* CHsContentControlFactory::NewL() +EXPORT_C CHsContentControlFactory* CHsContentControlFactory::NewL( + CXnAppUiAdapter& aAdapter ) { - CHsContentControlFactory* self = new ( ELeave ) CHsContentControlFactory(); + CHsContentControlFactory* self = + new ( ELeave ) CHsContentControlFactory( aAdapter ); CleanupStack::PushL( self ); self->ConstructL(); CleanupStack::Pop( self ); @@ -88,7 +92,8 @@ // CHsContentControlFactory::CHsContentControlFactory() // ---------------------------------------------------------------------------- // -CHsContentControlFactory::CHsContentControlFactory() +CHsContentControlFactory::CHsContentControlFactory( CXnAppUiAdapter& aAdapter ) + :iAdapter( aAdapter ) { } @@ -100,6 +105,16 @@ { iImplArray.ResetAndDestroy(); iImplArray.Close(); + + if ( iHsContentControlUis.Count() > 0 ) + { + for( TInt index( iHsContentControlUis.Count() - 1 ); index >= 0; --index ) + { + CHsContentControlUi* cc( iHsContentControlUis[ index ] ); + ReleaseHsCcUi( cc ); + } + } + iHsContentControlUis.ResetAndDestroy(); delete iHsContentControlEComListener; @@ -200,6 +215,7 @@ // ImplUid of plugin must match Sis pkg uid if ( cc && cc->ImplUid() == aPkgUid ) { + ReleaseHsCcUi( cc ); iHsContentControlUis.Remove( index ); delete cc; cc = NULL; @@ -245,6 +261,7 @@ CHsContentControlUi* cc( iHsContentControlUis[ innerIndex ] ); if ( cc && cc->ImplUid() == uid ) { + ReleaseHsCcUi( cc ); iHsContentControlUis.Remove( innerIndex ); delete cc; cc = NULL; @@ -310,6 +327,7 @@ CHsContentControlUi* cc( iHsContentControlUis[ innerIndex ] ); if ( cc && cc->ImplUid() == uid ) { + ReleaseHsCcUi( cc ); iHsContentControlUis.Remove( innerIndex ); delete cc; cc = NULL; @@ -323,4 +341,34 @@ return EFalse; } +// ---------------------------------------------------------------------------- +// CHsContentControlFactory::ReleaseHsCcUi +// ---------------------------------------------------------------------------- +// +void CHsContentControlFactory::ReleaseHsCcUi( + CHsContentControlUi* aHsContentControlUi ) + { + if ( &iAdapter && aHsContentControlUi ) + { + RPointerArray views; + + // notify plugin about deactivation + aHsContentControlUi->DeActivate(); + + // get all views from HsContentControlUi + aHsContentControlUi->Views( views ); + + for ( TInt i=0; i //Enable performance logs //#define AI3_DEBUG_PERFORMANCE +//#define HS_NETWORK_MONITOR //Run AI3 on startup #define FF_HOMESCREEN_COMMON_IDLEFW diff -r c743ef5928ba -r f966699dea19 idlehomescreen/inc/ainativeuiplugins.h --- a/idlehomescreen/inc/ainativeuiplugins.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/inc/ainativeuiplugins.h Fri Feb 19 22:42:37 2010 +0200 @@ -20,11 +20,10 @@ #define AINATIVEUIPLUGINS_H #include -#include "aipropertyextension.h" -#include "aiprofilepluginuids.hrh" +#include const TUid KDeviceStatusPluginUid = { AI_UID_ECOM_IMPLEMENTATION_CONTENTPUBLISHER_DEVSTAPLUGIN }; -_LIT( KDeviceStatusPluginName, "0x102750F8" ); +_LIT( KDeviceStatusPluginName, "DeviceStatus" ); const TUid KShortcutPluginUid = { AI_UID_ECOM_IMPLEMENTATION_CONTENTPUBLISHER_SHORTCUTPLUGIN }; _LIT( KShortcutPluginName, "Shortcut" ); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/inc/xnappuiadapter.h --- a/idlehomescreen/inc/xnappuiadapter.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/inc/xnappuiadapter.h Fri Feb 19 22:42:37 2010 +0200 @@ -61,6 +61,14 @@ // New functions /** + * Removes and deregisters view from AppUi + * + * @since S60 5.2 + * @param aView view to deregister + */ + IMPORT_C void RemoveViewL( CAknView& aView ); + + /** * Get the UI engine * * @since Series 60 3.1 @@ -90,20 +98,24 @@ * To be overriden by subclass. * * @since S60 5.0 - * @param aList list of plugins to load + * @param aPublisher Publisher to load + * @param aReason Load reason + * @return KErrNone if succesful, system wide error code otherwise */ - IMPORT_C virtual void LoadDataPluginsL( - RPointerArray< CXnNodeAppIf >& aList ); + IMPORT_C virtual TInt LoadPublisher( + CXnNodeAppIf& aPublisher, TInt aReason ); /** * Handles data plugin destroying. * To be overriden by subclass. * * @since S60 5.0 - * @param aList list of plugins to destroy + * @param aPublisher Publisher to destroy + * @param aReason Destroy reason + * @return KErrNone if succesful, system wide error code otherwise */ - IMPORT_C virtual void DestroyDataPluginsL( - RPointerArray< CXnNodeAppIf >& aList ); + IMPORT_C virtual TInt DestroyPublisher( + CXnNodeAppIf& aPublisher, TInt aReason ); /** * Handles dynamic menuitem element initialisation. @@ -117,16 +129,6 @@ IMPORT_C virtual TBool DynInitMenuItemL( const TDesC& aItemType, RPointerArray< CXnNodeAppIf >* aList = NULL ); - - /** - * Determines and sets data plugins to online. - * To be overriden by subclass. - * - * @since S60 5.0 - * @param aList List of data plugins - */ - IMPORT_C virtual void SetOnlineStateL( - RPointerArray< CXnNodeAppIf >& aList ); /* * Returns the Xml Ui view as CAknView reference. @@ -135,15 +137,7 @@ * @return Xml Ui View */ IMPORT_C CAknView& CXnAppUiAdapter::View() const; - - /** - * Handles page switch changes - * To be overriden by subclass. - * - * @since S60 5.0 - */ - IMPORT_C virtual void HandlePageSwitch(); - + /** * Handles changes when entering or exiting edit mode * To be overriden by subclass. @@ -153,6 +147,16 @@ */ IMPORT_C virtual void HandleEnterEditModeL( TBool aEnter ); + /** + * Routes the events from external rendering plug-ins to content plug-ins. + * + * @since S60 5.2 + * @param aEvent Event string + * @param aDestination Destination node for the event + */ + IMPORT_C virtual void HandleEventL( const TDesC& aEvent, + CXnNodeAppIf& aDestination ); + public: /** * From CEikAppUi. @@ -170,7 +174,14 @@ * @since Series 60 3.1 */ IMPORT_C void HandleResourceChangeL( TInt aType ); - + + /** + * From CAknAppUi. + * + * @since Series 60 5.2 + */ + IMPORT_C void PrepareToExit(); + public: // new functions @@ -262,6 +273,11 @@ // Data /** + * flag for application exit + */ + TBool iExitingApp; + + /** * application uid */ TUid iApplicationUid; diff -r c743ef5928ba -r f966699dea19 idlehomescreen/inc/xncomponent.h --- a/idlehomescreen/inc/xncomponent.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/inc/xncomponent.h Fri Feb 19 22:42:37 2010 +0200 @@ -35,7 +35,7 @@ * Xuikon component base class. * * @ingroup group_xnlayoutengine - * @lib ?library + * @lib xnlayoutengine.lib * @since Series 60 3.1 */ class CXnComponent : public CBase @@ -121,6 +121,18 @@ * Two-phased constructor. */ IMPORT_C void ConstructL(); + +public: + + /** + * Routes the data stream for the external rendering plugin. + * + * @since Series 60 5.2 + * @param aData Data stream. + * @param aType Type of the stream. + * @param aIndex Index of the data. + */ + IMPORT_C void SetDataL( const TDesC8& aData, const TDesC& aType, TInt aIndex ); private: // Data diff -r c743ef5928ba -r f966699dea19 idlehomescreen/inc/xncontroladapter.h --- a/idlehomescreen/inc/xncontroladapter.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/inc/xncontroladapter.h Fri Feb 19 22:42:37 2010 +0200 @@ -420,6 +420,11 @@ * Remove all child adapters */ void RemoveChildAdapters(); + + /** + * Set Longtap delays + */ + void SetLongTapDelays( const TInt aStartDelay, const TInt aLongTapDelay ); /** * Get child adapter list i.e which are not window owning controls @@ -430,6 +435,16 @@ * Determines wheter control refuses focus loss */ virtual TBool RefusesFocusLoss() const { return EFalse; }; + + /** + * Routes the data stream for the external rendering plugin. + * + * @since Series 60 5.2 + * @param aData Data stream. + * @param aType Type of the stream. + * @param aIndex Index of the data. + */ + IMPORT_C virtual void SetDataL( const TDesC8& aData, const TDesC& aType, TInt aIndex ); private: // Data @@ -445,6 +460,16 @@ * Own. */ CAknLongTapDetector* iLongTapDetector; + + /** + * Long tap delay + */ + TInt iCurrentLongTapTimeDelay; + + /** + * Start Long tap delay + */ + TInt iCurrentLongTapStartDelay; }; // Inline functions diff -r c743ef5928ba -r f966699dea19 idlehomescreen/inc/xneditmode.h --- a/idlehomescreen/inc/xneditmode.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/inc/xneditmode.h Fri Feb 19 22:42:37 2010 +0200 @@ -156,8 +156,9 @@ * Sets the title for status pane * * @since Series 60 5.0 + * @param aEdit Edit mode or not. */ - void SetStatusPaneTitleL(); + void SetStatusPaneTitleL( TBool aEdit ); private: // Constructors diff -r c743ef5928ba -r f966699dea19 idlehomescreen/inc/xnnodeappif.h --- a/idlehomescreen/inc/xnnodeappif.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/inc/xnnodeappif.h Fri Feb 19 22:42:37 2010 +0200 @@ -30,6 +30,7 @@ class CXnProperty; class CXnNode; class TXnUiEngineAppIf; +class CXnComponent; namespace XnComponentInterface { @@ -247,6 +248,14 @@ * Get namespace of this node */ IMPORT_C const TDesC8& Namespace(); + + /** + * Get the component object of the node. + * + * @since Series 60 5.2 + * @return component object + */ + IMPORT_C CXnComponent& Component(); private: // Data diff -r c743ef5928ba -r f966699dea19 idlehomescreen/inc/xnproperty.h --- a/idlehomescreen/inc/xnproperty.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/inc/xnproperty.h Fri Feb 19 22:42:37 2010 +0200 @@ -86,15 +86,16 @@ _LIT8(KLeft, "left"); } } - namespace styluspopup + namespace popup { - _LIT8(KPositionHint, "_s60-position-hint"); - namespace positionhint + _LIT8(KPopupType, "_s60-popup-type"); + + namespace popuptype { - _LIT8(KAbove, "above"); -// _LIT8(KBelow, "below"); - } - } + _LIT8(KNormal, "normal"); + _LIT8(KPermanent, "permanent"); + } + } namespace view { // _LIT8(KUid, "uid"); @@ -427,7 +428,6 @@ _LIT8(KRemoveFocusedWidget, "system/removefocusedwidget"); _LIT8(KRemoveWidget, "system/removewidget"); _LIT8(KAddWidget, "system/addwidget"); - _LIT8(KRunFullScreenEffect, "system/runfullscreeneffect"); _LIT8(KActivateView, "system/activateview"); _LIT8(KActivateNextView, "system/activatenextview"); _LIT8(KActivatePreviousView, "system/activatepreviousview"); @@ -453,6 +453,8 @@ /*_LIT8(KStoreFocus, "system/storefocus"); _LIT8(KRestoreFocus, "system/restorefocus");*/ _LIT8(KSetWallpaper, "system/setwallpaper"); + _LIT8(KActivateTextEditor, "system/activatetexteditor"); + _LIT8(KDeactivateTextEditor, "system/deactivatetexteditor"); _LIT8(KActivateSelectedItem, "system/activateselecteditem"); _LIT8(KDestination, "destination"); _LIT8(KBroadcast, "broadcast"); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/inc/xntexteditor.h --- a/idlehomescreen/inc/xntexteditor.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/inc/xntexteditor.h Fri Feb 19 22:42:37 2010 +0200 @@ -54,6 +54,14 @@ */ virtual const HBufC* Text() = 0; + /** + * Handles editor events + * + * @since S60 5.2 + * @param aReason, editor event + */ + virtual void HandleEditorEvent( TInt aReason ) = 0; + private: }; } @@ -67,6 +75,18 @@ { public: +/** + * Editor events + */ + enum TEditorEvent + { + KActivateTextEditor, + KDeactivateTextEditor, + KRemoveSplitInputFromStack, + KKeepSplitInputInStack + }; +public: + /** * 2 phase construction. */ @@ -91,6 +111,14 @@ */ const HBufC* Text(); + /** + * Handles editor events + * + * @since S60 5.2 + * @param aReason, editor event + */ + void HandleEditorEvent( TInt aReason ); + public: // from CCoeControl /** diff -r c743ef5928ba -r f966699dea19 idlehomescreen/inc/xnuiengine.h --- a/idlehomescreen/inc/xnuiengine.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/inc/xnuiengine.h Fri Feb 19 22:42:37 2010 +0200 @@ -412,19 +412,6 @@ CXnHitTest& HitTest() const; /** - * Positions stylus popup according given position - * - * @since S60 5.1 - * @param aNode stylus popup node - * @param aReference a reference node where popup should fit - * @param aPosition stylus popup position to set. - */ - void PositionStylusPopupL( - CXnNode& aNode, - CXnNode& aReference, - const TPoint& aPosition ); - - /** * Gets theme resource file * * @since S60 5.1 @@ -457,6 +444,23 @@ */ void SetEventDispatcher( CXnKeyEventDispatcher* aDispatcher ); + /** + * Enables partial touch input + * + * @since Series 60 5.2 + * @param aNode Editor Node + * @param TBool True if partial input is open + */ + void EnablePartialTouchInput( CXnNode& aNode, TBool aEnable ); + + /** + * Is partial input active + * + * @since Series 60 5.2 + * @return TBool is partial input active + */ + TBool IsPartialInputActive(); + private: /** * C++ default constructor. diff -r c743ef5928ba -r f966699dea19 idlehomescreen/inc/xnuienginepluginif.h --- a/idlehomescreen/inc/xnuienginepluginif.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/inc/xnuienginepluginif.h Fri Feb 19 22:42:37 2010 +0200 @@ -321,7 +321,16 @@ * @since Series 60 5.0 */ IMPORT_C void DisableRenderUiLC(); - + + /** + * Enables partial touch input + * + * @since Series 60 5.2 + * @param aNode Editor Node + * @param TBool True if partial input is open + */ + IMPORT_C void EnablePartialTouchInput( CXnNodePluginIf& aNode, TBool aEnable ); + private: // Data diff -r c743ef5928ba -r f966699dea19 idlehomescreen/inc/xnviewmanager.h --- a/idlehomescreen/inc/xnviewmanager.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/inc/xnviewmanager.h Fri Feb 19 22:42:37 2010 +0200 @@ -11,8 +11,7 @@ * * Contributors: * -* Description: -* Management of views in UiEngine +* Description: View Manager * */ @@ -21,7 +20,6 @@ // System includes #include -#include // Forward declarations class CXnUiEngine; @@ -86,23 +84,35 @@ */ NONSHARABLE_CLASS( CXnViewManager ) : public CBase { - // Friend classes - friend class CXnViewAdapter; - public: /** * Two-phased constructor. */ static CXnViewManager* NewL( CXnAppUiAdapter& aAdapter ); - + + /** + * Two-phased constructor. + */ static CXnViewManager* NewLC( CXnAppUiAdapter& aAdapter ); + /** + * Destructor + */ ~CXnViewManager(); private: + // constructors + + /** + * C++ constructor + */ CXnViewManager( CXnAppUiAdapter& aAdapter ); + + /** + * 2nd phase constructor + */ void ConstructL(); public: @@ -148,24 +158,24 @@ CXnPluginData& aPluginData ); TInt UnloadWidgetFromPluginL( - CXnPluginData& aPluginData ); + CXnPluginData& aPluginData, TBool aForce = EFalse ); TInt ReplaceWidgetToPluginL( CHsContentInfo& aContentInfo, CXnPluginData& aPluginData, TBool aUseHsps = ETrue ); - void ActivateNextViewL(); + void ActivateNextViewL( TInt aEffectId = 0 ); - void ActivatePreviousViewL(); + void ActivatePreviousViewL( TInt aEffectId = 0 ); TInt AddViewL( CHsContentInfo& aInfo ); - void AddViewL(); + void AddViewL( TInt aEffectId = 0 ); TInt RemoveViewL( const CHsContentInfo& aInfo ); - void RemoveViewL(); + void RemoveViewL( TInt aEffectId = 0 ); void AddObserver( const MXnViewObserver& aObserver ); @@ -174,13 +184,7 @@ CXnRootData& ActiveAppData() const; CXnViewData& ActiveViewData() const; - - void SetFirstPassDrawCompleteL(); - - void SetDataPluginLoadCompleteL( const CXnPluginData& aPluginData ); - - void UpdatePluginStateL( CXnPluginData& aPluginData ); - + TInt ActivateAppL( const TDesC8& aPluginUid ); TInt ActivateViewL( const TDesC8& aPluginId ); @@ -188,16 +192,15 @@ TInt ViewIndex() const; + TInt MaxPages() const; + CXnOomSysHandler& OomSysHandler() const; - /** - * Get maximum pages allowed - * - * @return number of pages allowed - */ - TInt32 MaxPages(); - + void UpdatePageManagementInformationL(); + private: + // new functions + void NotifyContainerChangedL( CXnViewData& aViewToActivate ); void NotifyViewActivatedL( const CXnViewData& aViewData ); @@ -223,23 +226,36 @@ CXnViewData& NextViewData() const; void UpdateCachesL(); - - void ValidateActiveViewL(); - - void InvalidateActiveView(); - + void ReportWidgetAmountL( const CXnViewData& aViewData ); void ShowDiskFullMessageL() const; - -public: - void UpdatePageManagementInformationL(); + -private: TInt ResolveIconIndex( TInt aPageCount, TInt aPageNum ) const; void UpdateWallpaperL( CXnViewData& aCurrent, CXnViewData& aNew ); + + /** + * Callback for stability timer + * + * @param aAny Pointer to CViewManager object + * @return TInt System wide error code. + */ + static TInt SystemStabileTimerCallback( TAny* aAny ); + /** + * Reset crash count + */ + void ResetCrashCount(); + + /** + * Show error note + * + * @param aResourceId Resource id for string to be displayed. + */ + void ShowErrorNoteL( const TInt aResourceId ); + private: // data @@ -314,22 +330,21 @@ * Own. */ RPointerArray< MXnViewObserver > iObservers; - - /** - * Failed plugins. - * Own. - */ - RPointerArray< CXnPluginData > iFailedPlugins; /** - * Flags - */ - TBitFlags32 iFlags; - - /** * OOM system handler. Owned. */ - CXnOomSysHandler* iOomSysHandler; + CXnOomSysHandler* iOomSysHandler; + +private: + // Friend classes + + friend class CXnViewAdapter; + + /** + * Timer for system stability. + */ + CPeriodic* iStabilityTimer; }; // Inline functions diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/group/ainatiui.mmp --- a/idlehomescreen/nativeuicontroller/group/ainatiui.mmp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/group/ainatiui.mmp Fri Feb 19 22:42:37 2010 +0200 @@ -41,8 +41,6 @@ SOURCE aisoftkeyrenderer.cpp SOURCE ainativeuimodel.cpp SOURCE aistatuspanetouchui.cpp -SOURCE aitoolbarrenderer.cpp -SOURCE aitoolbarbutton.cpp SOURCE ainotifierrenderer.cpp diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/inc/aidialogrenderer.h --- a/idlehomescreen/nativeuicontroller/inc/aidialogrenderer.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/inc/aidialogrenderer.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,12 +19,15 @@ #ifndef C_AIDIALOGRENDERER_H #define C_AIDIALOGRENDERER_H +// System incldues +#include -#include +// User includes #include "ainativerenderer.h" - +// Forward declarations class CAknNoteDialog; +class CHsContentPublisher; namespace AiNativeUiController { @@ -36,7 +39,7 @@ * * @since S60 3.2 */ -class CAiDialogRenderer : public CAiNativeRenderer +NONSHARABLE_CLASS( CAiDialogRenderer ) : public CAiNativeRenderer { public: @@ -46,9 +49,9 @@ // from base class CAiNativeRenderer - void DoPublishL( MAiPropertyExtension& aPlugin, TInt aContent, TInt aResource, TInt aIndex ); + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, TInt aResource, TInt aIndex ); - void DoCleanL( MAiPropertyExtension& aPlugin, TInt aContent ); + void DoCleanL( CHsContentPublisher& aPlugin, TInt aContent ); void FocusObtainedL(); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/inc/ainativerenderer.h --- a/idlehomescreen/nativeuicontroller/inc/ainativerenderer.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/inc/ainativerenderer.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,14 +19,16 @@ #ifndef M_AINATIVERENDERER_H #define M_AINATIVERENDERER_H +// System includes #include + +// User includes #include "aidevicestatuscontentmodel.h" -#include "aiscutcontentmodel.h" #include "aiprofileplugincontentmodel.h" - +// Forward declarations +class CHsContentPublisher; class RFile; -class MAiPropertyExtension; namespace AiNativeUiController { @@ -36,13 +38,15 @@ * * @since S60 3.2 */ -class CAiNativeRenderer : public CBase +NONSHARABLE_CLASS( CAiNativeRenderer ) : public CBase { +public: + + ~CAiNativeRenderer(); public: - - virtual ~CAiNativeRenderer(); - + // new methods + /** * Publish resource. * @@ -53,7 +57,7 @@ * @param aIndex is index of the content. * @return KErrNone if publish is successful. */ - virtual TInt Publish( MAiPropertyExtension& aPlugin, + virtual TInt Publish( CHsContentPublisher& aPlugin, TInt aContent, TInt aResource, TInt aIndex ); @@ -68,7 +72,7 @@ * @param aIndex is index of the content. * @return KErrNone if publish is successful. */ - virtual TInt Publish( MAiPropertyExtension& aPlugin, + virtual TInt Publish( CHsContentPublisher& aPlugin, TInt aContent, const TDesC16& aText, TInt aIndex ); @@ -83,7 +87,7 @@ * @param aIndex is index of the content. * @return KErrNone if publish is successful. */ - virtual TInt Publish( MAiPropertyExtension& aPlugin, + virtual TInt Publish( CHsContentPublisher& aPlugin, TInt aContent, const TDesC8& aBuf, TInt aIndex ); @@ -98,7 +102,7 @@ * @param aIndex is index of the content. * @return KErrNone if publish is successful. */ - virtual TInt Publish( MAiPropertyExtension& aPlugin, + virtual TInt Publish( CHsContentPublisher& aPlugin, TInt aContent, RFile& aFile, TInt aIndex ); @@ -112,7 +116,7 @@ * @param aIndex is index of the content. * @return KErrNone if cleaning works. */ - virtual TInt Clean( MAiPropertyExtension& aPlugin, TInt aContent ); + virtual TInt Clean( CHsContentPublisher& aPlugin, TInt aContent ); /** * Renderer must implement this method if it needs to support resource publishing. @@ -125,7 +129,7 @@ * @param aResource is id of the resource. * @param aIndex is index of the content. */ - virtual void DoPublishL( MAiPropertyExtension& aPlugin, + virtual void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, TInt aResource, TInt aIndex ); @@ -141,7 +145,7 @@ * @param aText is published text. * @param aIndex is index of the content. */ - virtual void DoPublishL( MAiPropertyExtension& aPlugin, + virtual void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, const TDesC16& aText, TInt aIndex ); @@ -157,7 +161,7 @@ * @param aBuf is published data. * @param aIndex is index of the content. */ - virtual void DoPublishL( MAiPropertyExtension& aPlugin, + virtual void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, const TDesC8& aBuf, TInt aIndex ); @@ -173,7 +177,7 @@ * @param aFile is reference to file client. * @param aIndex is index of the content. */ - virtual void DoPublishL( MAiPropertyExtension& aPlugin, + virtual void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, RFile& aFile, TInt aIndex ); @@ -187,7 +191,7 @@ * @param aPlugin is publishing plugin. * @param aContent is id of the content. */ - virtual void DoCleanL( MAiPropertyExtension& aPlugin, TInt aContent ); + virtual void DoCleanL( CHsContentPublisher& aPlugin, TInt aContent ); /** * Called when UI switches to foreground. @@ -238,7 +242,7 @@ * @param aMimeType is mime type. * @return ETrue if match is successful. */ - TBool MatchMimeType( MAiPropertyExtension& aPlugin, TInt aContentId, const TDesC8& aMimeType ) const; + TBool MatchMimeType( CHsContentPublisher& aPlugin, TInt aContentId, const TDesC8& aMimeType ) const; /** @@ -248,7 +252,7 @@ * @param aPlugin is publishing plugin. * @param aContentId is id of the content. */ - void DoMimeTypeCheckL( MAiPropertyExtension& aPlugin, TInt aContentId ); + void DoMimeTypeCheckL( CHsContentPublisher& aPlugin, TInt aContentId ); }; diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/inc/ainavipanerenderer.h --- a/idlehomescreen/nativeuicontroller/inc/ainavipanerenderer.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/inc/ainavipanerenderer.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,15 +19,16 @@ #ifndef C_AINAVIPANERENDERER_H #define C_AINAVIPANERENDERER_H +// System includes +#include -#include +// User includes #include "ainativerenderer.h" #include "ainavipaneanimatorcallback.h" #include "ainativeuimodel.h" namespace AiNativeUiController { - class CAiStatusPanel; class CAiNaviPaneAnimator; @@ -40,9 +41,8 @@ * @since S60 3.2 */ // inheritance order must be this, despite codescanner warnings -class CAiNaviPaneRenderer : public MAiNaviPaneAnimatorCallback, - public CAiNativeRenderer - +NONSHARABLE_CLASS( CAiNaviPaneRenderer ) : public MAiNaviPaneAnimatorCallback, + public CAiNativeRenderer { public: @@ -52,12 +52,12 @@ // from base class CAiNativeRenderer - void DoPublishL( MAiPropertyExtension& aPlugin, + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, const TDesC16& aText, TInt aIndex ); - void DoCleanL( MAiPropertyExtension& aPlugin, TInt aContent ); + void DoCleanL( CHsContentPublisher& aPlugin, TInt aContent ); void FocusObtainedL(); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/inc/ainotifierrenderer.h --- a/idlehomescreen/nativeuicontroller/inc/ainotifierrenderer.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/inc/ainotifierrenderer.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,16 +19,19 @@ #ifndef C_AISOFTNOTIFERRENDERER_H #define C_AISOFTNOTIFERRENDERER_H - +// System includes #include -#include "ainativerenderer.h" #include +// User includes +#include "ainativerenderer.h" + +// Forward declarations +class CHsContentPublisher; class CAknSoftNotifier; namespace AiNativeUiController { - /** * Dialog renderer. * @@ -36,7 +39,7 @@ * * @since S60 3.2 */ -class CAiNotifierRenderer : public CAiNativeRenderer +NONSHARABLE_CLASS( CAiNotifierRenderer ) : public CAiNativeRenderer { public: @@ -46,9 +49,9 @@ // from base class CAiNativeRenderer - void DoPublishL( MAiPropertyExtension& aPlugin, TInt aContent, TInt aResource, TInt aIndex ); + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, TInt aResource, TInt aIndex ); - void DoCleanL( MAiPropertyExtension& aPlugin, TInt aContent ); + void DoCleanL( CHsContentPublisher& aPlugin, TInt aContent ); private: diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/inc/aisoftkeyrenderer.h --- a/idlehomescreen/nativeuicontroller/inc/aisoftkeyrenderer.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/inc/aisoftkeyrenderer.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,12 +19,16 @@ #ifndef C_AISOFTKEYRENDERER_H #define C_AISOFTKEYRENDERER_H - +// System includes #include #include //ECoeStackPriorityDefault + +// User includes #include "ainativerenderer.h" #include "ainativeuimodel.h" +// Forward declarations +class CHsContentPublisher; namespace AiNativeUiController { @@ -48,7 +52,7 @@ * * @since S60 3.2 */ -class CAiSoftKeyRenderer : public CAiNativeRenderer +NONSHARABLE_CLASS( CAiSoftKeyRenderer ) : public CAiNativeRenderer { public: @@ -58,15 +62,15 @@ // from base class CAiNativeRenderer - void DoPublishL( MAiPropertyExtension& aPlugin, + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, const TDesC16& aText, TInt aIndex ); - void DoPublishL( MAiPropertyExtension& aPlugin, + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, TInt aResource, TInt aIndex ); - void DoPublishL( MAiPropertyExtension& aPlugin, + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, const TDesC8& aBuf, TInt aIndex ); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/inc/aistatuspanetouchui.h --- a/idlehomescreen/nativeuicontroller/inc/aistatuspanetouchui.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/inc/aistatuspanetouchui.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,21 +19,23 @@ #ifndef C_AISTATUSPANETOUCHUI_H #define C_AISTATUSPANETOUCHUI_H +// System includes #include #include #include #include #include +// User includes #include "ainativerenderer.h" +// Forward declarations +class CHsContentPublisher; class MAiFwEventHandler; - class CAknStylusPopUpMenu; namespace AiNativeUiController { - // Stylus activated popup command ids enum TLinkCommandID { @@ -42,14 +44,11 @@ EAIProfileCmdLink }; - class CAiStatusPanel; -class CAiStatusPaneTouchUi : public CAiNativeRenderer, - public MAknNaviDecoratorObserver, - public MEikMenuObserver +NONSHARABLE_CLASS( CAiStatusPaneTouchUi ) : public CAiNativeRenderer, + public MAknNaviDecoratorObserver, public MEikMenuObserver { - public: // Construction and destructor @@ -72,7 +71,7 @@ // from base class CAiNativeRenderer - void DoPublishL( MAiPropertyExtension& aPlugin, + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, const TDesC16& aText, TInt aIndex ); @@ -111,4 +110,4 @@ } // namespace AiNativeUiController -#endif //C_AISTATUSPANETOUCHUI_H \ No newline at end of file +#endif //C_AISTATUSPANETOUCHUI_H diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/inc/aititlepanerenderer.h --- a/idlehomescreen/nativeuicontroller/inc/aititlepanerenderer.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/inc/aititlepanerenderer.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,11 +19,16 @@ #ifndef C_AITITLEPANERENDERER_H #define C_AITITLEPANERENDERER_H +// System includes +#include -#include +// User includes #include "ainativerenderer.h" #include "ainativeuimodel.h" +// Forward declarations +class CHsContentPublisher; + namespace AiUtility { class CContentPriorityMap; @@ -43,7 +48,7 @@ * * @since S60 3.2 */ -class CAiTitlePaneRenderer : public CAiNativeRenderer +NONSHARABLE_CLASS( CAiTitlePaneRenderer ) : public CAiNativeRenderer { public: @@ -53,22 +58,22 @@ // from base class CAiNativeRenderer - void DoPublishL( MAiPropertyExtension& aPlugin, + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, const TDesC16& aText, TInt aIndex ); - void DoPublishL( MAiPropertyExtension& aPlugin, + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, const TDesC8& aBuf, TInt aIndex ); - void DoPublishL( MAiPropertyExtension& aPlugin, + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, TInt aResource, TInt aIndex ); - void DoCleanL( MAiPropertyExtension& aPlugin, TInt aContent ); + void DoCleanL( CHsContentPublisher& aPlugin, TInt aContent ); void TransactionCommittedL(); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/inc/aitoolbarrenderer.h --- a/idlehomescreen/nativeuicontroller/inc/aitoolbarrenderer.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/inc/aitoolbarrenderer.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,30 +19,31 @@ #ifndef C_AITOOLBARRENDERER_H #define C_AITOOLBARRENDERER_H +// System includes #include #include + +// User includes #include "ainativerenderer.h" #include "ainativeuimodel.h" #include "aitoolbarbutton.h" +// Forward declarations +class CHsContentPublisher; class MAiFwEventHandler; class CAknToolbar; namespace AiNativeUiController { - - /** * Toolbar class of Native UI Controller application * * @lib AiNatiUi */ // inheritance order must be this, despite codescanner warnings -class CAiToolbarRenderer : public MAknToolbarObserver, - public CAiNativeRenderer - { - - +NONSHARABLE_CLASS( CAiToolbarRenderer ) : public MAknToolbarObserver, + public CAiNativeRenderer + { public: // Constructors and destructor static CAiToolbarRenderer* NewLC( MAiFwEventHandler& aAiFwEventHandler, CAknToolbar& aToolbar); @@ -53,12 +54,12 @@ public: // from CAiNativeRenderer - void DoPublishL( MAiPropertyExtension& aPlugin, + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, const TDesC16& aText, TInt aIndex ); - void DoPublishL( MAiPropertyExtension& aPlugin, + void DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, const TDesC8& aBuf, TInt aIndex ); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/inc/nativeuicontroller.h --- a/idlehomescreen/nativeuicontroller/inc/nativeuicontroller.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/inc/nativeuicontroller.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,24 +19,24 @@ #ifndef C_NATIVEUICONTROLLER_H #define C_NATIVEUICONTROLLER_H - +// System includes #include -#include "aiuicontroller.h" -#include "aiuiframeworkobserver.h" -#include "aicontentobserver.h" +// User includes +#include +#include #include -class MAiPropertyExtension; +// Forward declarations class MAiPSPropertyObserver; +class CHsContentPublisher; +class THsPublisherInfo; namespace AiNativeUiController { - class CAiNativeRenderer; class CAiStatusPanel; class CAppUi; -class CAiToolbarRenderer; const TInt KImplementationUidNativeUiController = AI_UID_ECOM_IMPLEMENTATION_UICONTROLLER_NATIVE; @@ -50,125 +50,132 @@ * * @since Series 60 3.2 */ -class CNativeUiController : public CAiUiController, - public MAiSecondaryUiController, - public MAiMainUiController, - public MAiUiFrameworkObserver, - public MAiContentObserver +NONSHARABLE_CLASS( CNativeUiController ) : public CAiUiController, + public MAiSecondaryUiController, public MAiMainUiController, + public MAiContentObserver { public: - + // Constructor and destructor static CNativeUiController* NewL(); - virtual ~CNativeUiController(); - -// from base class CAiUiController - - void PrepareToExit(); + ~CNativeUiController(); +public: + // from CAiUiController + void LoadUIDefinitionL(); - - void GetPluginsL(RAiPublisherInfoArray& aPlugins); - - void GetSettingsL(const TAiPublisherInfo& aPubInfo, - RAiSettingsItemArray& aSettings); + + void GetSettingsL( const THsPublisherInfo& aPublisherInfo, + RAiSettingsItemArray& aSettings ); void ActivateUI(); MAiContentObserver& GetContentObserver(); - void SetEventHandler(MAiFwEventHandler& aEventHandler); + void SetEventHandler( MAiFwEventHandler& aEventHandler ); + + void SetStateHandler( MAiFwStateHandler& aStateHandler ); MAiFwEventHandler* FwEventHandler(); - void RemovePluginFromUI( MAiPropertyExtension& aPlugin ); - + MAiFwStateHandler* FwStateHandler(); + MAiMainUiController* MainInterface(); MAiSecondaryUiController* SecondaryInterface(); - - void HandleLoadedPlugins(const RAiPublisherInfoArray& /*aRequiredPlugins*/ ) {}; - -// from base class MAiMainUiController + +public: + // from MAiMainUiController void RunApplicationL(); CCoeEnv& CoeEnv(); - - void SetUiFrameworkObserver( MAiUiFrameworkObserver& aObserver ); TBool IsMenuOpen(); -// from base class CAiSecordaryUiController +public: + // from CAiSecordaryUiController void SetCoeEnv( CCoeEnv& aCoeEnv ); - MAiUiFrameworkObserver* UiFrameworkObserver(); - -// from base class MAiUiFrameworkObserver - - void HandleResourceChange( TInt aType ); - - void HandleForegroundEvent( TBool aForeground ); - -// from base class MAiContentObserver - +public: + // from MAiContentObserver TInt StartTransaction(TInt aTxId); TInt Commit(TInt aTxId); TInt CancelTransaction(TInt aTxId); - TBool CanPublish(MAiPropertyExtension& aPlugin, TInt aContent, TInt aIndex); + TBool CanPublish(CHsContentPublisher& aPlugin, TInt aContent, TInt aIndex); - TInt Publish(MAiPropertyExtension& aPlugin, TInt aContent, TInt aResource, TInt aIndex ); + TInt Publish(CHsContentPublisher& aPlugin, TInt aContent, TInt aResource, TInt aIndex ); - TInt Publish(MAiPropertyExtension& aPlugin, TInt aContent, const TDesC16& aText, TInt aIndex ); + TInt Publish(CHsContentPublisher& aPlugin, TInt aContent, const TDesC16& aText, TInt aIndex ); - TInt Publish(MAiPropertyExtension& aPlugin, TInt aContent, const TDesC8& aBuf, TInt aIndex ); + TInt Publish(CHsContentPublisher& aPlugin, TInt aContent, const TDesC8& aBuf, TInt aIndex ); - TInt Publish(MAiPropertyExtension& aPlugin, TInt aContent, RFile& aFile, TInt aIndex ); + TInt Publish(CHsContentPublisher& aPlugin, TInt aContent, RFile& aFile, TInt aIndex ); - TInt Clean(MAiPropertyExtension& aPlugin, TInt aContent, TInt aIndex ); + TInt Clean(CHsContentPublisher& aPlugin, TInt aContent, TInt aIndex ); TAny* Extension(TUid aUid); - TBool RequiresSubscription( const TAiPublisherInfo& aPublisherInfo ) const; + TBool RequiresSubscription( const THsPublisherInfo& aPublisherInfo ) const; - TInt SetProperty( MAiPropertyExtension& aPlugin, + TInt SetProperty( CHsContentPublisher& aPlugin, const TDesC8& aElementId, const TDesC8& aPropertyName, const TDesC8& aPropertyValue ); - TInt SetProperty( MAiPropertyExtension& aPlugin, + TInt SetProperty( CHsContentPublisher& aPlugin, const TDesC8& aElementId, const TDesC8& aPropertyName, const TDesC8& aPropertyValue, MAiContentObserver::TValueType aValueType); -// new methods +private: + // constructors + + /** + * C++ default contructor + */ + CNativeUiController(); +public: + // new functions + /** * Set app ui instance to this class. * * @since S60 3.2 * @param aAppUi is pointer to app ui. */ - void SetAppUi( CAppUi* aAppUi ) - { - iAppUi = aAppUi; - } - + void SetAppUi( CAppUi* aAppUi ); + + /** + * Promotes this UI controller as main UI controller. + * + * @since S60 3.2 + */ void VariateToMainUiController(); + /** + * Runs exit timer. + * + * @since S60 3.2 + */ void Exit(); + /** + * Preperas to exit + * + * @since S60 3.2 + */ + void PrepareToExit(); + private: - - CNativeUiController(); - - static CApaApplication* NewApplication(); - + // new functions + /** * Add renderer. * @@ -190,17 +197,6 @@ * @return ETrue upon successful removing. */ TBool RemoveRenderer( CAiNativeRenderer *aRenderer, TBool aDelete = EFalse ); - - /** - * Recreates the toolbar renderer - */ - TBool RecreateToolbarRendererL(); - - /** - * Deletes and removes the toolbar renderer from - * renderer array. - */ - void DeleteToolbarRenderer(); /** * Template function for publish. @@ -213,7 +209,7 @@ * @return KErrNone if publishing was successful. */ template - TInt DoPublish( MAiPropertyExtension& aPlugin, TInt aContent, T& aData, TInt aIndex ); + TInt DoPublish( CHsContentPublisher& aPlugin, TInt aContent, T& aData, TInt aIndex ); /** * Handles idle state changes. @@ -232,10 +228,13 @@ static TInt HandlePluginConfChange( TAny* aPtr ); static TInt ExitTimerCallBack( TAny* aSelf ); - void GetSettingsFromCRL( const TAiPublisherInfo& aPubInfo, - RAiSettingsItemArray &aPluginSettings ); - -private: // Data + void GetSettingsFromCRL( const THsPublisherInfo& aPublisherInfo, + RAiSettingsItemArray &aPluginSettings ); + + static CApaApplication* NewApplication(); + +private: + // data /** * Array of renderers. @@ -281,13 +280,19 @@ /** * Native UI controller plug-ins */ - RAiPublisherInfoArray iPlugins; + RArray< THsPublisherInfo > iPlugins; /** * Plug-in event handler. * Doesn't own. */ MAiFwEventHandler* iFwEventHandler; + + /** + * Plug-in state handler. + * Doesn't own. + */ + MAiFwStateHandler* iFwStateHandler; /** * Pointer to this, when role is main ui controller. @@ -295,11 +300,6 @@ MAiMainUiController* iMain; /** - * Ui framework observer. Not own. - */ - MAiUiFrameworkObserver* iUiFrameworkObserver; - - /** * Pointer to app ui. * Not own. */ @@ -320,13 +320,6 @@ * To prevent double loading of the UI **/ TBool iUiLoaded; - - /** - * Pointer to our toolbar renderer. Do not delete - * renderer through this pointer - */ - CAiToolbarRenderer *iToolbarRenderer; - }; #include "nativeuicontroller.inl" diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/src/aidialogrenderer.cpp --- a/idlehomescreen/nativeuicontroller/src/aidialogrenderer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/src/aidialogrenderer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -15,13 +15,16 @@ * */ - +// System includes #include -#include -#include #include #include #include + +// User includes +#include +#include +#include #include #include "aidialogrenderer.h" #include "ainativeuiplugins.h" @@ -32,7 +35,11 @@ using namespace AiNativeUiController; // ======== MEMBER FUNCTIONS ======== - +// ---------------------------------------------------------------------------- +// CAiDialogRenderer::NewLC() +// +// ---------------------------------------------------------------------------- +// CAiDialogRenderer* CAiDialogRenderer::NewLC() { CAiDialogRenderer* self = new( ELeave ) CAiDialogRenderer; @@ -40,25 +47,37 @@ return self; } - +// ---------------------------------------------------------------------------- +// CAiDialogRenderer::~CAiDialogRenderer() +// +// ---------------------------------------------------------------------------- +// CAiDialogRenderer::~CAiDialogRenderer() { delete iDialog; delete iText; } - +// ---------------------------------------------------------------------------- +// CAiDialogRenderer::CAiDialogRenderer() +// +// ---------------------------------------------------------------------------- +// CAiDialogRenderer::CAiDialogRenderer() { } - -void CAiDialogRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aResource, - TInt /*aIndex*/ ) +// ---------------------------------------------------------------------------- +// CAiDialogRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiDialogRenderer::DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, TInt aResource, TInt /*aIndex*/ ) { - if( aPlugin.PublisherInfoL()->iUid == KDeviceStatusPluginUid ) + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + if( info.Uid() == KDeviceStatusPluginUid ) { switch( aContent ) { @@ -99,7 +118,7 @@ User::Leave( KErrNotFound ); break; } - }; + } } else { @@ -107,8 +126,13 @@ } } -void CAiDialogRenderer::DoCleanL( MAiPropertyExtension& /*aPlugin*/, - TInt aContent ) +// ---------------------------------------------------------------------------- +// CAiDialogRenderer::DoCleanL() +// +// ---------------------------------------------------------------------------- +// +void CAiDialogRenderer::DoCleanL( CHsContentPublisher& /*aPlugin*/, + TInt aContent ) { switch( aContent ) { @@ -124,11 +148,14 @@ User::Leave( KErrNotFound ); break; } - }; - + } } - +// ---------------------------------------------------------------------------- +// CAiDialogRenderer::ShowDialogL() +// +// ---------------------------------------------------------------------------- +// void CAiDialogRenderer::ShowDialogL() { if ( iDialog ) @@ -153,7 +180,11 @@ iDialog->RunLD(); } - +// ---------------------------------------------------------------------------- +// CAiDialogRenderer::FocusObtainedL() +// +// ---------------------------------------------------------------------------- +// void CAiDialogRenderer::FocusObtainedL() { if( iShowDialog ) @@ -161,3 +192,5 @@ ShowDialogL(); } } + +// End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/src/ainativerenderer.cpp --- a/idlehomescreen/nativeuicontroller/src/ainativerenderer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/src/ainativerenderer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -15,21 +15,34 @@ * */ +// System includes -#include +// User includes +#include +#include + #include "ainativerenderer.h" #include "ainativeuiplugins.h" using namespace AiNativeUiController; - +// ======== MEMBER FUNCTIONS ======== +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::CAiNativeRenderer() +// +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::~CAiNativeRenderer() { } - -TInt CAiNativeRenderer::Publish( MAiPropertyExtension& aPlugin, TInt aContent, - TInt aResource, TInt aIndex ) +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::Publish() +// +// ---------------------------------------------------------------------------- +// +TInt CAiNativeRenderer::Publish( CHsContentPublisher& aPlugin, TInt aContent, + TInt aResource, TInt aIndex ) { TRAPD( err, DoMimeTypeCheckL( aPlugin, aContent ) ); @@ -39,12 +52,17 @@ } TRAP( err, DoPublishL( aPlugin, aContent, aResource, aIndex ) ); + return err; } - -TInt CAiNativeRenderer::Publish( MAiPropertyExtension& aPlugin, TInt aContent, - const TDesC16& aText, TInt aIndex ) +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::Publish() +// +// ---------------------------------------------------------------------------- +// +TInt CAiNativeRenderer::Publish( CHsContentPublisher& aPlugin, TInt aContent, + const TDesC16& aText, TInt aIndex ) { TRAPD( err, DoMimeTypeCheckL( aPlugin, aContent ) ); @@ -54,12 +72,17 @@ } TRAP( err, DoPublishL( aPlugin, aContent, aText, aIndex ) ); + return err; } - -TInt CAiNativeRenderer::Publish( MAiPropertyExtension& aPlugin, TInt aContent, - const TDesC8& aBuf, TInt aIndex ) +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::Publish() +// +// ---------------------------------------------------------------------------- +// +TInt CAiNativeRenderer::Publish( CHsContentPublisher& aPlugin, TInt aContent, + const TDesC8& aBuf, TInt aIndex ) { TRAPD( err, DoMimeTypeCheckL( aPlugin, aContent ) ); @@ -69,12 +92,17 @@ } TRAP( err, DoPublishL( aPlugin, aContent, aBuf, aIndex ) ); + return err; } - -TInt CAiNativeRenderer::Publish( MAiPropertyExtension& aPlugin, TInt aContent, - RFile& aFile, TInt aIndex ) +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::Publish() +// +// ---------------------------------------------------------------------------- +// +TInt CAiNativeRenderer::Publish( CHsContentPublisher& aPlugin, TInt aContent, + RFile& aFile, TInt aIndex ) { TRAPD( err, DoMimeTypeCheckL( aPlugin, aContent ) ); @@ -84,11 +112,16 @@ } TRAP( err, DoPublishL( aPlugin, aContent, aFile, aIndex ) ); + return err; } - -TInt CAiNativeRenderer::Clean( MAiPropertyExtension& aPlugin, TInt aContent ) +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::Clean() +// +// ---------------------------------------------------------------------------- +// +TInt CAiNativeRenderer::Clean( CHsContentPublisher& aPlugin, TInt aContent ) { TRAPD( err, DoMimeTypeCheckL( aPlugin, aContent ) ); @@ -98,50 +131,75 @@ } TRAP( err, DoCleanL( aPlugin, aContent ) ); + return err; } - -void CAiNativeRenderer::DoPublishL - ( MAiPropertyExtension& /*aPlugin*/, TInt /*aContent*/, TInt /*aResource*/, TInt /*aIndex*/ ) +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiNativeRenderer::DoPublishL( CHsContentPublisher& /*aPlugin*/, + TInt /*aContent*/, TInt /*aResource*/, TInt /*aIndex*/ ) { // Default implementation, overridden in subclass if needed. User::Leave( KErrNotFound ); } - -void CAiNativeRenderer::DoPublishL - ( MAiPropertyExtension& /*aPlugin*/, TInt /*aContent*/, const TDesC16& /*aText*/, TInt /*aIndex*/ ) +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiNativeRenderer::DoPublishL( CHsContentPublisher& /*aPlugin*/, + TInt /*aContent*/, const TDesC16& /*aText*/, TInt /*aIndex*/ ) { // Default implementation, overridden in subclass if needed. User::Leave( KErrNotFound ); } - -void CAiNativeRenderer::DoPublishL - ( MAiPropertyExtension& /*aPlugin*/, TInt /*aContent*/, const TDesC8& /*aBuf*/, TInt /*aIndex*/ ) +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiNativeRenderer::DoPublishL( CHsContentPublisher& /*aPlugin*/, + TInt /*aContent*/, const TDesC8& /*aBuf*/, TInt /*aIndex*/ ) { // Default implementation, overridden in subclass if needed. User::Leave( KErrNotFound ); } - -void CAiNativeRenderer::DoPublishL - ( MAiPropertyExtension& /*aPlugin*/, TInt /*aContent*/, RFile& /*aFile*/, TInt /*aIndex*/ ) +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiNativeRenderer::DoPublishL( CHsContentPublisher& /*aPlugin*/, + TInt /*aContent*/, RFile& /*aFile*/, TInt /*aIndex*/ ) { // Default implementation, overridden in subclass if needed. User::Leave( KErrNotFound ); } - -void CAiNativeRenderer::DoCleanL - ( MAiPropertyExtension& /*aPlugin*/, TInt /*aContent*/ ) +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::DoCleanL() +// +// ---------------------------------------------------------------------------- +// +void CAiNativeRenderer::DoCleanL( CHsContentPublisher& /*aPlugin*/, + TInt /*aContent*/ ) { // Default implementation, overridden in subclass if needed. User::Leave( KErrNotFound ); } - +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::GetIntContentId() +// +// ---------------------------------------------------------------------------- +// TInt CAiNativeRenderer::GetIntContentId( const TDesC& aCid ) const { for( TInt i( 0 ); i < KAiDeviceStatusContentCount; i++ ) @@ -154,30 +212,19 @@ } } - for( TInt i( 0 ); i < KAiScutContentCount; i++ ) - { - const TAiContentItem& item = KAiScutContent[i]; - if( ContentCid(item) == aCid ) - { - //match - return item.id; - } - } - return KErrNotFound; } - -TBool CAiNativeRenderer::MatchMimeType( MAiPropertyExtension& aPlugin, - TInt aContentId, - const TDesC8& aMimeType ) const +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::MatchMimeType() +// +// ---------------------------------------------------------------------------- +// +TBool CAiNativeRenderer::MatchMimeType( CHsContentPublisher& aPlugin, + TInt aContentId, const TDesC8& aMimeType ) const { - TUid pluginUid; - TRAPD( err, pluginUid = aPlugin.PublisherInfoL()->iUid ); - if ( err != KErrNone ) - { - return EFalse; - } + TUid pluginUid( aPlugin.PublisherInfo().Uid() ); + // loop through Device Status content items if ( pluginUid == KDeviceStatusPluginUid ) { @@ -195,23 +242,6 @@ return ( mimeType.Match( aMimeType ) != KErrNotFound ); } } - else if ( pluginUid == KShortcutPluginUid ) - { - // if match not found, loop through Shortcut content items - for( TInt i( 0 ); i < KAiScutContentCount; i++ ) - { - const TAiContentItem& item = KAiScutContent[i]; - - if( item.id != aContentId ) - { - continue; - } - - TBuf8 mimeType((TText8*) item.type); - - return ( mimeType.Match( aMimeType ) != KErrNotFound ); - } - } else if ( pluginUid == KProfilePluginUid ) { // if match not found, loop through Profile content items @@ -233,11 +263,22 @@ return EFalse; } - -void CAiNativeRenderer::DoMimeTypeCheckL( MAiPropertyExtension& aPlugin, TInt aContentId ) +// ---------------------------------------------------------------------------- +// CAiNativeRenderer::DoMimeTypeCheckL() +// +// ---------------------------------------------------------------------------- +// +void CAiNativeRenderer::DoMimeTypeCheckL( CHsContentPublisher& aPlugin, + TInt aContentId ) { - MAiContentItemIterator* iter = - (MAiContentItemIterator*)aPlugin.GetPropertyL( EAiPublisherContent ); + MAiContentItemIterator* iter( static_cast< MAiContentItemIterator* >( + aPlugin.GetProperty( CHsContentPublisher::EPublisherContent ) ) ); + + if ( !iter ) + { + User::Leave( KErrNotSupported ); + } + const TAiContentItem& item = iter->ItemL( aContentId ); aContentId = GetIntContentId( ContentCid(item) ); @@ -246,6 +287,7 @@ { User::Leave( KErrNotSupported ); } + } - } - +// End of file + diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/src/ainavipanerenderer.cpp --- a/idlehomescreen/nativeuicontroller/src/ainavipanerenderer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/src/ainavipanerenderer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -15,11 +15,14 @@ * */ - -#include +// System includes #include #include +// User includes +#include +#include + #include "ainavipanerenderer.h" #include "ainavipaneanimator.h" #include "aistatuspanel.h" @@ -31,7 +34,11 @@ using namespace AiNativeUiController; - +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::ConstructL() +// +// ---------------------------------------------------------------------------- +// void CAiNaviPaneRenderer::ConstructL() { iAnimator = CAiNaviPaneAnimator::NewL( iStatusPanel, @@ -41,17 +48,26 @@ iSilentIndicator = HBufC::NewL(0); } - +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::NewLC() +// +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer* CAiNaviPaneRenderer::NewLC( CAiStatusPanel& aStatusPanel ) { - CAiNaviPaneRenderer* self = new( ELeave ) CAiNaviPaneRenderer( aStatusPanel ); + CAiNaviPaneRenderer* self = + new( ELeave ) CAiNaviPaneRenderer( aStatusPanel ); CleanupStack::PushL( self ); self->ConstructL(); return self; } - +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::~CAiNaviPaneRenderer() +// +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::~CAiNaviPaneRenderer() { delete iAnimator; @@ -60,7 +76,11 @@ delete iTimedProfileIndicator; } - +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::CAiNaviPaneRenderer() +// +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::CAiNaviPaneRenderer( CAiStatusPanel& aStatusPanel ) : iStatusPanel( aStatusPanel ), iRenderingPriorities( AiNativeUiModel::RenderingPriorities( AiNativeUiModel::KNaviPaneId ) ), @@ -69,13 +89,17 @@ { } - -void CAiNaviPaneRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC16& aText, - TInt /*aIndex*/ ) +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiNaviPaneRenderer::DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, const TDesC16& aText, TInt /*aIndex*/ ) { - if( aPlugin.PublisherInfoL()->iUid == KDeviceStatusPluginUid ) + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + if( info.Uid() == KDeviceStatusPluginUid ) { switch( aContent ) { @@ -226,6 +250,11 @@ } } +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::ConstructProfileTextLC() +// +// ---------------------------------------------------------------------------- +// HBufC* CAiNaviPaneRenderer::ConstructProfileTextLC() { TInt bufLen = iProfileText->Length(); @@ -253,9 +282,16 @@ return temp; } -void CAiNaviPaneRenderer::DoCleanL( MAiPropertyExtension& aPlugin, TInt aContent ) +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::DoCleanL() +// +// ---------------------------------------------------------------------------- +// +void CAiNaviPaneRenderer::DoCleanL( CHsContentPublisher& aPlugin, TInt aContent ) { - if( aPlugin.PublisherInfoL()->iUid == KDeviceStatusPluginUid ) + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + if( info.Uid() == KDeviceStatusPluginUid ) { switch( aContent ) @@ -305,7 +341,7 @@ iStatusPanel.RenderNaviPaneL(); MAiContentRequest* contentReq = static_cast( - aPlugin.GetPropertyL( EAiContentRequest ) ); + aPlugin.GetProperty( CHsContentPublisher::EContentRequest ) ); if ( contentReq ) { @@ -349,7 +385,11 @@ } - +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::FocusObtainedL() +// +// ---------------------------------------------------------------------------- +// void CAiNaviPaneRenderer::FocusObtainedL() { if( !iStatusPanel.IsKeyLockEnabled() ) @@ -359,7 +399,11 @@ iFocusObtained = ETrue; } - +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::FocusLostL() +// +// ---------------------------------------------------------------------------- +// void CAiNaviPaneRenderer::FocusLostL() { iAnimator->CancelAnimationL(); @@ -367,19 +411,31 @@ iCommitted = EFalse; } - +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::KeylockDisabledL() +// +// ---------------------------------------------------------------------------- +// void CAiNaviPaneRenderer::KeylockDisabledL() { iAnimator->AnimateL(); } - +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::KeylockEnabledL() +// +// ---------------------------------------------------------------------------- +// void CAiNaviPaneRenderer::KeylockEnabledL() { iAnimator->CancelAnimationL(); } - +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::TransactionCommittedL() +// +// ---------------------------------------------------------------------------- +// void CAiNaviPaneRenderer::TransactionCommittedL() { if( iIsChanged ) @@ -393,7 +449,11 @@ } } - +// ---------------------------------------------------------------------------- +// CAiNaviPaneRenderer::AnimationCompleteL() +// +// ---------------------------------------------------------------------------- +// void CAiNaviPaneRenderer::AnimationCompleteL() { // Navi pane animation is now completed -> show original text @@ -414,3 +474,4 @@ CleanupStack::PopAndDestroy( newText ); } +// End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/src/ainotifierrenderer.cpp --- a/idlehomescreen/nativeuicontroller/src/ainotifierrenderer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/src/ainotifierrenderer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -15,23 +15,31 @@ * */ +// System includes +#include -#include +// User includes +#include +#include #include -#include - #include - #include "ainotifierrenderer.h" #include "ainativeuiplugins.h" using namespace AiNativeUiController; +// Constants + // 1-minute timeout before showing soft notification const TInt KNetworkLostTimeout = 60*1000000; // ======== MEMBER FUNCTIONS ======== +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer::NewLC() +// +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer* CAiNotifierRenderer::NewLC() { CAiNotifierRenderer* self = new( ELeave ) CAiNotifierRenderer; @@ -40,30 +48,48 @@ return self; } - +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer::~CAiNotifierRenderer() +// +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer::~CAiNotifierRenderer() { delete iSoftNotifier; delete iTimer; } - +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer::CAiNotifierRenderer() +// +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer::CAiNotifierRenderer() { } +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer::ConstructL() +// +// ---------------------------------------------------------------------------- +// void CAiNotifierRenderer::ConstructL() { iSoftNotifier = CAknSoftNotifier::NewL(); iTimer = CPeriodic::NewL( CActive::EPriorityStandard ); } -void CAiNotifierRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aResource, - TInt /*aIndex*/ ) +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiNotifierRenderer::DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, TInt aResource, TInt /*aIndex*/ ) { - if( aPlugin.PublisherInfoL()->iUid == KDeviceStatusPluginUid ) + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + if( info.Uid() == KDeviceStatusPluginUid ) { switch( aContent ) { @@ -90,7 +116,7 @@ User::Leave( KErrNotFound ); break; } - }; + } } else { @@ -98,8 +124,13 @@ } } -void CAiNotifierRenderer::DoCleanL( MAiPropertyExtension& /*aPlugin*/, - TInt aContent ) +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer::DoCleanL() +// +// ---------------------------------------------------------------------------- +// +void CAiNotifierRenderer::DoCleanL( CHsContentPublisher& /*aPlugin*/, + TInt aContent ) { switch( aContent ) { @@ -114,30 +145,47 @@ User::Leave( KErrNotFound ); break; } - }; - + } } - +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer::AddNotification() +// +// ---------------------------------------------------------------------------- +// void CAiNotifierRenderer::AddNotification( TAknSoftNotificationType aType ) { - TRAP_IGNORE( iSoftNotifier->AddNotificationL( aType, 1 ); ); + TRAP_IGNORE( iSoftNotifier->AddNotificationL( aType, 1 ) ); } -void CAiNotifierRenderer::RemoveNotification( TAknSoftNotificationType aType) +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer::RemoveNotification() +// +// ---------------------------------------------------------------------------- +// +void CAiNotifierRenderer::RemoveNotification( TAknSoftNotificationType aType ) { TRAP_IGNORE( iSoftNotifier->CancelSoftNotificationL( aType ); ); } -TInt CAiNotifierRenderer::NWLostDelayCallBack(TAny* aParam) +// ---------------------------------------------------------------------------- +// CAiNotifierRenderer::NWLostDelayCallBack() +// +// ---------------------------------------------------------------------------- +// +TInt CAiNotifierRenderer::NWLostDelayCallBack( TAny* aParam ) { - CAiNotifierRenderer* self = reinterpret_cast (aParam); - if ( self ) + CAiNotifierRenderer* self = + reinterpret_cast< CAiNotifierRenderer* >( aParam ); + + if ( self ) { self->iTimer->Cancel(); self->AddNotification( ESelectNetworkNotification ); } + return KErrNone; } +// End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/src/aisoftkeyrenderer.cpp --- a/idlehomescreen/nativeuicontroller/src/aisoftkeyrenderer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/src/aisoftkeyrenderer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -15,11 +15,10 @@ * */ - +// System includes #include #include #include -#include #include #include #include @@ -29,21 +28,25 @@ #include #include #include -#include + +// User includes +#include +#include + +#include #include "ainativeui.hrh" #include "aisoftkeyrenderer.h" #include "ainativeuiplugins.h" -#include "aiscutdefs.h" - using namespace AiNativeUiController; +// Constants // Index for left softkey; defined in avkon -const TInt KNativeUiLeftSoftkeyId = 0; +//const TInt KNativeUiLeftSoftkeyId = 0; // Index for right softkey; defined in avkon -const TInt KNativeUiRightSoftkeyId = 2; +//const TInt KNativeUiRightSoftkeyId = 2; const TInt KControlArrayCBAButton1Posn =0; const TInt KControlArrayCBAButton2Posn =2; @@ -51,7 +54,7 @@ const TInt KWideScreenWidth = 640; - +// ======== LOCAL FUNCTIONS ======== inline TAknWindowComponentLayout DoCompose( TAknWindowComponentLayout aLine1, TAknWindowComponentLayout aLine2 ) { @@ -420,14 +423,23 @@ return size; } - +// ======== MEMBER FUNCTIONS ======== +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer::ConstructL() +// +// ---------------------------------------------------------------------------- +// void CAiSoftKeyRenderer::ConstructL() { // load default soft key labels from resource CreateDefaultSoftKeysL(); } - +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer::NewLC() +// +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer* CAiSoftKeyRenderer::NewLC() { CAiSoftKeyRenderer* self = new( ELeave ) CAiSoftKeyRenderer(); @@ -436,7 +448,11 @@ return self; } - +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer::~CAiSoftKeyRenderer() +// +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer::~CAiSoftKeyRenderer() { delete iText; @@ -450,136 +466,54 @@ delete iCba; } - +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer::CAiSoftKeyRenderer() +// +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer::CAiSoftKeyRenderer() { iAppUi = iAvkonAppUi; } - - - -void CAiSoftKeyRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC16& aText, - TInt aIndex ) +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiSoftKeyRenderer::DoPublishL( CHsContentPublisher& /*aPlugin*/, + TInt /*aContent*/, const TDesC16& /*aText*/, TInt /*aIndex*/ ) { - if( aPlugin.PublisherInfoL()->iUid == KShortcutPluginUid ) - { - if( aContent == KAiScutContent[EAiScutContentShortcutShortCaption].id ) - { - HBufC* temp = aText.AllocL(); - delete iText; - iText = temp; - - UpdateSoftKeyL( aIndex, NULL ); - } - } - else - { - User::Leave( KErrNotFound ); - } + User::Leave( KErrNotFound ); } - -void CAiSoftKeyRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aResource, - TInt aIndex ) +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiSoftKeyRenderer::DoPublishL( CHsContentPublisher& /*aPlugin*/, + TInt /*aContent*/, TInt /*aResource*/, TInt /*aIndex*/ ) { - if( aPlugin.PublisherInfoL()->iUid == KShortcutPluginUid ) - { - if( aContent == KAiScutContent[EAiScutContentShortcutShortCaption].id ) - { - TInt internalId = KErrNotFound; - switch( aResource ) - { - case EAiScutResourceBackCaption: - { - internalId = R_NATIVEUI_SK_BACK; - break; - } - case EAiScutResourceNewMsgShortCaption: - { - internalId = R_NATIVEUI_SK_NEWMSG; - break; - } - case EAiScutResourceNewEmailShortCaption: - { - internalId = R_NATIVEUI_SK_EMAIL; - break; - } - case EAiScutResourceNewSyncMLMailShortCaption: - { - internalId = R_NATIVEUI_SK_SYNCMLMAIL; - break; - } - case EAiScutResourceNewPostcardShortCaption: - { - internalId = R_NATIVEUI_SK_MMSPOSTCARD; - break; - } - case EAiScutResourceSelectMsgTypeShortCaption: - { - internalId = R_NATIVEUI_SK_MSGTYPE; - break; - } - case EAiScutResourceNewAudioMsgShortCaption: - { - internalId = R_NATIVEUI_SK_AUDIOMSG; - break; - } - case EAiScutResourceChangeThemeShortCaption: - { - internalId = R_NATIVEUI_SK_CHANGETHEME; - break; - } - default: - { - User::Leave( KErrNotFound ); - } - } - - HBufC* temp = StringLoader::LoadL( internalId ); - delete iText; - iText = temp; - - UpdateSoftKeyL( aIndex, NULL ); - } - } - else - { - User::Leave( KErrNotFound ); - } + User::Leave( KErrNotFound ); } - -void CAiSoftKeyRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC8& aBuf, - TInt aIndex ) +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiSoftKeyRenderer::DoPublishL( CHsContentPublisher& /*aPlugin*/, + TInt /*aContent*/, const TDesC8& /*aBuf*/, TInt /*aIndex*/ ) { - if( aPlugin.PublisherInfoL()->iUid == KShortcutPluginUid ) - { - if( aContent == KAiScutContent[EAiScutContentShortcutSkIcon].id ) - { - CGulIcon* icon = NULL; - TPckg( icon ).Copy( aBuf ); - // icon ownership is transferred - UpdateSoftKeyL( aIndex, icon ); - } - else - { - User::Leave( KErrNotSupported ); - } - } - else - { - User::Leave( KErrNotFound ); - } + User::Leave( KErrNotFound ); } - +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer::CreateDefaultSoftKeysL() +// +// ---------------------------------------------------------------------------- +// void CAiSoftKeyRenderer::CreateDefaultSoftKeysL() { // If we already have cba, then do nothing. @@ -611,8 +545,12 @@ ECoeStackFlagRefusesFocus | ECoeStackFlagRefusesAllKeys ); } - -void CAiSoftKeyRenderer::UpdateSoftKeyL( TInt aKey, CGulIcon* aIcon ) +// ---------------------------------------------------------------------------- +// CAiSoftKeyRenderer::UpdateSoftKeyL() +// +// ---------------------------------------------------------------------------- +// +void CAiSoftKeyRenderer::UpdateSoftKeyL( TInt /*aKey*/, CGulIcon* /*aIcon*/ ) { if( !iCba ) { @@ -620,9 +558,10 @@ } // remove the locked flag if any - aKey &= KScutBitMaskLocked; + // NOTE ai_shortcut_command_api has been removed! + //aKey &= KScutBitMaskLocked; - TInt buttonPosImage; + /*TInt buttonPosImage; TInt buttonPosText; TInt buttonCmd; @@ -672,5 +611,7 @@ *iText ); } - iCba->DrawDeferred(); + iCba->DrawDeferred();*/ } + +// End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/src/aistatuspanetouchui.cpp --- a/idlehomescreen/nativeuicontroller/src/aistatuspanetouchui.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/src/aistatuspanetouchui.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -15,10 +15,22 @@ * */ - +// System includes #include -#include +#include +#include +#include +#include +#include +#include +#include +#ifdef RD_TACTILE_FEEDBACK +#include +#endif +// User includes +#include +#include #include "aistrcnv.h" #include "aistatuspanetouchui.h" #include "aistatuspanel.h" @@ -26,22 +38,11 @@ #include "aifweventhandler.h" #include "aiconsts.h" #include "aidevicestatuscontentmodel.h" -#include - #include -#include -#include -#include -#include -#include -#include - -#ifdef RD_TACTILE_FEEDBACK -#include -#endif using namespace AiNativeUiController; +// Constants _LIT( KProfileSwitchByIndexEvent, "Profile/SwitchProfileByIndex" ); const TInt KProfileSwitchByIndexEventLength = 28; const TInt KRadix = 10; @@ -52,6 +53,12 @@ _LIT( KOpenAppProfiles, "Shortcut/LaunchByValue(localapp:0x100058F8)" ); _LIT( KOpenAppCalendar, "Shortcut/LaunchByValue(localapp:0x10005901)" ); +// ======== LOCAL FUNCTIONS ======== +// ---------------------------------------------------------------------------- +// IndexLength() +// +// ---------------------------------------------------------------------------- +// static TInt IndexLength( TInt aIndex ) { TInt length = 0; @@ -72,35 +79,54 @@ // ======== MEMBER FUNCTIONS ======== - +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::NewL() +// +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi* CAiStatusPaneTouchUi::NewL( CAiStatusPanel& aStatusPanel, - MAiFwEventHandler& aEventHandler ) + MAiFwEventHandler& aEventHandler ) { - CAiStatusPaneTouchUi* self = CAiStatusPaneTouchUi::NewLC( aStatusPanel, aEventHandler ); + CAiStatusPaneTouchUi* self = + CAiStatusPaneTouchUi::NewLC( aStatusPanel, aEventHandler ); CleanupStack::Pop( self ); return self; } +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::NewLC() +// +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi* CAiStatusPaneTouchUi::NewLC( CAiStatusPanel& aStatusPanel, - MAiFwEventHandler& aEventHandler ) + MAiFwEventHandler& aEventHandler ) { - CAiStatusPaneTouchUi* self = new (ELeave) CAiStatusPaneTouchUi( aStatusPanel, aEventHandler ); + CAiStatusPaneTouchUi* self = + new ( ELeave ) CAiStatusPaneTouchUi( aStatusPanel, aEventHandler ); CleanupStack::PushL( self ); self->ConstructL(); return self; } +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::CAiStatusPaneTouchUi() +// +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::CAiStatusPaneTouchUi( CAiStatusPanel& aStatusPanel, - MAiFwEventHandler& aEventHandler ) - : - iStatusPane( aStatusPanel ), - iEventHandler( aEventHandler ) + MAiFwEventHandler& aEventHandler ) + : iStatusPane( aStatusPanel ), iEventHandler( aEventHandler ) { - // no implementation required + // no implementation required } +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::~CAiStatusPaneTouchUi() +// +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::~CAiStatusPaneTouchUi() { delete iEventBuffer; @@ -108,6 +134,11 @@ iProfileNamePointerArray.ResetAndDestroy(); } +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::ConstructL() +// +// ---------------------------------------------------------------------------- +// void CAiStatusPaneTouchUi::ConstructL() { if( AknLayoutUtils::PenEnabled() ) @@ -116,6 +147,11 @@ } } +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::LoadUIDefinitionL() +// +// ---------------------------------------------------------------------------- +// void CAiStatusPaneTouchUi::LoadUIDefinitionL() { // If profile popup exists, for example, when screendevicechange occurs, @@ -127,6 +163,11 @@ } } +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::ProcessCommandL() +// +// ---------------------------------------------------------------------------- +// void CAiStatusPaneTouchUi::ProcessCommandL( TInt aCommandId ) { if( aCommandId == EAIGotoCalendarCmdLink ) @@ -162,8 +203,11 @@ } } - - +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::HandleNaviDecoratorEventL() +// +// ---------------------------------------------------------------------------- +// void CAiStatusPaneTouchUi::HandleNaviDecoratorEventL( TInt aEventID ) { if( aEventID == EAknNaviDecoratorEventNaviLabel ) @@ -261,13 +305,17 @@ } } - -void CAiStatusPaneTouchUi::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC16& aText, - TInt aIndex ) +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiStatusPaneTouchUi::DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, const TDesC16& aText, TInt aIndex ) { - if( aPlugin.PublisherInfoL()->iUid == KProfilePluginUid ) + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + if( info.Uid() == KProfilePluginUid ) { switch( aContent ) { @@ -303,8 +351,14 @@ } } -void CAiStatusPaneTouchUi::SetEmphasis( CCoeControl* /*aMenuControl*/, TBool /*aEmphasis*/ ) - { - } +// ---------------------------------------------------------------------------- +// CAiStatusPaneTouchUi::SetEmphasis() +// +// ---------------------------------------------------------------------------- +// +void CAiStatusPaneTouchUi::SetEmphasis( CCoeControl* /*aMenuControl*/, + TBool /*aEmphasis*/ ) + { + } - +// End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/src/aititlepanerenderer.cpp --- a/idlehomescreen/nativeuicontroller/src/aititlepanerenderer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/src/aititlepanerenderer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -15,53 +15,80 @@ * */ - +// System includes #include #include #include + +// User includes +#include +#include + #include "aititlepanerenderer.h" #include "aistatuspanel.h" -#include "aipropertyextension.h" + #include #include "ainativeuiplugins.h" #include "debug.h" using namespace AiNativeUiController; - +// ======== MEMBER FUNCTIONS ======== +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::ConstructL() +// +// ---------------------------------------------------------------------------- +// void CAiTitlePaneRenderer::ConstructL() { } - -CAiTitlePaneRenderer* CAiTitlePaneRenderer::NewLC( CAiStatusPanel& aStatusPanel ) +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::NewLC() +// +// ---------------------------------------------------------------------------- +// +CAiTitlePaneRenderer* CAiTitlePaneRenderer::NewLC( + CAiStatusPanel& aStatusPanel ) { - CAiTitlePaneRenderer* self = new( ELeave ) CAiTitlePaneRenderer( aStatusPanel ); + CAiTitlePaneRenderer* self = + new( ELeave ) CAiTitlePaneRenderer( aStatusPanel ); + CleanupStack::PushL( self ); self->ConstructL(); return self; } - +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::CAiTitlePaneRenderer() +// +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::~CAiTitlePaneRenderer() { } - +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::CAiTitlePaneRenderer() +// +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::CAiTitlePaneRenderer( CAiStatusPanel& aStatusPanel ) : iStatusPanel( aStatusPanel ) { } - - - -void CAiTitlePaneRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC16& aText, - TInt /*aIndex*/ ) +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiTitlePaneRenderer::DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, const TDesC16& aText, TInt /*aIndex*/ ) { - if( aPlugin.PublisherInfoL()->iUid == KDeviceStatusPluginUid ) + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + if( info.Uid() == KDeviceStatusPluginUid ) { switch( aContent ) { @@ -89,12 +116,17 @@ } } -void CAiTitlePaneRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC8& aBuf, - TInt /*aIndex*/ ) +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiTitlePaneRenderer::DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, const TDesC8& aBuf, TInt /*aIndex*/ ) { - if( aPlugin.PublisherInfoL()->iUid == KDeviceStatusPluginUid ) + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + if( info.Uid() == KDeviceStatusPluginUid ) { switch( aContent ) { @@ -135,12 +167,17 @@ } } -void CAiTitlePaneRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aResource, - TInt /*aIndex*/ ) +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiTitlePaneRenderer::DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, TInt aResource, TInt /*aIndex*/ ) { - if( aPlugin.PublisherInfoL()->iUid == KDeviceStatusPluginUid ) + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + if( info.Uid() == KDeviceStatusPluginUid ) { switch( aContent ) { @@ -168,11 +205,19 @@ } } - -void CAiTitlePaneRenderer::DoCleanL( MAiPropertyExtension& aPlugin, TInt aContent ) +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::DoCleanL() +// +// ---------------------------------------------------------------------------- +// +void CAiTitlePaneRenderer::DoCleanL( CHsContentPublisher& aPlugin, + TInt aContent ) { __PRINT(__DBG_FORMAT("XAI: Clean title pane - %d"), aContent ); - if( aPlugin.PublisherInfoL()->iUid == KDeviceStatusPluginUid ) + + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + if( info.Uid() == KDeviceStatusPluginUid ) { switch( aContent ) { @@ -199,21 +244,43 @@ } } +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::TransactionCommittedL() +// +// ---------------------------------------------------------------------------- +// void CAiTitlePaneRenderer::TransactionCommittedL() { } +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::KeylockEnabledL() +// +// ---------------------------------------------------------------------------- +// void CAiTitlePaneRenderer::KeylockEnabledL() { iStatusPanel.StopTitlePaneScrollingL(); } +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::FocusObtainedL() +// +// ---------------------------------------------------------------------------- +// void CAiTitlePaneRenderer::FocusObtainedL() { iStatusPanel.RenderTitlePaneL(); } +// ---------------------------------------------------------------------------- +// CAiTitlePaneRenderer::FocusLostL() +// +// ---------------------------------------------------------------------------- +// void CAiTitlePaneRenderer::FocusLostL() { iStatusPanel.StopTitlePaneScrollingL(); } + +// End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/src/aitoolbarrenderer.cpp --- a/idlehomescreen/nativeuicontroller/src/aitoolbarrenderer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/src/aitoolbarrenderer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -15,17 +15,8 @@ * */ - -#include "aitoolbarrenderer.h" -#include "aifweventhandler.h" -#include "aicontentobserver.h" -#include "activeidle2domaincrkeys.h" -#include "activeidle2domainpskeys.h" -#include "aiscutplugindomaincrkeys.h" -#include -#include "ainativeuiplugins.h" - -#include +// System includes +#include #include #include #include @@ -33,13 +24,24 @@ #include #include -#include "centralrepository.h" +// User includes +#include +#include +#include "aitoolbarrenderer.h" +#include "aifweventhandler.h" +#include "aicontentobserver.h" +#include "activeidle2domaincrkeys.h" +#include "activeidle2domainpskeys.h" +#include "aiscutplugindomaincrkeys.h" +#include "ainativeuiplugins.h" +#include #include "debug.h" using namespace AiNativeUiController; +// Constants // Action to send to framework _LIT( KOpenAppByIndex, "Shortcut/LaunchByIndex(%d)" ); _LIT( KOpenAppByIndexAlternate, "Shortcut/LaunchByIndexAlternate(%d)"); @@ -52,6 +54,12 @@ const TInt KRadix = 10; +// ======== LOCAL FUNCTIONS ======== +// ---------------------------------------------------------------------------- +// IndexLength() +// +// ---------------------------------------------------------------------------- +// static TInt IndexLength( TInt aIndex ) { TInt length = 0; @@ -71,6 +79,11 @@ return length; } +// ---------------------------------------------------------------------------- +// CreateEventStringL() +// +// ---------------------------------------------------------------------------- +// static HBufC* CreateEventStringL( const TDesC& aFrom, TInt aEventIndex ) { HBufC* buffer = NULL; @@ -87,16 +100,25 @@ return buffer; } -// ========== MEMBER FUNCTIONS ================================================ - -CAiToolbarRenderer::CAiToolbarRenderer( MAiFwEventHandler& aAiFwEventHandler, CAknToolbar& aToolbar ) +// ======== MEMBER FUNCTIONS ======== +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::CAiToolbarRenderer() +// +// ---------------------------------------------------------------------------- +// +CAiToolbarRenderer::CAiToolbarRenderer( MAiFwEventHandler& aAiFwEventHandler, + CAknToolbar& aToolbar ) : iToolbar( aToolbar ), iAiFwEventHandler( aAiFwEventHandler ) - { // no implementation required } +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::ConstructL() +// +// ---------------------------------------------------------------------------- +// void CAiToolbarRenderer::ConstructL( ) { iToolbarEnabled = EFalse; @@ -119,24 +141,42 @@ iToolbar.SetToolbarObserver( this ); iToolbar.SetToolbarVisibility( ETrue, EFalse ); } - } -CAiToolbarRenderer* CAiToolbarRenderer::NewLC( MAiFwEventHandler& aAiFwEventHandler, CAknToolbar& aToolbar ) +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::NewLC() +// +// ---------------------------------------------------------------------------- +// +CAiToolbarRenderer* CAiToolbarRenderer::NewLC( + MAiFwEventHandler& aAiFwEventHandler, CAknToolbar& aToolbar ) { - CAiToolbarRenderer* self = new (ELeave) CAiToolbarRenderer( aAiFwEventHandler, aToolbar ); + CAiToolbarRenderer* self = + new ( ELeave ) CAiToolbarRenderer( aAiFwEventHandler, aToolbar ); CleanupStack::PushL( self ); - self->ConstructL( ); + self->ConstructL(); return self; } -CAiToolbarRenderer* CAiToolbarRenderer::NewL( MAiFwEventHandler& aAiFwEventHandler, CAknToolbar& aToolbar ) +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::NewL() +// +// ---------------------------------------------------------------------------- +// +CAiToolbarRenderer* CAiToolbarRenderer::NewL( + MAiFwEventHandler& aAiFwEventHandler, CAknToolbar& aToolbar ) { - CAiToolbarRenderer* self = CAiToolbarRenderer::NewLC( aAiFwEventHandler, aToolbar ); + CAiToolbarRenderer* self = + CAiToolbarRenderer::NewLC( aAiFwEventHandler, aToolbar ); CleanupStack::Pop(); // self return self; } +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::~CAiToolbarRenderer() +// +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::~CAiToolbarRenderer() { // We don't want anymore events from toolbar @@ -144,46 +184,67 @@ iButtons.ResetAndDestroy(); } -void CAiToolbarRenderer::DynInitToolbarL( TInt /*aResourceId*/, CAknToolbar* /*aToolbar*/ ) +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::DynInitToolbarL() +// +// ---------------------------------------------------------------------------- +// +void CAiToolbarRenderer::DynInitToolbarL( TInt /*aResourceId*/, + CAknToolbar* /*aToolbar*/ ) { // do nothing } +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::OfferToolbarEventL() +// +// ---------------------------------------------------------------------------- +// void CAiToolbarRenderer::OfferToolbarEventL( TInt aCommand ) { TInt modifiers = iToolbar.EventModifiers(); - if ( aCommand >= 0 && aCommand < iButtons.Count()) { CAiToolbarButton* button = iButtons[aCommand]; + if ( button ) { - HBufC *event = NULL; + if ( modifiers == CAknToolbar::ELongPress ) { - event = CreateEventStringL( KOpenAppByIndexAlternate, button->ShortcutId() ); + event = CreateEventStringL( + KOpenAppByIndexAlternate, button->ShortcutId() ); + CleanupStack::PushL( event ); } else { - event = CreateEventStringL( KOpenAppByIndex, button->ShortcutId() ); + event = CreateEventStringL( + KOpenAppByIndex, button->ShortcutId() ); + CleanupStack::PushL( event ); } + iAiFwEventHandler.HandlePluginEvent( *event ); CleanupStack::PopAndDestroy( event ); } } } -void CAiToolbarRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC16& aText, - TInt aIndex ) +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiToolbarRenderer::DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, const TDesC16& aText, TInt aIndex ) { + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + // Only interested on certain publish events - if ( aPlugin.PublisherInfoL()->iUid == KShortcutPluginUid && + if ( info.Uid() == KShortcutPluginUid && aContent == EAiScutContentShortcutToolbarCaption && ( aIndex == EAiScutToolbarFirst || aIndex == EAiScutToolbarSecond || @@ -199,13 +260,18 @@ } } -void CAiToolbarRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC8& aBuf, - TInt aIndex ) +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::DoPublishL() +// +// ---------------------------------------------------------------------------- +// +void CAiToolbarRenderer::DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, const TDesC8& aBuf, TInt aIndex ) { + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + // Only interested on certain publish events - if ( aPlugin.PublisherInfoL()->iUid == KShortcutPluginUid && + if ( info.Uid() == KShortcutPluginUid && aContent == EAiScutContentShortcutToolbarIcon && ( aIndex == EAiScutToolbarFirst || aIndex == EAiScutToolbarSecond || @@ -239,6 +305,11 @@ } } +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::ButtonL() +// +// ---------------------------------------------------------------------------- +// CAiToolbarButton* CAiToolbarRenderer::ButtonL( TInt aShortcutId ) { TInt index = KErrNotFound; @@ -279,12 +350,16 @@ return button; } - +// ---------------------------------------------------------------------------- +// CAiToolbarRenderer::TransactionCommittedL() +// +// ---------------------------------------------------------------------------- +// void CAiToolbarRenderer::TransactionCommittedL() { if ( !iCommitted ) { - for(TInt i = 0; i < iButtons.Count(); i++) + for ( TInt i = 0; i < iButtons.Count(); i++ ) { CAiToolbarButton *button = iButtons[i]; if ( button && button->Icon()) @@ -300,5 +375,4 @@ } } - // End of File. diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/src/appui.cpp --- a/idlehomescreen/nativeuicontroller/src/appui.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/src/appui.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -16,26 +16,8 @@ */ -#include "appui.h" -#include "ainativeui.hrh" -#include "ainativeuistrings.h" // string literals -#include "ainativeuiview.h" -#include "application.h" -#include "nativeuicontroller.h" -#include "aiuiframeworkobserver.h" -#include "aifweventhandler.h" -#include - -#include "aipropertyextension.h" -#include "aicontentmodel.h" -#include "aiuiidleintegration.h" -#include "activeidle2domaincrkeys.h" -#include "activeidle2domainpskeys.h" -#include "extrstandbycontainerif.h" -#include "debug.h" - +// System includes #include -#include #include #include #include @@ -51,6 +33,27 @@ #include #include +// User includes +#include +#include + +#include "appui.h" +#include "ainativeui.hrh" +#include "ainativeuistrings.h" // string literals +#include "ainativeuiview.h" +#include "application.h" +#include "nativeuicontroller.h" +#include "aifweventhandler.h" +#include + +#include "aicontentmodel.h" +#include "aiuiidleintegration.h" +#include "activeidle2domaincrkeys.h" +#include "activeidle2domainpskeys.h" +#include "extrstandbycontainerif.h" +#include "debug.h" + + namespace { _LIT( KResourceDrive, "Z:" ); @@ -193,9 +196,7 @@ } iFwEventHandler = iUiCtl->FwEventHandler(); - - iUiFwObserver = iUiCtl->UiFrameworkObserver(); - + TAiIdleKeySoundConfig keySoundConfig; keySoundConfig.iKeySounds = KeySounds(); keySoundConfig.iContextResId = R_NATIVEUI_DEFAULT_SKEY_LIST; @@ -328,11 +329,6 @@ void CAppUi::HandleForegroundEventL(TBool aForeground) { CAknAppUi::HandleForegroundEventL( aForeground ); - - if ( iUiFwObserver ) - { - iUiFwObserver->HandleForegroundEvent( aForeground ); - } } void CAppUi::HandleCommandL(TInt aCommand) @@ -463,11 +459,6 @@ } } - - if ( iUiFwObserver ) - { - iUiFwObserver->HandleResourceChange(aType); - } } void CAppUi::HandleWsEventL(const TWsEvent& aEvent, CCoeControl* aDestination) diff -r c743ef5928ba -r f966699dea19 idlehomescreen/nativeuicontroller/src/nativeuicontroller.cpp --- a/idlehomescreen/nativeuicontroller/src/nativeuicontroller.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/nativeuicontroller/src/nativeuicontroller.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -17,22 +17,20 @@ // System includes #include -#include #include -#include -#include #include #include -#include #include #include #include #include -#include #include #include // User includes +#include +#include +#include #include "nativeuicontroller.h" #include "ainativeui.hrh" #include "application.h" @@ -40,7 +38,6 @@ #include "aiutility.h" #include "aistrparser.h" #include "aidevicestatuscontentmodel.h" -#include "aipropertyextension.h" #include "aistatuspanel.h" #include "ainativerenderer.h" #include "aititlepanerenderer.h" @@ -48,13 +45,11 @@ #include "aidialogrenderer.h" #include "aisoftkeyrenderer.h" #include "ainotifierrenderer.h" -#include "aitoolbarrenderer.h" #include "ainativeuiplugins.h" #include "activeidle2domaincrkeys.h" #include "aistatuspanetouchui.h" #include "ainativeuistrings.h" // string literals #include "aistrcnv.h" -#include using namespace AiNativeUiController; @@ -75,9 +70,22 @@ IMPLEMENTATION_PROXY_ENTRY(KImplementationUidNativeUiController, CNativeUiController::NewL) }; +// ======== LOCAL FUNCTIONS ======== +// ---------------------------------------------------------------------------- +// IsDeviceStatus() +// +// ---------------------------------------------------------------------------- +// +TBool IsDeviceStatus( const THsPublisherInfo& aInfo ) + { + return ( aInfo.Name() == KDeviceStatusPluginName && + aInfo.Uid() == KDeviceStatusPluginUid ); + } +// ======== MEMBER FUNCTIONS ======== // ---------------------------------------------------------------------------- // CNativeUiController::NewL() +// // ---------------------------------------------------------------------------- // CNativeUiController* CNativeUiController::NewL() @@ -96,6 +104,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::Exit() +// // ---------------------------------------------------------------------------- // void CNativeUiController::Exit() @@ -107,11 +116,11 @@ iExitTimer->Start( 0, KOneSecondInMicroS, TCallBack( ExitTimerCallBack, this ) ); } - } // ---------------------------------------------------------------------------- // CNativeUiController::ExitTimerCallBack() +// // ---------------------------------------------------------------------------- // TInt CNativeUiController::ExitTimerCallBack( TAny *aSelf ) @@ -131,12 +140,13 @@ // ---------------------------------------------------------------------------- // CNativeUiController::~CNativeUiController() +// // ---------------------------------------------------------------------------- // CNativeUiController::~CNativeUiController() { - iPlugins.Close(); - + iPlugins.Reset(); + delete iExitTimer; PrepareToExit(); @@ -147,6 +157,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::PrepareToExit() +// // ---------------------------------------------------------------------------- // void CNativeUiController::PrepareToExit() @@ -175,6 +186,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::CNativeUiController() +// // ---------------------------------------------------------------------------- // CNativeUiController::CNativeUiController() @@ -183,7 +195,18 @@ } // ---------------------------------------------------------------------------- +// CNativeUiController::SetAppUi() +// +// ---------------------------------------------------------------------------- +// +void CNativeUiController::SetAppUi( CAppUi* aAppUi ) + { + iAppUi = aAppUi; + } + +// ---------------------------------------------------------------------------- // CNativeUiController::AddRendererL() +// // ---------------------------------------------------------------------------- // void CNativeUiController::AddRendererL( CAiNativeRenderer* aRenderer ) @@ -193,6 +216,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::RemoveRenderer() +// // ---------------------------------------------------------------------------- // TBool CNativeUiController::RemoveRenderer( CAiNativeRenderer *aRenderer, @@ -216,56 +240,17 @@ } // ---------------------------------------------------------------------------- -// CNativeUiController::ExitTimerCallBack() -// ---------------------------------------------------------------------------- -// -void CNativeUiController::DeleteToolbarRenderer() - { - if ( iToolbarRenderer ) - { - RemoveRenderer( iToolbarRenderer ); - delete iToolbarRenderer; - iToolbarRenderer = NULL; - } - } - -// ---------------------------------------------------------------------------- -// CNativeUiController::RecreateToolbarRendererL() -// ---------------------------------------------------------------------------- +// CNativeUiController::DoPublish() // -TBool CNativeUiController::RecreateToolbarRendererL() - { - TBool created( EFalse ); - // Remove the old renderer... - DeleteToolbarRenderer(); - - CAknToolbar* toolbar( iAvkonAppUi->CurrentFixedToolbar() ); - // ...and create the new if there is an existing toolbar that - // we can use - if ( toolbar ) - { - iToolbarRenderer = CAiToolbarRenderer::NewL( *iFwEventHandler, *toolbar); - AddRendererL( iToolbarRenderer ); - created = ETrue; - } - - return created; - } - - -// ---------------------------------------------------------------------------- -// CNativeUiController::DoPublish() // ---------------------------------------------------------------------------- // template -TInt CNativeUiController::DoPublish( MAiPropertyExtension& aPlugin, +TInt CNativeUiController::DoPublish( CHsContentPublisher& aPlugin, TInt aContent, T& aData, TInt aIndex ) { - const TAiPublisherInfo* info( NULL ); - - TRAP_IGNORE( info = aPlugin.PublisherInfoL() ); - - if ( !info || info->iNamespace != KNativeUiNamespace ) + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + if ( !IsDeviceStatus( info ) && info.Namespace() != KNativeUiNamespace ) { return KErrNotSupported; } @@ -294,6 +279,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::HandleIdleStateEvent() +// // ---------------------------------------------------------------------------- // TInt CNativeUiController::HandleIdleStateEvent( TAny* aPtr ) @@ -329,6 +315,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::HandleKeylockStateEvent() +// // ---------------------------------------------------------------------------- // TInt CNativeUiController::HandleKeylockStateEvent( TAny* aPtr ) @@ -376,6 +363,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::HandlePluginConfChange() +// // ---------------------------------------------------------------------------- // TInt CNativeUiController::HandlePluginConfChange( TAny* aPtr ) @@ -398,6 +386,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::LoadUIDefinitionL() +// // ---------------------------------------------------------------------------- // void CNativeUiController::LoadUIDefinitionL() @@ -412,7 +401,7 @@ } return; } - + if ( !iExitTimer ) { iExitTimer = CPeriodic::NewL( CActive::EPriorityStandard ); @@ -452,10 +441,23 @@ CleanupStack::Pop();//CAiSoftKeyRenderer // Toolbar shown only when we are not the main ui controller - DeleteToolbarRenderer(); - - TRAP_IGNORE( - iAppUi->StartL(); ) + //DeleteToolbarRenderer(); + + THsPublisherInfo deviceStatus( KDeviceStatusPluginUid, + KDeviceStatusPluginName, KNativeUiNamespace ); + + iPlugins.Append( deviceStatus ); + + iFwStateHandler->LoadPlugin( deviceStatus, EAiFwSystemStartup ); + + THsPublisherInfo profile( KProfilePluginUid, + KProfilePluginName, KNativeUiNamespace ); + + iPlugins.Append( profile ); + + iFwStateHandler->LoadPlugin( profile, EAiFwSystemStartup ); + + TRAP_IGNORE( iAppUi->StartL() ); } // We need to load the resource file here if we are not main controller. @@ -473,7 +475,7 @@ iResourceOffset = iCoeEnv->AddResourceFileL( resourceFile ); } // Create the toolbar renderer - RecreateToolbarRendererL(); + //RecreateToolbarRendererL(); } // 4) Add an observer that informs us about the focus transition changes @@ -503,59 +505,19 @@ } // ---------------------------------------------------------------------------- -// CNativeUiController::GetPluginsL() +// CNativeUiController::GetSettingsL() +// // ---------------------------------------------------------------------------- // -void CNativeUiController::GetPluginsL( RAiPublisherInfoArray& aPlugins ) - { - iPlugins.Reset(); - - if( iRunningAsMain ) - { - TAiPublisherInfo shortcutPublisherInfo; - shortcutPublisherInfo.iUid = KShortcutPluginUid; - shortcutPublisherInfo.iName.Copy( KShortcutPluginName ); - shortcutPublisherInfo.iNamespace.Copy( KNativeUiNamespace ); - - User::LeaveIfError( iPlugins.Append( shortcutPublisherInfo ) ); - - TAiPublisherInfo deviceStatusPublisherInfo; - deviceStatusPublisherInfo.iUid = KDeviceStatusPluginUid; - deviceStatusPublisherInfo.iName.Copy( KDeviceStatusPluginName ); - deviceStatusPublisherInfo.iNamespace.Copy( KNativeUiNamespace ); - - User::LeaveIfError( iPlugins.Append( deviceStatusPublisherInfo ) ); - - TAiPublisherInfo profilePublisherInfo; - profilePublisherInfo.iUid = KProfilePluginUid; - profilePublisherInfo.iName.Copy( KProfilePluginName ); - profilePublisherInfo.iNamespace.Copy( KNativeUiNamespace ); - - User::LeaveIfError( iPlugins.Append( profilePublisherInfo ) ); - - // Copy iPlugins to aPlugins - aPlugins.ReserveL( aPlugins.Count() + iPlugins.Count() ); - - for( TInt i = 0; i < iPlugins.Count(); ++i ) - { - aPlugins.Append( iPlugins[i] ); - } - } - } - -// ---------------------------------------------------------------------------- -// CNativeUiController::GetSettingsL() -// ---------------------------------------------------------------------------- -// -void CNativeUiController::GetSettingsL( const TAiPublisherInfo& aPubInfo, +void CNativeUiController::GetSettingsL( const THsPublisherInfo& aPublisherInfo, RAiSettingsItemArray& aSettings ) { - if ( aPubInfo.iNamespace != KNativeUiNamespace ) + if ( aPublisherInfo.Namespace() != KNativeUiNamespace ) { return; } - if( iRunningAsMain && aPubInfo.iUid == KShortcutPluginUid ) + if( iRunningAsMain && aPublisherInfo.Uid() == KShortcutPluginUid ) { RProperty::Set( KPSUidAiInformation, KActiveIdleExtHS_PluginConfChange, 0 ); @@ -563,7 +525,7 @@ CleanupDeletePushL( settings ); MAiPluginSettingsItem& item = settings->AiPluginSettingsItem(); - item.SetPublisherId( aPubInfo.iUid ); + item.SetPublisherId( aPublisherInfo.Uid() ); HBufC* appBuf; appBuf = HBufC::NewLC( RProperty::KMaxPropertySize ); @@ -593,7 +555,7 @@ CleanupDeletePushL( settings ); MAiPluginSettingsItem& item2 = settings->AiPluginSettingsItem(); - item2.SetPublisherId( aPubInfo.iUid ); + item2.SetPublisherId( aPublisherInfo.Uid() ); HBufC* app2Buf; app2Buf = HBufC::NewLC( RProperty::KMaxPropertySize ); @@ -619,19 +581,21 @@ // In case there are settings in the cenrep the settings // here are overwritten by them - GetSettingsFromCRL( aPubInfo, aSettings ); + GetSettingsFromCRL( aPublisherInfo, aSettings ); CleanupStack::Pop( settings ); } } // ---------------------------------------------------------------------------- // CNativeUiController::GetSettingsFromCRL() +// // ---------------------------------------------------------------------------- // -void CNativeUiController::GetSettingsFromCRL( const TAiPublisherInfo& aPubInfo, - RAiSettingsItemArray &aPluginSettings ) +void CNativeUiController::GetSettingsFromCRL( + const THsPublisherInfo& aPublisherInfo, + RAiSettingsItemArray &aPluginSettings ) { - if ( aPubInfo.iNamespace != KNativeUiNamespace ) + if ( aPublisherInfo.Namespace() != KNativeUiNamespace ) { return; } @@ -684,7 +648,7 @@ } // does the setting belong to this plugin - if ( err == KErrNone && pluginIdPtr == aPubInfo.iName ) + if ( err == KErrNone && pluginIdPtr == aPublisherInfo.Name() ) { // Get the settings id err = settingsRepository->Get(crKey++, settingKeyPtr); @@ -707,7 +671,7 @@ MAiPluginSettingsItem& item = setting->AiPluginSettingsItem(); // Existing setting found => replace it - if ( item.Key() == settingId && item.PublisherId() == aPubInfo.iUid ) + if ( item.Key() == settingId && item.PublisherId() == aPublisherInfo.Uid() ) { item.SetValueL( settingValuePtr, EFalse ); settingFound = ETrue; @@ -716,19 +680,21 @@ } // Existing setting not found => append new one ONLY if we // are dealing with the icon overrides + /* NOTE ai_shortcut_command_api has been removed! if ( !settingFound && ( settingId & KScutFlagBitIconOverride ) ) { MAiPluginSettings* settings = AiUtility::CreatePluginSettingsL(); CleanupDeletePushL( settings ); MAiPluginSettingsItem& item = settings->AiPluginSettingsItem(); - item.SetPublisherId( aPubInfo.iUid ); + item.SetPublisherId( aPublisherInfo.Uid() ); item.SetKey( settingId ); item.SetValueL( settingValuePtr, EFalse ); aPluginSettings.Append( settings ); CleanupStack::Pop( settings ); } + */ } } } @@ -753,6 +719,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::ActivateUI() +// // ---------------------------------------------------------------------------- // void CNativeUiController::ActivateUI() @@ -765,6 +732,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::GetContentObserver() +// // ---------------------------------------------------------------------------- // MAiContentObserver& CNativeUiController::GetContentObserver() @@ -774,6 +742,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::SetEventHandler() +// // ---------------------------------------------------------------------------- // void CNativeUiController::SetEventHandler( MAiFwEventHandler& aEventHandler ) @@ -782,7 +751,18 @@ } // ---------------------------------------------------------------------------- +// CNativeUiController::SetStateHandler() +// +// ---------------------------------------------------------------------------- +// +void CNativeUiController::SetStateHandler( MAiFwStateHandler& aStateHandler ) + { + iFwStateHandler = &aStateHandler; + } + +// ---------------------------------------------------------------------------- // CNativeUiController::FwEventHandler() +// // ---------------------------------------------------------------------------- // MAiFwEventHandler* CNativeUiController::FwEventHandler() @@ -791,16 +771,8 @@ } // ---------------------------------------------------------------------------- -// CNativeUiController::RemovePluginFromUI() -// ---------------------------------------------------------------------------- +// CNativeUiController::MainInterface() // -void CNativeUiController::RemovePluginFromUI( - MAiPropertyExtension& /*aPlugin*/ ) - { - } - -// ---------------------------------------------------------------------------- -// CNativeUiController::MainInterface() // ---------------------------------------------------------------------------- // MAiMainUiController* CNativeUiController::MainInterface() @@ -810,6 +782,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::SecondaryInterface() +// // ---------------------------------------------------------------------------- // MAiSecondaryUiController* CNativeUiController::SecondaryInterface() @@ -819,6 +792,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::RunApplicationL() +// // ---------------------------------------------------------------------------- // void CNativeUiController::RunApplicationL() @@ -831,6 +805,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::CoeEnv() +// // ---------------------------------------------------------------------------- // CCoeEnv& CNativeUiController::CoeEnv() @@ -839,26 +814,18 @@ } // ---------------------------------------------------------------------------- -// CNativeUiController::SetUiFrameworkObserver() -// ---------------------------------------------------------------------------- +// CNativeUiController::IsMenuOpen() // -void CNativeUiController::SetUiFrameworkObserver( - MAiUiFrameworkObserver& aObserver ) - { - iUiFrameworkObserver = &aObserver; - } - -// ---------------------------------------------------------------------------- -// CNativeUiController::IsMenuOpen() // ---------------------------------------------------------------------------- // TBool CNativeUiController::IsMenuOpen() { - return CoeEnv().AppUi()->IsDisplayingMenuOrDialog(); + return iAppUi->IsDisplayingMenuOrDialog(); } // ---------------------------------------------------------------------------- // CNativeUiController::SetCoeEnv() +// // ---------------------------------------------------------------------------- // void CNativeUiController::SetCoeEnv( CCoeEnv& aCoeEnv ) @@ -867,32 +834,8 @@ } // ---------------------------------------------------------------------------- -// CNativeUiController::UiFrameworkObserver() -// ---------------------------------------------------------------------------- -// -MAiUiFrameworkObserver* CNativeUiController::UiFrameworkObserver() - { - return iUiFrameworkObserver; - } - -// ---------------------------------------------------------------------------- -// CNativeUiController::HandleResourceChange() -// ---------------------------------------------------------------------------- +// CNativeUiController::StartTransaction() // -void CNativeUiController::HandleResourceChange( TInt /*aType*/ ) - { - } - -// ---------------------------------------------------------------------------- -// CNativeUiController::HandleForegroundEvent() -// ---------------------------------------------------------------------------- -// -void CNativeUiController::HandleForegroundEvent( TBool /*aForeground*/ ) - { - } - -// ---------------------------------------------------------------------------- -// CNativeUiController::StartTransaction() // ---------------------------------------------------------------------------- // TInt CNativeUiController::StartTransaction( TInt /*aTxId*/ ) @@ -902,6 +845,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::Commit() +// // ---------------------------------------------------------------------------- // TInt CNativeUiController::Commit( TInt /*aTxId*/ ) @@ -919,6 +863,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::CancelTransaction() +// // ---------------------------------------------------------------------------- // TInt CNativeUiController::CancelTransaction( TInt /*aTxId*/ ) @@ -928,23 +873,27 @@ // ---------------------------------------------------------------------------- // CNativeUiController::CanPublish() +// // ---------------------------------------------------------------------------- // -TBool CNativeUiController::CanPublish( MAiPropertyExtension& aPlugin, +TBool CNativeUiController::CanPublish( CHsContentPublisher& aPlugin, TInt /*aContent*/, TInt /*aIndex*/ ) { - const TAiPublisherInfo* info( NULL ); + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + if ( IsDeviceStatus( info ) ) + { + return ETrue; + } - TRAP_IGNORE( info = aPlugin.PublisherInfoL() ); - - if ( !info || info->iNamespace != KNativeUiNamespace ) + if ( info.Namespace() != KNativeUiNamespace ) { return EFalse; } for( TInt i = 0; i < iPlugins.Count(); i++ ) { - if ( iPlugins[i] == *info ) + if ( iPlugins[i] == info ) { return ETrue; } @@ -955,9 +904,10 @@ // ---------------------------------------------------------------------------- // CNativeUiController::Publish() +// // ---------------------------------------------------------------------------- // -TInt CNativeUiController::Publish( MAiPropertyExtension& aPlugin, +TInt CNativeUiController::Publish( CHsContentPublisher& aPlugin, TInt aContent, TInt aResource, TInt aIndex ) { TInt err = DoPublish( aPlugin, aContent, aResource, aIndex ); @@ -966,9 +916,10 @@ // ---------------------------------------------------------------------------- // CNativeUiController::Publish() +// // ---------------------------------------------------------------------------- // -TInt CNativeUiController::Publish( MAiPropertyExtension& aPlugin, +TInt CNativeUiController::Publish( CHsContentPublisher& aPlugin, TInt aContent, const TDesC16& aText, TInt aIndex ) { TInt err = DoPublish( aPlugin, aContent, aText, aIndex ); @@ -977,9 +928,10 @@ // ---------------------------------------------------------------------------- // CNativeUiController::Publish() +// // ---------------------------------------------------------------------------- // -TInt CNativeUiController::Publish( MAiPropertyExtension& aPlugin, +TInt CNativeUiController::Publish( CHsContentPublisher& aPlugin, TInt aContent, const TDesC8& aBuf, TInt aIndex ) { TInt err = DoPublish( aPlugin, aContent, aBuf, aIndex ); @@ -988,9 +940,10 @@ // ---------------------------------------------------------------------------- // CNativeUiController::Publish() +// // ---------------------------------------------------------------------------- // -TInt CNativeUiController::Publish( MAiPropertyExtension& aPlugin, +TInt CNativeUiController::Publish( CHsContentPublisher& aPlugin, TInt aContent, RFile& aFile, TInt aIndex ) { TInt err = DoPublish( aPlugin, aContent, aFile, aIndex ); @@ -999,9 +952,10 @@ // ---------------------------------------------------------------------------- // CNativeUiController::Clean() +// // ---------------------------------------------------------------------------- // -TInt CNativeUiController::Clean( MAiPropertyExtension& aPlugin, +TInt CNativeUiController::Clean( CHsContentPublisher& aPlugin, TInt aContent, TInt /*aIndex*/ ) { const TInt count( iRenderers.Count() ); @@ -1016,6 +970,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::Extension() +// // ---------------------------------------------------------------------------- // TAny* CNativeUiController::Extension( TUid /*aUid*/ ) @@ -1025,12 +980,14 @@ // ---------------------------------------------------------------------------- // CNativeUiController::RequiresSubscription() +// // ---------------------------------------------------------------------------- // TBool CNativeUiController::RequiresSubscription( - const TAiPublisherInfo& aPublisherInfo ) const + const THsPublisherInfo& aPublisherInfo ) const { - if ( aPublisherInfo.iNamespace == KNativeUiNamespace ) + if ( IsDeviceStatus( aPublisherInfo ) || + aPublisherInfo.Namespace() == KNativeUiNamespace ) { // Targeted to this content renderer return ETrue; @@ -1043,12 +1000,11 @@ // CNativeUiController::SetProperty() // ---------------------------------------------------------------------------- // -TInt CNativeUiController::SetProperty( MAiPropertyExtension& /*aPlugin*/, +TInt CNativeUiController::SetProperty( CHsContentPublisher& /*aPlugin*/, const TDesC8& /*aElementId*/, const TDesC8& /*aPropertyName*/, const TDesC8& /*aPropertyValue*/ ) - { - + { return KErrNotSupported; } @@ -1056,7 +1012,7 @@ // CNativeUiController::SetProperty() // ---------------------------------------------------------------------------- // -TInt CNativeUiController::SetProperty(MAiPropertyExtension& /*aPlugin*/, +TInt CNativeUiController::SetProperty(CHsContentPublisher& /*aPlugin*/, const TDesC8& /*aElementId*/, const TDesC8& /*aPropertyName*/, const TDesC8& /*aPropertyValue*/, @@ -1067,6 +1023,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::NewApplication() +// // ---------------------------------------------------------------------------- // CApaApplication* CNativeUiController::NewApplication() @@ -1079,6 +1036,7 @@ // ---------------------------------------------------------------------------- // CNativeUiController::VariateToMainUiController() +// // ---------------------------------------------------------------------------- // void CNativeUiController::VariateToMainUiController() diff -r c743ef5928ba -r f966699dea19 idlehomescreen/sapiwrapper/hspswrapper/bwins/hspswrapper.def --- a/idlehomescreen/sapiwrapper/hspswrapper/bwins/hspswrapper.def Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/sapiwrapper/hspswrapper/bwins/hspswrapper.def Fri Feb 19 22:42:37 2010 +0200 @@ -97,4 +97,6 @@ ?SetConfIdL@CHspsConfiguration@hspswrapper@@QAEAAV12@ABVTDesC8@@@Z @ 96 NONAME ; class hspswrapper::CHspsConfiguration & hspswrapper::CHspsConfiguration::SetConfIdL(class TDesC8 const &) ?NewLC@CPropertyMap@hspswrapper@@SAPAV12@XZ @ 97 NONAME ; class hspswrapper::CPropertyMap * hspswrapper::CPropertyMap::NewLC(void) ??0CAddPluginResult@hspswrapper@@AAE@XZ @ 98 NONAME ; hspswrapper::CAddPluginResult::CAddPluginResult(void) + ?RestoreActiveViewL@CHspsWrapper@hspswrapper@@QAEHXZ @ 99 NONAME ; int hspswrapper::CHspsWrapper::RestoreActiveViewL(void) + ?RestoreRootL@CHspsWrapper@hspswrapper@@QAEHXZ @ 100 NONAME ; int hspswrapper::CHspsWrapper::RestoreRootL(void) diff -r c743ef5928ba -r f966699dea19 idlehomescreen/sapiwrapper/hspswrapper/eabi/hspswrapper.def --- a/idlehomescreen/sapiwrapper/hspswrapper/eabi/hspswrapper.def Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/sapiwrapper/hspswrapper/eabi/hspswrapper.def Fri Feb 19 22:42:37 2010 +0200 @@ -130,4 +130,6 @@ _ZTVN11hspswrapper16CAddPluginResultE @ 129 NONAME _ZTVN11hspswrapper18CHspsConfigurationE @ 130 NONAME _ZTVN11hspswrapper8CItemMapE @ 131 NONAME + _ZN11hspswrapper12CHspsWrapper18RestoreActiveViewLEv @ 132 NONAME + _ZN11hspswrapper12CHspsWrapper12RestoreRootLEv @ 133 NONAME diff -r c743ef5928ba -r f966699dea19 idlehomescreen/sapiwrapper/hspswrapper/inc/hspswrapper.h --- a/idlehomescreen/sapiwrapper/hspswrapper/inc/hspswrapper.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/sapiwrapper/hspswrapper/inc/hspswrapper.h Fri Feb 19 22:42:37 2010 +0200 @@ -235,7 +235,22 @@ * @return Operation status. KErrNone (success), KErrNotFound */ IMPORT_C TInt SetActivePluginL(const TDesC8& aPluginId); - + + /** + * Restore active view. Will remove all plugins in active view. + * + * @return Operation status. KErrNone (success), KErrNotFound + */ + IMPORT_C TInt RestoreActiveViewL(); + + /** + * Restore whole root configuration. Will remove + * everything except one view. + * + * @return Operation status. KErrNone (success), KErrNotFound + */ + IMPORT_C TInt RestoreRootL(); + /** * Replace plugin in the active configuration. * diff -r c743ef5928ba -r f966699dea19 idlehomescreen/sapiwrapper/hspswrapper/src/hspswrapper.cpp --- a/idlehomescreen/sapiwrapper/hspswrapper/src/hspswrapper.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/sapiwrapper/hspswrapper/src/hspswrapper.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -65,6 +65,10 @@ _LIT8( KIndex, "position" ); _LIT8( KConfState, "state" ); _LIT8( KRequestNotification, "RequestNotification" ); +_LIT8( KHSPSCommandRestoreConfigurations, "RestoreConfigurations" ); +_LIT8( KRestore, "restore" ); +_LIT8( KActive, "active" ); +_LIT8( KAll, "all" ); namespace hspswrapper{ @@ -754,7 +758,79 @@ outParamList.Reset(); return status; } + +// --------------------------------------------------------------------------- +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CHspsWrapper::RestoreActiveViewL() + { + CLiwGenericParamList& inParamList = iServiceHandler->InParamListL(); + CLiwGenericParamList& outParamList = iServiceHandler->OutParamListL(); + + // Compose Liw message + TLiwGenericParam restoreTypeParam; + restoreTypeParam.SetNameAndValueL( KRestore, TLiwVariant( KActive ) ); + restoreTypeParam.PushL(); + inParamList.AppendL( restoreTypeParam ); + CleanupStack::Pop( &restoreTypeParam ); + restoreTypeParam.Reset(); + + iHspsInterface->ExecuteCmdL( KHSPSCommandRestoreConfigurations, + inParamList, + outParamList ); + + inParamList.Reset(); + + // check success + const TLiwGenericParam* outParam = NULL; + TInt pos(0); + outParam = outParamList.FindFirst( pos, KOutKeyStatus ); + TInt status(KErrGeneral); + if ( outParam ) + { + status = outParam->Value().AsTInt32(); + } + outParamList.Reset(); + return status; + } + +// --------------------------------------------------------------------------- +// --------------------------------------------------------------------------- +// +EXPORT_C TInt CHspsWrapper::RestoreRootL() + { + CLiwGenericParamList& inParamList = iServiceHandler->InParamListL(); + CLiwGenericParamList& outParamList = iServiceHandler->OutParamListL(); + + // Compose Liw message + TLiwGenericParam restoreTypeParam; + restoreTypeParam.SetNameAndValueL( KRestore, TLiwVariant( KAll ) ); + restoreTypeParam.PushL(); + inParamList.AppendL( restoreTypeParam ); + CleanupStack::Pop( &restoreTypeParam ); + restoreTypeParam.Reset(); + + iHspsInterface->ExecuteCmdL( KHSPSCommandRestoreConfigurations, + inParamList, + outParamList ); + + inParamList.Reset(); + + // check success + const TLiwGenericParam* outParam = NULL; + TInt pos(0); + outParam = outParamList.FindFirst( pos, KOutKeyStatus ); + TInt status(KErrGeneral); + + if ( outParam ) + { + status = outParam->Value().AsTInt32(); + } + outParamList.Reset(); + return status; + } + // --------------------------------------------------------------------------- // --------------------------------------------------------------------------- // diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/data/widgetmanagerview.rss --- a/idlehomescreen/widgetmanager/data/widgetmanagerview.rss Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/data/widgetmanagerview.rss Fri Feb 19 22:42:37 2010 +0200 @@ -190,6 +190,11 @@ buf = qtn_wm_uninst_process_busy; } +RESOURCE TBUF r_qtn_hs_add_widget_max_reached + { + buf = qtn_hs_add_widget_max_reached; + } + RESOURCE TBUF r_qtn_wm_uninstall_text { buf = qtn_wm_uninstall_text; diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/group/widgetmanager.mmp --- a/idlehomescreen/widgetmanager/group/widgetmanager.mmp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/group/widgetmanager.mmp Fri Feb 19 22:42:37 2010 +0200 @@ -52,6 +52,7 @@ SOURCE wmwidgetloaderao.cpp SOURCE wmconfiguration.cpp SOURCE wminstaller.cpp +SOURCE wmprocessmonitor.cpp SOURCEPATH ../data START RESOURCE 20026F53.rss @@ -115,4 +116,5 @@ LIBRARY etext.lib LIBRARY centralrepository.lib LIBRARY bmpanim.lib // AknBitmap animation +LIBRARY inetprotutil.lib // End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/inc/wmconfiguration.h --- a/idlehomescreen/widgetmanager/inc/wmconfiguration.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/inc/wmconfiguration.h Fri Feb 19 22:42:37 2010 +0200 @@ -86,54 +86,23 @@ const TDesC& PortalButtonIcon( TInt aIndex ); /** - * Portal button action method. - * Defines what happens when the portal button is pressed. + * Returns url to for browser by button index * @param aIndex index of the button, starting at 0 */ - TMethod PortalButtonPrimaryMethod( TInt aIndex ); + const TDesC& PortalButtonBrowserUrl( TInt aIndex ); /** - * Service name for the primary method. - * For EHttp this is unused. - * For EWidget, this is the widget Bundle ID. - * For EApplication, this is the application name. - * @param aIndex index of the button, starting at 0 - */ - const TDesC& PortalButtonPrimaryService( TInt aIndex ); - - /** - * parameters related to the method. - * For EHttp this is the HTTP address - * For EWidget the parameters passed to the widget - * For EApplication the params passed to the app. + * Returns client uid by button index * @param aIndex index of the button, starting at 0 */ - const TDesC& PortalButtonPrimaryParams( TInt aIndex ); - - /** - * Secondary method, which is excuted if - * primary method fails. - * Works like Primary method. - * @param aIndex index of the button, starting at 0 - */ - TMethod PortalButtonSecondaryMethod( TInt aIndex ); + TUid PortalButtonClientUid( TInt aIndex ); /** - * Service name for the primary method. - * For EHttp this is unused. - * For EWidget, this is the widget Bundle ID. - * For EApplication, this is the application name. + * Returns client parameter by button index * @param aIndex index of the button, starting at 0 */ - const TDesC& PortalButtonSecondaryService( TInt aIndex ); - - /** - * Parameters for Secondary method. Like Primary method - * Works like Primary params. - * @param aIndex index of the button, starting at 0 - */ - const TDesC& PortalButtonSecondaryParams( TInt aIndex ); - + const TDesC& PortalButtonClientParam( TInt aIndex ); + private: // New functions void LoadConfigurationL(); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/inc/wmlistbox.h --- a/idlehomescreen/widgetmanager/inc/wmlistbox.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/inc/wmlistbox.h Fri Feb 19 22:42:37 2010 +0200 @@ -118,10 +118,6 @@ */ CWmListBox* iListBox; - /** - * current font used in drawing (not owned) - */ - const CFont* iFont; /** * add-button colored bitmap (default color) @@ -292,13 +288,6 @@ */ void HandleSkinChanged(); - /** - * State of pointer down event - * - * @return ETrue if pointer is down - */ - inline TBool PressedDown(); - /** * Returns size of logo * @@ -388,11 +377,6 @@ */ TBool iFindPaneIsVisible; - /** - * state of pointer pressed down and hold - */ - TBool iPressedDown; - /** size of logo rect in list item */ TSize iLogoSize; }; diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/inc/wmlistbox.inl --- a/idlehomescreen/widgetmanager/inc/wmlistbox.inl Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/inc/wmlistbox.inl Fri Feb 19 22:42:37 2010 +0200 @@ -41,13 +41,4 @@ inline const RWidgetDataValues& CWmListBox::WidgetDataArray() { return iWidgetDatas; } -/** - * State of pointer down event - * - * @return ETrue if pointer is down - */ - inline TBool CWmListBox::PressedDown() - { return iPressedDown; } - - #endif /* WMLISTBOX_INL_ */ diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/inc/wmmaincontainer.h --- a/idlehomescreen/widgetmanager/inc/wmmaincontainer.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/inc/wmmaincontainer.h Fri Feb 19 22:42:37 2010 +0200 @@ -243,6 +243,12 @@ */ CWmConfiguration& Configuration(); + /** + * Process foregound events. + * @param aForeground ETrue indicates foreground + */ + void ProcessForegroundEvent( TBool aForeground ); + protected: // from base class CCoeControl /** diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/inc/wmmaincontainerview.h --- a/idlehomescreen/widgetmanager/inc/wmmaincontainerview.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/inc/wmmaincontainerview.h Fri Feb 19 22:42:37 2010 +0200 @@ -73,6 +73,21 @@ */ CWmMainContainer* CreateContainerL(); + /** + * View deactivation function intended for overriding by sub classes. + * + * @see CAknView::DoActivateL + */ + void DoDeactivate(); + +public: // from MeikMenuObserver + + /** + * Foreground event handling function. + * @param aForeground Indicates the required focus state of the control. + */ + void HandleForegroundEventL( TBool aForeground ); + private: CWmMainContainerView( CWmPlugin& aWmPlugin ); void ConstructL(); @@ -88,13 +103,6 @@ TUid aCustomMessageId, const TDesC8& aCustomMessage ); - /** - * View deactivation function intended for overriding by sub classes. - * - * @see CAknView::DoActivateL - */ - void DoDeactivate(); - /** * Event handler for status pane size changes. * @@ -122,8 +130,8 @@ TBool HandleHelpMenuItemSelectedL(); TBool HandleDetailsMenuItemSelectedL(); TBool HandleDeactivateFindPaneL(); - /** setup status pane */ - void SetupStatusPaneL(); + /** setup title in status pane */ + void SetTitleL(); private: /** diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/inc/wmplugin.h --- a/idlehomescreen/widgetmanager/inc/wmplugin.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/inc/wmplugin.h Fri Feb 19 22:42:37 2010 +0200 @@ -57,7 +57,23 @@ * @see MHsContentControlUi::Activate */ void Activate(); - + + /** + * notification for widget manager UI that its + * deactivated and plugin is about to be destroyed. + * + * @see MHsContentControlUi::DeActivate + */ + void DeActivate(); + + /** + * returns array of AknViews which were added to + * AknViewAppUi by this plugin. + * + * @see MHsContentControlUi::Views + */ + void Views( RPointerArray& aViews ); + /** * Notifies widget list changes * @@ -77,7 +93,7 @@ /** * hides widget manager UI */ - void Deactivate(); + void CloseView(); /** * main view activated. Sets the previous view ID and main container @@ -159,6 +175,13 @@ * @param aEnabled ETrue if numeric keys are forwarded to phone */ void ForwardNumericKeysToPhone( TBool aEnabled ); + + /** + * Shows error note. + * + * @parama aError Error to be shown. + */ + void ShowErrorNoteL( TInt aError ); private: // data members @@ -203,12 +226,6 @@ */ CHsContentInfo* iPostponedContent; - /** - * ActiveSchedulerWait used to wait while previous view is - * being activated upon deletion. - */ - CActiveSchedulerWait* iWait; - /* * Handles installation */ diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/inc/wmportalbutton.h --- a/idlehomescreen/widgetmanager/inc/wmportalbutton.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/inc/wmportalbutton.h Fri Feb 19 22:42:37 2010 +0200 @@ -26,6 +26,8 @@ // FORWARD DECLARATIONS class CWmMainContainer; class CFbsBitmap; +class CWmConfiguration; +class CWmProcessMonitor; /** * Portal button ( ovi, operator ) class for Wm @@ -103,7 +105,15 @@ const TDesC& aText, TAknTextComponentLayout& aLayout, TInt aMargin ) const; - + /** Runs operator button action */ + void RunOperatorL( CWmConfiguration& aConf ); + + /** Runs ovi store launcher */ + void RunOviL( CWmConfiguration& aConf ); + + /** Starts browser */ + void StartBrowserL( CWmConfiguration& aConf ); + private: //data members /** @@ -126,6 +136,9 @@ /** icon mask */ CFbsBitmap* iButtonIconMask; + + /** Monitors process */ + CWmProcessMonitor* iProcessMonitor; }; #endif //___WMPORTALBUTTON_H__ diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/inc/wmprocessmonitor.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlehomescreen/widgetmanager/inc/wmprocessmonitor.h Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,85 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).. +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +#ifndef __WMPROCESSMONITOR_ +#define __WMPROCESSMONITOR_ + +//includes +#include + +// Forward declaration +class RProcess; + + +/** + * CWmProcessMonitor + * Monitoring running process + */ +NONSHARABLE_CLASS( CWmProcessMonitor ) : public CActive + { +public: + /** + * Two-phased constructors. + */ + static CWmProcessMonitor* NewL(); + static CWmProcessMonitor* NewLC(); + + /** Destructor */ + ~CWmProcessMonitor(); + +private: + /** constructor */ + CWmProcessMonitor(); + + /** 2nd phase constructor */ + void ConstructL(); + +protected: // implementation of CActive + /** + * Implements cancellation of an outstanding request. + * + * @see CActive::DoCancel + */ + void DoCancel(); + + /** + * Handles an active object's request completion event. + * + * @see CActive::RunL + */ + void RunL(); + + /** + * RunError + * + * @see CActive::RunError + */ + TInt RunError(TInt aError); + +public: + /** + * Starts monitoring process + */ + void Monitor( RProcess& aProcess ); + +private: + + /** process to monitor*/ + RProcess iProcess; + }; + +#endif // __WMPROCESSMONITOR_ diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/inc/wmwidgetdata.h --- a/idlehomescreen/widgetmanager/inc/wmwidgetdata.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/inc/wmwidgetdata.h Fri Feb 19 22:42:37 2010 +0200 @@ -174,6 +174,9 @@ const CWmWidgetData& aDataTwo ); public: // methods to read the content + + /** Mdcapoint for listbox("\t0widget name") */ + const TDesC& MdcaPoint() const; /** the HsContent info */ inline CHsContentInfo& HsContentInfo(); @@ -262,7 +265,10 @@ /** persistent order of widgets (used in sorting) */ const CWmPersistentWidgetOrder* iPersistentWidgetOrder; - + + /** "0\t" + widget name for listbox*/ + HBufC* iMdcaPoint; + /** wrt widget publisher uid */ TUid iPublisherUid; diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/inc/wmwidgetdata.inl --- a/idlehomescreen/widgetmanager/inc/wmwidgetdata.inl Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/inc/wmwidgetdata.inl Fri Feb 19 22:42:37 2010 +0200 @@ -59,7 +59,6 @@ inline void CWmWidgetData::SetValid( TBool aValid ) { iValid = aValid; } - //From RWidgetDataValues /** returns number of items in the pointer array */ @@ -70,7 +69,7 @@ /** returns the pointed widget name */ inline TPtrC16 RWidgetDataValues::MdcaPoint(TInt aIndex) const { - const TPtrC16 ptr( (*this)[aIndex]->Name() ); + const TPtrC16 ptr( (*this)[aIndex]->MdcaPoint() ); return ptr; } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/loc/widgetmanagerview.loc --- a/idlehomescreen/widgetmanager/loc/widgetmanagerview.loc Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/loc/widgetmanagerview.loc Fri Feb 19 22:42:37 2010 +0200 @@ -92,7 +92,7 @@ // w: // r: TB9.2 // -#define qtn_options_wm_details "Details" +#define qtn_options_wm_show_details "Details" // MISC @@ -163,7 +163,7 @@ // d: Query for unistallation // d: // d: -// l: query +// l: popup_note_window // w: // r: TB9.2 // diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/sis/Nokia_RnDCert_02.der Binary file idlehomescreen/widgetmanager/sis/Nokia_RnDCert_02.der has changed diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/sis/Nokia_RnDCert_02.key --- a/idlehomescreen/widgetmanager/sis/Nokia_RnDCert_02.key Tue Feb 02 00:04:13 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,15 +0,0 @@ ------BEGIN RSA PRIVATE KEY----- -MIICXQIBAAKBgQC/TDP7KKIaf5+uW4OD2iVZuUMC2a+SeQTjf6srlKcOm+CpPNXn -uLNm/8fdEnyOIuRXPRKmqhs1n0JkxEGHynELWMTuKXbQx9SRAGUXzyneGn+IJNnO -vOKHWgKCouX2hfI8rtkdqJpqmO460gGsMgw+lsbeyWyW9lnfLxq+ZC7sqQIDAQAB -AoGBALmUWZE8GBaQ3P4u9WUCSd3DJkkrmXIFSULSZeH/chlwCwDjbbhArHothVzo -REE3hEFFlERvHbplZ+mNouzy7boduvgUzbksGrbGMLJ2qO1GzWWVwV+GzOWKd3ss -/98Gwoy5R8pjnkqUE2wP1iJFw0FjvUTKcYv/z6t3LLJ0CsoBAkEA+c7ixvsviQ3J -s0INytCKU2bf8fqFQJi1VI82ukxNsujGTQ9upVSjuvqPvWyDvvTdrUBHqO+3qPut -sEh01Q8aiQJBAMQKDJPVRu4ud3mwUfEavzL5EjqwG1k9VCNGYsT4FwtrHcxu1oP/ -pk6M3rIZukqomoEEnHWPMwhrK3fhBqi0OSECQQDr40VXege4FnH5OI2Hj4afHMyp -VdQQXGMWFyopnzXblFz0lXb43cTCIiorR9XcMqNFHybLypkWE5o+lRzlt55pAkBQ -P/zeF5Sts//cpL0mgdh7OVKpC6ZmZaCnwAx2rUhhuDu+kDDoYCLoTOps5fNI1LRK -1GRoC3LMo3Jr5IYhUYWBAkBpCpN6k4JU/mszq98EojHerQNxk8sPqvQKUzTutohT -1gLX9yepGayB/TtT2EEJDkWOlnTy/dvN6W3vzbJYz97x ------END RSA PRIVATE KEY----- diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/src/wmconfiguration.cpp --- a/idlehomescreen/widgetmanager/src/wmconfiguration.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/src/wmconfiguration.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -19,7 +19,7 @@ // INCLUDE FILES #include #include -#include +#include #include #include @@ -261,87 +261,52 @@ } // --------------------------------------------------------- -// CWmConfiguration::PortalButtonPrimaryMethod +// CWmConfiguration::PortalButtonBrowserUrl // --------------------------------------------------------- // -CWmConfiguration::TMethod - CWmConfiguration::PortalButtonPrimaryMethod( TInt aIndex ) +const TDesC& CWmConfiguration::PortalButtonBrowserUrl( TInt aIndex ) { - IndexConversion( aIndex ); - if ( aIndex == 0 && iOviStoreBundleId && iOviStoreBundleId->Length() > 0 ) - return EWidget; - if ( aIndex == 1 && iOperatorButtonUrl && iOperatorButtonUrl->Length() > 0 ) - return EHttp; - return ENone; - } + if ( aIndex == 0 && iOviButtonUrl ) + return *iOviButtonUrl; + else if ( aIndex == 1 && iOperatorButtonUrl ) + return *iOperatorButtonUrl; -// --------------------------------------------------------- -// CWmConfiguration::PortalButtonPrimaryService -// --------------------------------------------------------- -// -const TDesC& - CWmConfiguration::PortalButtonPrimaryService( TInt aIndex ) - { - IndexConversion( aIndex ); - if ( aIndex == 0 && iOviStoreBundleId && iOviStoreBundleId->Length() > 0 ) - return *iOviStoreBundleId; return KNullDesC; } // --------------------------------------------------------- -// CWmConfiguration::PortalButtonPrimaryParams +// CWmConfiguration::PortalButtonClientUid // --------------------------------------------------------- // -const TDesC& - CWmConfiguration::PortalButtonPrimaryParams( TInt aIndex ) +TUid CWmConfiguration::PortalButtonClientUid( TInt aIndex ) { - IndexConversion( aIndex ); + if ( aIndex == 0 && iOviStoreBundleId ) + { + // idea: change iOviStoreBundleId to UID of laucher in cenrep + return TUid::Uid( 0x2002D07F ); + } + // Operator client uid not supported. + // If operator client is a widget we can use widget registry + // to fetch uid of operator widget save it to member and return that here + return KNullUid; + } + +// --------------------------------------------------------- +// CWmConfiguration::PortalButtonClientParam +// --------------------------------------------------------- +// +const TDesC& CWmConfiguration::PortalButtonClientParam( TInt aIndex ) + { if ( aIndex == 0 && iOviStoreClientParam ) + { return *iOviStoreClientParam; - if ( aIndex == 1 && iOperatorButtonUrl ) - return *iOperatorButtonUrl; + } + // Operator client param not supported. Can be added if needed. return KNullDesC; } // --------------------------------------------------------- -// CWmConfiguration::PortalButtonSecondaryMethod -// --------------------------------------------------------- -// -CWmConfiguration::TMethod - CWmConfiguration::PortalButtonSecondaryMethod( TInt aIndex ) - { - IndexConversion( aIndex ); - if ( aIndex == 0 && iOviButtonUrl && iOviButtonUrl->Length() > 0 ) - return EHttp; - return ENone; - } - -// --------------------------------------------------------- -// CWmConfiguration::PortalButtonSecondaryService -// --------------------------------------------------------- -// -const TDesC& - CWmConfiguration::PortalButtonSecondaryService( TInt aIndex ) - { - IndexConversion( aIndex ); - return KNullDesC; - } - -// --------------------------------------------------------- -// CWmConfiguration::PortalButtonSecondaryParams -// --------------------------------------------------------- -// -const TDesC& - CWmConfiguration::PortalButtonSecondaryParams( TInt aIndex ) - { - IndexConversion( aIndex ); - if ( aIndex == 0 && iOviButtonUrl ) - return *iOviButtonUrl; - return KNullDesC; - } - -// --------------------------------------------------------- // CWmConfiguration::IndexConversion // --------------------------------------------------------- // @@ -356,8 +321,5 @@ // but for now, this method is empty. } - - - // End of File diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/src/wmlistbox.cpp --- a/idlehomescreen/widgetmanager/src/wmlistbox.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/src/wmlistbox.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -78,7 +78,6 @@ { iCellData = aFormattedCellData; iListBox = aListBox; - iFont = aFont; } // --------------------------------------------------------- @@ -131,12 +130,27 @@ // confuses listbox e.g. considering name as icon index CArrayPtr* dummyArray = new( ELeave ) CAknIconArray(2); CleanupStack::PushL(dummyArray); - CGulIcon* dummyIcon = CGulIcon::NewLC(); - CGulIcon* dummyIcon2 = CGulIcon::NewLC(); + + CFbsBitmap* dummyBmp = new(ELeave) CFbsBitmap; + CleanupStack::PushL( dummyBmp ); + User::LeaveIfError( dummyBmp->Create( TSize(0,0), EColor256 ) ); + CGulIcon* dummyIcon = CGulIcon::NewL( dummyBmp ); + CleanupStack::Pop( dummyBmp ); //ownership transfered + CleanupStack::PushL( dummyIcon ); + + CFbsBitmap* dummyBmp2 = new(ELeave) CFbsBitmap; + CleanupStack::PushL( dummyBmp2 ); + User::LeaveIfError( dummyBmp2->Create( TSize(0,0), EColor256 ) ); + CGulIcon* dummyIcon2 = CGulIcon::NewL( dummyBmp2 ); + CleanupStack::Pop( dummyBmp2 ); //ownership transfered + CleanupStack::PushL( dummyIcon2 ); + dummyArray->AppendL(dummyIcon); dummyArray->AppendL(dummyIcon2); ColumnData()->SetIconArray(dummyArray); - CleanupStack::Pop(3); + CleanupStack::Pop( dummyIcon2 ); + CleanupStack::Pop( dummyIcon ); + CleanupStack::Pop( dummyArray ); } // --------------------------------------------------------- @@ -196,8 +210,8 @@ // --------------------------------------------------------- // void CWmListItemDrawer::DrawItem( TInt aItemIndex, TPoint aItemRectPos, - TBool aItemIsSelected, TBool aItemIsCurrent, - TBool aViewIsEmphasized, TBool aViewIsDimmed ) const + TBool /*aItemIsSelected*/, TBool aItemIsCurrent, + TBool /*aViewIsEmphasized*/, TBool aViewIsDimmed ) const { TSize cellSize = ItemCellSize(); @@ -205,39 +219,28 @@ // Get graphics context which is used for drawing. CWindowGc& gc = *Gc(); MAknsSkinInstance* skin = AknsUtils::SkinInstance(); - TInt selectedIndex = iListBox->CurrentItemIndex(); - TBool isInFocus = ( selectedIndex == aItemIndex ); - TBool listFocused = iListBox->IsFocused(); + TBool highlightEnabled = !( iListBox->ItemDrawer()->Flags() & + CListItemDrawer::ESingleClickDisabledHighlight ); + TBool listFocused = ((iListBox->IsFocused() && !aViewIsDimmed) ? ETrue : EFalse); TRect itemRect = TRect( aItemRectPos, cellSize ); - - if ( isInFocus && listFocused ) + + CFormattedCellListBoxItemDrawer::DrawEmptyItem( + aItemIndex, aItemRectPos, aViewIsDimmed ); + + if ( aItemIsCurrent && listFocused && highlightEnabled ) { - // force baseclass to draw highlight and animation for this item - CFormattedCellListBoxItemDrawer::DrawItemText( - aItemIndex, itemRect, - aItemIsCurrent, aViewIsEmphasized, - ( isInFocus || aItemIsSelected ) ); + TRect innerRect( itemRect ); + const TInt highlightOffset = 2; + innerRect.Shrink( highlightOffset, highlightOffset ); - if ( iListBox->PressedDown() ) - { - TRect innerRect( itemRect ); - const TInt highlightOffset = 3; - innerRect.Shrink( highlightOffset, highlightOffset ); - AknsDrawUtils::DrawFrame( skin, - gc, - itemRect, - innerRect, - KAknsIIDQsnFrListPressed, - KAknsIIDQsnFrListCenterPressed ); - } + AknsDrawUtils::DrawFrame( skin, + gc, + itemRect, + innerRect, + KAknsIIDQsnFrList, + KAknsIIDQsnFrListCenter ); + } - else - { - // to prevent item staying highlighted when list isn't focused. - CFormattedCellListBoxItemDrawer::DrawEmptyItem( - aItemIndex, aItemRectPos, aViewIsDimmed ); - } - // DRAW LOGO CFbsBitmap* bitmap = const_cast(wData.LogoImage()); @@ -256,16 +259,14 @@ } TRgb textColor; - TAknsQsnTextColorsIndex index = ( isInFocus && listFocused )? + TAknsQsnTextColorsIndex index = + ( aItemIsCurrent && listFocused && highlightEnabled )? EAknsCIQsnTextColorsCG10 : EAknsCIQsnTextColorsCG6; AknsUtils::GetCachedColor( skin, textColor, KAknsIIDQsnTextColors, index ); // DRAW TEXT - gc.UseFont( iFont ); - gc.SetPenColor( textColor ); - gc.SetPenSize( TSize(2,2) ); TAknTextLineLayout titleTextLayout = AknLayoutScalable_Apps::listrow_wgtman_pane_t1().LayoutLine(); @@ -281,7 +282,7 @@ TAknLayoutRect addButtonLayout; addButtonLayout.LayoutRect( itemRect, AknLayoutScalable_Apps::listrow_wgtman_pane_g2().LayoutLine() ); - if ( isInFocus && listFocused ) + if ( aItemIsCurrent && listFocused && highlightEnabled ) { addButtonLayout.DrawImage( gc, iAddWidgetBtnHighlightImage, iAddWidgetBtnHighlightMask ); @@ -319,7 +320,6 @@ animationLayout.DrawImage( gc, animBitmap, animMask ); } } - gc.DiscardFont(); } // --------------------------------------------------------- @@ -433,7 +433,6 @@ iWmPlugin( aWmPlugin ) { iFindPaneIsVisible = EFalse; - iPressedDown = EFalse; iLogoSize = TSize( 0, 0); } @@ -494,10 +493,13 @@ void CWmListBox::AddWidgetDataL( CWmWidgetData* aWidgetData, TBool aRedraw ) { - aWidgetData->SetObserver( this ); - iWidgetDatas.InsertInOrderAllowRepeatsL( aWidgetData, + if ( aWidgetData ) + { + aWidgetData->SetObserver( this ); + iWidgetDatas.InsertInOrderAllowRepeatsL( aWidgetData, SortOrder(EStoredOrder) ); - if ( aRedraw ) { HandleItemAdditionL(); } + if ( aRedraw ) { HandleItemAdditionL(); } + } } // --------------------------------------------------------- @@ -695,9 +697,6 @@ // void CWmListBox::HandlePointerEventL( const TPointerEvent& aPointerEvent ) { - CAknDouble2LargeStyleListBox::HandlePointerEventL( aPointerEvent ); - - // Check if pointer is down ( needed for drawing correct hightlight frame ) if ( Rect().Contains( aPointerEvent.iPosition ) ) { TInt itemIndex = CurrentListBoxItemIndex(); @@ -706,20 +705,10 @@ itemIndex ); if ( itemIndex >= 0 && itemPointed ) { - if ( aPointerEvent.iType == TPointerEvent::EButton1Down ) - { - iPressedDown = ETrue; - // redraw item - RedrawItem( itemIndex ); - } - else if( aPointerEvent.iType == TPointerEvent::EButton1Up ) - { - iPressedDown = EFalse; - // redraw item - RedrawItem( itemIndex ); - } + SetCurrentItemIndex( itemIndex ); //update index } } + CAknDouble2LargeStyleListBox::HandlePointerEventL( aPointerEvent ); } // --------------------------------------------------------- diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/src/wmmaincontainer.cpp --- a/idlehomescreen/widgetmanager/src/wmmaincontainer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/src/wmmaincontainer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -295,6 +295,10 @@ return EKeyWasConsumed; } +// --------------------------------------------------------- +// CWmMainContainer::HandleSearchKeyEventL +// --------------------------------------------------------- +// TKeyResponse CWmMainContainer::HandleSearchKeyEventL( const TKeyEvent& aKeyEvent, TEventCode aType ) @@ -346,6 +350,10 @@ return keyResponse; } +// --------------------------------------------------------- +// CWmMainContainer::HandleListKeyEventL +// --------------------------------------------------------- +// TKeyResponse CWmMainContainer::HandleListKeyEventL( const TKeyEvent& aKeyEvent, TEventCode aType ) @@ -382,6 +390,10 @@ return keyResponse; } +// --------------------------------------------------------- +// CWmMainContainer::HandleButtonKeyEventL +// --------------------------------------------------------- +// TKeyResponse CWmMainContainer::HandleButtonKeyEventL( const TKeyEvent& aKeyEvent, TEventCode aType ) @@ -591,14 +603,14 @@ // focus is NOWHERE // ------------------------------------ if ( aKeyEvent.iScanCode == EStdKeyUpArrow || - aKeyEvent.iScanCode == EStdKeyDownArrow || - aKeyEvent.iScanCode == EStdKeyLeftArrow || - aKeyEvent.iScanCode == EStdKeyRightArrow ) + aKeyEvent.iScanCode == EStdKeyDownArrow ) { // no focus -> key hit -> focus list if ( aType == EEventKey ) + { SetFocusToWidgetList(); - keyResponse = EKeyWasConsumed; + keyResponse = EKeyWasNotConsumed; + } } } @@ -716,19 +728,6 @@ CCoeControl* control = FindChildControlByPoint( aPointerEvent.iPosition ); if ( control && !control->IsFocused() ) { - // set focus to selected list box item. - if ( control == iWidgetsList ) - { - TInt itemIndex = iWidgetsList->CurrentListBoxItemIndex(); - TBool itemPointed = iWidgetsList->View()->XYPosToItemIndex( - aPointerEvent.iPosition, - itemIndex ); - if ( itemIndex >= 0 && itemPointed ) - { - iWidgetsList->SetCurrentItemIndex( itemIndex ); - } - } - // remove focus from ALL other child controls. CCoeControlArray::TCursor cursor = Components().Begin(); CCoeControl* c; @@ -879,8 +878,17 @@ TInt aControlId ) { Components().AppendLC( aControl, aControlId ); // Ownership transfered - CleanupStack::Pop(aControl); - iWmPlugin.ViewAppUi().AddToStackL( aControl ); + CleanupStack::Pop(aControl); + CAknView* view = iWmPlugin.ViewAppUi().View( + TUid::Uid(EWmMainContainerViewId) ); + if ( view ) + { + iWmPlugin.ViewAppUi().AddToStackL( *view, aControl ); + } + else + { + iWmPlugin.ViewAppUi().AddToStackL( aControl ); + } aControl->MakeVisible( ETrue ); } @@ -1033,17 +1041,14 @@ } } - // do not deactivate wm if wrt widget already exists on hs, - // instead of that show popup info note. - if ( CWmWidgetData::ECps == data->WidgetType() && - !data->HsContentInfo().CanBeAdded() && - !hsContentFull ) + // deactivate wm if there's not enough space to add widget to hs. + if ( !data->HsContentInfo().CanBeAdded() && !hsContentFull ) { iWmPlugin.ExecuteCommandL(); } else { - iWmPlugin.Deactivate(); + iWmPlugin.CloseView(); } } } @@ -1147,12 +1152,15 @@ iWidgetsList->SetFindPaneIsVisible( EFalse ); LayoutControls(); - iWidgetsList->SetFocus( ETrue ); // set soft key set CEikButtonGroupContainer* cbaGroup = CEikButtonGroupContainer::Current(); - cbaGroup->SetCommandSetL( R_AVKON_SOFTKEYS_OPTIONS_BACK__SELECT ); + TInt cbaResourceId = ( AknLayoutUtils::MSKEnabled() ? + R_AVKON_SOFTKEYS_OPTIONS_BACK__SELECT : + R_AVKON_SOFTKEYS_OPTIONS_BACK ); + + cbaGroup->SetCommandSetL( cbaResourceId ); cbaGroup->DrawNow(); UpdateFocusMode(); @@ -1267,7 +1275,7 @@ // --------------------------------------------------------------------------- // void CWmMainContainer::RemoveCtrlsFromStack() - { + { for ( TInt i=0; i < CountComponentControls(); i++ ) { CCoeControl* ctl = ComponentControl( i ) ; @@ -1375,6 +1383,29 @@ iWidgetsList->DrawNow(); } +// ---------------------------------------------------- +// CWmMainContainer::ProcessForegroundEvent +// ---------------------------------------------------- +// +void CWmMainContainer::ProcessForegroundEvent( TBool aForeground ) + { + if ( aForeground ) + { + // set init state when wm comes to foreground. + // remove focus from all controls when activating view. + CCoeControl* control = NULL; + CCoeControlArray::TCursor cursor = Components().Begin(); + while( ( control = cursor.Control() ) != NULL ) + { + if( control->IsVisible() && control->IsFocused() ) + { + control->SetFocus( EFalse, EDrawNow ); + } + cursor.Next(); + } + UpdateFocusMode(); + } + } // End of File diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/src/wmmaincontainerview.cpp --- a/idlehomescreen/widgetmanager/src/wmmaincontainerview.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/src/wmmaincontainerview.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -55,7 +55,8 @@ { if ( iWmMainContainer != NULL ) { - AppUi()->RemoveFromViewStack( *this, iWmMainContainer ); + AppUi()->RemoveFromStack( iWmMainContainer ); + delete iWmMainContainer; iWmMainContainer = NULL; } @@ -140,7 +141,7 @@ break; case EWmMainContainerViewBackMenuItemCommand: // flow through case EAknSoftkeyBack: - iWmPlugin.Deactivate(); + iWmPlugin.CloseView(); break; case EWmMainContainerViewWiddetDetailsMenuItemCommand: HandleDetailsMenuItemSelectedL(); @@ -170,29 +171,34 @@ TUid /*aCustomMessageId*/, const TDesC8& /*aCustomMessage*/ ) { - if ( iWmMainContainer == NULL ) - { - iWmMainContainer = CreateContainerL(); - iWmMainContainer->SetMopParent( this ); - AppUi()->AddToStackL( *this, iWmMainContainer ); - } - - SetupStatusPaneL(); - - iWmPlugin.MainViewActivated( aPrevViewId, iWmMainContainer ); + // setup status pane layout StatusPane()->SwitchLayoutL( R_AVKON_STATUS_PANE_LAYOUT_USUAL_FLAT ); StatusPane()->ApplyCurrentSettingsL(); + + // title in status pane + SetTitleL(); + StatusPane()->DrawNow(); + + // update cba CEikButtonGroupContainer* bgc( Cba() ); - CEikCba* cba = static_cast< CEikCba* >( bgc->ButtonGroup() ); if ( cba ) - { - + { bgc->SetBoundingRect( TRect() ); cba->DrawNow(); } + + // create container + if ( iWmMainContainer == NULL ) + { + iWmMainContainer = CreateContainerL(); + iWmMainContainer->SetMopParent( this ); + AppUi()->AddToStackL( *this, iWmMainContainer ); + } + + iWmPlugin.MainViewActivated( aPrevViewId, iWmMainContainer ); } // --------------------------------------------------------- @@ -203,12 +209,11 @@ { if ( iWmMainContainer != NULL ) { - AppUi()->RemoveFromViewStack( *this, iWmMainContainer ); + AppUi()->RemoveFromStack( iWmMainContainer ); delete iWmMainContainer; iWmMainContainer = NULL; + iWmPlugin.MainViewDeactivated(); } - - iWmPlugin.MainViewDeactivated(); } // --------------------------------------------------------- @@ -233,10 +238,10 @@ } // --------------------------------------------------------- -// CWmMainContainerView::SetupStatusPaneL +// CWmMainContainerView::SetTitleL // --------------------------------------------------------- // -void CWmMainContainerView::SetupStatusPaneL() +void CWmMainContainerView::SetTitleL() { // setup the title pane TUid titlePaneUid = TUid::Uid( EEikStatusPaneUidTitle ); @@ -412,4 +417,17 @@ return ETrue; } +// --------------------------------------------------------- +// CWmMainContainerView::HandleForegroundEventL +// --------------------------------------------------------- +// +void CWmMainContainerView::HandleForegroundEventL( TBool aForeground ) + { + CAknView::HandleForegroundEventL( aForeground ); + if ( iWmMainContainer ) + { + iWmMainContainer->ProcessForegroundEvent( aForeground ); + } + } + // End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/src/wmpersistentwidgetorder.cpp --- a/idlehomescreen/widgetmanager/src/wmpersistentwidgetorder.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/src/wmpersistentwidgetorder.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -112,7 +112,8 @@ // 1. create stream for storing the data to a file TFileName storeFileName; GetStoreFileNameL( storeFileName ); - CPermanentFileStore* fileStore = CPermanentFileStore::ReplaceLC( + CPermanentFileStore* fileStore = NULL; + fileStore = CPermanentFileStore::ReplaceLC( iFs, storeFileName, EFileWrite ); fileStore->SetTypeL( KPermanentFileStoreLayoutUid ); RStoreWriteStream writer; @@ -121,8 +122,13 @@ writer.WriteInt32L( aArray.Count() ); for( TInt i=0; iUid().iUid; - const TDesC16& publisherId = aArray[i]->HsContentInfo().PublisherId(); + CWmWidgetData* data = aArray[i]; + if ( !data || !data->IsValid() ) + { + User::Leave( KErrArgument ); + } + TInt32 uid = data->Uid().iUid; + const TDesC16& publisherId = data->HsContentInfo().PublisherId(); writer.WriteInt32L( uid ); writer.WriteInt32L( publisherId.Length() ); writer.WriteL( publisherId, publisherId.Length() ); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/src/wmplugin.cpp --- a/idlehomescreen/widgetmanager/src/wmplugin.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/src/wmplugin.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -57,52 +57,10 @@ // CWmPlugin::~CWmPlugin() { - iPostponedCommand = ENone; - - // delete WM UI resources - if ( iViewAppUi ) - { - if ( iWmMainContainer && IsActive() ) - { - // WM is showing. Hide first! - iWmMainContainer->SetClosingDown( ETrue ); - TRAPD( err, iViewAppUi->ActivateLocalViewL( - iPreviousViewUid.iViewUid ); ); - if ( KErrNone == err ) - { - // wait until previous view is switched on top - // then continue destruction. - iWait->Start(); - } - else - { - // try to activate default view - TVwsViewId viewId; - if ( iViewAppUi->GetDefaultViewId( viewId ) != KErrNone ) - { - viewId.iAppUid = iViewAppUi->Application()->AppDllUid(); - viewId.iViewUid = TUid::Uid( 1 ); - } - - TRAPD( err, iViewAppUi->ActivateLocalViewL( viewId.iViewUid ); ); - if ( KErrNone == err ) - { - // wait until previous view is switched on top - // then continue destruction. - iWait->Start(); - } - } - } - // remove view from appui (also deletes it) - iViewAppUi->RemoveView( - TUid::Uid( EWmMainContainerViewId ) ); - } - - // delete other members + // delete members delete iResourceLoader; delete iEffectManager; delete iPostponedContent; - delete iWait; delete iWmInstaller; } @@ -133,18 +91,14 @@ iFs = &eikonEnv->FsSession(); iResourceLoader = CWmResourceLoader::NewL( *eikonEnv ); iEffectManager = CWmEffectManager::NewL( *eikonEnv ); - - // wait object - iWait = new (ELeave) CActiveSchedulerWait(); - + iWmInstaller = CWmInstaller::NewL(); + // main view CWmMainContainerView* mainView = CWmMainContainerView::NewL( *this ); CleanupStack::PushL( mainView ); iViewAppUi->AddViewL( mainView ); CleanupStack::Pop( mainView ); - - iWmInstaller = CWmInstaller::NewL(); } // --------------------------------------------------------- @@ -153,31 +107,73 @@ // void CWmPlugin::Activate() { - if ( !IsActive() && iHsContentController ) + CWmMainContainerView* view = static_cast( + iViewAppUi->View( TUid::Uid(EWmMainContainerViewId) ) ); + if ( !IsActive() && view && iHsContentController ) { TRAP_IGNORE( iEffectManager->BeginFullscreenEffectL( KAppStartCommonDefaultStyle ); iViewAppUi->ActivateLocalViewL( - TUid::Uid( EWmMainContainerViewId ) ); + TUid::Uid( EWmMainContainerViewId ) ); ); } } // --------------------------------------------------------- +// CWmPlugin::DeActivate +// --------------------------------------------------------- +// +void CWmPlugin::DeActivate() + { + iPostponedCommand = ENone; + iPreviousViewUid.iViewUid = KNullUid; + CWmMainContainerView* view = static_cast( + iViewAppUi->View( TUid::Uid(EWmMainContainerViewId) ) ); + if ( view ) { view->DoDeactivate(); } + } + +// --------------------------------------------------------- +// CWmPlugin::Views +// --------------------------------------------------------- +// +void CWmPlugin::Views( RPointerArray& aViews ) + { + // return view to be destroyed. + CAknView* view = iViewAppUi->View( + TUid::Uid(EWmMainContainerViewId) ); + if ( view ) + { + aViews.Append( view ); + } + } + +// --------------------------------------------------------- // CWmPlugin::IsActive // --------------------------------------------------------- // TBool CWmPlugin::IsActive() { - return ( iPreviousViewUid.iViewUid != KNullUid ); + TVwsViewId activeViewId(KNullUid,KNullUid); + if ( iViewAppUi->GetActiveViewId( activeViewId ) == KErrNone && + activeViewId.iViewUid == TUid::Uid( EWmMainContainerViewId ) ) + { + if ( iPreviousViewUid.iViewUid == KNullUid ) + { + iPreviousViewUid.iAppUid = iViewAppUi->Application()->AppDllUid(); + iPreviousViewUid.iViewUid = TUid::Uid( 1 ); + } + return ETrue; + } + + return( iPreviousViewUid.iViewUid != KNullUid ); } // --------------------------------------------------------- -// CWmPlugin::Deactivate +// CWmPlugin::CloseView // --------------------------------------------------------- // -void CWmPlugin::Deactivate() +void CWmPlugin::CloseView() { if ( IsActive() ) { @@ -200,13 +196,21 @@ CWmMainContainer* aWmMainContainer ) { iPreviousViewUid = aViewId; + // verify if we have correct viewid to activate. + if ( iPreviousViewUid.iViewUid == KNullUid ) + { + // use default if we got wrong viewid as previous view + iPreviousViewUid.iAppUid = iViewAppUi->Application()->AppDllUid(); + iPreviousViewUid.iViewUid = TUid::Uid( 1 ); + } + iWmMainContainer = aWmMainContainer; iEffectManager->UiRendered(); iWmMainContainer->SetClosingDown( EFalse ); // Don't forward numeric keys to phone ForwardNumericKeysToPhone( EFalse ); - } + } // --------------------------------------------------------- // CWmPlugin::MainViewDeactivated @@ -219,14 +223,12 @@ iPreviousViewUid.iViewUid = KNullUid; iWmMainContainer = NULL; - if ( iEffectManager && !iWait->IsStarted() ) + if ( iEffectManager ) { iEffectManager->UiRendered(); } TRAP_IGNORE( ExecuteCommandL(); ); - - if ( iWait->IsStarted() ) { iWait->AsyncStop(); } } // --------------------------------------------------------- @@ -267,26 +269,8 @@ if ( iPostponedCommand == EAddToHomescreen ) { TInt err = ContentController().AddWidgetL( *iPostponedContent ); - if ( err == KHsErrorViewFull || - err == KHsErrorDoesNotFit ) - { - ResourceLoader().InfoPopupL( - R_QTN_HS_ADD_WIDGET_NO_SPACE_NOTE, KNullDesC ); - } - else if ( err == KHsErrorMaxInstanceCountExceeded ) - { - ResourceLoader().InfoPopupL( - R_QTN_HS_ADD_WIDGET_MAX_COUNT_NOTE, KNullDesC ); - } - else if ( err == KErrNoMemory ) - { - ResourceLoader().InfoPopupL( - R_QTN_HS_HS_MEMORY_FULL, KNullDesC ); - } - else if ( ( err != KErrNone ) && ( err != KErrDiskFull ) ) - { - ResourceLoader().ErrorPopup( err ); - } + if ( err != KErrNone ) + ShowErrorNoteL( err ); } iPostponedCommand = ENone; delete iPostponedContent; @@ -294,7 +278,41 @@ } // --------------------------------------------------------- -// CWmPlugin::MainViewDeactivated +// CWmPlugin::ShowErrorNoteL +// --------------------------------------------------------- +// +void CWmPlugin::ShowErrorNoteL( TInt aError ) + { + switch ( aError ) + { + case KHsErrorViewFull: + case KHsErrorDoesNotFit: + ResourceLoader().InfoPopupL( + R_QTN_HS_ADD_WIDGET_NO_SPACE_NOTE, KNullDesC ); + break; + + case KHsErrorMaxInstanceCountExceeded: + { + TInt resource = ( iPostponedContent->Type() == KContentTemplate ) ? + resource = R_QTN_HS_ADD_WIDGET_MAX_REACHED : // wrt + resource = R_QTN_HS_ADD_WIDGET_MAX_COUNT_NOTE; // native + + ResourceLoader().InfoPopupL( resource, KNullDesC ); + break; + } + + case KErrNoMemory: + ResourceLoader().InfoPopupL( R_QTN_HS_HS_MEMORY_FULL, KNullDesC ); + break; + + default: + ResourceLoader().ErrorPopup( aError ); + break; + } + } + +// --------------------------------------------------------- +// CWmPlugin::ViewAppUi // --------------------------------------------------------- // CAknViewAppUi& CWmPlugin::ViewAppUi() @@ -303,7 +321,7 @@ } // --------------------------------------------------------- -// CWmPlugin::MainViewDeactivated +// CWmPlugin::ResourceLoader // --------------------------------------------------------- // CWmResourceLoader& CWmPlugin::ResourceLoader() @@ -312,7 +330,7 @@ } // --------------------------------------------------------- -// CWmPlugin::MainViewDeactivated +// CWmPlugin::ContentController // --------------------------------------------------------- // MHsContentController& CWmPlugin::ContentController() @@ -321,7 +339,7 @@ } // --------------------------------------------------------- -// CWmPlugin::MainViewDeactivated +// CWmPlugin::FileServer // --------------------------------------------------------- // RFs& CWmPlugin::FileServer() diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/src/wmportalbutton.cpp --- a/idlehomescreen/widgetmanager/src/wmportalbutton.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/src/wmportalbutton.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -30,7 +30,8 @@ #include #include #include // widgetreqistry - +#include +#include #include "wmportalbutton.h" #include "wmcommon.h" @@ -38,10 +39,16 @@ #include "wmresourceloader.h" #include "wmmaincontainer.h" #include "wmconfiguration.h" +#include "wmprocessmonitor.h" // CONSTANTS -_LIT( KBrowserPrefix, "4 "); +_LIT( KOviUrlPrefix, "oviurl "); +_LIT( KBrowserUrlPrefix, "browserurl "); +_LIT( KSpace, " "); +_LIT( Kurlprefix, "4 "); +const TUid KOSSBrowserUidValue = { 0x10008D39 }; +const TInt KMaxParam = 512; // MEMBER FUNCTIONS // --------------------------------------------------------- @@ -82,6 +89,7 @@ // then it'll try accessing imageconverter after bitmap deletion // for de-reference open file count, so it should be deleted last. delete iImageConverter; + delete iProcessMonitor; } // --------------------------------------------------------- @@ -96,6 +104,7 @@ { iButtonIcon = NULL; iButtonIconMask = NULL; + iProcessMonitor = NULL; } // --------------------------------------------------------- @@ -154,23 +163,95 @@ ActivateL(); } -// --------------------------------------------------------------------------- -// Runs HTTP method: (starts browser or brongs browser to foreground) -// --------------------------------------------------------------------------- +// --------------------------------------------------------- +// CWmPortalButton::ExecuteL +// --------------------------------------------------------- +// +void CWmPortalButton::ExecuteL() + { + if ( iPortalButtonIndex == 0 ) + { + if ( !iProcessMonitor ) + { + iProcessMonitor = CWmProcessMonitor::NewL(); + } + if ( !iProcessMonitor->IsActive() ) + { + // We will have laucher for starting ovi store but until + // it's added to SDK we need to start browser to ovi url + if ( 0 ) + RunOviL( iWmMainContainer->Configuration() ); + else + StartBrowserL( iWmMainContainer->Configuration() ); + } + } + else if ( iPortalButtonIndex == 1 ) + { + RunOperatorL( iWmMainContainer->Configuration() ); + } + else + { + // Not supported + User::Leave( KErrGeneral ); + } + } + +// --------------------------------------------------------- +// CWmPortalButton::RunOviL +// --------------------------------------------------------- // -void TryRunHttpL( const TDesC& aParam ) +void CWmPortalButton::RunOviL( CWmConfiguration& aConf ) + { + RApaLsSession session; + User::LeaveIfError( session.Connect() ); + CleanupClosePushL( session ); + + //get app info + TApaAppInfo appInfo; + TUid launchUid; //plan was to save uid in cenrep and fetch it from there + launchUid = aConf.PortalButtonClientUid( iPortalButtonIndex ); + User::LeaveIfError( session.GetAppInfo( appInfo, launchUid ) ); + + // Form parameter + // it should look like this "oviurl url1 browserurl url2" + HBufC* param = HBufC::NewLC( KMaxParam ); + param->Des().Copy( KOviUrlPrefix ); + HBufC* decodedParam = EscapeUtils::EscapeEncodeL( aConf.PortalButtonClientParam( iPortalButtonIndex ), EscapeUtils::EEscapeUrlEncoded ); + CleanupStack::PushL( decodedParam ); + param->Des().Append( *decodedParam ); + param->Des().Append( KSpace ); + param->Des().Append( KBrowserUrlPrefix ); + decodedParam->Des().Copy( aConf.PortalButtonBrowserUrl( iPortalButtonIndex ) ); + param->Des().Append( *decodedParam ); + + // do the launch + RProcess process; + User::LeaveIfError( process.Create( appInfo.iFullName, *param ) ); + iProcessMonitor->Monitor( process ); + process.Resume(); + + CleanupStack::PopAndDestroy( decodedParam ); + CleanupStack::PopAndDestroy( param ); + CleanupStack::PopAndDestroy( &session ); + } + +// --------------------------------------------------------- +// CWmPortalButton::StartBrowserL +// --------------------------------------------------------- +// +void CWmPortalButton::StartBrowserL( CWmConfiguration& aConf ) { RApaLsSession session; User::LeaveIfError( session.Connect() ); CleanupClosePushL( session ); // browser start parameters - const TUid KOSSBrowserUidValue = { 0x10008D39 }; - HBufC* param = HBufC::NewLC( aParam.Length() + - KBrowserPrefix().Length() ); + HBufC* param = HBufC::NewLC( + aConf.PortalButtonBrowserUrl( iPortalButtonIndex ).Length() + + Kurlprefix().Length() ); - param->Des().Copy( KBrowserPrefix ); - param->Des().Append( aParam ); + param->Des().Copy( Kurlprefix ); + param->Des().Append( aConf.PortalButtonBrowserUrl( iPortalButtonIndex ) ); TUid id( KOSSBrowserUidValue ); @@ -191,110 +272,21 @@ User::LeaveIfError( session.Connect() ); } TThreadId thread; - User::LeaveIfError(session.StartDocument(*param, KOSSBrowserUidValue, thread)); + User::LeaveIfError( + session.StartDocument(*param, KOSSBrowserUidValue, thread)); } CleanupStack::PopAndDestroy( param ); CleanupStack::PopAndDestroy( &session ); } -// --------------------------------------------------------------------------- -// Runs WIDGET method: (launches given widget with parameters) -// --------------------------------------------------------------------------- -// -void TryRunWidgetL( const TDesC& aBundleId, const TDesC& aParam ) - { - RApaLsSession session; - User::LeaveIfError( session.Connect() ); - CleanupClosePushL( session ); - TApaAppInfo appInfo; - TUid launchUid; - - // Get widget uid - RWidgetRegistryClientSession widgetSession; - User::LeaveIfError( widgetSession.Connect() ); - CleanupClosePushL( widgetSession ); - launchUid.iUid = widgetSession.GetWidgetUidL( aBundleId ); - CleanupStack::PopAndDestroy( &widgetSession ); - - // prepare widget start params - User::LeaveIfError( session.GetAppInfo( appInfo, launchUid ) ); - CApaCommandLine* commandLine = CApaCommandLine::NewLC(); - commandLine->SetExecutableNameL( appInfo.iFullName ); - HBufC8* buf8 = HBufC8::NewLC( aParam.Length() ); - buf8->Des().Copy( aParam ); - - // do the launch - commandLine->SetTailEndL( *buf8 ); - User::LeaveIfError( session.StartApp( *commandLine ) ); - - CleanupStack::PopAndDestroy( buf8 ); - CleanupStack::PopAndDestroy( commandLine ); - CleanupStack::PopAndDestroy( &session ); - } - -// --------------------------------------------------------------------------- -// Runs APPLICATION method: (launches given application with parameters) -// --------------------------------------------------------------------------- -// -void TryRunApplicationL( const TDesC& /*aApplication*/, const TDesC& /*aParam*/ ) - { - // This method has not been implemented - User::Leave( KErrNotSupported ); - } - -// --------------------------------------------------------------------------- -// Tries to open a portal with given method and parameters. -// this method may be called twice on a portal button, if a primary -// method fails. -// --------------------------------------------------------------------------- -// -void TryOpenPortalL( - CWmConfiguration::TMethod aMethod, const TDesC& aService, - const TDesC& aParam ) - { - // open portal according to the method. - if ( aMethod == CWmConfiguration::EHttp ) - { TryRunHttpL( aParam ); } - else if ( aMethod == CWmConfiguration::EWidget ) - { TryRunWidgetL( aService, aParam ); } - else if ( aMethod == CWmConfiguration::EApplication ) - { TryRunApplicationL( aService, aParam ); } - else - { User::Leave( KErrNotSupported ); } - } - -// --------------------------------------------------------------------------- -// Opens a portal. Called when user presses a portal button. tries the -// primary method, and if if fails, tries the secondary. If it fails, -// gives up. -// --------------------------------------------------------------------------- -// -void OpenPortalL( - CWmConfiguration& aConfiguration, TInt aPortalIndex ) - { - TRAPD( err, - TryOpenPortalL( - aConfiguration.PortalButtonPrimaryMethod( aPortalIndex ), - aConfiguration.PortalButtonPrimaryService( aPortalIndex ), - aConfiguration.PortalButtonPrimaryParams( aPortalIndex ) ); ); - if ( err != KErrNone ) - { - // if secondary method fails, leave will be propagated. - TryOpenPortalL( - aConfiguration.PortalButtonSecondaryMethod( aPortalIndex ), - aConfiguration.PortalButtonSecondaryService( aPortalIndex ), - aConfiguration.PortalButtonSecondaryParams( aPortalIndex ) ); - } - } - // --------------------------------------------------------- -// CWmPortalButton::ExecuteL +// CWmPortalButton::RunOperatorL // --------------------------------------------------------- // -void CWmPortalButton::ExecuteL() +void CWmPortalButton::RunOperatorL( CWmConfiguration& /*aConf*/ ) { - OpenPortalL( iWmMainContainer->Configuration(), iPortalButtonIndex ); + //TODO: current info is that this will be a widget } // --------------------------------------------------------- diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/src/wmprocessmonitor.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlehomescreen/widgetmanager/src/wmprocessmonitor.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,117 @@ +/* +* Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).. +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: +* +*/ + +#include +#include + +#include "wmprocessmonitor.h" + + +// --------------------------------------------------------- +// CWmProcessMonitor::NewL +// --------------------------------------------------------- +// +CWmProcessMonitor* CWmProcessMonitor::NewL( ) + { + CWmProcessMonitor* self = CWmProcessMonitor::NewLC(); + CleanupStack::Pop(); // self; + return self; + } + +// --------------------------------------------------------- +// CWmProcessMonitor::NewLC +// --------------------------------------------------------- +// +CWmProcessMonitor* CWmProcessMonitor::NewLC() + { + CWmProcessMonitor* self = new ( ELeave ) CWmProcessMonitor(); + CleanupStack::PushL(self); + self->ConstructL(); + return self; + } + +// --------------------------------------------------------- +// CWmProcessMonitor::CWmProcessMonitor +// --------------------------------------------------------- +// +CWmProcessMonitor::CWmProcessMonitor() + : CActive( EPriorityStandard ) + { + } + +// --------------------------------------------------------- +// CWmProcessMonitor::ConstructL +// --------------------------------------------------------- +// +void CWmProcessMonitor::ConstructL() + { + CActiveScheduler::Add( this ); + } + +// --------------------------------------------------------- +// CWmProcessMonitor::~CWmProcessMonitor +// --------------------------------------------------------- +// +CWmProcessMonitor::~CWmProcessMonitor() + { + Cancel(); + } + +// --------------------------------------------------------- +// CWmProcessMonitor::DoCancel +// --------------------------------------------------------- +// +void CWmProcessMonitor::DoCancel() + { + if ( IsActive() ) + { + iProcess.LogonCancel( iStatus ); + } + iProcess.Close(); + } + +// --------------------------------------------------------- +// CWmProcessMonitor::RunL +// --------------------------------------------------------- +// +void CWmProcessMonitor::RunL() + { + iProcess.Close(); + } + +// --------------------------------------------------------- +// CWmProcessMonitor::RunError +// --------------------------------------------------------- +// +TInt CWmProcessMonitor::RunError(TInt /*aError*/) + { + iProcess.Close(); + return KErrNone; + } + + +// --------------------------------------------------------- +// CWmProcessMonitor::Monitor +// --------------------------------------------------------- +// +void CWmProcessMonitor::Monitor( RProcess& aProcess ) + { + iProcess.SetHandle( aProcess.Handle() ); + iProcess.Logon( iStatus ); + SetActive(); + } + diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/src/wmresourceloader.cpp --- a/idlehomescreen/widgetmanager/src/wmresourceloader.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/src/wmresourceloader.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -133,7 +133,7 @@ { if ( iResourceFileOffset ) { - iEnv.DeleteResourceFile( iResourceFileOffset ); + iEnv.DeleteResourceFile( iResourceFileOffset ); } } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/src/wmwidgetdata.cpp --- a/idlehomescreen/widgetmanager/src/wmwidgetdata.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/src/wmwidgetdata.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -89,6 +89,7 @@ iAnimationIndex = 0; iAsyncUninstalling = EFalse; iFireLogoChanged = EFalse; + iMdcaPoint = NULL; } // --------------------------------------------------------- @@ -131,10 +132,14 @@ // take ownership of the content info iHsContentInfo = aHsContentInfo; - + + // create iMdcaPoint for listbox + _LIT( KFormatStr, "0\t%S"); + iMdcaPoint = HBufC::NewL( + iHsContentInfo->Name().Length() + KFormatStr().Length() ); + iMdcaPoint->Des().Format( KFormatStr(), &iHsContentInfo->Name() ); // get publisher uid from widget registry FetchPublisherUidL( aRegistryClientSession ); - } // --------------------------------------------------------- @@ -155,6 +160,7 @@ delete iLogoImageMask; delete iImageConverter; delete iHsContentInfo; + delete iMdcaPoint; } // --------------------------------------------------------- @@ -597,5 +603,17 @@ return iAsyncUninstalling; } +// --------------------------------------------------------- +// CWmWidgetData::MdcaPoint +// --------------------------------------------------------- +// +const TDesC& CWmWidgetData::MdcaPoint() const + { + if ( iMdcaPoint ) + return *iMdcaPoint; + else + return KNullDesC; + } + // End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/src/wmwidgetloaderao.cpp --- a/idlehomescreen/widgetmanager/src/wmwidgetloaderao.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/src/wmwidgetloaderao.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -135,6 +135,7 @@ controller.WidgetListL( *contentInfoArray ); // 2. load the widget order + if ( iWidgetOrder ) { Cleanup(); } iWidgetOrder = CWmPersistentWidgetOrder::NewL( iWmPlugin.FileServer() ); TRAPD( loadError, iWidgetOrder->LoadL() ); @@ -152,6 +153,7 @@ while( contentInfoArray->Array().Count() > 0 ) { CHsContentInfo* contentInfo = contentInfoArray->Array()[0]; + if ( !contentInfo ) { break; } contentInfoArray->Array().Remove( 0 ); // check if this widget exists. @@ -255,19 +257,20 @@ } CleanupStack::Pop( aContentInfo ); - CWmWidgetData* widgetData = CWmWidgetData::NewLC( + CWmWidgetData* widgetData = CWmWidgetData::NewLC( iWidgetsList.LogoSize(), iWmPlugin.ResourceLoader(), aContentInfo, iWidgetRegistry ); widgetData->SetPersistentWidgetOrder( iWidgetOrder ); widgetData->SetValid( ETrue ); - iWidgetsList.AddWidgetDataL( widgetData, EFalse ); - if ( iUninstallUid != KNullUid - && iUninstallUid == widgetData->PublisherUid() ) + + if ( iUninstallUid != KNullUid && + iUninstallUid == widgetData->PublisherUid() ) { widgetData->VisualizeUninstallL(); } + iWidgetsList.AddWidgetDataL( widgetData, EFalse ); CleanupStack::Pop( widgetData ); } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/tsrc/wmunittest/group/Nokia_RnDCert_02.der Binary file idlehomescreen/widgetmanager/tsrc/wmunittest/group/Nokia_RnDCert_02.der has changed diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/tsrc/wmunittest/group/Nokia_RnDCert_02.key --- a/idlehomescreen/widgetmanager/tsrc/wmunittest/group/Nokia_RnDCert_02.key Tue Feb 02 00:04:13 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,15 +0,0 @@ ------BEGIN RSA PRIVATE KEY----- -MIICXQIBAAKBgQC/TDP7KKIaf5+uW4OD2iVZuUMC2a+SeQTjf6srlKcOm+CpPNXn -uLNm/8fdEnyOIuRXPRKmqhs1n0JkxEGHynELWMTuKXbQx9SRAGUXzyneGn+IJNnO -vOKHWgKCouX2hfI8rtkdqJpqmO460gGsMgw+lsbeyWyW9lnfLxq+ZC7sqQIDAQAB -AoGBALmUWZE8GBaQ3P4u9WUCSd3DJkkrmXIFSULSZeH/chlwCwDjbbhArHothVzo -REE3hEFFlERvHbplZ+mNouzy7boduvgUzbksGrbGMLJ2qO1GzWWVwV+GzOWKd3ss -/98Gwoy5R8pjnkqUE2wP1iJFw0FjvUTKcYv/z6t3LLJ0CsoBAkEA+c7ixvsviQ3J -s0INytCKU2bf8fqFQJi1VI82ukxNsujGTQ9upVSjuvqPvWyDvvTdrUBHqO+3qPut -sEh01Q8aiQJBAMQKDJPVRu4ud3mwUfEavzL5EjqwG1k9VCNGYsT4FwtrHcxu1oP/ -pk6M3rIZukqomoEEnHWPMwhrK3fhBqi0OSECQQDr40VXege4FnH5OI2Hj4afHMyp -VdQQXGMWFyopnzXblFz0lXb43cTCIiorR9XcMqNFHybLypkWE5o+lRzlt55pAkBQ -P/zeF5Sts//cpL0mgdh7OVKpC6ZmZaCnwAx2rUhhuDu+kDDoYCLoTOps5fNI1LRK -1GRoC3LMo3Jr5IYhUYWBAkBpCpN6k4JU/mszq98EojHerQNxk8sPqvQKUzTutohT -1gLX9yepGayB/TtT2EEJDkWOlnTy/dvN6W3vzbJYz97x ------END RSA PRIVATE KEY----- diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/tsrc/wmunittest/group/wmunittest.mmp --- a/idlehomescreen/widgetmanager/tsrc/wmunittest/group/wmunittest.mmp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/tsrc/wmunittest/group/wmunittest.mmp Fri Feb 19 22:42:37 2010 +0200 @@ -52,6 +52,7 @@ SOURCE wmwidgetloaderao.cpp SOURCE wmconfiguration.cpp SOURCE wminstaller.cpp +SOURCE wmprocessmonitor.cpp SOURCEPATH ../src SOURCE wmunittest.cpp @@ -100,6 +101,7 @@ LIBRARY etext.lib LIBRARY centralrepository.lib LIBRARY bmpanim.lib // AknBitmap animation +LIBRARY inetprotutil.lib // libraries needed by the test framework LIBRARY stiftestinterface.lib diff -r c743ef5928ba -r f966699dea19 idlehomescreen/widgetmanager/tsrc/wmunittest/src/wmunittest_plugin.cpp --- a/idlehomescreen/widgetmanager/tsrc/wmunittest/src/wmunittest_plugin.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/widgetmanager/tsrc/wmunittest/src/wmunittest_plugin.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -98,7 +98,7 @@ TInt CWmUnitTest::PluginDeactivateL( CStifItemParser& /*aItem*/ ) { if ( iWmPlugin == 0 ) User::Leave( KErrArgument ); - iWmPlugin->Deactivate(); + iWmPlugin->CloseView(); _RETURN("PluginActivateL End", KErrNone); } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/group/aixmluimain.mmp --- a/idlehomescreen/xmluicontroller/group/aixmluimain.mmp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/group/aixmluimain.mmp Fri Feb 19 22:42:37 2010 +0200 @@ -55,6 +55,7 @@ SOURCE contentpublisher.cpp SOURCE globalqueryhandler.cpp SOURCE onlineofflinehelper.cpp +SOURCE cenrepobserver.cpp START RESOURCE ai3xmluimain.rss diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/inc/aixmluiconstants.h --- a/idlehomescreen/xmluicontroller/inc/aixmluiconstants.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/inc/aixmluiconstants.h Fri Feb 19 22:42:37 2010 +0200 @@ -112,6 +112,7 @@ _LIT8( KConfiguration, "configuration" ); _LIT8( KNewsTicker, "newsticker" ); _LIT8( KAnimation, "animation" ); + _LIT8( KTextEditor, "texteditor" ); } } // End of namespace xml @@ -120,6 +121,7 @@ #define KContentTypeText TPtrC8( reinterpret_cast< const TText8* >( KAiContentTypeText ) ) #define KContentTypeBitmap TPtrC8( reinterpret_cast< const TText8* >( KAiContentTypeBitmap ) ) +#define KContentTypeData TPtrC8( reinterpret_cast< const TText8* >( KAiContentTypeData )) _LIT8( KContentTypeImage, "image/" ); _LIT8( KContentTypeImageSvg, "image/svg+xml" ); _LIT( KTargetSliderVolumeValue, "slider::volume" ); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/inc/aixuikonmenueventhandler.h --- a/idlehomescreen/xmluicontroller/inc/aixuikonmenueventhandler.h Tue Feb 02 00:04:13 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,223 +0,0 @@ -/* -* Copyright (c) 2007-2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: Used for handling XUIKON menu events -* -*/ - - -#ifndef C_MENUEVENTHANDLER_H -#define C_MENUEVENTHANDLER_H - -#include -#include "xnmenu.h" -#include "xnbitmap.h" - -class CXnNodeAppIf; -class TXnUiEngineAppIf; -class MAiStrParser; -class MAiFwEventHandler; -class MAiPSPropertyObserver; -class CXnAppUiAdapter; -class CXnDomNode; -class XnMenuInterface::MXnMenuObserver; - -enum TAICBA - { - EAIMenuOff = 1, - EAIMenuOn - }; - - -namespace AiXmlUiController -{ - -/** - * @ingroup group_xmluicontroller - * - * This class is used for handling XUIKON events. - * - * Menu events are handled in here. This class parses - * the events and decides what to do with them. - * - * @lib AiXmlUiMain - */ -class CAIXuikonMenuEventHandler : public CBase, public XnMenuInterface::MXnMenuObserver - { -public: - - static CAIXuikonMenuEventHandler* NewL(TXnUiEngineAppIf& aUiEngine, - MAiFwEventHandler* aFwEventHandler, - CXnAppUiAdapter* aAppUi); - - ~CAIXuikonMenuEventHandler(); - - TBool HandleEventL( const TDesC8& aEventString8, CXnNodeAppIf* aOrigin = NULL, CXnDomNode* aEvent = NULL ); - -private: - CAIXuikonMenuEventHandler(TXnUiEngineAppIf& aUiEngine, - MAiFwEventHandler* aFwEventHandler, - CXnAppUiAdapter* aAppUi); - - void ConstructL(); - - static TInt HandleKeylockEvent(TAny* aSelf); - - void SetCBALabelsL(TAICBA aCBA, CXnDomNode* aEvent); - - void ShowMenuL(TBool aShow, const TDesC8& aMenuId, CXnDomNode* aEvent); - - void ShowMenuItemL(const TDesC8& aMenuItemId, TBool aShow, CXnDomNode* aEvent ); - - TBool IsMenuItemVisibleL( const TDesC8& aMenuItemId, CXnDomNode* aEvent ); - - void ParseParameterStringL(const TDesC8& aSourcePtr, TPtrC8& aTargetPtr); - - void RecurseChildrenL(TBool aShow, CXnNodeAppIf* aNode); - - void DoMacrosetL(const TDesC8& aMacrosetNodeId, CXnDomNode* aEvent); - - void GetTextFromElementL(HBufC8*& aMemberPtr, const TDesC8& aItemId, CXnDomNode* aEvent); - - TBool HandleMacroOperationL(const TDesC8& aSourcePtr, CXnNodeAppIf& aTargetNode, CXnDomNode& aEvent ); - - TBool AttemptRestoreSoftkeyIconL( - XnMenuInterface::MXnMenuInterface* aControl, - XnImageInterface::MXnImageInterface* aIconControl, - CXnNodeAppIf* aSourceNode, - XnMenuInterface::MXnMenuInterface::TSoftKeyPosition aPos ); - - void SetSoftkeyLabelL( - XnMenuInterface::MXnMenuInterface* aControl, - const TDesC8* aLabel, - XnMenuInterface::MXnMenuInterface::TSoftKeyPosition aPos ); - - void SetObserverL( const TDesC8& aParam, CXnDomNode* aEvent ); - - TBool InitEditModeMenuItemL( CXnNodeAppIf& aMenuItem, CXnNodeAppIf* aFocused, const TDesC8& aSource ); - - TBool InitDefaultModeMenuItemL( CXnNodeAppIf& aMenuItem, CXnNodeAppIf* aFocused, const TDesC8& aSource ); - - CXnProperty* GetWidgetPropertyL(CXnNodeAppIf& aPlugin, const TDesC8& aProperty); - -private: // from XnMenuInterface::MXnMenuObserver - TBool DynInitMenuItemL( CXnNodeAppIf& aMenuItem ); - -private: - TBool DynInitItemL( CXnNodeAppIf& aMenuItem, CXnNodeAppIf* aFocused ); - -private: // data - - /** - * Current CBA mode, menu/normal(shortcut). - */ - TAICBA iCurrentCBA; - - /** - * Pointer to UI engine IF. Not own. - */ - TXnUiEngineAppIf* iUiEngine; - - /** - * String parser utility. Own. - */ - MAiStrParser* iStrParser; - - /** - * Menu item Open event string. - * Own. - */ - HBufC* iActivationEvent; - - /** - * Menu item settings event string. - * Own. - */ - HBufC* iSettingsEvent; - - /** - * Close action id. - * Own. - */ - TPtrC8 iCloseActionId; - - /** - * Menu mode softkey labels. - * Own. - */ - HBufC8* iMenuModeLskLabel; - HBufC8* iMenuModeRskLabel; - - /** - * Normal mode softkey labels. - * Own. - */ - HBufC8* iNormalModeLskLabel; - HBufC8* iNormalModeRskLabel; - - /** - * Normal mode softkey label ids. - * Own. - */ - TPtrC8 iNormalModeLskLabelId; - TPtrC8 iNormalModeRskLabelId; - - /** - * Normal mode softkey icon ids. - * Own. - */ - TPtrC8 iNormalModeLskIconId; - TPtrC8 iNormalModeRskIconId; - - /** - * App softkey ids. - * Own. - */ - TPtrC8 iLskId; - TPtrC8 iRskId; - - TPtrC8 iLskMenuModeNode; - TPtrC8 iRskMenuModeNode; - /** - * Plug-in event handler. - * Doesn't own. - */ - MAiFwEventHandler* iFwEventHandler; - - /** - * Observers keylock status - * Owned - */ - MAiPSPropertyObserver* iKeylockObserver; - - /** - * Pointer to Appui for closing the menubar when necessary - * Not owned - */ - CXnAppUiAdapter* iAppUi; - /** - * For comparing has the bitmap changed. RSK - * Not owned. - */ - CFbsBitmap* iMenumodeBitmapRsk; - /** - * For comparing has the bitmap changed. LSK - * Not owned. - */ - CFbsBitmap* iMenumodeBitmapLsk; - - }; - -} // namespace AiXmlUiController - -#endif // C_MENUEVENTHANDLER_H diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/inc/appui.h --- a/idlehomescreen/xmluicontroller/inc/appui.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/inc/appui.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,12 +19,15 @@ #ifndef C_APPUI_H #define C_APPUI_H +// System includes #include + +// User includes +#include #include "xnappuiadapter.h" - +// Forward declarations class CAiUiIdleIntegration; -class MAiUiFrameworkObserver; namespace AiXmlUiController { @@ -40,7 +43,7 @@ * * @lib AiXmlUiMain */ -NONSHARABLE_CLASS( CAppUi ) : public CXnAppUiAdapter, +NONSHARABLE_CLASS( CAppUi ) : public CXnAppUiAdapter, public MCoeViewActivationObserver { public: // Constructors and destructor @@ -55,37 +58,28 @@ private: // from CXnAppUiAdapter + void PrepareToExit(); - - void HandleForegroundEventL( TBool aForeground ); - + void HandleCommandL( TInt aCommand ); - - void HandleResourceChangeL( TInt aType ); void HandleXuikonEventL( CXnNodeAppIf& aOrigin, CXnNodeAppIf& aTrigger, - CXnDomNode& aTriggerDefinition, CXnDomNode& aEvent ); + CXnDomNode& aTriggerDefinition, CXnDomNode& aEvent ); + + void HandleEventL( const TDesC& aEvent, CXnNodeAppIf& aDestination ); void HandleWsEventL( const TWsEvent& aEvent, CCoeControl* aDestination ); - void LoadDataPluginsL( RPointerArray< CXnNodeAppIf >& aList ); - - void DestroyDataPluginsL( RPointerArray< CXnNodeAppIf >& aList ); - - void SetOnlineStateL( RPointerArray< CXnNodeAppIf >& aList ); - + TInt LoadPublisher( CXnNodeAppIf& aPublisher, TInt aReason ); + + TInt DestroyPublisher( CXnNodeAppIf& aPublisher, TInt aReason ); + TBool DynInitMenuItemL( const TDesC& aItemType, RPointerArray< CXnNodeAppIf >* aList = NULL ); - - void HandlePageSwitch(); void HandleEnterEditModeL( TBool aEnter ); - -private: - // new functions - void LoadNativeDataPluginsL(); - void DestroyNativeDataPluginsL(); + private: // from MCoeViewActivationObserver @@ -95,7 +89,7 @@ */ void HandleViewActivation( const TVwsViewId& aNewlyActivatedViewId, const TVwsViewId& aViewIdToBeDeactivated ); - + public: // new functions @@ -115,6 +109,14 @@ * @return Ui Controller */ CXmlUiController& UiController() const; + + /** + * Gets online/offline helper object + * + * @since S60 5.0 + * @return online/offline helper + */ + COnlineOfflineHelper* Helper() const; private: // Constructors @@ -126,45 +128,22 @@ private: // data - /** - * UI Controller implementation. Not own. - */ + /** UI Controller implementation, not owned */ CXmlUiController& iUiCtl; - - /** - * Event handler. Own. - */ - CAIXuikonEventHandler* iEventHandler; - - /** - * Content renderer. Own. - */ - CContentRenderer* iContentRenderer; - - /** - * Ui framework event observer. Not own. - */ - MAiUiFrameworkObserver* iUiFwObserver; - - /** - * Idle Integration helper object. Own. - */ + /** Event handler, owned */ + CAIXuikonEventHandler* iEventHandler; + /** Content renderer, owned */ + CContentRenderer* iContentRenderer; + /** Idle Integration helper object, owed */ CAiUiIdleIntegration* iIdleIntegration; - - /** - * Online/Offline helper object. Own. - */ - COnlineOfflineHelper* iHelper; - - /** - * Flag to indicate whether native plugins are loaded. - */ - TBool iNativePluginsLoaded; - - /** - * Flag to indicate whether edit mode is active. - */ - TBool iIsEditModeActive; + /** Online/Offline helper object, owned */ + COnlineOfflineHelper* iHelper; + /** DeviceStatus publisher info */ + THsPublisherInfo iDeviceStatusInfo; + /** Flag to indicate whether edit mode is active */ + TBool iInEditMode; + /** Flag to indicate UI shutdown sequence is ongoing */ + TBool iUiShutdown; }; } // namespace AiXmlUiController diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/inc/cenrepobserver.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlehomescreen/xmluicontroller/inc/cenrepobserver.h Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,98 @@ +/* +* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Listens for changes in a Central Repository key. +* +*/ + +#ifndef CENREPOBSERVER_H +#define CENREPOBSERVER_H + +// FORWARD DECLARATIONS +class CRepository; +class MCenRepObserver; + +// Stop requesting new notifications after this many consecutive errors +const TInt KCenRepErrorRetryCount = 80; + +namespace AiXmlUiController +{ + +/** +* MCenRepObserver +* +* Client application must implement the CenRepObserver interface in +* order to receive a notification when Central Repository key +* KCRUidCmManager/ KCurrentCellularDataUsage changes. +* +*/ +class MCenRepObserver + { +public: + /** + * This method is called every time when Central Repository key + * KCRUidCmManager/ KCurrentCellularDataUsage changes. + * + * @param aValue The new value for KCurrentCellularDataUsage. + * + */ + virtual void CurrentCellularDataUsageChangedL( const TInt aValue ) = 0; + }; + +/** +* CCenRepObserver +* +*/ +NONSHARABLE_CLASS( CCenRepObserver ) : public CActive + { +public: // Constructors and destructor + static CCenRepObserver* NewL( MCenRepObserver* aObserver ); + + static CCenRepObserver* NewLC( MCenRepObserver* aObserver ); + + virtual ~CCenRepObserver(); + +private: + CCenRepObserver( MCenRepObserver* aObserver ); + + void ConstructL(); + + /** + * Request notification for network setting change + */ + void RequestNotifications(); + +private: // Methods from base class + void DoCancel(); + void RunL(); + +private: + /** + * Cenrep Observer. Not own + */ + MCenRepObserver* iObserver; + + /** + * Cenrep repository. Own + */ + CRepository* iRepository; + + /** + * Cenrep read error count. + */ + TInt iErrorCounter; + }; +}// namespace AiXmlUiController +#endif // AOCENREPOBSERVER_H + +// End-of-file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/inc/contentpublisher.h --- a/idlehomescreen/xmluicontroller/inc/contentpublisher.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/inc/contentpublisher.h Fri Feb 19 22:42:37 2010 +0200 @@ -34,13 +34,10 @@ class CLiwGenericParamList; class CLiwServiceHandler; class MLiwInterface; -class CAknGlobalConfirmationQuery; namespace AiXmlUiController { class CXmlUiController; -class CGlobalQueryHandler; - /** * @ingroup group_xmluicontroller @@ -113,14 +110,6 @@ void RegisterListenerL(); void UnRegisterListenerL(); - /** - * Displayes global query for 'go online' or 'go offline' confirmations - * @param aResourceId resource id for the text string - * @param aSetOnline if ETrue then set widgets online if confirmation accepted, - * if EFalse then set widgets offline if confirmation accepted - */ - void ShowGlobalQueryL( TInt aResourceId, TBool aSetOnline ); - private: MLiwInterface* iCpsInterface; CLiwServiceHandler* iServiceHandler; @@ -129,10 +118,6 @@ * Reference to XML ui controller. */ CXmlUiController& iUiController; - - CGlobalQueryHandler* iGlobalQueryHandler; - CAknGlobalConfirmationQuery* iGlobalConfirmationQuery; - }; }// namespace AiXmlUiController diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/inc/contentrenderer.h --- a/idlehomescreen/xmluicontroller/inc/contentrenderer.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/inc/contentrenderer.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,17 +19,22 @@ #ifndef C_CONTENTRENDERER_H #define C_CONTENTRENDERER_H +// System includes #include #include + +// User includes #include "xnnewsticker.h" +#include "aicontentobserver.h" #include "xnproperty.h" -#include "aicontentobserver.h" +// Forward declarations class TXnUiEngineAppIf; class CXnNodeAppIf; class CGulIcon; class MAiFwEventHandler; -struct TAiPublisherInfo; +class CHsContentPublisher; +class THsPublisherInfo; namespace AiUtility { @@ -50,7 +55,6 @@ class TAiPolicyElement; } - namespace AiXmlUiController { @@ -62,15 +66,19 @@ * @lib AiXmlUiMain */ class CContentRenderer : public CBase, - public MAiContentObserver, - public XnNewstickerInterface::MXnNewstickerCallbackInterface + public MAiContentObserver, + public XnNewstickerInterface::MXnNewstickerCallbackInterface { -public: // Constructors and destructor +public: + // Constructors and destructor static CContentRenderer* NewL( CAppUi& aAppUi ); - virtual ~CContentRenderer(); + ~CContentRenderer(); +public: + // New functions + /** * Sets event handler. * @@ -79,138 +87,158 @@ void SetEventHandler( MAiFwEventHandler& aFwEventHandler ); /** - * Resets content renderer for new theme. - */ - void Reset(); - - /** * Cleans all content items published by aPlugin. */ - void CleanPluginFromUi( MAiPropertyExtension& aPlugin ); + void CleanPluginFromUi( CHsContentPublisher& aPlugin ); -// Functions from MAiContentObserver +public: + // from MAiContentObserver + /** + * @see MAiContentObserver + */ TInt StartTransaction( TInt aTxId ); + /** + * @see MAiContentObserver + */ TInt Commit( TInt aTxId ); + /** + * @see MAiContentObserver + */ TInt CancelTransaction( TInt aTxId ); - TBool CanPublish( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aIndex ); - - TInt Publish( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aResource, - TInt aIndex ); + /** + * @see MAiContentObserver + */ + TBool CanPublish( CHsContentPublisher& aPlugin, + TInt aContent, TInt aIndex ); + + /** + * @see MAiContentObserver + */ + TInt Publish( CHsContentPublisher& aPlugin, + TInt aContent, TInt aResource, TInt aIndex ); + + /** + * @see MAiContentObserver + */ + TInt Publish( CHsContentPublisher& aPlugin, + TInt aContent, const TDesC16& aText, TInt aIndex ); - TInt Publish( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC16& aText, - TInt aIndex ); + /** + * @see MAiContentObserver + */ + TInt Publish( CHsContentPublisher& aPlugin, + TInt aContent, const TDesC8& aBuf, TInt aIndex ); - TInt Publish( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC8& aBuf, - TInt aIndex ); + /** + * @see MAiContentObserver + */ + TInt Publish( CHsContentPublisher& aPlugin, + TInt aContent, RFile& aFile, TInt aIndex ); - TInt Publish( MAiPropertyExtension& aPlugin, - TInt aContent, - RFile& aFile, - TInt aIndex ); + /** + * @see MAiContentObserver + */ + TInt Clean( CHsContentPublisher& aPlugin, + TInt aContent, TInt aIndex ); - TInt Clean( MAiPropertyExtension& aPlugin, TInt aContent, TInt aIndex ); - + /** + * @see MAiContentObserver + */ TAny* Extension( TUid aUid ); - TBool RequiresSubscription( const TAiPublisherInfo& aPublisherInfo ) const; - - TInt SetProperty(MAiPropertyExtension& aPlugin, - const TDesC8& aElementId, - const TDesC8& aPropertyName, - const TDesC8& aPropertyValue ); + /** + * @see MAiContentObserver + */ + TBool RequiresSubscription( + const THsPublisherInfo& aPublisherInfo ) const; + + /** + * @see MAiContentObserver + */ + TInt SetProperty( CHsContentPublisher& aPlugin, + const TDesC8& aElementId, const TDesC8& aPropertyName, + const TDesC8& aPropertyValue ); - TInt SetProperty(MAiPropertyExtension& aPlugin, - const TDesC8& aElementId, - const TDesC8& aPropertyName, - const TDesC8& aPropertyValue, - MAiContentObserver::TValueType aValueType); + /** + * @see MAiContentObserver + */ + TInt SetProperty( CHsContentPublisher& aPlugin, + const TDesC8& aElementId, const TDesC8& aPropertyName, + const TDesC8& aPropertyValue, + MAiContentObserver::TValueType aValueType ); + +private: + // Constructors - CXnDomPropertyValue::TPrimitiveValueType - DomPropertyValueType(MAiContentObserver::TValueType aValueType); - -private: - + /** + * C++ default constructor + */ CContentRenderer( CAppUi& aAppUi ); + /** + * 2nd phase constructor + */ void ConstructL(); +private: + // New functions + void DoStartTransactionL( TInt aTxId ); - TInt CanPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aIndex ); - - TInt DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aResource, - TInt aIndex); + TInt CanPublishL( CHsContentPublisher& aPlugin, + TInt aContent, TInt aIndex ); + + TInt DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, TInt aResource, TInt aIndex ); - TInt DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC16& aText, - TInt aIndex ); + TInt DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, const TDesC16& aText, TInt aIndex ); - TInt DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC8& aBuf, - TInt aIndex ); - - TInt DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - RFile& aFile, - TInt aIndex ); - - TInt DoCleanL( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aIndex ); - + TInt DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, const TDesC8& aBuf, TInt aIndex ); + + TInt DoPublishL( CHsContentPublisher& aPlugin, + TInt aContent, RFile& aFile, TInt aIndex ); + + TInt DoCleanL( CHsContentPublisher& aPlugin, + TInt aContent, TInt aIndex ); + void SetImmediateMode( TBool aImmediateMode ); TBool IsImmediateMode() const; - void ProcessTransactionElementL( MTransactionElement* aElement ); + void ProcessTransactionElementL( + MTransactionElement* aElement ); + + CXnNodeAppIf* FindNodeByClassL( + const TDesC& aCid, TInt aIndex, const TDesC8& aNs ); - CXnNodeAppIf* FindNodeByClassL( const TDesC& aCid, - TInt aIndex, - const TDesC8& aNs ); + CXnNodeAppIf* FindNodeByIdL( + const TDesC& aCid, const TDesC& aNs = KNullDesC ); - CXnNodeAppIf* FindNodeByIdL( const TDesC& aCid, const TDesC& aNs = KNullDesC ); - - CXnNodeAppIf* FindNodeByIdL( const TDesC8& aCid, const TDesC8& aNs = KNullDesC8 ); + CXnNodeAppIf* FindNodeByIdL( + const TDesC8& aCid, const TDesC8& aNs = KNullDesC8 ); - TInt PublishIconL( MAiPropertyExtension& aPlugin, - const TDesC& aCid, - CGulIcon* aIcon, - TInt aIndex, - CXnNodeAppIf* aResource = NULL ); + TInt PublishIconL( CHsContentPublisher& aPlugin, + const TDesC& aCid, CGulIcon* aIcon, TInt aIndex, + CXnNodeAppIf* aResource = NULL ); - TInt PublishDataL( MAiPropertyExtension& aPlugin, - const TDesC& aCid, - const TDesC8& aData, - const TDesC8& aContentType, - TInt aIndex, - CXnNodeAppIf* aResource = NULL ); + TInt PublishDataL( CHsContentPublisher& aPlugin, + const TDesC& aCid, const TDesC8& aData, + const TDesC8& aContentType, TInt aIndex, + CXnNodeAppIf* aResource = NULL ); - TBool AllowPublishByPriority( CXnNodeAppIf& aUiElement, - TInt aNewPriority ) const; - + TBool AllowPublishByPriority( + CXnNodeAppIf& aUiElement, TInt aNewPriority ) const; + void StartContentRefresh(); - TInt RefreshContentL( HBufC* aUiElementId, - TInt aOldPriority ); - + TInt RefreshContentL( HBufC* aUiElementId, TInt aOldPriority ); + static TInt RefreshContentCallback( TAny* aContentRenderer ); void SendRefreshContentEventL(); @@ -218,97 +246,55 @@ TBool IsParentNewsticker( CXnNodeAppIf& aTarget ); void RegisterNewstickerCallbackInterfaceL( CXnNodeAppIf& aTarget ); + + void ProcessContentChangesL( MTransaction& aTr ); + void ProcessContentChangeL( TAiPolicyElement& aElement ); - TInt SetPropertyL(MAiPropertyExtension& aPlugin, - const TDesC8& aElementId, - const TDesC8& aPropertyName, - const TDesC8& aPropertyValue, - MAiContentObserver::TValueType aValueType); - -// From XnNewstickerInterface::MXnNewstickerCallbackInterface + TInt SetPropertyL( CHsContentPublisher& aPlugin, + const TDesC8& aElementId, const TDesC8& aPropertyName, + const TDesC8& aPropertyValue, MAiContentObserver::TValueType aValueType ); + + CXnDomPropertyValue::TPrimitiveValueType DomPropertyValueType( + MAiContentObserver::TValueType aValueType ); + +private: + // From XnNewstickerInterface::MXnNewstickerCallbackInterface void TitleScrolled(TInt aTitleIndex); void TitleToScroll(TInt aTitleIndex); - void CleanPluginFromUiL( MAiPropertyExtension& aPlugin ); - - void ProcessContentChangesL( MTransaction& aTr ); - void ProcessContentChangeL( TAiPolicyElement& aElement ); - -private: // Data - - /** - * Transaction stack. Own. - */ - CActiveTransactionStack* iStack; - - /** - * Factory for transacations. Own. - */ - CTransactionFactoryImpl* iFactory; - - /** - * Immediate mode flag. Own. - */ - TBool iImmediateMode; - - /** - * App UI - */ - CAppUi& iAppUi; - - /** - * Node lookup id generator. Own. - */ - CXmlNodeIdGenerator* iNodeIdGenerator; - - /** - * Content priority map. Own. - */ - AiUtility::CContentPriorityMap* iContentPriorityMap; +private: + // data - /** - * Map of refreshable ui elements. - */ - RPtrHashMap< TDesC, TInt > iRefreshableUiElements; - - /** - * Timer for asynchronous content refreshing - */ - CPeriodic* iTimer; - - /** - * Fw event handler needed for content refresh event notifications. - * Not own. - */ + /** Transaction stack, Owned. */ + CActiveTransactionStack* iStack; + /** Factory for transacations, Owned. */ + CTransactionFactoryImpl* iFactory; + /** Immediate mode flag, Owned. */ + TBool iImmediateMode; + /** AppUI, Not owned. */ + CAppUi& iAppUi; + /** Node lookup id generator, Owned. */ + CXmlNodeIdGenerator* iNodeIdGenerator; + /** Content priority map, Owned. */ + AiUtility::CContentPriorityMap* iContentPriorityMap; + /** Map of refreshable ui elements. */ + RPtrHashMap< TDesC, TInt > iRefreshableUiElements; + /** Timer for asynchronous content refreshing, Owned. */ + CPeriodic* iTimer; + /** Fw event handler, Not owned. */ MAiFwEventHandler* iFwEventHandler; - - /** - * Newsticker callback handler - */ - CNewstickerCallbackHandler* iCallbackHandler; - - /** - * Pointer descriptor to newsticker plugin name - */ - TPtrC iNTPublisher; - - /** - * Newsticker element property class. - */ - HBufC* iNTClass; - - /** - * CSS property map. Own - */ - CCssPropertyMap* iPropertyMap; - - /** - * Publishing policy evaluator. Own. - */ + /** Newsticker callback handler, Owned */ + CNewstickerCallbackHandler* iCallbackHandler; + /** Pointer descriptor to newsticker plugin name */ + TPtrC iNTPublisher; + /** Newsticker element property class, Owned */ + HBufC* iNTClass; + /** CSS property map, Owned. */ + CCssPropertyMap* iPropertyMap; + /** Publishing policy evaluator, Owned. */ CPolicyEvaluator* iPolicyEvaluator; - }; } // namespace AiXmlUiController diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/inc/onlineofflinehelper.h --- a/idlehomescreen/xmluicontroller/inc/onlineofflinehelper.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/inc/onlineofflinehelper.h Fri Feb 19 22:42:37 2010 +0200 @@ -1,5 +1,5 @@ /* -* Copyright (c) 2005-2007 Nokia Corporation and/or its subsidiary(-ies). +* Copyright (c) 2009-2010 Nokia Corporation and/or its subsidiary(-ies). * All rights reserved. * This component and the accompanying materials are made available * under the terms of "Eclipse Public License v1.0" @@ -22,17 +22,20 @@ #include #include #include +#include +#include "cenrepobserver.h" // Forward declrations class CNWSession; class CProfileChangeNotifyHandler; class CXnNodeAppIf; +class CAknGlobalConfirmationQuery; namespace AiXmlUiController { // Forward declrations class CXmlUiController; - +class CGlobalQueryHandler; // Classe declaration @@ -45,7 +48,7 @@ */ class COnlineOfflineHelper : public CBase, - public MNWMessageObserver, public MProfileChangeObserver + public MNWMessageObserver, public MProfileChangeObserver, public MCenRepObserver { public: // Constructors @@ -71,6 +74,18 @@ */ void ConstructL(); +public : + // from MCenRepObserver + + /** + * This method is called every time when Central Repository key + * KCRUidCmManager/ KCurrentCellularDataUsage changes. + * + * @param aValue The new value for KCurrentCellularDataUsage. + * + */ + void CurrentCellularDataUsageChangedL( const TInt aValue ); + public: // New functions @@ -91,14 +106,6 @@ TBool ShowOfflineItem() const; /* - * Check and set whether online/offline state is needed by plugins - * - * @since S60 5.0 - * @param aList List of plugins - */ - void ProcessOnlineStateL( RPointerArray< CXnNodeAppIf >& aList ); - - /* * Set online or offline state based on user selection * * @since S60 5.0 @@ -106,6 +113,22 @@ */ void ProcessOnlineStateL( TBool aOnline ); + /* + * Handles the connection query dialogs + * + * @since S60 5.0 + * @param aConnection connection disconnected or connected + */ + void HandleConnectionQueryL( const TDesC& aConnection); + + /** + * Displayes global query for 'go online' or 'go offline' confirmations + * @param aResourceId resource id for the text string + * @param aSetOnline if ETrue then set widgets online if confirmation accepted, + * if EFalse then set widgets offline if confirmation accepted + */ + void ShowGlobalQueryL( TInt aResourceId, TBool aSetOnline ); + private: // from MNWMessageObserver @@ -146,7 +169,10 @@ TBool HasNetworkInfoChanged( const TNWMessages aMsg ); void InterpretNWMessageL( const TNWMessages aMessage, const TNWInfo ); - void SetOnlineL( TBool aOnline ); + void SetOnline( TBool aOnline ); + + void CurrentNetworkSetting(); + private: // Data types @@ -222,12 +248,34 @@ * Flags */ TBitFlags32 iFlags; + + /** + * Network setting observer, owned + */ + CCenRepObserver *iNwSettingObserver; + + /** + * Home network setting + */ + TInt iHomeNetwork; + + /** + * Roaming network setting + */ + TInt iRoamingNetwork; + + /** + * Global query handler, owned. + */ + CGlobalQueryHandler* iGlobalQueryHandler; + + /** + * Global confirmation query, owned. + */ + CAknGlobalConfirmationQuery* iGlobalConfirmationQuery; + }; }// namespace AiXmlUiController #endif //ONLINEOFFLINEHELPER_H - - - - diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/inc/xmlnodeidgenerator.h --- a/idlehomescreen/xmluicontroller/inc/xmlnodeidgenerator.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/inc/xmlnodeidgenerator.h Fri Feb 19 22:42:37 2010 +0200 @@ -19,15 +19,18 @@ #ifndef C_XMLNODEIDGENERATOR_H #define C_XMLNODEIDGENERATOR_H +// System includes #include -class MAiPropertyExtension; -struct TAiPublisherInfo; +// User includes + +// Forward declarations +class CHsContentPublisher; +class THsPublisherInfo; struct TAiContentItem; namespace AiXmlUiController { - /** * @ingroup group_xmluicontroller * @@ -36,25 +39,27 @@ * * @lib AiXmlUiMain */ -class CXmlNodeIdGenerator : public CBase +NONSHARABLE_CLASS( CXmlNodeIdGenerator ) : public CBase { -public: // Construction +public: + // Constructor and destructor static CXmlNodeIdGenerator* NewL(); ~CXmlNodeIdGenerator(); -// New methods +public: + // New functions /** * Generates an identifier that is used to look up settings node from * XML UI model. * - * @param aPubInfo Active Idle publisher info to use in the - * identifier generation. + * @param aPublisherInfo Active Idle publisher info to use in the + * identifier generation. * @return content node identifier. */ - TPtrC SettingsNodeIdL( const TAiPublisherInfo& aPubInfo); + TPtrC SettingsNodeIdL( const THsPublisherInfo& aPublisherInfo ); /** * Generates an identifier that is used to look up content node from @@ -66,19 +71,21 @@ * identifier generation. * @return content node identifier. */ - TPtrC ContentNodeIdL(MAiPropertyExtension& aPlugin, const TAiContentItem& aContentItem); + TPtrC ContentNodeIdL( CHsContentPublisher& aPlugin, + const TAiContentItem& aContentItem ); /** * Generates an identifier that is used to look up content node from * XML UI model. * - * @param aPubInfo Active Idle publisher info to use in the - * identifier generation. - * @param aContentItem Active Idle content item to use in the - * identifier generation. + * @param aPublisherInfo Active Idle publisher info to use in the + * identifier generation. + * @param aContentItem Active Idle content item to use in the + * identifier generation. * @return content node identifier. */ - TPtrC ContentNodeIdL(const TAiPublisherInfo& aPubInfo, const TAiContentItem& aContentItem); + TPtrC ContentNodeIdL( const THsPublisherInfo& aPublisherInfo, + const TAiContentItem& aContentItem ); /** * Generates an identifier that is used to look up resource node from @@ -90,32 +97,39 @@ * identifier generation. * @return resource node identifier. */ - TPtrC ResourceNodeIdL(MAiPropertyExtension& aPlugin, const TAiContentItem& aContentItem); + TPtrC ResourceNodeIdL( CHsContentPublisher& aPlugin, + const TAiContentItem& aContentItem ); /** * Generates an identifier that is used to look up resource node from * XML UI model. * - * @param aPubInfo Active Idle publisher info to use in the - * identifier generation. - * @param aContentItem Active Idle content item to use in the - * identifier generation. + * @param aPublisherInfo Active Idle publisher info to use in the + * identifier generation. + * @param aContentItem Active Idle content item to use in the + * identifier generation. * @return resource node identifier. */ - TPtrC ResourceNodeIdL(const TAiPublisherInfo& aPubInfo, const TAiContentItem& aContentItem); + TPtrC ResourceNodeIdL( const THsPublisherInfo& aPublisherInfo, + const TAiContentItem& aContentItem ); -private: // Construction - - CXmlNodeIdGenerator(); +private: + // Constructors - void ConstructL(); - -private: // Data + /** + * C++ default constructor + */ + CXmlNodeIdGenerator(); + +private: + // data - HBufC* iContentNodeIdBuf; - + /** Content node id buffer, Owned */ + HBufC* iContentNodeIdBuf; }; } // namespace AiXmlUiController #endif // C_XMLNODEIDGENERATOR_H + +// End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/inc/xmluicontroller.h --- a/idlehomescreen/xmluicontroller/inc/xmluicontroller.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/inc/xmluicontroller.h Fri Feb 19 22:42:37 2010 +0200 @@ -15,42 +15,42 @@ * */ +#ifndef _XMLUICONTROLLER_H +#define _XMLUICONTROLLER_H -#ifndef C_XMLUICONTROLLER_H -#define C_XMLUICONTROLLER_H +// System includes +// User includes #include #include "aiuicontroller.h" #include "aiuieventhandler.h" - +// Constants const TInt KImplementationUidXmlUiController = AI3_UID_ECOM_IMPLEMENTATION_UICONTROLLER_XML; const TUid KUidXmlUiController = { KImplementationUidXmlUiController }; - +// Forward declarations class CApaApplication; class TXnUiEngineAppIf; class CXnNodeAppIf; class CRepository; +class THsPublisherInfo; namespace AiXmlUiController { - class CAppUi; class CAIXuikonEventHandler; class CXmlNodeIdGenerator; class CContentRenderer; class CContentPublisher; - /** * @ingroup group_xmluicontroller * * Active Idle XML UI Controller. */ -class CXmlUiController : public CAiUiController, - public MAiMainUiController, - public MAiUiEventHandler +NONSHARABLE_CLASS( CXmlUiController ) : public CAiUiController, + public MAiMainUiController, public MAiUiEventHandler { public: // Constructors and destructor @@ -104,20 +104,20 @@ void NotifyAppEnvReadyL(); /** - * Gets UiFw observer - * - * @since S60 5.0 - * @return UiFw observer - */ - MAiUiFrameworkObserver* UiFrameworkObserver() const; - - /** * Gets UiFw event handler * * @since S60 5.0 * @return UiFw event handler */ MAiFwEventHandler* FwEventHandler() const; + + /** + * Gets UiFw state handler + * + * @since S60 5.2 + * @return UiFw state handler + */ + MAiFwStateHandler* FwStateHandler() const; /** * Gets UiEngine. @@ -136,135 +136,149 @@ CRepository& SettingsRepository() const; /** - * Gets native ui publishers - * - * @since S60 5.0 - * @param aPlugins Array where plugins are appended. - */ - void PublisherInfoL( RAiPublisherInfoArray& aPlugins ); - - /** * Gets xml ui publishers * - * @since S60 5.0 + * @since S60 5.2 * @param aSource Xml node which defineds the publisher - * @param aInfo Publisher info filled based aSource information + * @param aPublisherInfo Publisher info filled based aSource information */ void PublisherInfoL( CXnNodeAppIf& aSource, - TAiPublisherInfo& aInfo ); + THsPublisherInfo& aPublisherInfo ); public: // from CAiUiController + /** + * @see CAiUiController + */ void LoadUIDefinitionL(); - - void GetPluginsL( RAiPublisherInfoArray& aPlugins ); - - void GetSettingsL( const TAiPublisherInfo& aPubInfo, + + /** + * @see CAiUiController + */ + void GetSettingsL( const THsPublisherInfo& aPublisherInfo, RAiSettingsItemArray& aSettings ); + /** + * @see CAiUiController + */ void ActivateUI(); + /** + * @see CAiUiController + */ MAiContentObserver& GetContentObserver(); + /** + * @see CAiUiController + */ void SetEventHandler( MAiFwEventHandler& aFwEventHandler ); - void RemovePluginFromUI( MAiPropertyExtension& aPlugin ); - + /** + * @see CAiUiController + */ + void SetStateHandler( MAiFwStateHandler& aFwStateHandler ); + + /** + * @see CAiUiController + */ MAiMainUiController* MainInterface(); + /** + * @see CAiUiController + */ MAiSecondaryUiController* SecondaryInterface(); private: // from MAiMainUiController + /** + * @see MAiMainUiController + */ void RunApplicationL(); + /** + * @see MAiMainUiController + */ CCoeEnv& CoeEnv(); - - void SetUiFrameworkObserver( MAiUiFrameworkObserver& aObserver ); - + + /** + * @see MAiMainUiController + */ void Exit(); - + + /** + * @see MAiMainUiController + */ TBool IsMenuOpen(); private: // from MAiUiEventHandler + /** + * @see MAiUiEventHandler + */ TBool HandleUiEvent(TAny* aEvent, const TDesC8& aParam); private: // Constructors + /** + * C++ default constructor + */ CXmlUiController(); + /** + * 2nd phase constructor + */ void ConstructL(); private: - // New methods + // New functions + static CApaApplication* NewApplication(); - void HandleFocusGainedL( const TDesC8& aUiElement1, const TDesC8& aUiElement2, CXnNodeAppIf& aOrigin ); + void HandleFocusGainedL( const TDesC8& aUiElement1, + const TDesC8& aUiElement2, CXnNodeAppIf& aOrigin ); - void HandleSetElementSizeL( const TDesC8& aElementName, CXnNodeAppIf& aOrigin ); + void HandleSetElementSizeL( const TDesC8& aElementName, + CXnNodeAppIf& aOrigin ); - static TInt ExitTimerCallBack(TAny *aSelf); - - void GetSettingsFromCRL( const TAiPublisherInfo& aPubInfo, RAiSettingsItemArray &aPluginSettings ); + static TInt ExitTimerCallBack( TAny *aSelf ); + + void GetContentItemL( CXnNodeAppIf& aNode, + RAiSettingsItemArray& aSettings, HBufC*& aItemName ); - void GetContentItemL( CXnNodeAppIf& aNode, RAiSettingsItemArray& aSettings, HBufC*& aItemName ); + void GetConfigurationsL( CXnNodeAppIf& aNode, + RAiSettingsItemArray& aSettings, const TDesC& aConfOwner ); - void GetConfigurationsL( CXnNodeAppIf& aNode, RAiSettingsItemArray& aSettings, const TDesC& aConfOwner ); - - void GetContentModelL(const TAiPublisherInfo& aPubInfo, RAiSettingsItemArray& aSettings); + void GetContentModelL( const THsPublisherInfo& aPubInfo, + RAiSettingsItemArray& aSettings ); -private: // data +private: + // data - /** - * Ai content observer. Not own. - */ - MAiContentObserver* iObserver; - - /** - * Ui framework observer. Not own. - */ - MAiUiFrameworkObserver* iUiFrameworkObserver; - - /** - * Event handler. Not own. - */ + /** Ai content observer, Not owned */ + MAiContentObserver* iObserver; + /** AiFw Event handler, Not owned */ MAiFwEventHandler* iFwEventHandler; - - /** - * Node id generator. Own. - */ - CXmlNodeIdGenerator* iNodeIdGenerator; - - /** - * App UI. Not own. - */ - CAppUi* iAppUi; - - /** - * Timer to call AppUi's exit. Own. - **/ + /** AiFw State handler, Not owned */ + MAiFwStateHandler* iFwStateHandler; + /** * Node id generator, Owned */ + CXmlNodeIdGenerator* iNodeIdGenerator; + /** AppUi, Not owned */ + CAppUi* iAppUi; + /** Timer to call AppUi's exit, Owned */ CPeriodic *iExitTimer; - - /** - * Cenrep. Own. - */ + /** Cenrep, Owned */ CRepository *iAISettingsRepository; - - /** - * CPS publisher. Own. - */ - CContentPublisher* iCPSpublisher; - - /** - * Flag to indicate whether running as main UI controller - */ + /** CPS publisher, Owned */ + CContentPublisher* iCPSpublisher; + /** Flag to indicate whether running as main UI controller */ TBool iRunningAsMain; }; } // namespace AiXmlUiController -#endif // C_XMLUICONTROLLER_H +#endif // _XMLUICONTROLLER_H + +// End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/src/aixuikoneventhandler.cpp --- a/idlehomescreen/xmluicontroller/src/aixuikoneventhandler.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/src/aixuikoneventhandler.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -15,6 +15,28 @@ * */ +// System includes +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +// User includes +#include +#include +#include +#include +#include +#include +#include #include "aixuikoneventhandler.h" #include "aifweventhandler.h" @@ -25,11 +47,6 @@ #include "aixmluiconstants.h" #include "aixmluiutils.h" #include "contentrenderer.h" -#include -#include -#include -#include - #include "xnnodeappif.h" #include "xnuiengineappif.h" #include "xnproperty.h" @@ -37,20 +54,6 @@ #include "xntype.h" #include "xndomlist.h" // for cxndomlist #include "xndomattribute.h" // for cxndomattribute -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include #include "xndompropertyvalue.h" #include "xnnodeappif.h" #include "appui.h" @@ -73,16 +76,14 @@ void AppEnvReadyL(); void HandleUiReadyEventL( CAiUiController& aUiController ); void HandleActivateUI(); - void HandleUiShutdown( CAiUiController& aUiController ); - void CriticalStartupPhaseOver( TInt aStageInteger ); - void HandleLoadPluginL( const TAiPublisherInfo& aPublisherInfo ); - void HandleDestroyPluginL( const TAiPublisherInfo& aPublisherInfo ); + void HandleUiShutdown( CAiUiController& aUiController ); void HandlePluginEvent( const TDesC& aParam ); - void HandlePluginEventL( const TAiPublisherInfo& aPublisherInfo, const TDesC& aParam ); - TBool HasMenuItemL( const TAiPublisherInfo& aPublisherInfo, const TDesC& aMenuItem ); + void HandlePluginEventL( const THsPublisherInfo& aPublisherInfo, const TDesC& aParam ); + TBool HasMenuItemL( const THsPublisherInfo& aPublisherInfo, const TDesC& aMenuItem ); TBool RefreshContent( const TDesC& aContentCid ); - TBool QueryIsMenuOpen(); - void ProcessStateChange( TAifwStates aSate ); + TBool RefreshContent( const THsPublisherInfo& aPublisherInfo, const TDesC& aContentId ); + TBool SuspendContent( const THsPublisherInfo& aPublisherInfo, const TDesC& aContentId ); + TBool QueryIsMenuOpen(); private: // from MAiUiEventHandler TBool HandleUiEvent( TAny* aEvent, const TDesC8& aParam ); @@ -358,7 +359,7 @@ // Broadcast event to all plugins for ( TInt i = 0; i < list.Count(); i++ ) { - TAiPublisherInfo info; + THsPublisherInfo info; iUiController.PublisherInfoL( *list[i], info ); @@ -383,7 +384,7 @@ { // Only one data plugin in this namespace, // it must handle this event. - TAiPublisherInfo info; + THsPublisherInfo info; iUiController.PublisherInfoL( *list[0], info ); @@ -403,7 +404,7 @@ if ( eventHandler ) { - TAiPublisherInfo info; + THsPublisherInfo info; iUiController.PublisherInfoL( *eventHandler, info ); @@ -423,11 +424,11 @@ for ( TInt i = 0; i < list.Count(); i++ ) { - TAiPublisherInfo info; + THsPublisherInfo info; iUiController.PublisherInfoL( *list[i], info ); - if( info.iName == pluginName ) + if( info.Name() == pluginName ) { // Forward Plug-in events to AI FW for further // dispatching to the target Plug-in @@ -476,8 +477,8 @@ { } -void CAIXuikonEventHandler::CNullEventHandler::HandleUiReadyEventL - ( CAiUiController& /*aUiController*/ ) +void CAIXuikonEventHandler::CNullEventHandler::HandleUiReadyEventL( + CAiUiController& /*aUiController*/ ) { } @@ -485,24 +486,24 @@ { } -void CAIXuikonEventHandler::CNullEventHandler::HandlePluginEvent - ( const TDesC& /*aParam*/ ) +void CAIXuikonEventHandler::CNullEventHandler::HandlePluginEvent( + const TDesC& /*aParam*/ ) { } -void CAIXuikonEventHandler::CNullEventHandler::HandlePluginEventL - (const TAiPublisherInfo& /*aPublisherInfo*/, const TDesC& /*aParam*/ ) +void CAIXuikonEventHandler::CNullEventHandler::HandlePluginEventL( + const THsPublisherInfo& /*aPublisherInfo*/, const TDesC& /*aParam*/ ) { } TBool CAIXuikonEventHandler::CNullEventHandler::HasMenuItemL( - const TAiPublisherInfo& /*aPublisherInfo*/, const TDesC& /*aMenuItem*/ ) + const THsPublisherInfo& /*aPublisherInfo*/, const TDesC& /*aMenuItem*/ ) { return EFalse; } -void CAIXuikonEventHandler::CNullEventHandler::HandleUiShutdown - ( CAiUiController& /*aUiController*/ ) +void CAIXuikonEventHandler::CNullEventHandler::HandleUiShutdown( + CAiUiController& /*aUiController*/ ) { } @@ -512,9 +513,16 @@ return EFalse; } -void CAIXuikonEventHandler::CNullEventHandler::CriticalStartupPhaseOver( - TInt /*aStageInteger*/ ) +TBool CAIXuikonEventHandler::CNullEventHandler::RefreshContent( + const THsPublisherInfo& /*aPublisherInfo*/, const TDesC& /*aContentId*/ ) { + return EFalse; + } + +TBool CAIXuikonEventHandler::CNullEventHandler::SuspendContent( + const THsPublisherInfo& /*aPublisherInfo*/, const TDesC& /*aContentId*/ ) + { + return EFalse; } TBool CAIXuikonEventHandler::CNullEventHandler::QueryIsMenuOpen() @@ -522,29 +530,14 @@ return EFalse; } -void CAIXuikonEventHandler::CNullEventHandler::ProcessStateChange( - TAifwStates /*aSate*/) - { - } - -void CAIXuikonEventHandler::CNullEventHandler::HandleLoadPluginL( - const TAiPublisherInfo& /*aPluginToLoad*/ ) - { - } - -void CAIXuikonEventHandler::CNullEventHandler::HandleDestroyPluginL( - const TAiPublisherInfo& /*aPluginToDestroy*/ ) - { - } - -TBool CAIXuikonEventHandler::CNullEventHandler::HandleUiEvent - (TAny* /*aEvent*/, const TDesC8& /*aParam*/) +TBool CAIXuikonEventHandler::CNullEventHandler::HandleUiEvent( + TAny* /*aEvent*/, const TDesC8& /*aParam*/ ) { return EFalse; } -TBool CAIXuikonEventHandler::CNullEventHandler::HandleApplicationEvent - (TInt /*aEvent*/, const TDesC8& /*aParam*/) +TBool CAIXuikonEventHandler::CNullEventHandler::HandleApplicationEvent( + TInt /*aEvent*/, const TDesC8& /*aParam*/ ) { return EFalse; } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/src/aixuikonmenueventhandler.cpp --- a/idlehomescreen/xmluicontroller/src/aixuikonmenueventhandler.cpp Tue Feb 02 00:04:13 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,1742 +0,0 @@ -/* -* Copyright (c) 2007-2007 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: Used for handling XUIKON menu events -* -*/ - - -#include "aixuikonmenueventhandler.h" -#include "aiconsts.h" -#include "aixmluiconstants.h" -#include "aixmluiutils.h" - -#include "mxncomponentinterface.h" -#include "xnmenuadapter.h" -#include "xnappuiadapter.h" -#include "xntext.h" -#include "xnnodeappif.h" -#include "xndomnode.h" -#include "xndomlist.h" -#include "xntype.h" -#include -#include -#include -#include "aifweventhandler.h" -#include "xnproperty.h" -#include "xnuiengineappif.h" -#include "xndompropertyvalue.h" -#include -#include -#include //CaknViewAppui -#include "xnplugindefs.h" - -_LIT8( KMenubar, "menubar" ); -_LIT8( KClass, "class" ); -_LIT8( KId, "id" ); -_LIT8( KEditWidget, "edit_widget" ); -_LIT8( KRemoveItem, "removeitem" ); -_LIT8( KWidget, "widget" ); -_LIT8( KRemovable, "removable" ); -_LIT ( KMenuItem, "menuitem"); - -using namespace AiXmlUiController; - - -// --------------------------------------------------------------------------- -// FindFromContentModelL -// --------------------------------------------------------------------------- -// -static CXnNodeAppIf* FindFromContentModelL( CXnNodeAppIf* aNode ) - { - if ( !aNode ) - { - return NULL; - } - - CXnProperty* node = aNode->GetPropertyL( KClass ); - if ( node && node->StringValue() == KContentSource ) - { - return aNode; - } - - // Recurse children - RPointerArray< CXnNodeAppIf > children( aNode->ChildrenL() ); - CleanupClosePushL( children ); - - CXnNodeAppIf* retval( NULL ); - - for ( TInt i = 0; i < children.Count(); i++ ) - { - CXnNodeAppIf* node( FindFromContentModelL( children[i] ) ); - - if ( node ) - { - retval = node; - break; - } - } - - CleanupStack::PopAndDestroy( &children ); - - return retval; - } - -// --------------------------------------------------------------------------- -// FindFromConfigurationL -// --------------------------------------------------------------------------- -// -static CXnNodeAppIf* FindFromConfigurationL( CXnNodeAppIf* aNode ) - { - if ( !aNode ) - { - return NULL; - } - // Is this node type of settingsconfiguration - if ( aNode->Type()->Type() == KSettingsConfiguration ) - { - return aNode; - } - - // Recurse children - RPointerArray< CXnNodeAppIf > children( aNode->ChildrenL() ); - CleanupClosePushL( children ); - - CXnNodeAppIf* retval( NULL ); - - for ( TInt i = 0; i < children.Count(); i++ ) - { - CXnNodeAppIf* node( FindFromConfigurationL( children[i] ) ); - - if ( node ) - { - retval = node; - break; - } - } - - CleanupStack::PopAndDestroy( &children ); - - return retval; - } - -// --------------------------------------------------------------------------- -// DeletePluginNames -// --------------------------------------------------------------------------- -// -static void DeletePluginNames( TAny* aObject ) - { - reinterpret_cast< - RPointerArray*>( aObject )->ResetAndDestroy(); - } - -CAIXuikonMenuEventHandler::CAIXuikonMenuEventHandler( TXnUiEngineAppIf& aUiEngine, - MAiFwEventHandler* aFwEventHandler, - CXnAppUiAdapter* aAppUi ) - : iCurrentCBA( EAIMenuOff ), - iUiEngine( &aUiEngine ), - iFwEventHandler( aFwEventHandler ), - iAppUi( aAppUi ) - { - } - -void CAIXuikonMenuEventHandler::ConstructL() - { - iStrParser = AiUtility::CreateStrParserL(); - iKeylockObserver = AiUtility::CreatePSPropertyObserverL - ( TCallBack( HandleKeylockEvent, this ), - KPSUidAvkonDomain, KAknKeyguardStatus ); - } - -void CAIXuikonMenuEventHandler::SetObserverL( const TDesC8& aParam, CXnDomNode* aEvent ) - { - if ( aEvent ) - { - CXnNodeAppIf* node( iUiEngine->FindNodeByIdL( aParam, aEvent->Namespace() ) ); - - if ( node && node->Type()->Type() == KMenubar ) - { - XnMenuInterface::MXnMenuInterface* menuIf( NULL ); - XnComponentInterface::MakeInterfaceL( menuIf, *node ); - - if ( menuIf ) - { - menuIf->SetObserver( *this ); - } - } - } - } - -TInt CAIXuikonMenuEventHandler::HandleKeylockEvent( TAny* aSelf ) - { - // Stop displaying menu when keylock is activated. - CAIXuikonMenuEventHandler* self = - static_cast( aSelf ); - TInt err = KErrNone; - TInt value = EKeyguardNotActive; - if ( self ) - { - TInt err = self->iKeylockObserver->Get( value ); - if ( err == KErrNone ) - { - if ( value > EKeyguardNotActive ) - { - if ( self->iAppUi && self->iCurrentCBA == EAIMenuOn ) - { - self->iAppUi->StopDisplayingMenuBar(); - TRAP_IGNORE( self->iUiEngine->RefreshMenuL() ); - } - } - } - } - return err; - } - -CAIXuikonMenuEventHandler* CAIXuikonMenuEventHandler::NewL( TXnUiEngineAppIf& aUiEngine, - MAiFwEventHandler* aFwEventHandler, - CXnAppUiAdapter* aAppUi ) - { - CAIXuikonMenuEventHandler* self = - new( ELeave ) CAIXuikonMenuEventHandler( aUiEngine, aFwEventHandler, aAppUi ); - CleanupStack::PushL( self ); - self->ConstructL(); - CleanupStack::Pop( self ); - return self; - } - -CAIXuikonMenuEventHandler::~CAIXuikonMenuEventHandler() - { - Release ( iKeylockObserver ); - Release( iStrParser ); - delete iActivationEvent; - delete iSettingsEvent; - - // Delete stored label id's - delete iMenuModeLskLabel; - delete iMenuModeRskLabel; - delete iNormalModeLskLabel; - delete iNormalModeRskLabel; - } - -TBool CAIXuikonMenuEventHandler::HandleEventL( const TDesC8& aEventString8, CXnNodeAppIf* aOrigin, CXnDomNode* aEvent ) - { - if ( aEventString8 == AiUiDef::xml::event::KScreenDeviceChange ) - { - iUiEngine = iAppUi->UiEngineL(); - return ETrue; - } - else if ( aEventString8.Left(KAIDynamicMenuPrefixLen).Compare( KAIDynamicMenuPrefix ) != 0 ) - { - // For optimization when dynamic menu prefix is not found from event string start - // return immediate from here. - return EFalse; - } - - if ( (iCurrentCBA == EAIMenuOff && aEventString8.Find(KAIMenuEventIfMenuOff) >= 0 ) || - (iCurrentCBA == EAIMenuOn && aEventString8.Find(KAIMenuEventIfMenuOn) >= 0) ) - { - TPtrC8 eventString; - ParseParameterStringL(aEventString8, eventString); - if ( !HandleEventL(eventString, aOrigin, aEvent ) ) - { - // Default action from the event string - HBufC16* eventString16 = NULL; - eventString16 = iStrParser->CopyToBufferL( eventString16, eventString ); - CleanupStack::PushL( eventString16 ); - if ( iFwEventHandler && eventString16 ) - { - iFwEventHandler->HandlePluginEvent( *eventString16 ); - } - CleanupStack::PopAndDestroy( eventString16 ); - } - return ETrue; - } - else if ( aEventString8 == KAIMenuEventInitPluginItems ) - { - if ( !aEvent ) - { - return ETrue; - } - - CXnDomList& children( aEvent->ChildNodes() ); - - TInt count( children.Length() ); - - for ( TInt i = 0; i < count; i++ ) - { - CXnDomNode* node = static_cast< CXnDomNode* >( children.Item( i ) ); - - const TDesC8& type( node->Name() ); - - if ( type == XnPropertyNames::action::KProperty ) - { - const TDesC8& id( node->AttributeValue( - XnPropertyNames::action::KValue ) ); - - if ( id != KNullDesC8 ) - { - CXnNodeAppIf* nodeById( iUiEngine->FindNodeByIdL( id, aEvent->Namespace() ) ); - - if ( nodeById ) - { - TBool showItem( DynInitItemL( *nodeById, aOrigin ) ); - - const TDesC8 *value( NULL ); - - if ( showItem ) - { - value = &XnPropertyNames::style::common::display::KBlock; - } - else - { - value = &XnPropertyNames::style::common::display::KNone; - } - - CXnDomStringPool& sp( aEvent->StringPool() ); - - // create property - CXnProperty* prop = CXnProperty::NewL( XnPropertyNames::style::common::KDisplay, - *value, - CXnDomPropertyValue::EString, - sp ); - - CleanupStack::PushL( prop ); - - // and set it - nodeById->SetPropertyL( prop ); - - CleanupStack::Pop( prop ); - } - } - } - } - - return ETrue; - } - else if ( aEventString8 == KAIMenuEventInitEmptyItems || - aEventString8 == KAIMenuEventInitWidgetItems ) - { - if ( !aEvent ) - { - return ETrue; - } - - CXnProperty* pluginId( aOrigin->GetPropertyL( KPluginId ) ); - CXnProperty* pluginName( aOrigin->GetPropertyL( KPluginName ) ); - - TBool showItem( EFalse ); - - if ( aEventString8 == KAIMenuEventInitWidgetItems ) - { - if( pluginId && pluginName && pluginName->StringValue() != KDummy8 ) - { - // check if plugin can be removed - CXnProperty* removable = GetWidgetPropertyL(*aOrigin, KRemovable); - if ( removable && removable->StringValue() == XnPropertyNames::KFalse ) - { - showItem = EFalse; - } - else - { - showItem = ETrue; - } - } - } - else - { - if ( pluginId && pluginName && pluginName->StringValue() == KDummy8 ) - { - showItem = ETrue; - } - } - - CXnDomList& children( aEvent->ChildNodes() ); - - TInt count( children.Length() ); - - for ( TInt i = 0; i < count; i++ ) - { - CXnDomNode* node = static_cast< CXnDomNode* >( children.Item( i ) ); - - const TDesC8& type( node->Name() ); - - if ( type == XnPropertyNames::action::KProperty ) - { - const TDesC8& id( node->AttributeValue( - XnPropertyNames::action::KValue ) ); - - if ( id != KNullDesC8 ) - { - CXnNodeAppIf* nodeById( iUiEngine->FindNodeByIdL( id, aEvent->Namespace() ) ); - - if ( nodeById ) - { - const TDesC8 *value( NULL ); - - if ( showItem ) - { - value = &XnPropertyNames::style::common::display::KBlock; - } - else - { - value = &XnPropertyNames::style::common::display::KNone; - } - - CXnDomStringPool& sp( aEvent->StringPool() ); - - // create property - CXnProperty* prop = CXnProperty::NewL( XnPropertyNames::style::common::KDisplay, - *value, - CXnDomPropertyValue::EString, - sp ); - - CleanupStack::PushL( prop ); - - // and set it - nodeById->SetPropertyL( prop ); - - CleanupStack::Pop( prop ); - } - } - } - } - - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventIfMenuOff ) >= 0 ) - { - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventIfMenuOn ) >= 0 ) - { - return ETrue; - } - else if ( aEventString8.Compare( KAIMenuEventGenerateSetActivationEvent ) == 0 ) - { - // Generate set plugin event - if ( iFwEventHandler && iActivationEvent ) - { - iFwEventHandler->HandlePluginEvent( *iActivationEvent ); - } - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventSetActivationEvent ) >= 0 ) - { - // find event string - TPtrC8 eventString; - ParseParameterStringL( aEventString8, eventString ); - delete iActivationEvent; - iActivationEvent = NULL; - // store activation event (plugin event string) - iActivationEvent = iStrParser->CopyToBufferL( iActivationEvent, eventString ); - return ETrue; - } - else if (aEventString8.Compare( KAIMenuEventGenerateOpenSettingsEvent ) == 0) - { - // Generate set plugin event - if ( iFwEventHandler && iSettingsEvent ) - { - iFwEventHandler->HandlePluginEvent( *iSettingsEvent ); - } - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventSetOpenSettingsnEvent ) >= 0 ) - { - // find event string - TPtrC8 eventString; - ParseParameterStringL( aEventString8, eventString ); - delete iSettingsEvent; - iSettingsEvent = NULL; - // store activation event (plugin event string) - iSettingsEvent = iStrParser->CopyToBufferL( iSettingsEvent, eventString ); - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventShowMenuItem ) >= 0 ) - { - if (iCurrentCBA == EAIMenuOn) - { - // find node by id - TPtrC8 menuItem; - ParseParameterStringL( aEventString8, menuItem ); - // set visibility property to visible - ShowMenuItemL( menuItem, ETrue, aEvent ); - } - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventHideMenuItem ) >= 0 ) - { - if ( iCurrentCBA == EAIMenuOn ) - { - // find node by id - TPtrC8 menuItem; - ParseParameterStringL( aEventString8, menuItem ); - // set visibility property to visible - ShowMenuItemL( menuItem, EFalse, aEvent ); - } - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventShowHideMenuItem ) >= 0 ) - { - if ( iCurrentCBA == EAIMenuOn ) - { - // find node by id - TPtrC8 menuItem; - ParseParameterStringL( aEventString8, menuItem ); - // set visibility property - if ( IsMenuItemVisibleL( menuItem, aEvent ) ) - { - ShowMenuItemL( menuItem, EFalse, aEvent ); - } - else - { - ShowMenuItemL( menuItem, ETrue, aEvent ); - } - } - return ETrue; - } - else if ( aEventString8.Compare( KAIMenuEventMenuOn ) == 0 ) - { - if ( iCurrentCBA != EAIMenuOn ) - { - // also updates current state - SetCBALabelsL( EAIMenuOn, aEvent ); - } - return ETrue; - } - else if ( aEventString8.Compare( KAIMenuEventMenuOff ) == 0 ) - { - if ( iCurrentCBA != EAIMenuOff ) - { - // also updates current state - SetCBALabelsL( EAIMenuOff, aEvent ); - } - return ETrue; - } - else if ( ( aEventString8.Find( KAIMenuEventShowAll ) ) >= 0 ) - { - if ( iCurrentCBA == EAIMenuOn ) - { - // Show all menu items. Xuikon actually open the menu it self.. - TPtrC8 menu; - ParseParameterStringL( aEventString8, menu ); - ShowMenuL( ETrue, menu, aEvent ); - } - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventRefresh ) >= 0 ) - { - if ( iCurrentCBA == EAIMenuOn ) - { - iUiEngine->RefreshMenuL(); - } - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventHideAll ) >= 0 ) - { - // Hide all menu items - TPtrC8 menu; - ParseParameterStringL( aEventString8, menu ); - ShowMenuL( EFalse, menu, aEvent ); - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventSetCloseAction ) >= 0 ) - { - // Set menu mode close action / RSK action - TPtrC8 closeActionId; - ParseParameterStringL( aEventString8, closeActionId ); - - // Store close action macroset node id - iCloseActionId.Set( closeActionId ); - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventCloseAction ) >= 0 ) - { - // Decide action - if ( iCurrentCBA == EAIMenuOff ) - { - TPtrC8 eventString; - ParseParameterStringL( aEventString8, eventString ); - - // Default action - HBufC16* eventString16 = NULL; - eventString16 = iStrParser->CopyToBufferL( eventString16, eventString ); - CleanupStack::PushL( eventString16 ); - if ( iFwEventHandler && eventString16 ) - { - iFwEventHandler->HandlePluginEvent( *eventString16 ); - } - CleanupStack::PopAndDestroy( eventString16 ); - } - else - { - DoMacrosetL( iCloseActionId, aEvent ); - } - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventSetSoftKeyId ) >= 0 ) - { - // Store softkey labels and label node id's - TPtrC8 softkeyString; - ParseParameterStringL( aEventString8, softkeyString ); - TPtrC8 softkeyId; - ParseParameterStringL( softkeyString, softkeyId ); - if ( softkeyString.Find( KAIMenuModeLsk ) >= 0) - { - GetTextFromElementL( iMenuModeLskLabel, softkeyId, aEvent ); - if ( iMenuModeLskLabel && iMenuModeLskLabel->Length() <= 0 ) - { - delete iMenuModeLskLabel; - iMenuModeLskLabel = NULL; - } - iLskMenuModeNode.Set( softkeyId ); - } - else if ( softkeyString.Find( KAIMenuModeRsk ) >= 0 ) - { - GetTextFromElementL( iMenuModeRskLabel, softkeyId, aEvent ); - if ( iMenuModeLskLabel && iMenuModeRskLabel->Length() <= 0 ) - { - delete iMenuModeRskLabel; - iMenuModeRskLabel = NULL; - } - iRskMenuModeNode.Set( softkeyId ); - } - else if ( softkeyString.Find( KAINormalModeLskLabel ) >= 0) - { - GetTextFromElementL( iNormalModeLskLabel, softkeyId, aEvent ); - iNormalModeLskLabelId.Set( softkeyId ); - } - else if ( softkeyString.Find( KAINormalModeRskLabel ) >= 0) - { - GetTextFromElementL( iNormalModeRskLabel, softkeyId, aEvent ); - iNormalModeRskLabelId.Set( softkeyId ); - } - else if ( softkeyString.Find( KAINormalModeLskIcon ) >= 0) - { - iNormalModeLskIconId.Set( softkeyId ); - } - else if ( softkeyString.Find( KAINormalModeRskIcon ) >= 0) - { - iNormalModeRskIconId.Set( softkeyId ); - } - else if ( softkeyString.Find( KAIMenuLsk ) >= 0) - { - iLskId.Set( softkeyId ); - } - else if ( softkeyString.Find( KAIMenuRsk ) >= 0) - { - iRskId.Set( softkeyId ); - } - - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventSettingsReady ) >= 0) - { - SetCBALabelsL( EAIMenuOff, aEvent ); - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventDoMacroset ) >= 0 ) - { - // Do defined macro set - - // Parse macroset node id - TPtrC8 macroNodeId; - ParseParameterStringL( aEventString8, macroNodeId ); - if ( macroNodeId != KNullDesC8 ) - { - DoMacrosetL( macroNodeId, aEvent ); - } - return ETrue; - } - else if ( aEventString8.Find( KAIMenuEventSetDynMenuItemObserver ) >= 0 ) - { - TPtrC8 eventString; - ParseParameterStringL( aEventString8, eventString ); - SetObserverL( eventString, aEvent ); - return ETrue; - } - else if ( aEventString8 == KAIToggleWidgetsState ) - { - iFwEventHandler->SetPluginsVisibility( iUiEngine->WidgetsVisible() ); - return ETrue; - } - else - { - // Handlers for macroset operations - TPtrC8 targetNodeName; - ParseParameterStringL( aEventString8, targetNodeName ); - TBool handledEvent = EFalse; - - if ( targetNodeName != KNullDesC8 ) - { - CXnNodeAppIf* eventTargetNode = NULL; - if ( aEvent ) - { - eventTargetNode = iUiEngine->FindNodeByIdL( targetNodeName, aEvent->Namespace() ); - } - if ( eventTargetNode ) - { - handledEvent = HandleMacroOperationL( - aEventString8, *eventTargetNode, *aEvent ); - iUiEngine->RenderUIL( NULL ); - } - } - return handledEvent; - } - } - -void CAIXuikonMenuEventHandler::ParseParameterStringL( const TDesC8& aSourcePtr, - TPtrC8& aTargetPtr ) - { - // Parses parameter string between the first '(' and last ')' - // Trailing and heading white spaces ARE NOT handled! - - const TInt separatorPos = aSourcePtr.Locate( KEventParameterSeparator ); - User::LeaveIfError( separatorPos ); - - const TInt eventSeparatorPos = aSourcePtr.LocateReverse( - KEventParameterSeparatorEnd ); - User::LeaveIfError( eventSeparatorPos ); - - // separatorPos + 1 must be smaller than eventSeparatorPos - 1 - User::LeaveIfError( ( eventSeparatorPos ) - ( separatorPos + 1 ) ); - - // Extract event and parameter string - TPtrC8 menuName( aSourcePtr.Mid( separatorPos + 1, - ( eventSeparatorPos ) - ( separatorPos + 1 ) ) ); - - aTargetPtr.Set( menuName ); - } - -void CAIXuikonMenuEventHandler::SetCBALabelsL( TAICBA aCBA, CXnDomNode* aEvent ) - { - // Set CBA labels according to mode, to the predefined CBA nodes - if ( (iLskId == KNullDesC8) || (iRskId == KNullDesC8) || !aEvent ) - { - return; - } - CXnNodeAppIf* lskNode = iUiEngine->FindNodeByIdL( iLskId, aEvent->Namespace() ); - CXnNodeAppIf* rskNode = iUiEngine->FindNodeByIdL( iRskId, aEvent->Namespace() ); - - TBool propertyUpdated = EFalse; - - if ( rskNode && lskNode ) - { - CXnNodeAppIf* menuBar = lskNode->ParentL(); - - XnMenuInterface::MXnMenuInterface* lskControl = NULL; - XnMenuInterface::MXnMenuInterface* rskControl = NULL; - - if ( menuBar ) - { - XnComponentInterface::MakeInterfaceL( lskControl, *menuBar ); - XnComponentInterface::MakeInterfaceL( rskControl, *menuBar ); - } - if ( !lskControl || !rskControl ) - { - return; - } - switch ( aCBA ) - { - case EAIMenuOff: - { - CXnNodeAppIf* lskIconNode = NULL; - CXnNodeAppIf* rskIconNode = NULL; - XnImageInterface::MXnImageInterface* lskIconControl = NULL; - XnImageInterface::MXnImageInterface* rskIconControl = NULL; - if ( iNormalModeLskIconId != KNullDesC8 ) - { - lskIconNode = iUiEngine->FindNodeByIdL( iNormalModeLskIconId, aEvent->Namespace() ); - XnComponentInterface::MakeInterfaceL( lskIconControl, *lskIconNode ); - } - - if ( iNormalModeRskIconId != KNullDesC8 ) - { - rskIconNode = iUiEngine->FindNodeByIdL( iNormalModeRskIconId, aEvent->Namespace() ); - XnComponentInterface::MakeInterfaceL( rskIconControl, *rskIconNode ); - } - - // Try to set the icon, if the icon setting fails - // try to set the text - if ( !AttemptRestoreSoftkeyIconL( lskControl, - lskIconControl, - lskIconNode, - XnMenuInterface::MXnMenuInterface::ELeft ) ) - { - if ( iNormalModeLskLabelId != KNullDesC8 ) - { - GetTextFromElementL( iNormalModeLskLabel, iNormalModeLskLabelId, aEvent ); - } - - SetSoftkeyLabelL( lskControl, iNormalModeLskLabel, - XnMenuInterface::MXnMenuInterface::ELeft ); - } - - if ( !AttemptRestoreSoftkeyIconL( rskControl, - rskIconControl, - rskIconNode, - XnMenuInterface::MXnMenuInterface::ERight ) ) - { - if ( iNormalModeRskLabelId != KNullDesC8 ) - { - GetTextFromElementL( iNormalModeRskLabel, iNormalModeRskLabelId, aEvent ); - } - - SetSoftkeyLabelL( rskControl, iNormalModeRskLabel, - XnMenuInterface::MXnMenuInterface::ERight ); - } - propertyUpdated = ETrue; - break; - } - case EAIMenuOn: - { - // Need to set the bitmaps back after - // the menu is closed - iMenumodeBitmapLsk = NULL; - iMenumodeBitmapRsk = NULL; - if ( !iMenuModeLskLabel ) - { - GetTextFromElementL( iMenuModeLskLabel, iLskMenuModeNode, aEvent ); - } - SetSoftkeyLabelL( lskControl, iMenuModeLskLabel, - XnMenuInterface::MXnMenuInterface::ELeft ); - - if ( !iMenuModeRskLabel ) - { - GetTextFromElementL( iMenuModeRskLabel, iRskMenuModeNode, aEvent ); - } - SetSoftkeyLabelL( rskControl, iMenuModeRskLabel, - XnMenuInterface::MXnMenuInterface::ERight ); - propertyUpdated = ETrue; - break; - } - default: - break; - } - } - iCurrentCBA = aCBA; - if ( propertyUpdated ) - { - iUiEngine->RefreshMenuL(); - } - } - -void CAIXuikonMenuEventHandler::ShowMenuL( TBool aShow, const TDesC8& aMenuId, CXnDomNode* aEvent ) - { - if ( aEvent ) - { - // Show or hide all menu items - CXnNodeAppIf* lskNode = iUiEngine->FindNodeByIdL( aMenuId, aEvent->Namespace() ); - - if ( lskNode ) - { - RecurseChildrenL( aShow, lskNode ); - } - } - } - -void CAIXuikonMenuEventHandler::RecurseChildrenL( TBool aShow, CXnNodeAppIf* aNode ) - { - RPointerArray children = aNode->ChildrenL(); - CleanupClosePushL( children ); - - for ( TInt i=0; iType()->Type() == KAIMenuItem || - node->Type()->Type() == KAIMenu ) ) - { - if ( aShow ) - { - SetPropertyToNodeL( *node, XnPropertyNames::style::common::KVisibility, - XnPropertyNames::style::common::visibility::KVisible ); - } - else - { - SetPropertyToNodeL( *node, XnPropertyNames::style::common::KVisibility, - XnPropertyNames::style::common::visibility::KHidden ); - } - - if ( node->Type()->Type() == KAIMenu ) - { - RecurseChildrenL(aShow, node); - } - } - } - - CleanupStack::PopAndDestroy( &children ); - } - -void CAIXuikonMenuEventHandler::DoMacrosetL( const TDesC8& aMacrosetNodeId, CXnDomNode* aEvent ) - { - if ( !aEvent ) - { - return; - } - // Do operations in a macroset - CXnNodeAppIf* actionNode = iUiEngine->FindNodeByIdL( aMacrosetNodeId, aEvent->Namespace() ); - if ( !actionNode ) - { - return; - } - RPointerArray children = actionNode->ChildrenL(); - for ( TInt i=0; iFindNodeByIdL( targetNodeName, aEvent->Namespace() ); - if ( eventTargetNode ) - { - HandleMacroOperationL( *value, *eventTargetNode, *aEvent ); - } - } - } - } - children.Reset(); - } - -void CAIXuikonMenuEventHandler::ShowMenuItemL( const TDesC8& aMenuItemId, TBool aShow, CXnDomNode* aEvent ) - { - if ( aEvent ) - { - // Show a single menuitem - CXnNodeAppIf* itemNode = iUiEngine->FindNodeByIdL( aMenuItemId, aEvent->Namespace() ); - if ( itemNode && ( itemNode->Type()->Type() == KAIMenuItem || - itemNode->Type()->Type() == KAIMenu ) ) - { - if ( aShow ) - { - SetPropertyToNodeL( *itemNode, XnPropertyNames::style::common::KVisibility, - XnPropertyNames::style::common::visibility::KVisible ); - } - else - { - SetPropertyToNodeL( *itemNode, XnPropertyNames::style::common::KVisibility, - XnPropertyNames::style::common::visibility::KHidden ); - } - } - } - } - -TBool CAIXuikonMenuEventHandler::IsMenuItemVisibleL( const TDesC8& aMenuItemId, CXnDomNode* aEvent ) - { - TBool ret = EFalse; - if ( aEvent ) - { - CXnNodeAppIf* itemNode = iUiEngine->FindNodeByIdL( aMenuItemId, aEvent->Namespace() ); - if ( itemNode && ( itemNode->Type()->Type() == KAIMenuItem || - itemNode->Type()->Type() == KAIMenu ) ) - { - CXnProperty* visibility = itemNode->GetPropertyL( XnPropertyNames::style::common::KVisibility ); - if ( visibility && (visibility->StringValue() == XnPropertyNames::style::common::visibility::KVisible) ) - { - ret = ETrue; - } - } - } - return ret; - } - -void CAIXuikonMenuEventHandler::GetTextFromElementL( HBufC8*& aMemberPtr, - const TDesC8& aItemId, - CXnDomNode* aEvent ) - { - delete aMemberPtr; - aMemberPtr = NULL; - if ( aEvent ) - { - CXnNodeAppIf* labelNode = iUiEngine->FindNodeByIdL( aItemId, aEvent->Namespace() ); - - if ( labelNode ) - { - if ( labelNode->Type() ) - { - const TDesC8& type = labelNode->Type()->Type(); - if ( type == XnTextInterface::MXnTextInterface::Type() ) - { - XnTextInterface::MXnTextInterface* textControl = NULL; - XnComponentInterface::MakeInterfaceL( textControl, *labelNode ); - if ( textControl ) - { - // Set text - aMemberPtr = iStrParser->CopyToBufferL( aMemberPtr, - *(textControl->Text()) ); - } - } - } - } - } - } - -TBool CAIXuikonMenuEventHandler::HandleMacroOperationL( const TDesC8& aSourcePtr, - CXnNodeAppIf& aTargetNode, - CXnDomNode& aEvent ) - { - if ( aSourcePtr.Find( KAIMenuEventSetFocus ) >= 0 ) - { - // Set focus - aTargetNode.SetStateL( XnPropertyNames::style::common::KFocus ); - return ETrue; - } - else if ( aSourcePtr.Find( KAIMenuEventSetDisplayNone ) >= 0 ) - { - SetPropertyToNodeL( aTargetNode, XnPropertyNames::style::common::KDisplay, - XnPropertyNames::style::common::display::KNone ); - return ETrue; - } - else if ( aSourcePtr.Find( KAIMenuEventSetDisplayBlock) >= 0 ) - { - SetPropertyToNodeL( aTargetNode, XnPropertyNames::style::common::KDisplay, - XnPropertyNames::style::common::display::KBlock ); - return ETrue; - } - else - { - HandleEventL( aSourcePtr, &aTargetNode, &aEvent ); - return ETrue; - } - } - -TBool CAIXuikonMenuEventHandler::AttemptRestoreSoftkeyIconL( - XnMenuInterface::MXnMenuInterface* aControl, - XnImageInterface::MXnImageInterface* aIconControl, - CXnNodeAppIf* aSourceNode, - XnMenuInterface::MXnMenuInterface::TSoftKeyPosition aPos ) - { - if ( aControl && aSourceNode ) - { - const TDesC8* isVisible = - PropertyValue( *aSourceNode, - XnPropertyNames::style::common::KVisibility ); - - // node not "visible" so assume that text has been published - // after image - if ( !isVisible || *isVisible == XnPropertyNames::style::common::visibility::KHidden ) - { - return EFalse; - } - - CGulIcon* icon = NULL; - TBool transferOwnership = ETrue; - // First try to get the icon from image interface - if ( aIconControl ) - { - CFbsBitmap* bitmap = NULL; - CFbsBitmap* mask = NULL; - aIconControl->ContentBitmaps( bitmap, mask ); - if ( bitmap ) - { - icon = CGulIcon::NewL( bitmap, mask ); - icon->SetBitmapsOwnedExternally( ETrue ); - // image adapter wants to keep ownership - transferOwnership = EFalse; - CleanupStack::PushL( icon ); - } - } - // Then try to load it ourselves. - if ( !icon ) - { - const TDesC8* value = - PropertyValue( *aSourceNode, XnPropertyNames::image::KPath ); - - if ( value ) - { - icon = LoadIconLC( *aSourceNode ); - icon->SetBitmapsOwnedExternally( ETrue ); - // transfer ownerhsip to menunode - transferOwnership = ETrue; - } - } - // This icon is already in menu, no need to set it - // again - if ( icon && - (icon->Bitmap() == iMenumodeBitmapLsk || - icon->Bitmap() == iMenumodeBitmapRsk) ) - { - CleanupStack::PopAndDestroy( icon ); - return ETrue; - } - else if ( icon ) - { - switch ( aPos ) - { - case XnMenuInterface::MXnMenuInterface::ELeft: - iMenumodeBitmapLsk = icon->Bitmap(); - break; - case XnMenuInterface::MXnMenuInterface::ERight: - iMenumodeBitmapRsk = icon->Bitmap(); - break; - default: - break; - } - aControl->SetSoftKeyImageL( - icon->Bitmap(), - icon->Mask(), - aPos, - ETrue, /* preserve aspect ratio */ - EFalse, /* !invert mask */ - transferOwnership - ); - CleanupStack::PopAndDestroy( icon ); - return ETrue; - } - } - return EFalse; - } - -void CAIXuikonMenuEventHandler::SetSoftkeyLabelL( - XnMenuInterface::MXnMenuInterface* aControl, - const TDesC8* aLabel, - XnMenuInterface::MXnMenuInterface::TSoftKeyPosition aPos ) - { - if ( aControl && aLabel ) - { - HBufC16* string16 = NULL; - string16 = iStrParser->CopyToBufferL( string16, *aLabel ); - CleanupStack::PushL( string16 ); - // Trapped because this will leave when setting the same again - TRAP_IGNORE( - aControl->SetSoftKeyTextL( *string16, aPos ); - ) - CleanupStack::PopAndDestroy( string16 ); - } - } - -TBool CAIXuikonMenuEventHandler::InitEditModeMenuItemL( CXnNodeAppIf& aMenuItem, CXnNodeAppIf* aFocused, const TDesC8& aSource ) - { - TBool showItem( EFalse ); - CXnNodeAppIf* focused( aFocused ); - - if ( focused && aSource == KContentModel ) - { - CXnNodeAppIf* node = FindFromContentModelL( focused ); - if ( !node ) - { - // no plugin or no launch action - return showItem; - } - CXnProperty* plugin ( node->GetPropertyL( KName ) ) ; - if ( !plugin ) - { - // no plugin or no launch action - return showItem; - } - HBufC* pluginName( plugin->StringValueL() ); - CleanupStack::PushL( pluginName ); - HBufC* item ( aMenuItem.GetPropertyL( KName )->StringValueL() ); - CleanupStack::PushL( item ); - - showItem = iFwEventHandler->HasMenuItem( *pluginName , *item ); - - if ( showItem ) - { - // pluginName/menuitem(item) - // Create launch event and store it to menuitem's property - HBufC8* eventstr = HBufC8::NewLC( pluginName->Length() - + 15 // / ( ) - + item->Length() ); - TPtr8 str ( eventstr->Des() ); - str.Copy( pluginName->Des() ); - str.Append( TChar( '/' )); - str.Append( KMenuItem ); - str.Append( TChar( '(' )); - str.Append( item->Des() ); - str.Append( TChar( ')' )); - - CXnDomStringPool& sp( iUiEngine->StringPool() ); - - CXnDomPropertyValue* newValue = CXnDomPropertyValue::NewL( sp ); - CleanupStack::PushL( newValue ); - - newValue->SetStringValueL( CXnDomPropertyValue::EString, str ); - - CXnProperty* prop = CXnProperty::NewL( XnPropertyNames::menu::KEvent, - newValue, sp ); - - CleanupStack::Pop( newValue ); - - CleanupStack::PushL( prop ); - - // and set it - aMenuItem.SetPropertyL( prop ); - CleanupStack::Pop( prop ); - - CleanupStack::PopAndDestroy(eventstr ); // eventstr, children - } - - CleanupStack::PopAndDestroy( item ); - CleanupStack::PopAndDestroy( pluginName ); - } - else if ( focused && aSource == KConfigurationModel ) - { - CXnNodeAppIf* node( FindFromConfigurationL( focused ) ); - - if ( node ) - { - CXnProperty* launch( node->GetPropertyL( KLaunch ) ); - CXnProperty* plugin( node->GetPropertyL( KName ) ); - - if ( !launch || !plugin ) - { - // no plugin or no launch action - return showItem; - } - - HBufC* pluginName( plugin->StringValueL() ); - CleanupStack::PushL( pluginName ); - - CXnProperty* prop( aMenuItem.GetPropertyL( KName ) ); - - if ( prop ) - { - HBufC* item( prop->StringValueL() ); - CleanupStack::PushL( item ); - - showItem = iFwEventHandler->HasMenuItem( *pluginName, *item ); - - CleanupStack::PopAndDestroy( item ); - } - else - { - showItem = iFwEventHandler->HasMenuItem( *pluginName, KNullDesC ); - } - - CleanupStack::PopAndDestroy( pluginName ); - - if ( showItem ) - { - // Create launch event and store it to menuitem's property - RPointerArray children( node->ChildrenL() ); - CleanupClosePushL( children ); - - TInt count( children.Count() ); - - TInt length( launch->StringValue().Length() + 2 ); // +2 for '(' and ')' - - for ( TInt i = 0; i < count; i++ ) - { - if ( i > 0 ) - { - length += 1; - } - - CXnProperty* prop( children[i]->GetPropertyL( KName ) ); - - if ( prop ) - { - length += prop->StringValue().Length(); - } - } - - HBufC8* eventstr = HBufC8::NewLC( length ); - - TPtr8 str( eventstr->Des() ); - - str.Append( launch->StringValue() ); - - str.Append( TChar( '(' ) ); - - for ( TInt i = 0; i < count; i++ ) - { - if ( i > 0 ) - { - str.Append( TChar( ',' ) ); - } - - CXnProperty* prop( children[i]->GetPropertyL( KName ) ); - - if ( prop ) - { - str.Append( prop->StringValue() ); - } - } - - str.Append( TChar( ')' ) ); - - CXnDomStringPool& sp( iUiEngine->StringPool() ); - - CXnDomPropertyValue* newValue = CXnDomPropertyValue::NewL( sp ); - CleanupStack::PushL( newValue ); - - newValue->SetStringValueL( CXnDomPropertyValue::EString, str ); - - CXnProperty* prop = CXnProperty::NewL( XnPropertyNames::menu::KEvent, - newValue, sp ); - - CleanupStack::Pop( newValue ); - - CleanupStack::PushL( prop ); - - // and set it - aMenuItem.SetPropertyL( prop ); - CleanupStack::Pop( prop ); - - CleanupStack::PopAndDestroy( 2, &children ); // eventstr, children - } - } - } - - return showItem; - } - -TBool CAIXuikonMenuEventHandler::InitDefaultModeMenuItemL( CXnNodeAppIf& aMenuItem, CXnNodeAppIf* aFocused, const TDesC8& aSource ) - { - TBool showItem( EFalse ); - TInt len( 0 ); - if ( aSource == KContentModel ) - { - CXnProperty* prop( aMenuItem.GetPropertyL( KName ) ); - if ( !prop ) - { - return showItem; - } - - RPointerArray plnNames; - CleanupStack::PushL( TCleanupItem( DeletePluginNames, &plnNames ) ); - - CXnNodeAppIf* focused( aFocused ); - HBufC* item ( prop->StringValueL() ); - CleanupStack::PushL( item ); - - if( item->Des() == KHSOnLine_OffLine() ) - { - TBool webContent = EFalse; - RPointerArray plugins = iUiEngine->FindNodeByClassL( KContentSource16 ) ; - CleanupClosePushL( plugins ); - if( plugins.Count() <= 0 ) - { - CleanupStack::PopAndDestroy(&plugins); - CleanupStack::PopAndDestroy( item ); - CleanupStack::PopAndDestroy(&plnNames); - return showItem; - } - for (TInt i = 0; i < plugins.Count(); i++) - { - CXnProperty* property ( plugins[i]->GetPropertyL( KName ) ) ; - if ( property ) - { - HBufC16* pluginName ( property->StringValueL() ); - CleanupStack::PushL( pluginName ); - if( iFwEventHandler->HasMenuItem( *pluginName , *item ) ) - { - webContent = ETrue; - CleanupStack::PopAndDestroy( pluginName ); - break; - } - CleanupStack::PopAndDestroy( pluginName ); - } - } - CleanupStack::PopAndDestroy(&plugins); - - // At least one widget using web content - if ( webContent ) - { - CXnProperty* status( aMenuItem.GetPropertyL(KStatus) ); - if ( status ) - { - HBufC* statusValue ( status->StringValueL() ); - CleanupStack::PushL( statusValue ); - if ( (statusValue->Des() == KHSOnLine()) && !iFwEventHandler->IsPluginsOnline() ) - { - plnNames.AppendL( KHSOnLine().Alloc() ); - len = KHSOnLine().Length(); - } - else if ( (statusValue->Des() == KHSOffLine()) && iFwEventHandler->IsPluginsOnline() ) - { - plnNames.AppendL( KHSOffLine().Alloc() ); - len = KHSOffLine().Length(); - } - CleanupStack::PopAndDestroy( statusValue ); - } - } - } - else - { - if( focused ) - { - RPointerArray< CXnNodeAppIf > plugins; - CleanupClosePushL( plugins ); - - iUiEngine->GetPluginNodeArrayL( plugins ); - - CXnNodeAppIf* node( NULL ); - - for( ; focused; focused = focused->ParentL() ) - { - if( plugins.Find( focused ) != KErrNotFound ) - { - node = FindFromContentModelL( focused ); - break; - } - } - - CleanupStack::PopAndDestroy( &plugins ); - - if( !node ) - { - // no plugin or no launch action - CleanupStack::PopAndDestroy(item ); - CleanupStack::PopAndDestroy(&plnNames); - return showItem; - } - CXnProperty* plugin ( node->GetPropertyL( KName ) ) ; - if( !plugin ) - { - // no plugin or no launch action - CleanupStack::PopAndDestroy(item ); - CleanupStack::PopAndDestroy(&plnNames); - return showItem; - } - HBufC16* pluginName( plugin->StringValueL() ); - CleanupStack::PushL( pluginName ); - if( iFwEventHandler->HasMenuItem( *pluginName , *item ) ) - { - plnNames.AppendL( pluginName ); - len += pluginName->Length(); - CleanupStack::Pop( pluginName ); - } - else - { - CleanupStack::PopAndDestroy( pluginName ); - } - } - else - { - RPointerArray plugins = iUiEngine->FindNodeByClassL( KContentSource16 ) ; - if( plugins.Count() <= 0 ) - { - CleanupStack::PopAndDestroy( item ); - CleanupStack::PopAndDestroy(&plnNames); - return showItem; - } - CleanupClosePushL( plugins ); - for (TInt i = 0; i < plugins.Count(); i++) - { - CXnProperty* property ( plugins[i]->GetPropertyL( KName ) ) ; - if ( property ) - { - HBufC16* pluginName ( property->StringValueL() ); - CleanupStack::PushL( pluginName ); - if( iFwEventHandler->HasMenuItem( *pluginName , *item ) ) - { - plnNames.AppendL( pluginName ); - len += pluginName->Length(); - CleanupStack::Pop( pluginName ); - } - else - { - CleanupStack::PopAndDestroy( pluginName ); - } - } - } - CleanupStack::PopAndDestroy(&plugins); - } - } - - TInt count = plnNames.Count(); - if( count > 0 ) - { - showItem = ETrue; - // [pluginName1,...]/menuitem(item) - // Create launch event and store it to menuitem's property - HBufC8* eventstr = HBufC8::NewLC( len + - + 15 // / ( ) [ ] - + item->Length() ); - TPtr8 str ( eventstr->Des() ); - str.Copy( KOpenBrace ); - for ( TInt i = 0; i < count; i++ ) - { - str.Append( plnNames[i]->Des() ); - if ( i+1 != count ) str.Append( TChar( ',' ) ); - } - str.Append( KCloseBrace ); - str.Append( TChar( '/' ) ); - str.Append( KMenuItem ); - str.Append( TChar( '(' ) ); - str.Append( item->Des() ); - str.Append( TChar( ')' ) ); - - CXnDomStringPool& sp( iUiEngine->StringPool() ); - - CXnDomPropertyValue* newValue = CXnDomPropertyValue::NewL( sp ); - CleanupStack::PushL( newValue ); - - newValue->SetStringValueL( CXnDomPropertyValue::EString, str ); - - CXnProperty* prop = CXnProperty::NewL( XnPropertyNames::menu::KEvent, - newValue, sp ); - - CleanupStack::Pop( newValue ); - - CleanupStack::PushL( prop ); - - // and set it - aMenuItem.SetPropertyL( prop ); - CleanupStack::Pop( prop ); - - CleanupStack::PopAndDestroy( eventstr ); // eventstr, children - } - - CleanupStack::PopAndDestroy( item ); - CleanupStack::PopAndDestroy( &plnNames ); - } - else if ( aFocused && aSource == KConfigurationModel ) - { - CXnNodeAppIf* node( FindFromConfigurationL( aFocused ) ); - - if ( node ) - { - CXnProperty* launch( node->GetPropertyL( KLaunch ) ); - CXnProperty* plugin( node->GetPropertyL( KName ) ); - - if ( !launch || !plugin ) - { - // no plugin or no launch action - return showItem; - } - - HBufC* pluginName( plugin->StringValueL() ); - CleanupStack::PushL( pluginName ); - - CXnProperty* prop( aMenuItem.GetPropertyL( KName ) ); - - if ( prop ) - { - HBufC* item( prop->StringValueL() ); - CleanupStack::PushL( item ); - - showItem = iFwEventHandler->HasMenuItem( *pluginName, *item ); - - CleanupStack::PopAndDestroy( item ); - } - else - { - showItem = iFwEventHandler->HasMenuItem( *pluginName, KNullDesC ); - } - - CleanupStack::PopAndDestroy( pluginName ); - - if ( showItem ) - { - // Create launch event and store it to menuitem's property - RPointerArray children( node->ChildrenL() ); - CleanupClosePushL( children ); - - TInt count( children.Count() ); - - TInt length( launch->StringValue().Length() + 2 ); // +2 for '(' and ')' - - for ( TInt i = 0; i < count; i++ ) - { - if ( i > 0 ) - { - length += 1; - } - - CXnProperty* prop( children[i]->GetPropertyL( KName ) ); - - if ( prop ) - { - length += prop->StringValue().Length(); - } - } - - HBufC8* eventstr = HBufC8::NewLC( length ); - - TPtr8 str( eventstr->Des() ); - - str.Append( launch->StringValue() ); - - str.Append( TChar( '(' ) ); - - for ( TInt i = 0; i < count; i++ ) - { - if ( i > 0 ) - { - str.Append( TChar( ',' ) ); - } - - CXnProperty* prop( children[i]->GetPropertyL( KName ) ); - - if ( prop ) - { - str.Append( prop->StringValue() ); - } - } - - str.Append( TChar( ')' ) ); - - CXnDomStringPool& sp( iUiEngine->StringPool() ); - - CXnDomPropertyValue* newValue = CXnDomPropertyValue::NewL( sp ); - CleanupStack::PushL( newValue ); - - newValue->SetStringValueL( CXnDomPropertyValue::EString, str ); - - CXnProperty* prop = CXnProperty::NewL( XnPropertyNames::menu::KEvent, - newValue, sp ); - - CleanupStack::Pop( newValue ); - - CleanupStack::PushL( prop ); - - // and set it - aMenuItem.SetPropertyL( prop ); - CleanupStack::Pop( prop ); - - CleanupStack::PopAndDestroy( 2, &children ); // eventstr, children - } - } - } - - // Currently we don't support default mode dynamic menu item for ConfigurationModel - return showItem; - } - -CXnProperty* CAIXuikonMenuEventHandler::GetWidgetPropertyL(CXnNodeAppIf& aPlugin, const TDesC8& aProperty) - { - CXnProperty* retval = NULL; - RPointerArray children(aPlugin.ChildrenL()); - CleanupClosePushL( children ); - TInt childCount = children.Count(); - for (TInt i = 0; i < childCount; i++) - { - //search for widget element and get given property - CXnNodeAppIf* widget = children[i]; - if (widget && widget->InternalDomNodeType() == KWidget) - { - retval = widget->GetPropertyL(aProperty); - i = childCount; - } - } - CleanupStack::PopAndDestroy( &children ); - return retval; - } - -TBool CAIXuikonMenuEventHandler::DynInitItemL( CXnNodeAppIf& aMenuItem, CXnNodeAppIf* aFocused ) - { - CXnProperty* prop( aMenuItem.GetPropertyL( KSource ) ); - if ( prop ) - { - if ( prop && prop->StringValue().Length() > 0 ) - { - if ( iUiEngine->IsEditMode() ) - { - return InitEditModeMenuItemL( aMenuItem, aFocused, prop->StringValue() ); - } - else - { - return InitDefaultModeMenuItemL( aMenuItem, aFocused, prop->StringValue() ); - } - } - } - else - { - CXnProperty* idProp( aMenuItem.GetPropertyL( KId ) ); - if ( idProp ) - { - const TDesC8& id = idProp->StringValue(); - if ( id == KEditWidget ) - { - if ( aFocused ) - { - for ( CXnNodeAppIf* candidate = aFocused; candidate; candidate = candidate->ParentL() ) - { - if ( candidate->InternalDomNodeType() == KPlugin && !iUiEngine->IsEditMode() ) - { - return ETrue; - } - } - } - } - else if( id == KRemoveItem && iUiEngine->IsEditMode() ) - { - // get plugin node from focused - CXnNodeAppIf* node = aFocused; - CXnNodeAppIf* pluginNode = NULL; - for(; node && node->Type()->Type() != KView; node = node->ParentL() ) - { - CXnProperty* configurationId( node->GetPropertyL( KConfigurationId ) ); - CXnProperty* pluginId( node->GetPropertyL( KPluginId ) ); - - if( configurationId && pluginId ) - { - pluginNode = node; - break; - } - } - - if( pluginNode ) - { - // check if plugin can be removed - CXnProperty* removable = GetWidgetPropertyL(*pluginNode, KRemovable); - if ( removable && removable->StringValue() == XnPropertyNames::KFalse ) - { - return EFalse; - } - // hide menu item if the focused plugin is an "empty" widget - CXnProperty* pluginName = pluginNode->GetPropertyL( KPluginName ); - if( pluginName ) - { - const TDesC8& nameStr = pluginName->StringValue(); - if( nameStr == KDummy8 ) - { - return EFalse; - } - else - { - return ETrue; - } - } - } - } - } - } - - return EFalse; - } - - -TBool CAIXuikonMenuEventHandler::DynInitMenuItemL( CXnNodeAppIf& aMenuItem ) - { - TBool ret = EFalse; - if( !iUiEngine->WidgetsVisible() ) - { - // only online/offline dynamic menu item is allowed to show now - CXnProperty* prop( aMenuItem.GetPropertyL(KName) ); - if ( prop ) - { - HBufC* item ( prop->StringValueL() ); - CleanupStack::PushL( item ); - if (item->Des() == KHSOnLine_OffLine() ) - { - ret = DynInitItemL( aMenuItem, iUiEngine->FocusedNode() ); - } - CleanupStack::PopAndDestroy( item ); - } - } - else - { - ret = DynInitItemL( aMenuItem, iUiEngine->FocusedNode() ); - } - return ret; - } - diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/src/appui.cpp --- a/idlehomescreen/xmluicontroller/src/appui.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/src/appui.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -25,20 +25,21 @@ #include // User includes +#include +#include #include #include +#include #include #include "appui.h" #include "application.h" #include "xmluicontroller.h" #include "aixuikoneventhandler.h" -#include "aiuiframeworkobserver.h" #include "aixmluiconstants.h" #include "contentrenderer.h" #include "psobserver.h" -#include "aipropertyextension.h" #include "aicontentmodel.h" #include "aiuiidleintegration.h" #include "xmluicontrollerpanic.h" @@ -49,6 +50,11 @@ #include "xnproperty.h" #include "xnuiengineappif.h" #include "onlineofflinehelper.h" +#include "ainativeuiplugins.h" + +// Constants +// EAiDeviceStatusContentNetworkIdentity content id +_LIT( KNetworkIdentity, "NetworkIdentity" ); using namespace AiXmlUiController; @@ -72,29 +78,28 @@ AI3_PERF_START(perfdata, "xmluicontroller: CAppUi::ConstructL") // Always reset the phoneforward P&S key on startup just in case - RProperty::Set(KPSUidAiInformation, - KActiveIdleForwardNumericKeysToPhone, - EPSAiForwardNumericKeysToPhone); - + RProperty::Set( KPSUidAiInformation, + KActiveIdleForwardNumericKeysToPhone, EPSAiForwardNumericKeysToPhone ); + // Initialize with empty title pane so it's not shown on startup. __HEAP("XML UI: Init - Construct App UI") __TIME("XML UI: XnAppUiAdapted::ConstructL", CXnAppUiAdapter::ConstructL(); ) - + // Register for XML UI view activation & deactivation AddViewActivationObserverL( this ); // Disable CCoeEnv exit checks. // Active Idle Framework will perform the checks. - iCoeEnv->DisableExitChecks(ETrue); + iCoeEnv->DisableExitChecks( ETrue ); __TIME("XML UI: Construct Content Renderer", iContentRenderer = CContentRenderer::NewL( *this ); ) __HEAP("XML UI: Construct Content Renderer"); - TXnUiEngineAppIf* uiEngine = UiEngineL(); + TXnUiEngineAppIf* uiEngine( UiEngineL() ); __ASSERT_ALWAYS( uiEngine, Panic(ECriticalPointerNull) ); iUiCtl.SetObserver( *iContentRenderer ); @@ -104,29 +109,30 @@ iUiCtl.SetAppUi( *this ); iEventHandler = iUiCtl.CreateXuikonEventHandlerL( *iContentRenderer ); - - iUiFwObserver = iUiCtl.UiFrameworkObserver(); - + TAiIdleKeySoundConfig keySoundConfig; keySoundConfig.iKeySounds = KeySounds(); keySoundConfig.iContextResId = R_XUI_DEFAULT_SKEY_LIST; iIdleIntegration = CAiUiIdleIntegration::NewL ( *iEikonEnv, keySoundConfig, iUiCtl.FwEventHandler() ); - + + iUiCtl.NotifyAppEnvReadyL(); + + CAknAppUiBase::SetKeyEventFlags( CAknAppUiBase::EDisableSendKeyShort | + CAknAppUiBase::EDisableSendKeyLong ); + iHelper = COnlineOfflineHelper::NewL( iUiCtl ); - iUiCtl.NotifyAppEnvReadyL(); + // Load device status plugin here because it is always needed + iDeviceStatusInfo = THsPublisherInfo( KDeviceStatusPluginUid, + KDeviceStatusPluginName, KNullDesC8 ); + + iUiCtl.FwStateHandler()->LoadPlugin( + iDeviceStatusInfo, EAiFwSystemStartup ); - LoadNativeDataPluginsL(); - - CAknAppUiBase::SetKeyEventFlags( CAknAppUiBase::EDisableSendKeyShort | - CAknAppUiBase::EDisableSendKeyLong ); + __HEAP("XML UI: Done - Construct App UI"); - iIsEditModeActive = EFalse; - - - __HEAP("XML UI: Done - Construct App UI"); AI3_PERF_STOP(perfdata, "xmluicontroller: CAppUi::ConstructL") } @@ -161,26 +167,16 @@ // void CAppUi::PrepareToExit() { + iUiShutdown = ETrue; + + RemoveViewActivationObserver( this ); + iUiCtl.FwEventHandler()->HandleUiShutdown( iUiCtl ); CXnAppUiAdapter::PrepareToExit(); } // ---------------------------------------------------------------------------- -// CAppUi::HandleForegroundEventL() -// ---------------------------------------------------------------------------- -// -void CAppUi::HandleForegroundEventL( TBool aForeground ) - { - CXnAppUiAdapter::HandleForegroundEventL( aForeground ); - - if( iUiFwObserver ) - { - iUiFwObserver->HandleForegroundEvent( aForeground ); - } - } - -// ---------------------------------------------------------------------------- // CAppUi::HandleCommandL() // ---------------------------------------------------------------------------- // @@ -210,20 +206,6 @@ } // ---------------------------------------------------------------------------- -// CAppUi::HandleResourceChangeL() -// ---------------------------------------------------------------------------- -// -void CAppUi::HandleResourceChangeL( TInt aType ) - { - CXnAppUiAdapter::HandleResourceChangeL( aType ); - - if( iUiFwObserver ) - { - iUiFwObserver->HandleResourceChange( aType ); - } - } - -// ---------------------------------------------------------------------------- // CAppUi::HandleWsEventL() // ---------------------------------------------------------------------------- // @@ -279,92 +261,70 @@ { __TIME("UC: Event Management", iEventHandler->HandleXuikonEventL( aOrigin, - aTrigger, - aTriggerDefinition, - aEvent ); - ); + aTrigger, aTriggerDefinition, aEvent ) ); } __PRINTS("*** UI: Done - Event Management"); } + +// ---------------------------------------------------------------------------- +// CAppUi::HandleEventL() +// ---------------------------------------------------------------------------- +// +void CAppUi::HandleEventL( const TDesC& aEvent, CXnNodeAppIf& aDestination ) + { + THsPublisherInfo info; + iUiCtl.PublisherInfoL( aDestination, info ); + + iUiCtl.FwEventHandler()->HandlePluginEventL( info, aEvent ); + } + // ---------------------------------------------------------------------------- // CAppUi::LoadDataPluginsL() // ---------------------------------------------------------------------------- // -void CAppUi::LoadDataPluginsL( RPointerArray< CXnNodeAppIf >& aList ) +TInt CAppUi::LoadPublisher( CXnNodeAppIf& aPublisher, TInt aReason ) { - for( TInt i = 0; i < aList.Count(); i++ ) + if ( iUiShutdown ) { - TAiPublisherInfo info; - - iUiCtl.PublisherInfoL( *aList[i], info ); - - iUiCtl.FwEventHandler()->HandleLoadPluginL( info ); + // Framework has already destroyed all publishers + return KErrNone; } - } + + THsPublisherInfo info; + + TRAP_IGNORE( iUiCtl.PublisherInfoL( aPublisher, info ) ); -// ---------------------------------------------------------------------------- -// CAppUi::LoadNativeDataPluginsL() -// ---------------------------------------------------------------------------- -// -void CAppUi::LoadNativeDataPluginsL() - { - if ( !iNativePluginsLoaded ) + if ( info.Uid() == KDeviceStatusPluginUid ) { - RAiPublisherInfoArray plugins; - CleanupClosePushL( plugins ); - - iUiCtl.PublisherInfoL( plugins ); - - for ( TInt i = 0; i < plugins.Count(); i++ ) - { - iUiCtl.FwEventHandler()->HandleLoadPluginL( plugins[i] ); - } - - CleanupStack::PopAndDestroy( &plugins ); - - iNativePluginsLoaded = ETrue; - } + // Update device status info + iDeviceStatusInfo = info; + } + + return iUiCtl.FwStateHandler()->LoadPlugin( + info, (TAiFwLoadReason) aReason ); } // ---------------------------------------------------------------------------- -// CAppUi::DestroyDataPluginsL() -// ---------------------------------------------------------------------------- -// -void CAppUi::DestroyDataPluginsL( RPointerArray< CXnNodeAppIf >& aList ) - { - for( TInt i = 0; i < aList.Count(); i++ ) - { - TAiPublisherInfo info; - - iUiCtl.PublisherInfoL( *aList[i], info ); - - iUiCtl.FwEventHandler()->HandleDestroyPluginL( info ); - } - } - -// ---------------------------------------------------------------------------- -// CAppUi::DestroyNativeDataPluginsL() +// CAppUi::DestroyPublisher() // ---------------------------------------------------------------------------- // -void CAppUi::DestroyNativeDataPluginsL() +TInt CAppUi::DestroyPublisher( CXnNodeAppIf& aPublisher, TInt aReason ) { - if ( iNativePluginsLoaded ) - { - RAiPublisherInfoArray plugins; - CleanupClosePushL( plugins ); - - iUiCtl.PublisherInfoL( plugins ); - - for ( TInt i = 0; i < plugins.Count(); i++ ) - { - iUiCtl.FwEventHandler()->HandleDestroyPluginL( plugins[i] ); - } - - CleanupStack::PopAndDestroy( &plugins ); - - iNativePluginsLoaded = EFalse; + if ( iUiShutdown ) + { + // Framework has already destroyed all publishers + return KErrNone; } + + THsPublisherInfo info; + + TRAP_IGNORE( iUiCtl.PublisherInfoL( aPublisher, info ) ); + + iUiCtl.FwStateHandler()->DestroyPlugin( + info, (TAiFwDestroyReason) aReason ); + + return KErrNone; } // ---------------------------------------------------------------------------- @@ -374,6 +334,12 @@ TBool CAppUi::DynInitMenuItemL( const TDesC& aItemType, RPointerArray< CXnNodeAppIf >* aList ) { + if ( iUiShutdown ) + { + // Framework has already destroyed all publishers + return EFalse; + } + _LIT( KOnline, "hs_online" ); _LIT( KOffline, "hs_offline" ); @@ -393,7 +359,7 @@ for( TInt i = 0; !retval && i < list.Count(); i++ ) { - TAiPublisherInfo info; + THsPublisherInfo info; iUiCtl.PublisherInfoL( *list[i], info ); @@ -406,48 +372,14 @@ // ---------------------------------------------------------------------------- // CAppUi::SetOnlineStateL() -// Called always by view manager when view is activated. -// ---------------------------------------------------------------------------- -// -void CAppUi::SetOnlineStateL( RPointerArray< CXnNodeAppIf >& aList ) - { - iHelper->ProcessOnlineStateL( aList ); - } - -// ---------------------------------------------------------------------------- -// CAppUi::SetOnlineL() // Called always when user changed HS online/offline status from option menu. // ---------------------------------------------------------------------------- // void CAppUi::SetOnlineStateL( TBool aOnline ) { - iHelper->ProcessOnlineStateL( aOnline ); - } - -// ---------------------------------------------------------------------------- -// CAppUi::HandleViewActivation() -// ---------------------------------------------------------------------------- -// -void CAppUi::HandleViewActivation( const TVwsViewId& aNewlyActivatedViewId, - const TVwsViewId& aViewIdToBeDeactivated ) - { - if ( iIsEditModeActive ) + if ( !iUiShutdown ) { - return; - } - - // Get Xml Ui view id - TVwsViewId viewId( View().ViewId() ); - - if ( viewId == aNewlyActivatedViewId ) - { - // Xml Ui view became active - TRAP_IGNORE( LoadNativeDataPluginsL() ); - } - else if ( viewId == aViewIdToBeDeactivated ) - { - // Xml Ui view became inactive - TRAP_IGNORE( DestroyNativeDataPluginsL() ); + iHelper->ProcessOnlineStateL( aOnline ); } } @@ -461,12 +393,12 @@ } // ---------------------------------------------------------------------------- -// CAppUi::HandlePageSwitch() +// CAppUi::Helper() // ---------------------------------------------------------------------------- // -void CAppUi::HandlePageSwitch() +COnlineOfflineHelper* CAppUi::Helper() const { - iUiCtl.FwEventHandler()->ProcessStateChange( EAifwPageSwitch ); + return iHelper; } // ---------------------------------------------------------------------------- @@ -475,16 +407,54 @@ // void CAppUi::HandleEnterEditModeL( TBool aEnter ) { - if ( aEnter ) + if ( iInEditMode != aEnter ) { - DestroyNativeDataPluginsL(); - iIsEditModeActive = ETrue; - } - else - { - LoadNativeDataPluginsL(); - iIsEditModeActive = EFalse; - } + if ( aEnter ) + { + iUiCtl.FwEventHandler()->SuspendContent( + iDeviceStatusInfo, KNetworkIdentity ); + } + else + { + iUiCtl.FwEventHandler()->RefreshContent( + iDeviceStatusInfo, KNetworkIdentity ); + } + + iInEditMode = aEnter; + } } +// ---------------------------------------------------------------------------- +// CAppUi::HandleViewActivation() +// ---------------------------------------------------------------------------- +// +void CAppUi::HandleViewActivation( const TVwsViewId& aNewlyActivatedViewId, + const TVwsViewId& aViewIdToBeDeactivated ) + { + TVwsViewId activeViewId; + + TInt err( GetActiveViewId( activeViewId ) ); + + if ( iInEditMode || err == KErrNotFound ) + { + return; + } + + // Get Xml Ui view id + TVwsViewId xmlViewId( View().ViewId() ); + + if ( xmlViewId == aNewlyActivatedViewId && activeViewId != xmlViewId ) + { + // Xml Ui view became active + iUiCtl.FwEventHandler()->RefreshContent( + iDeviceStatusInfo, KNetworkIdentity ); + } + else if ( xmlViewId == aViewIdToBeDeactivated && activeViewId == xmlViewId ) + { + // Xml Ui view became inactive + iUiCtl.FwEventHandler()->SuspendContent( + iDeviceStatusInfo, KNetworkIdentity ); + } + } + // End of File. diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/src/cenrepobserver.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/idlehomescreen/xmluicontroller/src/cenrepobserver.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,174 @@ +/* +* Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Listens to changes in a Central Repository key +* KCurrentCellularDataUsage in Repository KCRUidCmManager. +*/ + +#include +#include +#include + +#include "cenrepobserver.h" +#include "ai3.hrh" +using namespace AiXmlUiController; + +#ifdef HS_NETWORK_MONITOR +#include +_LIT( KLogFolder,"xnnetwork" ); +_LIT( KLogDom, "networksettings.log" ); + +#define _LOG1( a ) RFileLogger::Write( \ + KLogFolder, KLogDom, EFileLoggingModeAppend, ( a ) ); +#define _LOG2( a, b ) RFileLogger::WriteFormat( \ + KLogFolder, KLogDom, EFileLoggingModeAppend, ( a ), ( b ) ) +#else +#define _LOG1 +#define _LOG2 +#endif + +// ----------------------------------------------------------------------------- +// CCenRepObserver::NewL +// ----------------------------------------------------------------------------- +// +CCenRepObserver* CCenRepObserver::NewL( MCenRepObserver* aObserver ) + { + CCenRepObserver* self = + CCenRepObserver::NewLC( aObserver ); + CleanupStack::Pop( self ); + return self; + } + +// ----------------------------------------------------------------------------- +// CCenRepObserver::NewLC +// ----------------------------------------------------------------------------- +// +CCenRepObserver* CCenRepObserver::NewLC( MCenRepObserver* aObserver ) + { + CCenRepObserver* self = + new( ELeave ) CCenRepObserver( aObserver ); + CleanupStack::PushL( self ); + self->ConstructL(); + return self; + } + +// ----------------------------------------------------------------------------- +// CCenRepObserver::~CCenRepObserver +// ----------------------------------------------------------------------------- +// +CCenRepObserver::~CCenRepObserver() + { + // Cancel outstanding request, if exists + Cancel(); + delete iRepository; + iObserver = NULL; + } + +// ----------------------------------------------------------------------------- +// CCenRepObserver::CCenRepObserver +// ----------------------------------------------------------------------------- +// +CCenRepObserver::CCenRepObserver( MCenRepObserver* aObserver ) + : + CActive( CActive::EPriorityStandard ), + iObserver( aObserver ) + { + } + +// ----------------------------------------------------------------------------- +// CCenRepObserver::ConstructL +// ----------------------------------------------------------------------------- +// +void CCenRepObserver::ConstructL() + { + TRAPD( err, iRepository = CRepository::NewL( KCRUidCmManager ) ) + + if ( err == KErrNone ) + { + CActiveScheduler::Add( this ); + RequestNotifications(); + } + else + { + _LOG2( _L("FAILED to open KCRUidCmManager repository <%d>"), err ); + } + } + +// ----------------------------------------------------------------------------- +// CCenRepObserver::RequestNotifications +// ----------------------------------------------------------------------------- +// +void CCenRepObserver::RequestNotifications() + { + _LOG1( _L("CCenRepObserver::RequestNotifications") ); + + TInt err = iRepository->NotifyRequest( KCurrentCellularDataUsage, iStatus ); + + if ( err == KErrNone ) + { + SetActive(); + } + else + { + _LOG2( _L("ERROR, iRepository->NotifyRequest() %d"), err ); + } + } + +// ----------------------------------------------------------------------------- +// CCenRepObserver::DoCancel +// ----------------------------------------------------------------------------- +// +void CCenRepObserver::DoCancel() + { + iRepository->NotifyCancel( KCurrentCellularDataUsage ); + } + +// ----------------------------------------------------------------------------- +// CCenRepObserver::RunL +// ----------------------------------------------------------------------------- +// +void CCenRepObserver::RunL() + { + _LOG2( _L("CCenRepObserver::RunL() %d"), iStatus.Int() ); + + if ( iStatus.Int() < KErrNone ) + { + iErrorCounter++; + if ( iErrorCounter > KCenRepErrorRetryCount ) + { + _LOG2( _L("Over %d consecutive errors, stopping notifications permanently"), + KCenRepErrorRetryCount ); + return; + } + } + else + { + iErrorCounter = 0; + + TInt value( 0 ); + TInt err = iRepository->Get( KCurrentCellularDataUsage, value ); + + if ( err == KErrNone ) + { + _LOG2( _L("KCurrentCellularDataUsage: %d"), value ); + iObserver->CurrentCellularDataUsageChangedL( value ); + } + else + { + _LOG2( _L("ERROR, iRepository->Get(KCurrentCellularDataUsage) %d"), err ); + } + } + + RequestNotifications(); + } +// End-of-file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/src/contentpublisher.cpp --- a/idlehomescreen/xmluicontroller/src/contentpublisher.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/src/contentpublisher.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -16,16 +16,13 @@ */ #include "contentpublisher.h" -#include "globalqueryhandler.h" #include #include #include -#include -#include #include "xmluicontroller.h" -#include -#include // StringLoader +#include "appui.h" +#include "onlineofflinehelper.h" using namespace AiXmlUiController; @@ -46,9 +43,6 @@ _LIT8( KAPStatus, "apstatus"); _LIT(KNetwork, "network"); -_LIT( KDisConnected, "disconnected"); -_LIT( KConnected, "connected"); - _LIT(KPublisher16, "publisher"); @@ -62,6 +56,7 @@ _LIT8( KWidth, "width"); _LIT8( KHeight, "height"); _LIT8( KChangeInfo, "change_info" ); + // ============================ LOCAL FUNCTIONS =============================== @@ -105,8 +100,6 @@ delete iServiceHandler; iServiceHandler = NULL; } - delete iGlobalQueryHandler; - delete iGlobalConfirmationQuery; } // ----------------------------------------------------------------------------- @@ -125,9 +118,6 @@ { InitCpsInterfaceL(); RegisterListenerL(); - iGlobalQueryHandler = CGlobalQueryHandler::NewL(iUiController); - iGlobalConfirmationQuery = CAknGlobalConfirmationQuery::NewL(); - } // ----------------------------------------------------------------------------- @@ -387,44 +377,21 @@ } void CContentPublisher::HandlePublisherInfoL( const TDesC& aPubInfo) - { - //Currently HS will handle only network status update form publisher - if ( aPubInfo == KNetwork ) - { - CLiwDefaultMap *outDataMap = CLiwDefaultMap::NewLC(); - GetDataL( KAI3HSPublisher(), KPublisher16, KNetwork(), outDataMap ); - TLiwVariant variant; - variant.PushL(); - if ( outDataMap->FindL(KAPStatus, variant)) - { - HBufC16* netStatus = variant.AsDes().AllocLC(); - if ( netStatus->Des() == KDisConnected() ) - { - ShowGlobalQueryL(R_QTN_HS_DISABLE_NETWORK, EFalse ); - } - else if ( netStatus->Des() == KConnected() ) - { - ShowGlobalQueryL(R_QTN_HS_SWITCH_ONLINE, ETrue ); - } - CleanupStack::PopAndDestroy( netStatus ); - } - CleanupStack::PopAndDestroy( &variant ); - CleanupStack::PopAndDestroy(outDataMap); - } - } - - -void CContentPublisher::ShowGlobalQueryL( TInt aResourceId, TBool aSetOnline ) { - if ( !iGlobalQueryHandler->IsActive() ) + //Currently HS will handle only network status update form publisher + if ( aPubInfo == KNetwork ) { - HBufC* confirmationText = StringLoader::LoadLC(aResourceId); - iGlobalConfirmationQuery->ShowConfirmationQueryL( - iGlobalQueryHandler->iStatus, - *confirmationText, - R_AVKON_SOFTKEYS_YES_NO); - iGlobalQueryHandler->SetOnlineParamAndActivate(aSetOnline); - CleanupStack::PopAndDestroy(); //confirmationText + _LIT( KOffline, "hs_offline" ); + CLiwDefaultMap *outDataMap = CLiwDefaultMap::NewLC(); + GetDataL( KAI3HSPublisher(), KPublisher16, KNetwork(), outDataMap ); + TLiwVariant variant; + variant.PushL(); + if ( outDataMap->FindL(KAPStatus, variant)) + { + iUiController.AppUi()->Helper()->HandleConnectionQueryL(variant.AsDes()); + } + CleanupStack::PopAndDestroy( &variant ); + CleanupStack::PopAndDestroy(outDataMap); } } // END OF FILE diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/src/contentrenderer.cpp --- a/idlehomescreen/xmluicontroller/src/contentrenderer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/src/contentrenderer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -16,289 +16,91 @@ */ // System includes -#include -#include -#include +#include +#include +#include // User includes - -#include "contentrenderer.h" -#include "appui.h" -#include "activetransactionstack.h" -#include "transactionfactoryimpl.h" -#include "mtransaction.h" -#include "mtransactionelement.h" -#include "aixmluiutils.h" -#include "xmluicontroller.h" -#include "xmlnodeidgenerator.h" -#include "aixmluiconstants.h" -#include "aifweventhandler.h" -#include "databuffertransactionelement.h" -#include "newstickercallbackhandler.h" -#include "newstickertransactionelement.h" -#include "csspropertymap.h" -#include "policyevaluator.h" -#include "debug.h" -#include "xnuiengineappif.h" -#include "xnnodeappif.h" -#include "xnproperty.h" -#include "mxncomponentinterface.h" -#include "xntext.h" -#include "xnbitmap.h" -#include "xntype.h" -#include "xnmenuadapter.h" -#include "xnlistquerydialogadapter.h" -#include "mxncomponentinterface.h" -#include "aistrcnv.h" -#include "contentprioritymap.h" -#include "ainativeuiplugins.h" +#include +#include +#include "contentrenderer.h" +#include "appui.h" +#include "activetransactionstack.h" +#include "transactionfactoryimpl.h" +#include "mtransaction.h" +#include "mtransactionelement.h" +#include "aixmluiutils.h" +#include "xmluicontroller.h" +#include "xmlnodeidgenerator.h" +#include "aixmluiconstants.h" +#include "aifweventhandler.h" +#include "databuffertransactionelement.h" +#include "newstickercallbackhandler.h" +#include "newstickertransactionelement.h" +#include "csspropertymap.h" +#include "policyevaluator.h" +#include "debug.h" +#include "xnuiengineappif.h" +#include "xnnodeappif.h" +#include "xncomponentnodeimpl.h" +#include "xnproperty.h" +#include "mxncomponentinterface.h" +#include "xntext.h" +#include "xnbitmap.h" +#include "xntype.h" +#include "xnmenuadapter.h" +#include "xnlistquerydialogadapter.h" +#include "mxncomponentinterface.h" +#include "aistrcnv.h" +#include "contentprioritymap.h" +#include "ainativeuiplugins.h" using namespace AiXmlUiController; using namespace AiUiDef::xml; using namespace XnTextInterface; using namespace XnImageInterface; -namespace +/** + * Cleanup item for cleanup of TPtrHashMapIter + */ +class TMapCleanupItem { - typedef RPointerArray RXnNodeArray; - - /** - * Gets content item iterator. - * - * @param aPlugin plugin to fetch the iterator - * @param aContentType type of iterator (content/resource/event) - * @return the iterator - * @leave KErrNotSupported if plugin does not provide iterator - */ - static MAiContentItemIterator& ContentItemIteratorL( MAiPropertyExtension& aPlugin, - TInt aContentType ) - { - MAiContentItemIterator* iter = - static_cast< MAiContentItemIterator* >( aPlugin.GetPropertyL( aContentType ) ); - - if ( !iter ) - { - User::Leave( KErrNotSupported ); - } - - return *iter; - } - - /** - * Gets the content priority associated in the property element. - * - * @param aPropertyElement the property element - * @return priority value or KErrNotFound for non-prioritized element - */ - TInt GetContentPriority( CXnNodeAppIf& aPropertyElement ) - { - TInt32 priority( KErrNotFound ); - - const TDesC8* name = PropertyValue( aPropertyElement, - property::KName ); - - - if ( name && *name == name::KPriority ) - { - const TDesC8* value = PropertyValue( aPropertyElement, - property::KValue ); - if ( value ) - { - AiUtility::ParseInt( priority, *value ); - } - } - - return priority; - } - +public: /** - * Remove elements from array which do not contain priority or priority is not lower than - * the given value. - * - * @param aElements array of elements - * @param aLastPriority upper bound of priority value (excluded from the array) + * C++ consturctor */ - void RemoveNonPriorityElements( RPointerArray< CXnNodeAppIf>& aElements, - TInt aLastPriority ) - { - // Remove non priority elements and higher priority elements - - TInt elementCount = aElements.Count(); - for ( TInt i = 0; i < elementCount; ) - { - CXnNodeAppIf* current = aElements[i]; - - // Check name attribute - const TDesC8* name = PropertyValue( *current, property::KName ); - - if ( !name || *name != name::KPriority ) - { - // Remove current - aElements.Remove( i ); - --elementCount; - } - else - { - // Check current priority - const TDesC8* value = PropertyValue( *current, property::KValue ); - - if ( !value ) // value not present - { - aElements.Remove( i ); - --elementCount; - continue; - } - - TInt32 currentPriority( KErrNotFound ); - if ( AiUtility::ParseInt( currentPriority, *value ) != KErrNone ) - { - // value is not integer - aElements.Remove( i ); - --elementCount; - continue; - } - - if ( currentPriority < aLastPriority ) - { - // Keep element and iterate further - ++i; - } - else - { - // priority is too high - aElements.Remove( i ); - --elementCount; - } - } - } - } + TMapCleanupItem( TPtrHashMapIter< TDesC, TInt >& aIterator ); /** - * Descending priority order for prioritized content selectors. - * - * @param aNode1 First node to compare - * @param aNode2 Second node to compare - * @return 0 nodes have equal priority - * @return >0 aNode1 has lower priority - * @return <0 aNode2 has lower priority - */ - TInt DescendingPriorityOrder( const CXnNodeAppIf& aNode1, - const CXnNodeAppIf& aNode2 ) - { - // Array content has been validated, so no checks are needed - const TDesC8* value1 = PropertyValue( aNode1, - property::KValue ); - - const TDesC8* value2 = PropertyValue( aNode2, - property::KValue ); - - TInt32 priority1( KErrNotFound ); - AiUtility::ParseInt( priority1, *value1 ); - - TInt32 priority2( KErrNotFound ); - AiUtility::ParseInt( priority2, *value2 ); - - if ( priority1 == priority2 ) - { - return 0; - } + * Removes the pointers in the map and deletes the objects + * referenced by the pointers. + */ + void Release(); - return ( priority1 < priority2 ) ? 1 : -1; - } - - /** - * Removes duplicate entries in content change array - */ - void RemoveDuplicateContentChangesL( RAiPolicyElementArray& aArray ) - { - for ( TInt i = 0; i < aArray.Count(); ++i ) - { - HBufC* id = PropertyValueL( aArray[i].Target(), - AiUiDef::xml::property::KId ); - if ( id ) - { - CleanupStack::PushL( id ); - for ( TInt j = i; j < aArray.Count(); ++j ) - { - HBufC* id2 = PropertyValueL( aArray[j].Target(), - AiUiDef::xml::property::KId ); - if ( id2) - { - CleanupStack::PushL( id2 ); - // Same id and same policy - if ( i != j && - id->Compare( *id2 ) == 0 && - ( aArray[i].Policy().Compare( aArray[j].Policy()) == 0) - ) - { - aArray.Remove( j ); - --j; - } - } - CleanupStack::PopAndDestroy( id2 ); - - } - CleanupStack::PopAndDestroy( id ); - } - } - } - /** - * Cleanup item for cleanup of TPtrHashMapIter - */ - class TMapCleanupItem - { - public: - - TMapCleanupItem( TPtrHashMapIter< TDesC, TInt >& aIterator ); - - /** - * Removes the pointers in the map and deletes the objects - * referenced by the pointers. - */ - void Release(); - - private: - - TPtrHashMapIter< TDesC, TInt > iIterator; - - }; +private: + TPtrHashMapIter< TDesC, TInt > iIterator; + }; - /** - * Helper to handle cleanup of map iterator - * @param aMapCleanupItem - */ - void CleanupRelease( TAny* aMapCleanupItem ) - { - if ( aMapCleanupItem ) - { - static_cast< TMapCleanupItem* >( aMapCleanupItem )->Release(); - } - } - - /** - * Helper to push map iterator into cleanup stack. - * - * @param aCleanupItem item to push into cleanup stack - **/ - void CleanupReleasePushL( TMapCleanupItem& aCleanupItem ) - { - CleanupStack::PushL( TCleanupItem( CleanupRelease, - &aCleanupItem ) ); - } - - - } - +// ---------------------------------------------------------------------------- +// TMapCleanupItem::TMapCleanupItem +// +// ---------------------------------------------------------------------------- +// TMapCleanupItem::TMapCleanupItem( TPtrHashMapIter< TDesC, TInt >& aIterator ) : iIterator( aIterator ) { } +// ---------------------------------------------------------------------------- +// TMapCleanupItem::Release +// +// ---------------------------------------------------------------------------- +// void TMapCleanupItem::Release() { // Delete current key and value - const TDesC* key = iIterator.CurrentKey(); - const TInt* value = iIterator.CurrentValue(); + const TDesC* key( iIterator.CurrentKey() ); + const TInt* value( iIterator.CurrentValue() ); delete key; delete value; @@ -307,15 +109,228 @@ iIterator.RemoveCurrent(); } +// ============================ LOCAL FUNCTIONS =============================== +// ---------------------------------------------------------------------------- +// ContentItemIterator +// Gets content item iterator +// ---------------------------------------------------------------------------- +// +static MAiContentItemIterator* ContentItemIterator( CHsContentPublisher& aPlugin, + CHsContentPublisher::TProperty aType ) + { + return static_cast< + MAiContentItemIterator* >( aPlugin.GetProperty( aType ) ); + } + +// ---------------------------------------------------------------------------- +// ContentPriority +// Gets the content priority associated in the property element +// ---------------------------------------------------------------------------- +// +static TInt ContentPriority( CXnNodeAppIf& aPropertyElement ) + { + TInt32 priority( KErrNotFound ); + + const TDesC8* name( + PropertyValue( aPropertyElement, property::KName ) ); + + if ( name && *name == name::KPriority ) + { + const TDesC8* value( + PropertyValue( aPropertyElement, property::KValue ) ); + + if ( value ) + { + AiUtility::ParseInt( priority, *value ); + } + } + + return priority; + } + +// ---------------------------------------------------------------------------- +// RemoveNonPriorityElements +// Remove elements from array which do not contain priority or priority is +// not lower than the given value. +// ---------------------------------------------------------------------------- +// +static void RemoveNonPriorityElements( RPointerArray< CXnNodeAppIf>& aElements, + TInt aLastPriority ) + { + // Remove non priority elements and higher priority elements + TInt elementCount( aElements.Count() ); + + for ( TInt i = 0; i < elementCount; ) + { + CXnNodeAppIf* current( aElements[i] ); + + // Check name attribute + const TDesC8* name( PropertyValue( *current, property::KName ) ); + + if ( !name || *name != name::KPriority ) + { + // Remove current + aElements.Remove( i ); + --elementCount; + } + else + { + // Check current priority + const TDesC8* value( + PropertyValue( *current, property::KValue ) ); + + if ( !value ) // value not present + { + aElements.Remove( i ); + --elementCount; + continue; + } + + TInt32 currentPriority( KErrNotFound ); + + if ( AiUtility::ParseInt( currentPriority, *value ) != KErrNone ) + { + // value is not integer + aElements.Remove( i ); + --elementCount; + continue; + } + + if ( currentPriority < aLastPriority ) + { + // Keep element and iterate further + ++i; + } + else + { + // priority is too high + aElements.Remove( i ); + --elementCount; + } + } + } + } + +// ---------------------------------------------------------------------------- +// DescendingPriorityOrder +// Descending priority order for prioritized content selectors. +// ---------------------------------------------------------------------------- +// +static TInt DescendingPriorityOrder( const CXnNodeAppIf& aNode1, + const CXnNodeAppIf& aNode2 ) + { + /* + * @param aNode1 First node to compare + * @param aNode2 Second node to compare + * @return 0 nodes have equal priority + * @return >0 aNode1 has lower priority + * @return <0 aNode2 has lower priority + */ + // Array content has been validated, so no checks are needed + const TDesC8* value1( + PropertyValue( aNode1, property::KValue ) ); + + const TDesC8* value2( + PropertyValue( aNode2, property::KValue ) ); + + TInt32 priority1( KErrNotFound ); + AiUtility::ParseInt( priority1, *value1 ); + + TInt32 priority2( KErrNotFound ); + AiUtility::ParseInt( priority2, *value2 ); + + if ( priority1 == priority2 ) + { + return 0; + } + + return ( priority1 < priority2 ) ? 1 : -1; + } + +// ---------------------------------------------------------------------------- +// RemoveDuplicateContentChangesL +// Removes duplicate entries in content change array +// ---------------------------------------------------------------------------- +// +static void RemoveDuplicateContentChangesL( RAiPolicyElementArray& aArray ) + { + for ( TInt i = 0; i < aArray.Count(); ++i ) + { + HBufC* id( PropertyValueL( aArray[i].Target(), + AiUiDef::xml::property::KId ) ); + + if ( id ) + { + CleanupStack::PushL( id ); + + for ( TInt j = i; j < aArray.Count(); ++j ) + { + HBufC* id2( PropertyValueL( aArray[j].Target(), + AiUiDef::xml::property::KId ) ); + + if ( id2 ) + { + CleanupStack::PushL( id2 ); + + // Same id and same policy + if ( i != j && id->Compare( *id2 ) == 0 && + ( aArray[i].Policy().Compare( aArray[j].Policy()) == 0 ) ) + + { + aArray.Remove( j ); + --j; + } + } + + CleanupStack::PopAndDestroy( id2 ); + } + + CleanupStack::PopAndDestroy( id ); + } + } + } + +// ---------------------------------------------------------------------------- +// CleanupReleaseMapItem +// Helper to handle cleanup of map iterator +// ---------------------------------------------------------------------------- +// +static void CleanupReleaseMapItem( TAny* aMapCleanupItem ) + { + if ( aMapCleanupItem ) + { + static_cast< TMapCleanupItem* >( aMapCleanupItem )->Release(); + } + } + +// ---------------------------------------------------------------------------- +// CleanupReleasePushL +// Helper to push map iterator into cleanup stack. +// ---------------------------------------------------------------------------- +// +static void CleanupReleasePushL( TMapCleanupItem& aCleanupItem ) + { + CleanupStack::PushL( TCleanupItem( CleanupReleaseMapItem, &aCleanupItem ) ); + } // ============================ MEMBER FUNCTIONS =============================== +// ---------------------------------------------------------------------------- +// CContentRenderer::CContentRenderer +// +// ---------------------------------------------------------------------------- +// CContentRenderer::CContentRenderer( CAppUi& aAppUi ) : iAppUi( aAppUi ) { } +// ---------------------------------------------------------------------------- +// CContentRenderer::ConstructL +// +// ---------------------------------------------------------------------------- +// void CContentRenderer::ConstructL() { iContentPriorityMap = AiUtility::CContentPriorityMap::NewL(); @@ -328,17 +343,27 @@ iPolicyEvaluator = CPolicyEvaluator::NewL(); } +// ---------------------------------------------------------------------------- +// CContentRenderer::NewL +// +// ---------------------------------------------------------------------------- +// CContentRenderer* CContentRenderer::NewL( CAppUi& aAppUi ) { CContentRenderer* self = new( ELeave ) CContentRenderer( aAppUi ); CleanupStack::PushL( self ); self->ConstructL(); - CleanupStack::Pop(); + CleanupStack::Pop( self ); return self; } +// ---------------------------------------------------------------------------- +// CContentRenderer::~CContentRenderer +// +// ---------------------------------------------------------------------------- +// CContentRenderer::~CContentRenderer() { delete iPolicyEvaluator; @@ -374,46 +399,27 @@ delete iCallbackHandler; } +// ---------------------------------------------------------------------------- +// CContentRenderer::SetEventHandler +// +// ---------------------------------------------------------------------------- +// void CContentRenderer::SetEventHandler( MAiFwEventHandler& aFwEventHandler ) { iFwEventHandler = &aFwEventHandler; } -void CContentRenderer::Reset() - { - iContentPriorityMap->Reset(); - iPropertyMap->Reset(); - } - -void CContentRenderer::CleanPluginFromUi( MAiPropertyExtension& aPlugin ) - { - // Create transaction to clean UI - TInt txId = reinterpret_cast< TInt >( &aPlugin ); - - TBool txCreated = ( StartTransaction( txId ) == KErrNone ); - - // Clean plugin - TRAPD( cleanError, CleanPluginFromUiL( aPlugin ) ); - - // Commit transaction - if ( txCreated ) - { - if (cleanError ) - { - CancelTransaction( txId ); - } - else - { - Commit( txId ); - } - } - } - +// ---------------------------------------------------------------------------- +// CContentRenderer::StartTransaction +// +// ---------------------------------------------------------------------------- +// TInt CContentRenderer::StartTransaction( TInt aTxId ) { __PRINT(__DBG_FORMAT("\t[I]\tXML UI: Start transaction id=%d"), aTxId); __HEAP("XML UI: Start transaction"); __TICK("XML UI: Start transaction"); + TRAPD( error, DoStartTransactionL( aTxId ) ); if ( error ) @@ -424,10 +430,15 @@ return error; } +// ---------------------------------------------------------------------------- +// CContentRenderer::Commit +// +// ---------------------------------------------------------------------------- +// TInt CContentRenderer::Commit( TInt aTxId ) { // Remove transaction with aTxId from stack - MTransaction* tr = iStack->Remove( aTxId ); + MTransaction* tr( iStack->Remove( aTxId ) ); if ( tr ) { @@ -437,10 +448,12 @@ TBool layoutChanged( EFalse ); TRAPD( error, tr->CommitL( layoutChanged, propertyHashMap ) ); + if( error == KErrNone ) { TRAP_IGNORE( SetPropertyArraysL( propertyHashMap ) ); } + propertyHashMap.Close(); __TICK("XML UI: Commit transaction"); @@ -464,9 +477,14 @@ return KErrNotSupported; } +// ---------------------------------------------------------------------------- +// CContentRenderer::ProcessContentChangesL +// +// ---------------------------------------------------------------------------- +// void CContentRenderer::ProcessContentChangesL( MTransaction& aTr ) { - TDblQueIter iter = aTr.ElementIter(); + TDblQueIter iter( aTr.ElementIter() ); RAiPolicyElementArray contentChangedArray; CleanupClosePushL( contentChangedArray ); @@ -479,7 +497,7 @@ iPolicyEvaluator->EvaluateContentChangedPolicyL( target, contentChangedArray); - iPolicyEvaluator->EvaluateContentChangedPolicyL( *(target.ParentL()), + iPolicyEvaluator->EvaluateContentChangedPolicyL( *(target.ParentL() ), contentChangedArray); } @@ -489,16 +507,25 @@ { ProcessContentChangeL( contentChangedArray[i] ); } + CleanupStack::PopAndDestroy(); } +// ---------------------------------------------------------------------------- +// CContentRenderer::ProcessContentChangeL +// +// ---------------------------------------------------------------------------- +// void CContentRenderer::ProcessContentChangeL( TAiPolicyElement& aElement ) { - const TDesC8* id = PropertyValue( aElement.Target(), - AiUiDef::xml::property::KId ); + const TDesC8* id( PropertyValue( + aElement.Target(), AiUiDef::xml::property::KId ) ); + if ( id ) { - CXnNodeAppIf* targetNode = FindNodeByIdL( *id, aElement.Target().Namespace() ); + CXnNodeAppIf* targetNode( + FindNodeByIdL( *id, aElement.Target().Namespace() ) ); + if ( targetNode ) { if ( aElement.Policy() == AiUiDef::xml::value::KShowTooltips ) @@ -509,10 +536,15 @@ } } +// ---------------------------------------------------------------------------- +// CContentRenderer::CancelTransaction +// +// ---------------------------------------------------------------------------- +// TInt CContentRenderer::CancelTransaction( TInt aTxId ) { // Remove transaction with aTxId from stack - MTransaction* tr = iStack->Remove( aTxId ); + MTransaction* tr( iStack->Remove( aTxId ) ); if ( tr ) { @@ -529,12 +561,17 @@ return KErrNotSupported; } -TBool CContentRenderer::CanPublish( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aIndex ) +// ---------------------------------------------------------------------------- +// CContentRenderer::CanPublish +// +// ---------------------------------------------------------------------------- +// +TBool CContentRenderer::CanPublish( CHsContentPublisher& aPlugin, + TInt aContent, TInt aIndex ) { TInt error( KErrNone ); TInt retval( KErrNone ); + __PRINTS("*** UC: Init - Content Validation ***"); __TIME("UC: Content Validation", TRAP( error, retval = CanPublishL( aPlugin, aContent, aIndex ) ); @@ -545,13 +582,17 @@ return ( error == KErrNone && retval == KErrNone ); } -TInt CContentRenderer::Publish( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aResource, - TInt aIndex ) +// ---------------------------------------------------------------------------- +// CContentRenderer::Publish +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::Publish( CHsContentPublisher& aPlugin, TInt aContent, + TInt aResource, TInt aIndex ) { TInt error( KErrNone ); TInt retval( KErrNone ); + __PRINTS("*** UC: Init - Content Publishing (Resource) ***"); __TIME("UC: Content Publishing (Resource)", TRAP( error, retval = DoPublishL( aPlugin, aContent, aResource, aIndex ) ); @@ -567,10 +608,13 @@ return error; } -TInt CContentRenderer::Publish( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC16& aText, - TInt aIndex ) +// ---------------------------------------------------------------------------- +// CContentRenderer::Publish +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::Publish( CHsContentPublisher& aPlugin, TInt aContent, + const TDesC16& aText, TInt aIndex ) { TInt error( KErrNone ); TInt retval( KErrNone ); @@ -590,10 +634,13 @@ return error; } -TInt CContentRenderer::Publish( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC8& aBuf, - TInt aIndex ) +// ---------------------------------------------------------------------------- +// CContentRenderer::Publish +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::Publish( CHsContentPublisher& aPlugin, TInt aContent, + const TDesC8& aBuf, TInt aIndex ) { TInt error( KErrNone ); TInt retval( KErrNone ); @@ -613,10 +660,13 @@ return error; } -TInt CContentRenderer::Publish( MAiPropertyExtension& aPlugin, - TInt aContent, - RFile& aFile, - TInt aIndex ) +// ---------------------------------------------------------------------------- +// CContentRenderer::Publish +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::Publish( CHsContentPublisher& aPlugin, TInt aContent, + RFile& aFile, TInt aIndex ) { TInt error( KErrNone ); TInt retval( KErrNone ); @@ -636,7 +686,13 @@ return error; } -TInt CContentRenderer::Clean( MAiPropertyExtension& aPlugin, TInt aContent, TInt aIndex ) +// ---------------------------------------------------------------------------- +// CContentRenderer::Clean +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::Clean( CHsContentPublisher& aPlugin, TInt aContent, + TInt aIndex ) { TInt error( KErrNone ); TInt retval( KErrNone ); @@ -656,16 +712,26 @@ return error; } +// ---------------------------------------------------------------------------- +// CContentRenderer::CContentRenderer +// +// ---------------------------------------------------------------------------- +// TAny* CContentRenderer::Extension( TUid /*aUid*/ ) { // No extensions supported return NULL; } +// ---------------------------------------------------------------------------- +// CContentRenderer::RequiresSubscription +// +// ---------------------------------------------------------------------------- +// TBool CContentRenderer::RequiresSubscription( - const TAiPublisherInfo& aPublisherInfo ) const + const THsPublisherInfo& aPublisherInfo ) const { - if ( aPublisherInfo.iNamespace == KNativeUiNamespace ) + if ( aPublisherInfo.Namespace() == KNativeUiNamespace ) { // Not targeted to this content renderer return EFalse; @@ -674,21 +740,867 @@ return ETrue; } -TInt CContentRenderer::SetProperty( MAiPropertyExtension& aPlugin, - const TDesC8& aElementId, - const TDesC8& aPropertyName, - const TDesC8& aPropertyValue ) +// ---------------------------------------------------------------------------- +// CContentRenderer::DoStartTransactionL +// +// ---------------------------------------------------------------------------- +// +void CContentRenderer::DoStartTransactionL( TInt aTxId ) + { + MTransaction* tr( iFactory->CreateTransactionL( aTxId ) ); + iStack->Push( tr ); + + SetImmediateMode( EFalse ); + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::CanPublishL +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::CanPublishL( CHsContentPublisher& aPlugin, + TInt aContent, TInt aIndex ) + { + // Get content item for aContent + MAiContentItemIterator* iter( ContentItemIterator( + aPlugin, CHsContentPublisher::EPublisherContent ) ); + + if ( !iter ) + { + return KErrNotSupported; + } + + const TAiContentItem& item( iter->ItemL( aContent ) ); + + // Lookup ui element + const TDesC& nodeId( iNodeIdGenerator->ContentNodeIdL( aPlugin, item ) ); + + CXnNodeAppIf* property( FindNodeByClassL( nodeId, aIndex, + aPlugin.PublisherInfo().Namespace() ) ); + + if( !property ) + { + return KErrNotFound; + } + + // Check content priority + TInt priority( ContentPriority( *property ) ); + + CXnNodeAppIf* target( property->ParentL() ); + + if( !target ) + { + return KErrNotSupported; + } + + if ( !AllowPublishByPriority( *target, priority ) ) + { + return KErrAccessDenied; + } + + // Check if content type is supported by target + const TDesC8& contentType( ContentType( item ) ); + + if ( !iFactory->IsSupported( *target, contentType ) && + target->Type()->Type() != XnPropertyNames::listquerydialog::KListQueryDialog ) + { + return KErrNotSupported; + } + + return KErrNone; + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::DoPublishL +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, + TInt aResource, TInt aIndex ) + { + TInt retval( KErrNotSupported ); + + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + // Read ref value. + MAiContentItemIterator* resIter( ContentItemIterator( + aPlugin, CHsContentPublisher::EPublisherResources ) ); + + if ( !resIter ) + { + return retval; + } + + const TAiContentItem& ref( resIter->ItemL( aResource ) ); + + const TDesC8& refType( ContentType( ref ) ); + + // Resolve source node + const TDesC& nodeId( iNodeIdGenerator->ResourceNodeIdL( aPlugin, ref ) ); + + HBufC8* nodeId8( CnvUtfConverter::ConvertFromUnicodeToUtf8L( nodeId ) ); + CleanupStack::PushL( nodeId8 ); + + CXnNodeAppIf* source( NULL ); + + __TIME_MARK( xmlOverhead ); + + source = FindNodeByIdL( *nodeId8, info.Namespace() ); + + __TIME_ENDMARK("XML UI: Lookup node by id", xmlOverhead); + __PRINT(__DBG_FORMAT("\t[I]\tXML UI: Lookup node by id=%S"), &nodeId); + + CleanupStack::PopAndDestroy( nodeId8 ); + + // Fetch content id + MAiContentItemIterator* iter( ContentItemIterator( + aPlugin, CHsContentPublisher::EPublisherContent ) ); + + if ( !iter ) + { + return retval; + } + + const TAiContentItem& item( iter->ItemL( aContent ) ); + + const TDesC& targetId( iNodeIdGenerator->ContentNodeIdL( aPlugin, item ) ); + + // Check types + if ( refType == KContentTypeText ) + { + // Fetch text + const TDesC8& text( source->GetPCData() ); + + // Delegate to data publishing function + retval = PublishDataL( aPlugin, + targetId, + text, + refType, + aIndex, + source ); + } + else if ( refType.Find( KContentTypeImage ) != KErrNotFound ) + { + // Fetch icon + CGulIcon* icon( LoadIconLC( *source ) ); + + // Delegate to icon publishing function + retval = PublishIconL( aPlugin, + targetId, + icon, + aIndex, + source ); + + CleanupStack::Pop( icon ); + } + + return retval; + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::DoPublishL +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, + const TDesC16& aText, TInt aIndex ) + { + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + // Resolve content item + MAiContentItemIterator* iter( ContentItemIterator( + aPlugin, CHsContentPublisher::EPublisherContent ) ); + + if ( !iter ) + { + return KErrNotSupported; + } + + const TAiContentItem& item( iter->ItemL( aContent ) ); + + const TDesC8& type( ContentType( item ) ); + + if ( type == KContentTypeText ) + { + // Find ui element + const TDesC& nodeId( + iNodeIdGenerator->ContentNodeIdL( aPlugin, item ) ); + + __TIME_MARK( xmlOverhead ); + + CXnNodeAppIf* property( FindNodeByClassL( + nodeId, aIndex, info.Namespace() ) ); + + if( !property ) + { + return KErrNotFound; + } + + TInt priority( ContentPriority( *property ) ); + + __TIME_ENDMARK("XML UI: Lookup node by class", xmlOverhead); + __PRINT(__DBG_FORMAT("\t[I]\tXML UI: Lookup node by class=%S"), &nodeId); + + //Navigate to parent + CXnNodeAppIf* target( property->ParentL() ); + + if( !target ) + { + return KErrNotSupported; + } + + // Check priority + if ( AllowPublishByPriority( *target, priority ) ) + { + // Check if target is newsticker + MTransactionElement* element( NULL ); + + if ( IsParentNewsticker( *target ) ) + { + // Register callback interface for newsticker + CXnNodeAppIf *parent( target->ParentL() ); + + if( !parent ) + { + return KErrNotFound; + } + + RegisterNewstickerCallbackInterfaceL( *parent ); + + iNTPublisher.Set( info.Name() ); + iNTClass = AiUtility::CopyToBufferL( iNTClass, nodeId ); + + element = iFactory->CreateNewsTickerTransactionElementL( + *target, aText, priority, aIndex ); + } + else if( target->Type()->Type() == + XnListQueryDialogInterface::MXnListQueryDialogInterface::Type()) + { + // Get the data interface for dialog and publish data + XnListQueryDialogInterface::MXnListQueryDialogInterface* listQuery( NULL ); + XnComponentInterface::MakeInterfaceL( listQuery, *target ); + LeaveIfNull( listQuery, KErrNotSupported ); + listQuery->ReplaceItemL( aText, aIndex -1 );// plugins publish ordinals not indexes + return KErrNone; + } + else + { + // Create transaction element for text + // Not put to cleanupstack, because element is from our pool! + element = iFactory->CreateTextTransactionElementL( *target, + aText, + priority ); + } + + iPolicyEvaluator->EvaluateContentPolicyL( + *target, element->PolicyArray() ); + + iPolicyEvaluator->EvaluateVisibilityPolicyL( + *target, element->PolicyArray() ); + + ProcessTransactionElementL( element ); + } + else + { + return KErrAccessDenied; + } + } + else + { + return KErrNotSupported; + } + + return KErrNone; + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::DoPublishL +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, + const TDesC8& aBuf, TInt aIndex ) + { + TInt retval( KErrNotSupported ); + + // resolve content item + MAiContentItemIterator* iter( ContentItemIterator( + aPlugin, CHsContentPublisher::EPublisherContent ) ); + + if ( !iter ) + { + return retval; + } + + const TAiContentItem& item( iter->ItemL( aContent ) ); + + const TDesC8& type( ContentType( item ) ); + + const TDesC& nodeId( iNodeIdGenerator->ContentNodeIdL( aPlugin, item ) ); + + if( type == KContentTypeBitmap ) + { + // Unpack icon from pointer + CGulIcon* icon( LeaveIfNull( UnpackPtr( aBuf ), KErrArgument ) ); + + // Publish icon + retval = PublishIconL( aPlugin, nodeId, icon, aIndex ); + } + else if ( type == KContentTypeImageSvg || + type == KContentTypeData ) + { + // Publish data + retval = PublishDataL( aPlugin, nodeId, aBuf, type, aIndex ); + } + + return retval; + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::DoPublishL +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::DoPublishL( CHsContentPublisher& aPlugin, TInt aContent, + RFile& aFile, TInt aIndex ) + { + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + //Resolve content item + MAiContentItemIterator* iter( ContentItemIterator( + aPlugin, CHsContentPublisher::EPublisherContent ) ); + + if ( !iter ) + { + return KErrNotSupported; + } + + const TAiContentItem& item( iter->ItemL( aContent ) ); + + const TDesC8& type( ContentType( item ) ); + + // Image support + if ( type.Find( KContentTypeImage ) != KErrNotFound ) + { + // Find ui element + const TDesC& nodeId( iNodeIdGenerator->ContentNodeIdL( aPlugin, item ) ); + + CXnNodeAppIf* property( FindNodeByClassL( + nodeId, aIndex, info.Namespace() ) ); + + if( !property ) + { + return KErrNotFound; + } + + // Check priority + TInt priority( ContentPriority( *property ) ); + + CXnNodeAppIf* target( property->ParentL() ); + + if( !target ) + { + return KErrNotSupported; + } + + if ( AllowPublishByPriority( *target, priority ) ) + { + // Check if target is newsticker + if ( IsParentNewsticker( *target ) ) + { + // Register callback interface + CXnNodeAppIf *parent( target->ParentL() ); + + if( !parent ) + { + return KErrNotFound; + } + + RegisterNewstickerCallbackInterfaceL( *parent ); + + iNTPublisher.Set( info.Name() ); + iNTClass = AiUtility::CopyToBufferL( iNTClass, nodeId ); + } + + // Create transaction element for file + MTransactionElement* element = + iFactory->CreateImageTransactionElementL( + *target, aFile, priority ); + + iPolicyEvaluator->EvaluateContentPolicyL( + *target, element->PolicyArray() ); + + iPolicyEvaluator->EvaluateVisibilityPolicyL( + *target, element->PolicyArray() ); + + ProcessTransactionElementL( element ); + } + else + { + return KErrAccessDenied; + } + } + else + { + return KErrNotSupported; + } + + return KErrNone; + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::DoCleanL +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::DoCleanL( CHsContentPublisher& aPlugin, TInt aContent, + TInt aIndex ) + { + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + // Resolve content item + MAiContentItemIterator* iter( ContentItemIterator( + aPlugin, CHsContentPublisher::EPublisherContent ) ); + + if ( !iter ) + { + return KErrNotSupported; + } + + const TAiContentItem& item( iter->ItemL( aContent ) ); + + const TDesC& nodeId( iNodeIdGenerator->ContentNodeIdL( aPlugin, item ) ); + + CXnNodeAppIf* property( FindNodeByClassL( + nodeId, aIndex, info.Namespace() ) ); + + if( !property ) + { + return KErrNotFound; + } + + TInt priority( ContentPriority( *property ) ); + + // Navigate to parent + CXnNodeAppIf* target( property->ParentL() ); + + if( !target ) + { + return KErrNotSupported; + } + + if ( !AllowPublishByPriority( *target, priority ) ) + { + return KErrAccessDenied; + } + + if ( IsParentNewsticker( *target ) ) + { + CXnNodeAppIf *parent( target->ParentL() ); + + if( !parent ) + { + return KErrNotFound; + } + + RegisterNewstickerCallbackInterfaceL( *parent ); + + iNTPublisher.Set( info.Name() ); + iNTClass = AiUtility::CopyToBufferL( iNTClass, nodeId ); + } + + if( target->Type()->Type() == + XnListQueryDialogInterface::MXnListQueryDialogInterface::Type()) + { + // Get the data interface for dialog and delete data + XnListQueryDialogInterface::MXnListQueryDialogInterface* listQuery( NULL ); + XnComponentInterface::MakeInterfaceL( listQuery, *target ); + LeaveIfNull( listQuery, KErrNotSupported ); + listQuery->DeleteItem( aIndex -1 );// plugins publish ordinals not indexes + return KErrNone; + } + + // Create transaction element for empty content + MTransactionElement* element = + iFactory->CreateEmptyContentTransactionElementL( + *target, aIndex ); + + iPolicyEvaluator->EvaluateEmptyContentPolicyL( + *target, element->PolicyArray() ); + + iPolicyEvaluator->EvaluateVisibilityPolicyL( + *target, element->PolicyArray() ); + + ProcessTransactionElementL( element ); + + if ( priority > KErrNotFound ) // Only for prioritized elements + { + // Add current ui element into content refresh map + HBufC* uiElementId( PropertyValueL( + *target, XnPropertyNames::common::KId ) ); + + return RefreshContentL( uiElementId, priority ); + } + + return KErrNone; + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::SetImmediateMode +// +// ---------------------------------------------------------------------------- +// +void CContentRenderer::SetImmediateMode( TBool aImmediateMode ) + { + iImmediateMode = aImmediateMode; + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::IsImmediateMode +// +// ---------------------------------------------------------------------------- +// +TBool CContentRenderer::IsImmediateMode() const + { + return iImmediateMode; + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::ProcessTransactionElementL +// +// ---------------------------------------------------------------------------- +// +void CContentRenderer::ProcessTransactionElementL( + MTransactionElement* aElement ) + { + LeaveIfNull( aElement, KErrArgument ); + + if ( IsImmediateMode() || iStack->IsEmpty() ) + { + // No transaction. Commit element immediately + TBool layoutChanged( EFalse ); + + RPropertyHashMap propertyHashMap; + CleanupClosePushL( propertyHashMap ); + + aElement->CommitL( layoutChanged, propertyHashMap ); + SetPropertyArraysL( propertyHashMap ); + + CleanupStack::PopAndDestroy( &propertyHashMap ); + + iFactory->ReleaseTransactionElement( aElement ); + StartContentRefresh(); + + // Re-layout + iAppUi.UiEngineL()->RenderUIL(); + } + else + { + // Append transaction element to transaction + MTransaction* tr( iStack->Top() ); + tr->Append( *aElement ); + } + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::FindNodeByClassL +// +// ---------------------------------------------------------------------------- +// +CXnNodeAppIf* CContentRenderer::FindNodeByClassL( const TDesC& aCid, + TInt aIndex, const TDesC8& aNs ) + { + // Find node + HBufC8* classId( CnvUtfConverter::ConvertFromUnicodeToUtf8L( aCid ) ); + CleanupStack::PushL( classId ); + + RPointerArray nodes( + iAppUi.UiEngineL()->FindNodeByClassL( *classId, aNs ) ); + + CleanupStack::PopAndDestroy( classId ); + + CleanupClosePushL( nodes ); + + for ( TInt i = 0; i < nodes.Count(); ++i ) + { + CXnNodeAppIf* node = nodes[i]; + + const TDesC8* name( + PropertyValue( *node, AiUiDef::xml::property::KName ) ); + + if ( name && ( *name == AiUiDef::xml::name::KOrdinal ) ) + { + const TDesC8* value( + PropertyValue( *node, AiUiDef::xml::property::KValue ) ); + + if ( value ) + { + // Try to parse index from string either + TInt32 index( 0 ); + + User::LeaveIfError( AiUtility::ParseInt( index, *value ) ); + + if ( index == aIndex ) + { + CleanupStack::PopAndDestroy( &nodes ); + + return node; + } + } + } + else if ( name && ( *name == AiUiDef::xml::name::KTarget ) ) + { + const TDesC8* target( + PropertyValue( *node, AiUiDef::xml::property::KValue ) ); + + CXnNodeAppIf* targetNode( + FindNodeByIdL( *target, node->Namespace() ) ); + + if ( targetNode ) + { + CleanupStack::PopAndDestroy( &nodes ); + + return targetNode; + } + } + else if ( nodes.Count() == 1 ) // Only one node in class + { + node = nodes[ 0 ]; + + // No ordinal specified + CleanupStack::PopAndDestroy( &nodes ); + + return node; + } + } + + CleanupStack::PopAndDestroy( &nodes ); + + return NULL; // Never reached. Needed to omit compiler warning + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::FindNodeByIdL +// +// ---------------------------------------------------------------------------- +// +CXnNodeAppIf* CContentRenderer::FindNodeByIdL( const TDesC& aCid, + const TDesC& aNs ) + { + // Find node + return LeaveIfNull( + iAppUi.UiEngineL()->FindNodeByIdL( aCid, aNs ), KErrNotFound ); + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::FindNodeByIdL +// +// ---------------------------------------------------------------------------- +// +CXnNodeAppIf* CContentRenderer::FindNodeByIdL( const TDesC8& aCid, + const TDesC8& aNs ) + { + // Find node + return LeaveIfNull( + iAppUi.UiEngineL()->FindNodeByIdL( aCid, aNs ), KErrNotFound ); + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::PublishIconL +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::PublishIconL( CHsContentPublisher& aPlugin, + const TDesC& aCid, CGulIcon* aIcon, TInt aIndex, CXnNodeAppIf* aResource ) + { + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + // Find proiperty element by class + CXnNodeAppIf* property( + FindNodeByClassL( aCid, aIndex, info.Namespace() ) ); + + if( !property ) + { + return KErrNotFound; + } + + // Get priority information + TInt priority( ContentPriority( *property ) ); + + // Navigate to parent + CXnNodeAppIf* target( property->ParentL() ); + + if( !target ) + { + return KErrNotFound; + } + + // Check priority + if ( !AllowPublishByPriority( *target, priority ) ) + { + return KErrAccessDenied; + } + + // Special handling of newsticker + if ( IsParentNewsticker( *target ) ) + { + // Register callback interface + CXnNodeAppIf *parent( target->ParentL() ); + + if( !parent ) + { + return KErrNotFound; + } + + RegisterNewstickerCallbackInterfaceL( *parent ); + + iNTPublisher.Set( info.Name() ); + iNTClass = AiUtility::CopyToBufferL( iNTClass, aCid ); + } + + MTransactionElement* element = + iFactory->CreateImageTransactionElementL( + *target, aIcon, priority ); + + if ( aResource ) + { + iPolicyEvaluator->EvaluateResourcePolicyL( + *target, *aResource, element->PolicyArray() ); + + iPolicyEvaluator->EvaluateContentPolicyL( + *target, element->PolicyArray() ); + + iPolicyEvaluator->EvaluateVisibilityPolicyL( + *target, element->PolicyArray() ); + } + + else + { + iPolicyEvaluator->EvaluateContentPolicyL( + *target, element->PolicyArray() ); + + iPolicyEvaluator->EvaluateVisibilityPolicyL( + *target, element->PolicyArray() ); + } + + ProcessTransactionElementL( element ); + + return KErrNone; + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::PublishDataL +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::PublishDataL( CHsContentPublisher& aPlugin, + const TDesC& aCid, const TDesC8& aData, const TDesC8& aContentType, + TInt aIndex, CXnNodeAppIf* aResource ) + { + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + CXnNodeAppIf* property( + FindNodeByClassL( aCid, aIndex, info.Namespace() ) ); + + if( !property ) + { + return KErrNotFound; + } + + TInt priority( ContentPriority( *property ) ); + + // Navigate to parent + CXnNodeAppIf* target( property->ParentL() ); + + if( !target ) + { + return KErrNotFound; + } + + if ( !AllowPublishByPriority( *target, priority ) ) + { + return KErrAccessDenied; + } + + if( aContentType == KContentTypeData ) + { + CXnComponent& component( target->ParentL()->Component() ); + component.SetDataL( aData, aCid, aIndex ); + return KErrNone; + } + + if ( !CDataBufferTransactionElement::IsSupported( *target, aContentType ) ) + { + return KErrNotSupported; + } + + // Handle newsticker + if ( IsParentNewsticker( *target ) ) + { + CXnNodeAppIf *parent( target->ParentL() ); + + if( !parent ) + { + return KErrNotFound; + } + + RegisterNewstickerCallbackInterfaceL( *parent ); + + iNTPublisher.Set( info.Name() ); + iNTClass = AiUtility::CopyToBufferL( iNTClass, aCid ); + } + + MTransactionElement* element = + iFactory->CreateDataBufferTransactionElementL( + *target, aData, priority ); + + if ( aResource ) + { + iPolicyEvaluator->EvaluateResourcePolicyL( + *target, *aResource, element->PolicyArray() ); + + iPolicyEvaluator->EvaluateContentPolicyL( + *target, element->PolicyArray() ); + + iPolicyEvaluator->EvaluateVisibilityPolicyL( + *target, element->PolicyArray() ); + } + else + { + iPolicyEvaluator->EvaluateContentPolicyL( + *target, element->PolicyArray() ); + + iPolicyEvaluator->EvaluateVisibilityPolicyL( + *target, element->PolicyArray() ); + } + + ProcessTransactionElementL( element ); + + return KErrNone; + } + +// ---------------------------------------------------------------------------- +// CContentRenderer::SetProperty +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::SetProperty( CHsContentPublisher& aPlugin, + const TDesC8& aElementId, const TDesC8& aPropertyName, + const TDesC8& aPropertyValue ) { return ( SetProperty( aPlugin, aElementId, aPropertyName, aPropertyValue, MAiContentObserver::EValueString ) ); } -TInt CContentRenderer::SetProperty( MAiPropertyExtension& aPlugin, - const TDesC8& aElementId, - const TDesC8& aPropertyName, - const TDesC8& aPropertyValue, - MAiContentObserver::TValueType aValueType) +// ---------------------------------------------------------------------------- +// CContentRenderer::SetProperty +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::SetProperty( CHsContentPublisher& aPlugin, + const TDesC8& aElementId, const TDesC8& aPropertyName, + const TDesC8& aPropertyValue, MAiContentObserver::TValueType aValueType ) { TInt error( KErrNone ); TInt retval( KErrNone ); @@ -704,15 +1616,21 @@ return error; } -TInt CContentRenderer::SetPropertyL( MAiPropertyExtension& aPlugin, - const TDesC8& aElementId, - const TDesC8& aPropertyName, - const TDesC8& aPropertyValue, - MAiContentObserver::TValueType aValueType) +// ---------------------------------------------------------------------------- +// CContentRenderer::SetPropertyL +// +// ---------------------------------------------------------------------------- +// +TInt CContentRenderer::SetPropertyL( CHsContentPublisher& aPlugin, + const TDesC8& aElementId, const TDesC8& aPropertyName, + const TDesC8& aPropertyValue, MAiContentObserver::TValueType aValueType ) { - TInt err = KErrNone; + TInt err( KErrNone ); // Find node - CXnNodeAppIf* targetNode = FindNodeByIdL( aElementId, aPlugin.PublisherInfoL()->iNamespace ); + + CXnNodeAppIf* targetNode( + FindNodeByIdL( aElementId, aPlugin.PublisherInfo().Namespace() ) ); + if ( targetNode ) { CXnDomStringPool& sp( targetNode->UiEngineL()->StringPool() ); @@ -732,16 +1650,21 @@ { err = KErrNotFound; } + return err; } - -CXnDomPropertyValue::TPrimitiveValueType - CContentRenderer::DomPropertyValueType( - MAiContentObserver::TValueType aValueType) +// ---------------------------------------------------------------------------- +// CContentRenderer::DomPropertyValueType +// +// ---------------------------------------------------------------------------- +// +CXnDomPropertyValue::TPrimitiveValueType CContentRenderer::DomPropertyValueType( + MAiContentObserver::TValueType aValueType ) { - CXnDomPropertyValue::TPrimitiveValueType type = - CXnDomPropertyValue::EUnknown; + CXnDomPropertyValue::TPrimitiveValueType type( + CXnDomPropertyValue::EUnknown ); + switch ( aValueType ) { case MAiContentObserver::EValueNumber : @@ -779,755 +1702,37 @@ type = CXnDomPropertyValue::EUnknown; } } + return type; } -void CContentRenderer::DoStartTransactionL( TInt aTxId ) - { - MTransaction* tr = iFactory->CreateTransactionL( aTxId ); - iStack->Push(tr); - SetImmediateMode(EFalse); - } - -TInt CContentRenderer::CanPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aIndex ) - { - // Get content item for aContent - MAiContentItemIterator& iter( - ContentItemIteratorL( aPlugin, EAiPublisherContent ) ); - - const TAiContentItem& item( iter.ItemL( aContent ) ); - - // Lookup ui element - const TDesC& nodeId( iNodeIdGenerator->ContentNodeIdL( aPlugin, item ) ); - - CXnNodeAppIf* property( FindNodeByClassL( nodeId, aIndex, - aPlugin.PublisherInfoL()->iNamespace ) ); - - if( !property ) - { - return KErrNotFound; - } - - // Check content priority - TInt priority( GetContentPriority( *property ) ); - - CXnNodeAppIf* target( property->ParentL() ); - - if( !target ) - { - return KErrNotSupported; - } - - if ( !AllowPublishByPriority( *target, priority ) ) - { - return KErrAccessDenied; - } - - // Check if content type is supported by target - const TDesC8& contentType( ContentType( item ) ); - - if ( !iFactory->IsSupported( *target, contentType ) && - target->Type()->Type() != XnPropertyNames::listquerydialog::KListQueryDialog ) - { - return KErrNotSupported; - } - - return KErrNone; - } - -TInt CContentRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aResource, - TInt aIndex ) - { - TAiPublisherInfo *info = static_cast(aPlugin.GetPropertyL( EAiPublisherInfo )); - if (!info) - { - return KErrNotFound; - } - // Read ref value. - MAiContentItemIterator& refIter( ContentItemIteratorL( aPlugin, EAiPublisherResources ) ); - const TAiContentItem& ref( refIter.ItemL( aResource ) ); - - const TDesC8& refType( ContentType( ref ) ); - - // Resolve source node - const TDesC& nodeId = iNodeIdGenerator->ResourceNodeIdL(aPlugin, ref); - HBufC8* nodeId8 = CnvUtfConverter::ConvertFromUnicodeToUtf8L(nodeId); - CleanupStack::PushL(nodeId8); - CXnNodeAppIf* source = NULL; - __TIME_MARK(xmlOverhead); - source = FindNodeByIdL( *nodeId8, info->iNamespace ); - __TIME_ENDMARK("XML UI: Lookup node by id", xmlOverhead); - __PRINT(__DBG_FORMAT("\t[I]\tXML UI: Lookup node by id=%S"), &nodeId); - - CleanupStack::PopAndDestroy(nodeId8); - - // Fetch content id - MAiContentItemIterator& iter = ContentItemIteratorL( aPlugin, EAiPublisherContent ); - const TAiContentItem& item = iter.ItemL( aContent ); - - const TDesC& targetId = iNodeIdGenerator->ContentNodeIdL(aPlugin, item); - - TInt retval( KErrNotSupported ); - - // Check types - if ( refType == KContentTypeText ) - { - // Fetch text - const TDesC8& text = source->GetPCData(); - - // Delegate to data publishing function - retval = PublishDataL( aPlugin, - targetId, - text, - refType, - aIndex, - source ); - } - else if ( refType.Find( KContentTypeImage ) != KErrNotFound ) - { - // Fetch icon - CGulIcon* icon = LoadIconLC( *source ); - - // Delegate to icon publishing function - retval = PublishIconL( aPlugin, - targetId, - icon, - aIndex, - source ); - - CleanupStack::Pop( icon ); - } - - return retval; - } - -TInt CContentRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC16& aText, - TInt aIndex ) - { - // Resolve content item - MAiContentItemIterator& iter( - ContentItemIteratorL( aPlugin, EAiPublisherContent ) ); - - const TAiContentItem& item( iter.ItemL( aContent ) ); - - const TDesC8& type( ContentType( item ) ); - - if ( type == KContentTypeText ) - { - // Find ui element - const TDesC& nodeId = iNodeIdGenerator->ContentNodeIdL( aPlugin, item ); - - __TIME_MARK(xmlOverhead); - - CXnNodeAppIf* property( FindNodeByClassL( nodeId, aIndex, - aPlugin.PublisherInfoL()->iNamespace ) ); - - if( !property ) - { - return KErrNotFound; - } - - TInt priority( GetContentPriority( *property ) ); - - __TIME_ENDMARK("XML UI: Lookup node by class", xmlOverhead); - __PRINT(__DBG_FORMAT("\t[I]\tXML UI: Lookup node by class=%S"), &nodeId); - - //Navigate to parent - CXnNodeAppIf* target( property->ParentL() ); - - if( !target ) - { - return KErrNotSupported; - } - - // Check priority - if ( AllowPublishByPriority( *target, priority ) ) - { - // Check if target is newsticker - MTransactionElement* element( NULL ); - - if ( IsParentNewsticker( *target ) ) - { - // Register callback interface for newsticker - CXnNodeAppIf *parent( target->ParentL() ); - - if( !parent ) - { - return KErrNotFound; - } - - RegisterNewstickerCallbackInterfaceL( *parent ); - - const TAiPublisherInfo* info( aPlugin.PublisherInfoL() ); - - if ( info ) - { - iNTPublisher.Set( info->iName ); - iNTClass = AiUtility::CopyToBufferL( iNTClass, nodeId ); - } - - element = iFactory->CreateNewsTickerTransactionElementL( *target, - aText, - priority, - aIndex ); - } - else if( target->Type()->Type() == - XnListQueryDialogInterface::MXnListQueryDialogInterface::Type()) - { - // Get the data interface for dialog and publish data - XnListQueryDialogInterface::MXnListQueryDialogInterface* listQuery( NULL ); - XnComponentInterface::MakeInterfaceL( listQuery, *target ); - LeaveIfNull( listQuery, KErrNotSupported ); - listQuery->ReplaceItemL( aText, aIndex -1 );// plugins publish ordinals not indexes - return KErrNone; - } - else - { - // Create transaction element for text - // Not put to cleanupstack, because element is from our pool! - element = iFactory->CreateTextTransactionElementL( *target, - aText, - priority ); - } - - iPolicyEvaluator->EvaluateContentPolicyL( *target, - element->PolicyArray() ); - iPolicyEvaluator->EvaluateVisibilityPolicyL( *target, - element->PolicyArray() ); - - ProcessTransactionElementL( element ); - } - else - { - return KErrAccessDenied; - } - } - else - { - return KErrNotSupported; - } - - return KErrNone; - } - -TInt CContentRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - const TDesC8& aBuf, - TInt aIndex ) - { - // resolve content item - MAiContentItemIterator& iter( - ContentItemIteratorL( aPlugin, EAiPublisherContent ) ); - - const TAiContentItem& item( iter.ItemL( aContent ) ); - - const TDesC8& type( ContentType( item ) ); - - TInt retval( KErrNotSupported ); - - if( type == KContentTypeBitmap ) - { - // Unpack icon from pointer - CGulIcon* icon( LeaveIfNull( UnpackPtr( aBuf ), KErrArgument ) ); - - const TDesC& nodeId( iNodeIdGenerator->ContentNodeIdL( aPlugin, item ) ); - - // Publish icon - retval = PublishIconL( aPlugin, nodeId, icon, aIndex ); - } - else if ( type == KContentTypeImageSvg ) - { - // Get node id - const TDesC& nodeId( iNodeIdGenerator->ContentNodeIdL( aPlugin, item ) ); - - // Publish SVG data - retval = PublishDataL( aPlugin, nodeId, aBuf, KContentTypeImageSvg, aIndex ); - } - - return retval; - } - -TInt CContentRenderer::DoPublishL( MAiPropertyExtension& aPlugin, - TInt aContent, - RFile& aFile, - TInt aIndex) - { - //Resolve content item - MAiContentItemIterator& iter( - ContentItemIteratorL( aPlugin, EAiPublisherContent ) ); - - const TAiContentItem& item( iter.ItemL( aContent ) ); - - const TDesC8& type( ContentType( item ) ); - - // Image support - if ( type.Find( KContentTypeImage ) != KErrNotFound ) - { - // Find ui element - const TDesC& nodeId( iNodeIdGenerator->ContentNodeIdL( aPlugin, item ) ); - - CXnNodeAppIf* property( FindNodeByClassL( nodeId, aIndex, - aPlugin.PublisherInfoL()->iNamespace ) ); - - if( !property ) - { - return KErrNotFound; - } - - // Check priority - TInt priority( GetContentPriority( *property ) ); - - CXnNodeAppIf* target( property->ParentL() ); - - if( !target ) - { - return KErrNotSupported; - } - - if ( AllowPublishByPriority( *target, priority ) ) - { - // Check if target is newsticker - if ( IsParentNewsticker( *target ) ) - { - // Register callback interface - CXnNodeAppIf *parent( target->ParentL() ); - - if( !parent ) - { - return KErrNotFound; - } - - RegisterNewstickerCallbackInterfaceL( *parent ); - - const TAiPublisherInfo* info( aPlugin.PublisherInfoL() ); - - if( info ) - { - iNTPublisher.Set( info->iName ); - iNTClass = AiUtility::CopyToBufferL( iNTClass, nodeId ); - } - } - - // Create transaction element for file - MTransactionElement* element = - iFactory->CreateImageTransactionElementL( *target, - aFile, - priority ); - - iPolicyEvaluator->EvaluateContentPolicyL( *target, - element->PolicyArray() ); - iPolicyEvaluator->EvaluateVisibilityPolicyL( *target, - element->PolicyArray() ); - - ProcessTransactionElementL( element ); - } - else - { - return KErrAccessDenied; - } - } - else - { - return KErrNotSupported; - } - - return KErrNone; - } - -TInt CContentRenderer::DoCleanL( MAiPropertyExtension& aPlugin, - TInt aContent, - TInt aIndex ) - { - // Resolve content item - MAiContentItemIterator& iter( - ContentItemIteratorL( aPlugin, EAiPublisherContent ) ); - - const TAiContentItem& item( iter.ItemL( aContent ) ); - - const TDesC& nodeId( iNodeIdGenerator->ContentNodeIdL( aPlugin, item ) ); - - CXnNodeAppIf* property( FindNodeByClassL( nodeId, aIndex, - aPlugin.PublisherInfoL()->iNamespace ) ); - - if( !property ) - { - return KErrNotFound; - } - - TInt priority( GetContentPriority( *property ) ); - - // Navigate to parent - CXnNodeAppIf* target( property->ParentL() ); - - if( !target ) - { - return KErrNotSupported; - } - - if ( !AllowPublishByPriority( *target, priority ) ) - { - return KErrAccessDenied; - } - - if ( IsParentNewsticker( *target ) ) - { - CXnNodeAppIf *parent( target->ParentL() ); - - if( !parent ) - { - return KErrNotFound; - } - - RegisterNewstickerCallbackInterfaceL( *parent ); - - const TAiPublisherInfo* info( aPlugin.PublisherInfoL() ); - - if( info ) - { - iNTPublisher.Set( info->iName ); - iNTClass = AiUtility::CopyToBufferL( iNTClass, nodeId ); - } - } - if( target->Type()->Type() == - XnListQueryDialogInterface::MXnListQueryDialogInterface::Type()) - { - // Get the data interface for dialog and delete data - XnListQueryDialogInterface::MXnListQueryDialogInterface* listQuery( NULL ); - XnComponentInterface::MakeInterfaceL( listQuery, *target ); - LeaveIfNull( listQuery, KErrNotSupported ); - listQuery->DeleteItem( aIndex -1 );// plugins publish ordinals not indexes - return KErrNone; - } - - // Create transaction element for empty content - MTransactionElement* element = - iFactory->CreateEmptyContentTransactionElementL( *target, aIndex ); - - iPolicyEvaluator->EvaluateEmptyContentPolicyL( *target, - element->PolicyArray() ); - iPolicyEvaluator->EvaluateVisibilityPolicyL( *target, - element->PolicyArray() ); - - ProcessTransactionElementL( element ); - - if ( priority > KErrNotFound ) // Only for prioritized elements - { - // Add current ui element into content refresh map - HBufC* uiElementId = PropertyValueL( *target, - XnPropertyNames::common::KId ); - return RefreshContentL( uiElementId, priority ); - } - - return KErrNone; - } - -void CContentRenderer::SetImmediateMode( TBool aImmediateMode ) - { - iImmediateMode = aImmediateMode; - } - -TBool CContentRenderer::IsImmediateMode() const - { - return iImmediateMode; - } - -void CContentRenderer::ProcessTransactionElementL( MTransactionElement* aElement ) - { - LeaveIfNull( aElement, KErrArgument ); - - if ( IsImmediateMode() || iStack->IsEmpty() ) - { - // No transaction. Commit element immediately - TBool layoutChanged = EFalse; - - RPropertyHashMap propertyHashMap; - aElement->CommitL(layoutChanged, propertyHashMap); - SetPropertyArraysL( propertyHashMap ); - propertyHashMap.Close(); - - iFactory->ReleaseTransactionElement( aElement ); - StartContentRefresh(); - - // Re-layout - iAppUi.UiEngineL()->RenderUIL(); - } - else - { - // Append transaction element to transaction - MTransaction* tr = iStack->Top(); - tr->Append( *aElement ); - } - } - -CXnNodeAppIf* CContentRenderer::FindNodeByClassL( const TDesC& aCid, - TInt aIndex, - const TDesC8& aNs ) - { - // Find node - HBufC8* classId = CnvUtfConverter::ConvertFromUnicodeToUtf8L(aCid); - CleanupStack::PushL(classId); - - RPointerArray nodes = iAppUi.UiEngineL()->FindNodeByClassL( *classId, aNs ); - - CleanupStack::PopAndDestroy(classId); - - CleanupClosePushL( nodes ); - - for ( TInt i = 0; i < nodes.Count(); ++i ) - { - CXnNodeAppIf* node = nodes[i]; - - const TDesC8* name = - PropertyValue( *node, AiUiDef::xml::property::KName ); - - if ( name && ( *name == AiUiDef::xml::name::KOrdinal ) ) - { - const TDesC8* value = - PropertyValue( *node, AiUiDef::xml::property::KValue ); - - if ( value ) - { - // Try to parse index from string either - - TInt32 index( 0 ); - User::LeaveIfError( AiUtility::ParseInt( index, *value ) ); - - if ( index == aIndex ) - { - CleanupStack::PopAndDestroy(&nodes); - return node; - } - } - } - else if ( name && ( *name == AiUiDef::xml::name::KTarget ) ) - { - const TDesC8* target = - PropertyValue( *node, AiUiDef::xml::property::KValue ); - - CXnNodeAppIf* targetNode = FindNodeByIdL( *target, node->Namespace() ); - if ( targetNode ) - { - CleanupStack::PopAndDestroy( &nodes ); - return targetNode; - } - } - else if ( nodes.Count() == 1 ) // Only one node in class - { - // No ordinal specified - node = nodes[ 0 ]; - CleanupStack::PopAndDestroy(&nodes); - return node; - } - } - - CleanupStack::PopAndDestroy( &nodes ); - - return NULL; // Never reached. Needed to omit compiler warning - } - -CXnNodeAppIf* CContentRenderer::FindNodeByIdL( const TDesC& aCid, const TDesC& aNs ) - { - // Find node - return LeaveIfNull( iAppUi.UiEngineL()->FindNodeByIdL( aCid, aNs ), - KErrNotFound ); - } - -CXnNodeAppIf* CContentRenderer::FindNodeByIdL( const TDesC8& aCid, const TDesC8& aNs ) - { - // Find node - return LeaveIfNull( iAppUi.UiEngineL()->FindNodeByIdL( aCid, aNs ), - KErrNotFound ); - } - -TInt CContentRenderer::PublishIconL( MAiPropertyExtension& aPlugin, - const TDesC& aCid, - CGulIcon* aIcon, - TInt aIndex, - CXnNodeAppIf* aResource ) - { - // Find proiperty element by class - CXnNodeAppIf* property( FindNodeByClassL( aCid, aIndex, - aPlugin.PublisherInfoL()->iNamespace ) ); - - if( !property ) - { - return KErrNotFound; - } - - // Get priority information - TInt priority( GetContentPriority( *property ) ); - - // Navigate to parent - CXnNodeAppIf* target( property->ParentL() ); - - if( !target ) - { - return KErrNotFound; - } - - // Check priority - if ( !AllowPublishByPriority( *target, priority ) ) - { - return KErrAccessDenied; - } - - // Special handling of newsticker - if ( IsParentNewsticker( *target ) ) - { - // Register callback interface - CXnNodeAppIf *parent( target->ParentL() ); - - if( !parent ) - { - return KErrNotFound; - } - - RegisterNewstickerCallbackInterfaceL( *parent ); - - const TAiPublisherInfo* info( aPlugin.PublisherInfoL() ); - - if( info ) - { - iNTPublisher.Set( info->iName ); - iNTClass = AiUtility::CopyToBufferL( iNTClass, aCid ); - } - } - - MTransactionElement* element = - iFactory->CreateImageTransactionElementL( *target, - aIcon, - priority ); - - if ( aResource ) - { - iPolicyEvaluator->EvaluateResourcePolicyL( *target, - *aResource, - element->PolicyArray() ); - iPolicyEvaluator->EvaluateContentPolicyL( *target, - element->PolicyArray() ); - iPolicyEvaluator->EvaluateVisibilityPolicyL( *target, - element->PolicyArray() ); - } - - else - { - iPolicyEvaluator->EvaluateContentPolicyL( *target, - element->PolicyArray() ); - iPolicyEvaluator->EvaluateVisibilityPolicyL( *target, - element->PolicyArray() ); - } - - ProcessTransactionElementL( element ); - - return KErrNone; - } - -TInt CContentRenderer::PublishDataL( MAiPropertyExtension& aPlugin, - const TDesC& aCid, - const TDesC8& aData, - const TDesC8& aContentType, - TInt aIndex, - CXnNodeAppIf* aResource ) - { - CXnNodeAppIf* property( FindNodeByClassL( aCid, aIndex, - aPlugin.PublisherInfoL()->iNamespace ) ); - - if( !property ) - { - return KErrNotFound; - } - - TInt priority( GetContentPriority( *property ) ); - - // Navigate to parent - CXnNodeAppIf* target( property->ParentL() ); - - if( !target ) - { - return KErrNotFound; - } - - if ( !AllowPublishByPriority( *target, priority ) ) - { - return KErrAccessDenied; - } - - if ( !CDataBufferTransactionElement::IsSupported( *target, aContentType ) ) - { - return KErrNotSupported; - } - - // Handle newsticker - if ( IsParentNewsticker( *target ) ) - { - CXnNodeAppIf *parent( target->ParentL() ); - - if( !parent ) - { - return KErrNotFound; - } - - RegisterNewstickerCallbackInterfaceL( *parent ); - - const TAiPublisherInfo* info( aPlugin.PublisherInfoL() ); - - if( info ) - { - iNTPublisher.Set( info->iName ); - iNTClass = AiUtility::CopyToBufferL( iNTClass, aCid ); - } - } - - MTransactionElement* element = - iFactory->CreateDataBufferTransactionElementL( *target, - aData, - priority ); - - if ( aResource ) - { - iPolicyEvaluator->EvaluateResourcePolicyL( *target, - *aResource, - element->PolicyArray() ); - iPolicyEvaluator->EvaluateContentPolicyL( *target, - element->PolicyArray() ); - iPolicyEvaluator->EvaluateVisibilityPolicyL( *target, - element->PolicyArray() ); - } - else - { - iPolicyEvaluator->EvaluateContentPolicyL( *target, - element->PolicyArray() ); - iPolicyEvaluator->EvaluateVisibilityPolicyL( *target, - element->PolicyArray() ); - } - - ProcessTransactionElementL( element ); - - return KErrNone; - } - +// ---------------------------------------------------------------------------- +// CContentRenderer::AllowPublishByPriority +// +// ---------------------------------------------------------------------------- +// TBool CContentRenderer::AllowPublishByPriority( CXnNodeAppIf& aUiElement, - TInt aPriority ) const + TInt aPriority ) const { // Get ui element id - const TDesC8* uiElementId = PropertyValue( aUiElement, - XnPropertyNames::common::KId ); - + const TDesC8* uiElementId( + PropertyValue( aUiElement, XnPropertyNames::common::KId ) ); + if ( uiElementId ) { // compare given priority with the current value of ui element return iContentPriorityMap->OverrideContent( *uiElementId, aPriority ); } - return EFalse; // priority cannot be used, because ui element does not have id + // priority cannot be used, because ui element does not have id + return EFalse; } +// ---------------------------------------------------------------------------- +// CContentRenderer::StartContentRefresh +// +// ---------------------------------------------------------------------------- +// void CContentRenderer::StartContentRefresh() { // Cancel ongoing refresh @@ -1542,14 +1747,13 @@ } } -/** - * Adds ui element to list of refreshable elements - * - * @param aUiElementId ui element id - * @param aOldPriority old priority value - */ +// ---------------------------------------------------------------------------- +// CContentRenderer::RefreshContentL +// +// ---------------------------------------------------------------------------- +// TInt CContentRenderer::RefreshContentL( HBufC* aUiElementId, - TInt aOldPriority ) + TInt aOldPriority ) { if( !aUiElementId ) { @@ -1563,11 +1767,12 @@ { // Content refresh event cannot be sent CleanupStack::PopAndDestroy( aUiElementId ); + return KErrNotReady; } // Find current mapping - TInt* oldPriority = iRefreshableUiElements.Find( *aUiElementId ); + TInt* oldPriority( iRefreshableUiElements.Find( *aUiElementId ) ); if ( oldPriority ) { @@ -1590,9 +1795,11 @@ return KErrNone; } -/** - * Callback function to make content refreshing asynchronous - */ +// ---------------------------------------------------------------------------- +// CContentRenderer::RefreshContentCallback +// +// ---------------------------------------------------------------------------- +// TInt CContentRenderer::RefreshContentCallback( TAny* aContentRenderer ) { if ( !aContentRenderer ) @@ -1600,18 +1807,27 @@ return KErrArgument; } - CContentRenderer* renderer = static_cast< CContentRenderer* >( aContentRenderer ); - TRAP_IGNORE( renderer->SendRefreshContentEventL() ); + CContentRenderer* self = + static_cast< CContentRenderer* >( aContentRenderer ); + + TRAP_IGNORE( self->SendRefreshContentEventL() ); + return KErrNone; } -/** - * Sends Refresh content event to framework. - * Event is sent for content selectors with lower priority than the - * last content which has been cleaned from ui element. - */ +// ---------------------------------------------------------------------------- +// CContentRenderer::SendRefreshContentEventL +// +// ---------------------------------------------------------------------------- +// void CContentRenderer::SendRefreshContentEventL() { + /** + * Sends Refresh content event to framework. + * Event is sent for content selectors with lower priority than the + * last content which has been cleaned from ui element. + */ + // Cancel periodic timer. iTimer->Cancel(); @@ -1619,21 +1835,21 @@ TPtrHashMapIter< TDesC, TInt> iter( iRefreshableUiElements ); iter.Reset(); - const TDesC* uiElementId = iter.NextKey(); // Never NULL - TInt priority = *( iter.CurrentValue() ); + const TDesC* uiElementId( iter.NextKey() ); // Never NULL + TInt priority( *( iter.CurrentValue() ) ); // Cleanup item for iterator TMapCleanupItem cleanup( iter ); CleanupReleasePushL( cleanup ); // Lookup ui element - CXnNodeAppIf* uiElement = FindNodeByIdL( *uiElementId ); + CXnNodeAppIf* uiElement( FindNodeByIdL( *uiElementId ) ); // Remove current ui element from the map CleanupStack::PopAndDestroy( &cleanup ); // Find lower priority content elements associated to this ui element - RPointerArray< CXnNodeAppIf > children = uiElement->ChildrenL(); + RPointerArray< CXnNodeAppIf > children( uiElement->ChildrenL() ); // Remove higher priority content elements RemoveNonPriorityElements( children, priority ); @@ -1645,13 +1861,14 @@ // Continue until first content gets published or array exhausts. for ( TInt i = 0; i < children.Count(); ++i ) { - CXnNodeAppIf* current = children[ i ]; + CXnNodeAppIf* current( children[ i ] ); // Get content selector - const HBufC* contentSelector = PropertyValueL( *current, - XnPropertyNames::common::KClass ); - - if ( contentSelector && iFwEventHandler->RefreshContent( *contentSelector )) + const HBufC* contentSelector( + PropertyValueL( *current, XnPropertyNames::common::KClass ) ); + + if ( contentSelector && + iFwEventHandler->RefreshContent( *contentSelector ) ) { break; } @@ -1664,133 +1881,82 @@ StartContentRefresh(); } +// ---------------------------------------------------------------------------- +// CContentRenderer::TitleScrolled +// +// ---------------------------------------------------------------------------- +// void CContentRenderer::TitleScrolled( TInt aTitleIndex ) { if ( iCallbackHandler ) { - TRAP_IGNORE( iCallbackHandler->TitleScrolledL( iNTPublisher, - *iNTClass, - aTitleIndex ) ); + TRAP_IGNORE( iCallbackHandler->TitleScrolledL( + iNTPublisher, *iNTClass, aTitleIndex ) ); } } - + +// ---------------------------------------------------------------------------- +// CContentRenderer::TitleToScroll +// +// ---------------------------------------------------------------------------- +// void CContentRenderer::TitleToScroll( TInt aTitleIndex ) { if ( iCallbackHandler ) { - TRAP_IGNORE( iCallbackHandler->TitleToScrollL( iNTPublisher, - *iNTClass, - aTitleIndex ) ); + TRAP_IGNORE( iCallbackHandler->TitleToScrollL( + iNTPublisher, *iNTClass, aTitleIndex ) ); } } +// ---------------------------------------------------------------------------- +// CContentRenderer::IsParentNewsticker +// +// ---------------------------------------------------------------------------- +// TBool CContentRenderer::IsParentNewsticker( CXnNodeAppIf& aTarget ) { - CXnNodeAppIf* parent = NULL; + CXnNodeAppIf* parent( NULL ); + TRAP_IGNORE( parent = aTarget.ParentL() ); + if ( !parent ) { return EFalse; } - CXnType* typeInfo = parent->Type(); - if ( !typeInfo ) - { - return EFalse; - } - - return ( typeInfo->Type() == XnNewstickerInterface::MXnNewstickerInterface::Type()); + const TDesC8& type( parent->Type()->Type() ) ; + + return ( type == XnNewstickerInterface::MXnNewstickerInterface::Type() ); } -void CContentRenderer::RegisterNewstickerCallbackInterfaceL( CXnNodeAppIf& aTarget ) +// ---------------------------------------------------------------------------- +// CContentRenderer::RegisterNewstickerCallbackInterfaceL +// +// ---------------------------------------------------------------------------- +// +void CContentRenderer::RegisterNewstickerCallbackInterfaceL( + CXnNodeAppIf& aTarget ) { if ( !iCallbackHandler ) { // Instantiate callback handler - CNewstickerCallbackHandler* handler = CNewstickerCallbackHandler::NewLC( *iFwEventHandler ); + CNewstickerCallbackHandler* handler = + CNewstickerCallbackHandler::NewLC( *iFwEventHandler ); // Set callback handler iCallbackHandler = handler; CleanupStack::Pop( handler ); } - // Obtain newsticker component interface - XnNewstickerInterface::MXnNewstickerInterface* newsticker = NULL; - XnComponentInterface::MakeInterfaceL( newsticker, aTarget ); - - LeaveIfNull( newsticker, KErrGeneral ); - - // Set callback interface - newsticker->SetCallbackInterfaceL( this ); - } -void CContentRenderer::CleanPluginFromUiL( MAiPropertyExtension& aPlugin ) - { - TInt itemCount = 0; - - // Resolve content items - MAiContentItemIterator& iter = ContentItemIteratorL( aPlugin, EAiPublisherContent ); - iter.Reset(); + // Obtain newsticker component interface + XnNewstickerInterface::MXnNewstickerInterface* newsticker( NULL ); + XnComponentInterface::MakeInterfaceL( newsticker, aTarget ); - // Clean all content items - while ( iter.HasNext() ) - { - const TAiContentItem& item = iter.NextL(); - - const TDesC& nodeId = iNodeIdGenerator->ContentNodeIdL( aPlugin, item ); - - // Find nodes - HBufC8* nodeId8 = CnvUtfConverter::ConvertFromUnicodeToUtf8L(nodeId); - CleanupStack::PushL(nodeId8); - - RPointerArray nodes = iAppUi.UiEngineL()->FindNodeByClassL( - *nodeId8, aPlugin.PublisherInfoL()->iNamespace ); - - CleanupStack::PopAndDestroy(nodeId8); - - itemCount += nodes.Count(); - - CleanupClosePushL( nodes ); - - for ( TInt i = 0; i < nodes.Count(); ++i ) - { - CXnNodeAppIf* property = nodes[i]; - - TInt priority = GetContentPriority( *property ); - - // Navigate to parent - CXnNodeAppIf* target = LeaveIfNull( property->ParentL(), KErrNotFound ); - - if ( AllowPublishByPriority( *target, priority ) ) - { - // Create transaction element for empty content - MTransactionElement* element = - iFactory->CreateEmptyContentTransactionElementL( *target, 0 ); - - iPolicyEvaluator->EvaluateEmptyContentPolicyL( *target, - element->PolicyArray() ); - iPolicyEvaluator->EvaluateVisibilityPolicyL( *target, - element->PolicyArray() ); - - ProcessTransactionElementL( element ); - - if ( priority > KErrNotFound ) // Only for prioritized elements - { - // Add current ui element into content refresh map - HBufC* uiElementId = PropertyValueL( *target, - XnPropertyNames::common::KId ); - RefreshContentL( uiElementId, priority ); - } - } - } - - CleanupStack::PopAndDestroy(&nodes); - } - - if ( itemCount == 0 ) - { - //Nothing to clean from UI. Cancel transaction outside current trap harness - User::Leave( KErrNotFound ); - } + LeaveIfNull( newsticker, KErrGeneral ); + + // Set callback interface + newsticker->SetCallbackInterfaceL( this ); } // End of File diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/src/onlineofflinehelper.cpp --- a/idlehomescreen/xmluicontroller/src/onlineofflinehelper.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/src/onlineofflinehelper.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -20,23 +20,48 @@ #include #include #include -#include #include #include #include #include - +#include +#include +#include // StringLoader +#include +#include // User includes +#include +#include #include +#include #include "onlineofflinehelper.h" #include "xmluicontroller.h" #include "appui.h" +#include "ai3.hrh" +#include "globalqueryhandler.h" // Constants const TInt KOfflineProfileId( 5 ); using namespace AiXmlUiController; +#ifdef HS_NETWORK_MONITOR +#include +_LIT( KLogFolder,"xnnetwork" ); +_LIT( KLogDom, "networksettings.log" ); + +#define _LOG1( a ) RFileLogger::Write( \ + KLogFolder, KLogDom, EFileLoggingModeAppend, ( a ) ); +#define _LOG2( a, b ) RFileLogger::WriteFormat( \ + KLogFolder, KLogDom, EFileLoggingModeAppend, ( a ), ( b ) ) +#else +#define _LOG1 +#define _LOG2 +#endif + +_LIT( KDisConnected, "disconnected"); +_LIT( KConnected, "connected"); + // ============================ LOCAL FUNCTIONS ============================== // ============================ MEMBER FUNCTIONS ============================= @@ -92,10 +117,18 @@ } } - // Update repository - iUiCtl.SettingsRepository().Set( KAIWebStatus, iFlags.IsSet( EOnline ) ); + // Update state manager + SetOnline( iFlags.IsSet( EOnline ) ); + + iCurrentNwStatus = ENWRegistrationUnknown; + iHomeNetwork = KErrNotFound; + iRoamingNetwork = KErrNotFound; - iCurrentNwStatus = ENWRegistrationUnknown; + iNwSettingObserver = CCenRepObserver::NewL( this ); + + iGlobalQueryHandler = CGlobalQueryHandler::NewL(iUiCtl); + iGlobalConfirmationQuery = CAknGlobalConfirmationQuery::NewL(); + } // ---------------------------------------------------------------------------- @@ -106,7 +139,25 @@ { delete iHandler; delete iSession; - // Whether the user choice EOnline should be stored in cenrep ? + delete iNwSettingObserver; + delete iGlobalQueryHandler; + delete iGlobalConfirmationQuery; + } + +// ---------------------------------------------------------------------------- +// COnlineOfflineHelper::CurrentCellularDataUsageChangedL +// ---------------------------------------------------------------------------- +// +void COnlineOfflineHelper::CurrentCellularDataUsageChangedL(const TInt aValue) + { + if ( iCurrentNwStatus == ENWRegisteredOnHomeNetwork ) + { + iHomeNetwork = aValue; + } + else if ( iCurrentNwStatus == ENWRegisteredRoaming ) + { + iRoamingNetwork = aValue; + } } // ---------------------------------------------------------------------------- @@ -114,8 +165,8 @@ // ---------------------------------------------------------------------------- // TBool COnlineOfflineHelper::ShowOnlineItem() const - { - if ( iFlags.IsSet( EUtilizeOnline ) ) + { + if ( iUiCtl.FwStateHandler()->OnlineStateInUse() ) { TInt value ( KErrNotFound ); if ( iUiCtl.SettingsRepository().Get( KAIWebStatus, value ) == KErrNone ) @@ -132,7 +183,7 @@ // TBool COnlineOfflineHelper::ShowOfflineItem() const { - if ( iFlags.IsSet( EUtilizeOnline ) ) + if ( iUiCtl.FwStateHandler()->OnlineStateInUse() ) { TInt value ( KErrNotFound ); if ( iUiCtl.SettingsRepository().Get( KAIWebStatus, value ) == KErrNone ) @@ -147,71 +198,22 @@ // COnlineOfflineHelper::ProcessOnlineStateL // ---------------------------------------------------------------------------- // -void COnlineOfflineHelper::ProcessOnlineStateL( - RPointerArray< CXnNodeAppIf >& aList ) - { - _LIT( KOnlineOffline, "online_offline" ); - - iFlags.Clear( EUtilizeOnline ); - - // Check if data plugins are using online_offline - for ( TInt i = 0; i < aList.Count(); i++ ) - { - TAiPublisherInfo info; - - iUiCtl.PublisherInfoL( *aList[i], info ); - - if( iUiCtl.FwEventHandler()->HasMenuItemL( info, KOnlineOffline() ) ) - { - iFlags.Set( EUtilizeOnline ); - break; - } - } - - if( iFlags.IsSet( EUtilizeOnline ) ) - { - TInt value( 0 ); - iUiCtl.SettingsRepository().Get( KAIWebStatus, value ); - - if ( value ) - { - // Switch to online - SetOnlineL( ETrue ); - } - else - { - // Switch to offline - SetOnlineL( EFalse ); - } - } - } - -// ---------------------------------------------------------------------------- -// COnlineOfflineHelper::ProcessOnlineStateL -// ---------------------------------------------------------------------------- -// void COnlineOfflineHelper::ProcessOnlineStateL( TBool aOnline ) { // User has selected online/offline item from menu - if( iFlags.IsSet( EUtilizeOnline ) ) + if( iUiCtl.FwStateHandler()->OnlineStateInUse() ) { - // Don't show R_YES_NO_HS_ONLINE query as user selected online - if (aOnline ) - { + // Don't show R_YES_NO_HS_ONLINE query as user selected online + if ( aOnline ) + { iFlags.Set( EOnline ); - // Save state - iUiCtl.SettingsRepository().Set( KAIWebStatus, ETrue ); - // Run state change. - iUiCtl.FwEventHandler()->ProcessStateChange( EAifwOnline ); } - else - { - iFlags.Clear( EOnline ); - // Save state - iUiCtl.SettingsRepository().Set( KAIWebStatus, EFalse ); - // Run state change. - iUiCtl.FwEventHandler()->ProcessStateChange( EAifwOffline ); - } + else + { + iFlags.Clear( EOnline ); + } + + SetOnline( aOnline ); } } @@ -219,22 +221,14 @@ // COnlineOfflineHelper::SetOnline // ---------------------------------------------------------------------------- // -void COnlineOfflineHelper::SetOnlineL( TBool aOnline ) - { - +void COnlineOfflineHelper::SetOnline( TBool aOnline ) + { // Save state iUiCtl.SettingsRepository().Set( KAIWebStatus, aOnline ); - if( aOnline ) - { - // Run state change. - iUiCtl.FwEventHandler()->ProcessStateChange( EAifwOnline ); - } - else - { - // Run state change. - iUiCtl.FwEventHandler()->ProcessStateChange( EAifwOffline ); - } + // Run state change. + iUiCtl.FwStateHandler()->ChangePluginState( + aOnline ? EAiFwOnline : EAiFwOffline ); } // ---------------------------------------------------------------------------- @@ -265,11 +259,16 @@ switch ( aNWInfo.iRegistrationStatus ) { case ENWRegisteredRoaming: - if( iFlags.IsSet( EOnline ) ) + _LOG1( _L(" Roaming Network Activated ")); + iCurrentNwStatus = aNWInfo.iRegistrationStatus; + CurrentNetworkSetting(); + if( ( iRoamingNetwork == ECmCellularDataUsageConfirm + || iRoamingNetwork == ECmCellularDataUsageDisabled ) + && iFlags.IsSet( EOnline ) ) { // Process to offline state. // Don't change the user selection. - SetOnlineL ( EFalse ); + SetOnline( EFalse ); // Show roaming notification CAknGlobalNote* note = CAknGlobalNote::NewLC(); HBufC* msg( StringLoader::LoadLC( R_QTN_HS_AUTOMATIC_OFFLINE ) ); @@ -277,15 +276,19 @@ note->ShowNoteL( EAknGlobalInformationNote, *msg ); CleanupStack::PopAndDestroy( 2, note ); // msg } - - iCurrentNwStatus = aNWInfo.iRegistrationStatus; break; + case ENWRegisteredOnHomeNetwork: - // Reset to user selection - SetOnlineL(iFlags.IsSet( EOnline ) ); - + _LOG1( _L(" Home Network Activated ")); iCurrentNwStatus = aNWInfo.iRegistrationStatus; + CurrentNetworkSetting(); + if( iHomeNetwork == ECmCellularDataUsageAutomatic ) + { + // Reset to user selection + SetOnline( iFlags.IsSet( EOnline ) ); + } break; + default: // unknown state iCurrentNwStatus = ENWRegistrationUnknown; @@ -372,13 +375,13 @@ { iFlags.Set( EOfflineProfile ); // Don't change the user selection. - SetOnlineL( EFalse ); + SetOnline( EFalse ); } else { iFlags.Clear( EOfflineProfile ); // Reset to user selection - SetOnlineL(iFlags.IsSet( EOnline ) ); + SetOnline( iFlags.IsSet( EOnline ) ); } } @@ -388,5 +391,70 @@ iHandler = CProfileChangeNotifyHandler::NewL( this ); } +// --------------------------------------------------------------------------- +// COnlineOfflineHelper::CurrentNetworkSetting +// --------------------------------------------------------------------------- +// +void COnlineOfflineHelper::CurrentNetworkSetting() + { + CRepository* repository( NULL ); + + TRAP_IGNORE( repository = CRepository::NewL( KCRUidCmManager ) ) + + if ( repository ) + { + TInt value( 0 ); + TInt err( repository->Get( KCurrentCellularDataUsage, value ) ); + + if ( err == KErrNone ) + { + if ( iCurrentNwStatus == ENWRegisteredRoaming ) + { + iRoamingNetwork = value; + _LOG2( _L("Roaming Network Setting <%d>"), value ); + } + else if ( iCurrentNwStatus == ENWRegisteredOnHomeNetwork ) + { + iHomeNetwork = value; + _LOG2( _L("Home Network Setting <%d>"), value ); + } + } + } + delete repository; + } + +// --------------------------------------------------------------------------- +// COnlineOfflineHelper::HandleConnectionQueryL +// --------------------------------------------------------------------------- +// +void COnlineOfflineHelper::HandleConnectionQueryL( const TDesC& aConnection) + { + if ( aConnection == KDisConnected() ) + { + ShowGlobalQueryL(R_QTN_HS_DISABLE_NETWORK, EFalse ); + } + else if ( aConnection == KConnected() ) + { + ShowGlobalQueryL(R_QTN_HS_SWITCH_ONLINE, ETrue ); + } + } + +// --------------------------------------------------------------------------- +// COnlineOfflineHelper::ShowGlobalQueryL +// --------------------------------------------------------------------------- +// +void COnlineOfflineHelper::ShowGlobalQueryL( TInt aResourceId, TBool aSetOnline ) + { + if ( !iGlobalQueryHandler->IsActive() ) + { + HBufC* confirmationText = StringLoader::LoadLC(aResourceId); + iGlobalConfirmationQuery->ShowConfirmationQueryL( + iGlobalQueryHandler->iStatus, + *confirmationText, + R_AVKON_SOFTKEYS_YES_NO); + iGlobalQueryHandler->SetOnlineParamAndActivate(aSetOnline); + CleanupStack::PopAndDestroy(); //confirmationText + } + } + // End of file - diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/src/texttransactionelement.cpp --- a/idlehomescreen/xmluicontroller/src/texttransactionelement.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/src/texttransactionelement.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -22,6 +22,7 @@ #include "xntype.h" #include "xnproperty.h" #include "xntext.h" +#include "xntexteditor.h" #include "xnmenuadapter.h" #include "xnnewsticker.h" //#include @@ -33,6 +34,8 @@ #include "xnvolumecontrol.h" #include "aistrcnv.h" +_LIT8( KTextEditor, "texteditor" ); + // ============================ MEMBER FUNCTIONS =============================== using namespace AiXmlUiController; @@ -109,9 +112,8 @@ type == KXnMenuItem || type == KXnMenu || type == XnPropertyNames::softkey::KNodeName || - type == XnPropertyNames::volumecontrol::KSlider /*|| - type == XnNewstickerInterface::MXnNewstickerInterface::Type() || - type == XnMarqueeInterface::MXnMarqueeInterface::Type() */); + type == XnPropertyNames::volumecontrol::KSlider || + type == KTextEditor ); } void CTextTransactionElement::CheckTypeL( CXnNodeAppIf& aTarget ) @@ -134,9 +136,17 @@ XnComponentInterface::MakeInterfaceL( textControl, Target() ); LeaveIfNull( textControl, KErrNotSupported ); - // Set text + // set text + textControl->SetTextL( *iNewText ); + } + else if( type == XnTextEditorInterface::MXnTextEditorInterface::Type() ) + { + XnTextEditorInterface::MXnTextEditorInterface* editorControl = NULL; + XnComponentInterface::MakeInterfaceL( editorControl, Target() ); + LeaveIfNull( editorControl, KErrNotSupported ); - textControl->SetTextL( *iNewText ); + // set text + editorControl->SetTextL( *iNewText ); } // Menu softkey texts diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/src/xmlnodeidgenerator.cpp --- a/idlehomescreen/xmluicontroller/src/xmlnodeidgenerator.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/src/xmlnodeidgenerator.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -15,66 +15,104 @@ * */ +// System includes -#include "xmlnodeidgenerator.h" -#include "aipropertyextension.h" +// User includes +#include +#include #include "aicontentmodel.h" #include "aixmluiutils.h" #include "aixmluiconstants.h" #include "aistrcnv.h" +#include "xmlnodeidgenerator.h" + using namespace AiXmlUiController; +// ---------------------------------------------------------------------------- +// CXmlNodeIdGenerator::CXmlNodeIdGenerator +// +// ---------------------------------------------------------------------------- +// CXmlNodeIdGenerator::CXmlNodeIdGenerator() { } - + +// ---------------------------------------------------------------------------- +// CXmlNodeIdGenerator::NewL +// +// ---------------------------------------------------------------------------- +// CXmlNodeIdGenerator* CXmlNodeIdGenerator::NewL() { - return new(ELeave) CXmlNodeIdGenerator; + return new ( ELeave ) CXmlNodeIdGenerator; } - + +// ---------------------------------------------------------------------------- +// CXmlNodeIdGenerator::CXmlNodeIdGenerator +// +// ---------------------------------------------------------------------------- +// CXmlNodeIdGenerator::~CXmlNodeIdGenerator() { delete iContentNodeIdBuf; } -TPtrC CXmlNodeIdGenerator::SettingsNodeIdL( const TAiPublisherInfo& aPubInfo ) +// ---------------------------------------------------------------------------- +// CXmlNodeIdGenerator::SettingsNodeIdL +// +// ---------------------------------------------------------------------------- +// +TPtrC CXmlNodeIdGenerator::SettingsNodeIdL( + const THsPublisherInfo& aPublisherInfo ) { - const TInt idLength = aPubInfo.iName.Length() - + AiUiDef::xml::id::KSettingsIdSeparator().Length() - + AiUiDef::xml::propertyClass::KSettings().Length(); - TPtr bufPtr( AiUtility::EnsureBufMaxLengthL( iContentNodeIdBuf, idLength ) ); + const TInt idLength( aPublisherInfo.Name().Length() + + AiUiDef::xml::id::KSettingsIdSeparator().Length() + + AiUiDef::xml::propertyClass::KSettings().Length() ); + + TPtr bufPtr( + AiUtility::EnsureBufMaxLengthL( iContentNodeIdBuf, idLength ) ); bufPtr.Copy( AiUiDef::xml::propertyClass::KSettings ); bufPtr.Append( AiUiDef::xml::id::KSettingsIdSeparator ); - bufPtr.Append( aPubInfo.iName ); + bufPtr.Append( aPublisherInfo.Name() ); return bufPtr; } -TPtrC CXmlNodeIdGenerator::ContentNodeIdL(MAiPropertyExtension& aPlugin, const TAiContentItem& aContentItem) +// ---------------------------------------------------------------------------- +// CXmlNodeIdGenerator::CXmlNodeIdGenerator +// +// ---------------------------------------------------------------------------- +// +TPtrC CXmlNodeIdGenerator::ContentNodeIdL( CHsContentPublisher& aPlugin, + const TAiContentItem& aContentItem ) { - TAiPublisherInfo* info = static_cast( aPlugin.GetPropertyL( EAiPublisherInfo ) ); - - LeaveIfNull( info, KErrNotFound ); - - return ContentNodeIdL(*info, aContentItem); + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + return ContentNodeIdL( info, aContentItem ); } - -TPtrC CXmlNodeIdGenerator::ContentNodeIdL - ( const TAiPublisherInfo& aPubInfo, const TAiContentItem& aContentItem ) + +// ---------------------------------------------------------------------------- +// CXmlNodeIdGenerator::CXmlNodeIdGenerator +// +// ---------------------------------------------------------------------------- +// +TPtrC CXmlNodeIdGenerator::ContentNodeIdL( + const THsPublisherInfo& aPublisherInfo, + const TAiContentItem& aContentItem ) { - const TDesC& contentCid = ContentCid( aContentItem ); + const TDesC& contentCid( ContentCid( aContentItem ) ); // Calculate buffer size and ensure buffer has enough room - const TInt idLength = aPubInfo.iName.Length() - + AiUiDef::xml::id::KContentIdSeparator().Length() - + contentCid.Length(); - TPtr bufPtr( AiUtility::EnsureBufMaxLengthL( iContentNodeIdBuf, idLength ) ); + const TInt idLength( aPublisherInfo.Name().Length() + + AiUiDef::xml::id::KContentIdSeparator().Length() + contentCid.Length() ); + + TPtr bufPtr( + AiUtility::EnsureBufMaxLengthL( iContentNodeIdBuf, idLength ) ); // Copy publisher info name to the buffer - bufPtr.Copy( aPubInfo.iName ); + bufPtr.Copy( aPublisherInfo.Name() ); // Append separator bufPtr.Append( AiUiDef::xml::id::KContentIdSeparator ); @@ -85,19 +123,30 @@ return bufPtr; } -TPtrC CXmlNodeIdGenerator::ResourceNodeIdL - ( MAiPropertyExtension& aPlugin, const TAiContentItem& aContentItem ) +// ---------------------------------------------------------------------------- +// CXmlNodeIdGenerator::CXmlNodeIdGenerator +// +// ---------------------------------------------------------------------------- +// +TPtrC CXmlNodeIdGenerator::ResourceNodeIdL( + CHsContentPublisher& aPlugin, const TAiContentItem& aContentItem ) { - TAiPublisherInfo* info = static_cast( aPlugin.GetPropertyL( EAiPublisherInfo ) ); - - LeaveIfNull( info, KErrNotFound ); - - return ResourceNodeIdL(*info, aContentItem); + const THsPublisherInfo& info( aPlugin.PublisherInfo() ); + + return ResourceNodeIdL( info, aContentItem ); } -TPtrC CXmlNodeIdGenerator::ResourceNodeIdL - ( const TAiPublisherInfo& aPubInfo, const TAiContentItem& aContentItem ) +// ---------------------------------------------------------------------------- +// CXmlNodeIdGenerator::CXmlNodeIdGenerator +// +// ---------------------------------------------------------------------------- +// +TPtrC CXmlNodeIdGenerator::ResourceNodeIdL( + const THsPublisherInfo& aPublisherInfo, + const TAiContentItem& aContentItem ) { // Resources node id is similar to content node id - return ContentNodeIdL( aPubInfo, aContentItem ); + return ContentNodeIdL( aPublisherInfo, aContentItem ); } + +// End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluicontroller/src/xmluicontroller.cpp --- a/idlehomescreen/xmluicontroller/src/xmluicontroller.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluicontroller/src/xmluicontroller.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -26,7 +26,8 @@ // User includes #include #include -#include +#include +#include #include #include @@ -56,16 +57,12 @@ #include "xnplugindefs.h" #include "ainativeuiplugins.h" +// Constants +const TInt KOneSecondInMicroS = 1000*1000; +_LIT8( KData, "data" ); using namespace AiXmlUiController; -const TInt KOneSecondInMicroS = 1000*1000; -const TInt KAI2CrKeyIncrementBy2 = 2; - -typedef TBuf<32> TNamespace; - -_LIT( KSettingsDummyData, "" ); - // ======== LOCAL FUNCTIONS ======== // ---------------------------------------------------------------------------- // ResolveEventParameters() @@ -285,36 +282,7 @@ // ---------------------------------------------------------------------------- // void CXmlUiController::LoadUIDefinitionL() - { - // No implementation required - } - -// ---------------------------------------------------------------------------- -// CXmlUiController::GetPluginsL() -// ---------------------------------------------------------------------------- -// -void CXmlUiController::GetPluginsL( RAiPublisherInfoArray& /*aPlugins*/ ) - { - // No implementation required - } - -// ---------------------------------------------------------------------------- -// CXmlUiController::PublisherInfo() -// ---------------------------------------------------------------------------- -// -void CXmlUiController::PublisherInfoL( RAiPublisherInfoArray& aPlugins ) - { - // This method returns plugins with namespace KNativeUiNamespace - if ( iRunningAsMain ) - { - // This plugin is used to publish data on secondary ui controller side - TAiPublisherInfo deviceStatus; - deviceStatus.iUid = KDeviceStatusPluginUid; - deviceStatus.iName.Copy( KDeviceStatusPluginName ); - deviceStatus.iNamespace.Copy( KNativeUiNamespace ); - - aPlugins.AppendL( deviceStatus ); - } + { } // ---------------------------------------------------------------------------- @@ -322,7 +290,7 @@ // ---------------------------------------------------------------------------- // void CXmlUiController::PublisherInfoL( CXnNodeAppIf& aSource, - TAiPublisherInfo& aInfo ) + THsPublisherInfo& aInfo ) { // Fetch uid from XML and convert it to TUid const TDesC8* uid( PropertyValue( aSource, @@ -332,62 +300,59 @@ { return; } - + _LIT8( KPrefix, "0x" ); const TInt pos( uid->FindF( KPrefix ) ); + TInt32 uidValue( 0 ); + if( pos != KErrNotFound ) { TLex8 lex( uid->Mid( pos + KPrefix().Length() ) ); // Hex parsing needs unsigned int - TUint32 value = 0; - const TInt parseResult = lex.Val( value, EHex ); + TUint32 value( 0 ); + TInt err( lex.Val( value, EHex ) ); - if ( parseResult == KErrNone ) + if ( err == KErrNone ) { - TInt32 value32( value ); - - aInfo.iUid = TUid::Uid( value32 ); + uidValue = value; } } // Fetch plug-in name from XML - HBufC* pluginName( PropertyValueL( aSource, - AiUiDef::xml::property::KName ) ); - - CleanupStack::PushL( pluginName ); - - if ( pluginName ) - { - aInfo.iName.Copy( *pluginName ); - } + HBufC* name( PropertyValueL( aSource, AiUiDef::xml::property::KName ) ); + + TUid pluginuid( TUid::Uid( uidValue ) ); + + aInfo = THsPublisherInfo( pluginuid, *name, aSource.Namespace() ); - CleanupStack::PopAndDestroy( pluginName ); - - aInfo.iNamespace.Copy( aSource.Namespace() ); + delete name; + name = NULL; } // ---------------------------------------------------------------------------- // CXmlUiController::GetSettingsL() +// // ---------------------------------------------------------------------------- // -void CXmlUiController::GetSettingsL( const TAiPublisherInfo& aPubInfo, +void CXmlUiController::GetSettingsL( const THsPublisherInfo& aPublisherInfo, RAiSettingsItemArray& aSettings ) { - if ( aPubInfo.iNamespace == KNativeUiNamespace ) + if ( aPublisherInfo.Namespace() == KNativeUiNamespace ) { // This controller doesn't provide settings for native ui namespace return; } - const TDesC& classId( iNodeIdGenerator->SettingsNodeIdL( aPubInfo ) ); + const TDesC& classId( + iNodeIdGenerator->SettingsNodeIdL( aPublisherInfo ) ); + + TBuf< KHsPublisherNamespaceMaxLength > ns; - TNamespace ns; + ns.Copy( aPublisherInfo.Namespace() ); - ns.Copy( aPubInfo.iNamespace ); - // Find settings nodes RPointerArray< CXnNodeAppIf > nodes( UiEngineL()->FindNodeByClassL( classId, ns ) ); @@ -405,10 +370,10 @@ CXnNodeAppIf* node( nodes[i] ); const TDesC8* name( - PropertyValue( *node, AiUiDef::xml::property::KName ) ); + PropertyValue( *node, AiUiDef::xml::property::KName ) ); HBufC* value( - PropertyValueL( *node, AiUiDef::xml::property::KValue ) ); + PropertyValueL( *node, AiUiDef::xml::property::KValue ) ); CleanupStack::PushL( value ); @@ -418,7 +383,7 @@ CleanupDeletePushL( settings ); MAiPluginSettingsItem& item( settings->AiPluginSettingsItem() ); - item.SetPublisherId( aPubInfo.iUid ); + item.SetPublisherId( aPublisherInfo.Uid() ); TInt32 key( 0 ); @@ -438,148 +403,7 @@ CleanupStack::PopAndDestroy( &nodes ); - GetSettingsFromCRL( aPubInfo, aSettings ); - GetContentModelL( aPubInfo, aSettings ); - } - -// ---------------------------------------------------------------------------- -// CXmlUiController::GetSettingsFromCRL() -// ---------------------------------------------------------------------------- -// -void CXmlUiController::GetSettingsFromCRL( const TAiPublisherInfo& aPubInfo, - RAiSettingsItemArray &aPluginSettings ) - { - if ( aPubInfo.iNamespace == KNativeUiNamespace ) - { - // This controller doesn't provide settings for native ui namespace - return; - } - - /* - * The settings are stored in the cenrep starting from 0x1000. - * 0x1000 is the name of the plugin which this setting belongs to (for example Settings/Shortcut) - * 0x1001 is the id of the setting (for example 1) - * 0x1002 is the value of the setting (for example localapp:0x012345678) - * - * So three keys per setting. - * - * Settings from cenrep override those from XML - */ - - TUint32 crKey( KAIPluginSettingsKeyRangeStart ); - - TBool moreSettings( ETrue ); - - HBufC* pluginId = HBufC::NewLC( - NCentralRepositoryConstants::KMaxUnicodeStringLength ); - - HBufC* settingValue = HBufC::NewLC( - NCentralRepositoryConstants::KMaxUnicodeStringLength ); - - HBufC* settingKey = HBufC::NewLC( - NCentralRepositoryConstants::KMaxUnicodeStringLength ); - - TPtr pluginIdPtr( pluginId->Des() ); - TPtr settingValuePtr( settingValue->Des() ); - TPtr settingKeyPtr( settingKey->Des() ); - - TInt32 settingId( 0 ); - - TInt err( KErrNone ); - TBool settingFound( EFalse ); - - while( moreSettings ) - { - settingFound = EFalse; - - pluginIdPtr.Zero(); - settingValuePtr.Zero(); - settingKeyPtr.Zero(); - - //Get the name of plugin with the Settings/ prefix - err = iAISettingsRepository->Get( crKey++, pluginIdPtr ); - - // remove the Settings/ prefix if it is located at the start of the string - if( pluginIdPtr.FindC( AiUiDef::xml::propertyClass::KSettings ) == 0 ) - { - pluginIdPtr.Delete( 0, - AiUiDef::xml::id::KSettingsIdSeparator().Length() + - AiUiDef::xml::propertyClass::KSettings().Length() ); - } - - // does the setting belong to this plugin - if( err == KErrNone && pluginIdPtr == aPubInfo.iName ) - { - // Get the settings id - err = iAISettingsRepository->Get( crKey++, settingKeyPtr ); - - if( err == KErrNone ) - { - err = AiUtility::ParseInt( settingId,settingKeyPtr ); - } - - if( err == KErrNone ) - { - // Get the actual value of the setting - err = iAISettingsRepository->Get( crKey++, settingValuePtr ); - - // Ignore possible placeholder data in cenrep - if( err == KErrNone && settingValuePtr.Compare( KSettingsDummyData ) != 0 ) - { - // Try to find an existing setting for this - for( TInt j = 0; j < aPluginSettings.Count(); j++ ) - { - MAiPluginSettings* setting( aPluginSettings[j] ); - MAiPluginSettingsItem& item( setting->AiPluginSettingsItem() ); - - // Existing setting found => replace it - if( item.Key() == settingId && item.PublisherId() == aPubInfo.iUid ) - { - item.SetValueL( settingValuePtr, EFalse ); - settingFound = ETrue; - break; - } - } - - // Existing setting not found => append new one ONLY if we - // are dealing with the icon overrides or toolbar shortcuts - if( !settingFound && - ( ( settingId & KScutFlagBitToolbarShortcut ) || - ( settingId & KScutFlagBitIconOverride ) ) ) - { - MAiPluginSettings* settings( AiUtility::CreatePluginSettingsL() ); - CleanupDeletePushL( settings ); - - MAiPluginSettingsItem& item( settings->AiPluginSettingsItem() ); - - item.SetPublisherId( aPubInfo.iUid ); - item.SetKey( settingId ); - item.SetValueL( settingValuePtr, EFalse ); - - aPluginSettings.Append( settings ); - CleanupStack::Pop( settings ); - } - } - } - else - { - // no settings id found => invalid settings in cenrep - __PRINT8( __DBG_FORMAT8("CXmlUiController::GetSettingsFromCRL: ERROR: invalid settings. key: %d pluginname: %S id: %d value: %S"), crKey, pluginId, settingId, settingValue ); - } - } - else if( err != KErrNone ) - { - // name of the plugin not found => no more settings - moreSettings = EFalse; - } - else - { - // not the correct setting for this plugin - crKey += KAI2CrKeyIncrementBy2; - } - } - - CleanupStack::PopAndDestroy( 3, pluginId ); // settingValue, settingKey + GetContentModelL( aPublisherInfo, aSettings ); } // ---------------------------------------------------------------------------- @@ -587,10 +411,10 @@ // ---------------------------------------------------------------------------- // // ContentModelL() -void CXmlUiController::GetContentModelL( const TAiPublisherInfo& aPubInfo, +void CXmlUiController::GetContentModelL( const THsPublisherInfo& aPublisherInfo, RAiSettingsItemArray& aSettings ) { - if ( aPubInfo.iNamespace == KNativeUiNamespace ) + if ( aPublisherInfo.Namespace() == KNativeUiNamespace ) { // This controller doesn't provide content model for native ui namespace return; @@ -599,7 +423,8 @@ // Find the node for the publisher // TODO Does not work if widget is in view RPointerArray list( - UiEngineL()->FindContentSourceNodesL( aPubInfo.iNamespace ) ); + UiEngineL()->FindContentSourceNodesL( aPublisherInfo.Namespace() ) ); + CleanupClosePushL( list ); CXnNodeAppIf* publisherNode( NULL ); @@ -638,7 +463,9 @@ else if( nodeType == AiUiDef::xml::element::KImage || nodeType == AiUiDef::xml::element::KText || nodeType == AiUiDef::xml::element::KNewsTicker || - nodeType == AiUiDef::xml::element::KAnimation ) + nodeType == AiUiDef::xml::element::KAnimation || + nodeType == AiUiDef::xml::element::KTextEditor || + nodeType == KData ) { // Is created in GetContenItem and used in GetConfigurationsL HBufC* confOwner( NULL ); @@ -793,18 +620,12 @@ } // ---------------------------------------------------------------------------- -// CXmlUiController::RemovePluginFromUI() +// CXmlUiController::SetStateHandler() // ---------------------------------------------------------------------------- // -void CXmlUiController::RemovePluginFromUI( MAiPropertyExtension& aPlugin ) +void CXmlUiController::SetStateHandler( MAiFwStateHandler& aFwStateHandler ) { - CContentRenderer* contentRenderer = - static_cast< CContentRenderer* >( iObserver ); - - if ( contentRenderer ) - { - contentRenderer->CleanPluginFromUi( aPlugin ); - } + iFwStateHandler = &aFwStateHandler; } // ---------------------------------------------------------------------------- @@ -817,6 +638,15 @@ } // ---------------------------------------------------------------------------- +// CXmlUiController::FwStateHandler() +// ---------------------------------------------------------------------------- +// +MAiFwStateHandler* CXmlUiController::FwStateHandler() const + { + return iFwStateHandler; + } + +// ---------------------------------------------------------------------------- // CXmlUiController::MainInterface() // ---------------------------------------------------------------------------- // @@ -857,33 +687,12 @@ } // ---------------------------------------------------------------------------- -// CXmlUiController::SetUiFrameworkObserver() -// ---------------------------------------------------------------------------- -// -void CXmlUiController::SetUiFrameworkObserver( - MAiUiFrameworkObserver& aObserver ) - { - iUiFrameworkObserver = &aObserver; - } - -// ---------------------------------------------------------------------------- // CXmlUiController::IsMenuOpen() // ---------------------------------------------------------------------------- // TBool CXmlUiController::IsMenuOpen() { - TBool menuOpen( EFalse ); - TRAP_IGNORE( menuOpen = UiEngineL()->IsMenuDisplaying() ); - return menuOpen; - } - -// ---------------------------------------------------------------------------- -// CXmlUiController::UiFrameworkObserver() -// ---------------------------------------------------------------------------- -// -MAiUiFrameworkObserver* CXmlUiController::UiFrameworkObserver() const - { - return iUiFrameworkObserver; + return iAppUi->IsDisplayingMenuOrDialog(); } // ---------------------------------------------------------------------------- diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/dom/src/xndomstringpooloptimizer.cpp --- a/idlehomescreen/xmluirendering/dom/src/xndomstringpooloptimizer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/dom/src/xndomstringpooloptimizer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -82,7 +82,7 @@ } TInt index = FindEntry( aString, 0, iEntries.Count() - 1 ); - if( index > 0 && index < iEntries.Count() ) + if( index >= 0 && index < iEntries.Count() ) { return iEntries[index].iIndex; } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/renderingplugins/extrenderingplugin/bwins/extrenderingplugin.def --- a/idlehomescreen/xmluirendering/renderingplugins/extrenderingplugin/bwins/extrenderingplugin.def Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/renderingplugins/extrenderingplugin/bwins/extrenderingplugin.def Fri Feb 19 22:42:37 2010 +0200 @@ -7,4 +7,6 @@ ?ImplUid@CXnExtRenderingPluginAdapter@@QBE?AVTUid@@XZ @ 6 NONAME ; class TUid CXnExtRenderingPluginAdapter::ImplUid(void) const ??1CXnExtRenderingPluginAdapter@@UAE@XZ @ 7 NONAME ; CXnExtRenderingPluginAdapter::~CXnExtRenderingPluginAdapter(void) ?EnterPowerSaveModeL@CXnExtRenderingPluginAdapter@@UAEXXZ @ 8 NONAME ; void CXnExtRenderingPluginAdapter::EnterPowerSaveModeL(void) + ?SetEventHandler@CXnExtRenderingPluginAdapter@@UAEXPAVMXnExtEventHandler@@@Z @ 9 NONAME ; void CXnExtRenderingPluginAdapter::SetEventHandler(class MXnExtEventHandler *) + ?SetDataL@CXnExtRenderingPluginAdapter@@UAEXABVTDesC8@@ABVTDesC16@@H@Z @ 10 NONAME ; void CXnExtRenderingPluginAdapter::SetDataL(class TDesC8 const &, class TDesC16 const &, int) diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/renderingplugins/extrenderingplugin/eabi/extrenderingplugin.def --- a/idlehomescreen/xmluirendering/renderingplugins/extrenderingplugin/eabi/extrenderingplugin.def Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/renderingplugins/extrenderingplugin/eabi/extrenderingplugin.def Fri Feb 19 22:42:37 2010 +0200 @@ -11,4 +11,6 @@ _ZNK28CXnExtRenderingPluginAdapter7ImplUidEv @ 10 NONAME _ZTI28CXnExtRenderingPluginAdapter @ 11 NONAME _ZTV28CXnExtRenderingPluginAdapter @ 12 NONAME + _ZN28CXnExtRenderingPluginAdapter15SetEventHandlerEP18MXnExtEventHandler @ 13 NONAME + _ZN28CXnExtRenderingPluginAdapter8SetDataLERK6TDesC8RK7TDesC16i @ 14 NONAME diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/renderingplugins/extrenderingplugin/src/xnextrenderingpluginadapter.cpp --- a/idlehomescreen/xmluirendering/renderingplugins/extrenderingplugin/src/xnextrenderingpluginadapter.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/renderingplugins/extrenderingplugin/src/xnextrenderingpluginadapter.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -19,6 +19,7 @@ #include #include #include +#include // Local constants @@ -102,5 +103,24 @@ { } +// ---------------------------------------------------------------------------- +// CXnExtRenderingPluginAdapter::SetEventHandler() +// ---------------------------------------------------------------------------- +// +EXPORT_C void CXnExtRenderingPluginAdapter::SetEventHandler( + MXnExtEventHandler* /*aEventHandler*/ ) + { + + } + +// ---------------------------------------------------------------------------- +// CXnExtRenderingPluginAdapter::SetDataL() +// ---------------------------------------------------------------------------- +// +EXPORT_C void CXnExtRenderingPluginAdapter::SetDataL( const TDesC8& /*aData*/, + const TDesC& /*aType*/, TInt /*aIndex*/ ) + { + + } // End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/renderingplugins/xnanimationfactory/src/xnanimationadapter.cpp --- a/idlehomescreen/xmluirendering/renderingplugins/xnanimationfactory/src/xnanimationadapter.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/renderingplugins/xnanimationfactory/src/xnanimationadapter.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -15,8 +15,8 @@ * */ #include -#include -#include +#include +#include #include #include "xnnodepluginif.h" #include "xndomproperty.h" diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/renderingplugins/xnmenufactory/src/xnmenuadapter.cpp --- a/idlehomescreen/xmluirendering/renderingplugins/xnmenufactory/src/xnmenuadapter.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/renderingplugins/xnmenufactory/src/xnmenuadapter.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -55,19 +55,16 @@ #undef _AVKON_CBA_LSC -_LIT8( KWidgetSpecific, "Menu/WidgetSpecific" ); -_LIT8( KViewSpecific, "Menu/ViewSpecific" ); -_LIT8( KWidgetsHidden, "Menu/WidgetsHidden" ); -_LIT8( KWidgetsShown, "Menu/WidgetsShown" ); _LIT8( KEditMode, "Menu/EditMode" ); +_LIT8( KNormalMode, "Menu/NormalMode" ); _LIT8( KAlwaysShown, "Menu/AlwaysShown" ); _LIT8( KHsShowHelp, "hs_show_help" ); const TInt KMenuCommandFirst = 6000; const TInt KMenuCommandLast = 6199; -const TInt KCBACommandFirst = 6200; -const TInt KCBACommandSecond = 6201; -const TInt KCBACommandMiddle = 6202; +const TInt KCBACommandFirst = EAknSoftkeyOptions; +const TInt KCBACommandSecond = EAknSoftkeyBack; +const TInt KCBACommandMiddle = EAknSoftkeyDialler; const TInt KXnMenuArrayGranularity = 6; const TInt KWideScreenWidth = 640; @@ -809,6 +806,34 @@ return retval; } +// ----------------------------------------------------------------------------- +// FindWidgetElementL +// +// ----------------------------------------------------------------------------- +// +static CXnNodePluginIf* FindWidgetElementL( CXnNodePluginIf& aPluginNode ) + { + CXnNodePluginIf* retval( NULL ); + + RPointerArray< CXnNodePluginIf > children( aPluginNode.ChildrenL() ); + CleanupClosePushL( children ); + + for ( TInt i = 0; i < children.Count(); i++ ) + { + CXnNodePluginIf* node( children[i] ); + + if ( node->AppIfL().InternalDomNodeType() == XnPropertyNames::KWidget ) + { + retval = node; + break; + } + } + + CleanupStack::PopAndDestroy( &children ); + + return retval; + } + // ============================ MEMBER FUNCTIONS =============================== // ----------------------------------------------------------------------------- @@ -1449,24 +1474,7 @@ iMenuItems.Reset(); iIdCounter = KMenuCommandFirst; - - CXnNodePluginIf* focused( iUiEngine->FocusedNodeL() ); - - const TDesC8& ns( iRootNode->Namespace() ); - - TBool widgetSpecific( EFalse ); - - for( ; focused ; focused = focused->ParentL() ) - { - if( focused->AppIfL().InternalDomNodeType() == XnPropertyNames::KPlugin ) - { - widgetSpecific = ETrue; - break; - } - } - - TBool widgetsShown( iUiEngine->WidgetsVisible() ); - + RPointerArray< const TDesC8 > groups; CleanupClosePushL( groups ); @@ -1476,8 +1484,7 @@ } else { - groups.AppendL( widgetSpecific ? &KWidgetSpecific : &KViewSpecific ); - groups.AppendL( widgetsShown ? &KWidgetsShown : &KWidgetsHidden ); + groups.Append( &KNormalMode ); } groups.AppendL( &KAlwaysShown ); @@ -2736,15 +2743,13 @@ // Get element CXnNodePluginIf& pluginNode( iUiEngine->PluginNodeL( focusedNode ) ); - RPointerArray< CXnNodePluginIf > children( pluginNode.ChildrenL() ); - CleanupClosePushL( children ); - + CXnNodePluginIf* widget( FindWidgetElementL( pluginNode ) ); + CXnNodePluginIf* widgetExtNode( NULL ); - if( children.Count() > 0 ) - { - // children[0] must be element - widgetExtNode = FindChildL( *children[0], KXnMenuExtension ); + if( widget ) + { + widgetExtNode = FindChildL( *widget, KXnMenuExtension ); } if( !widgetExtNode ) @@ -2773,9 +2778,7 @@ source ); } } - } - - CleanupStack::PopAndDestroy( &children ); + } } if( menuItem && IsNodeVisibleL( *menuItem ) ) diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/renderingplugins/xntexteditorfactory/inc/xntexteditoradapter.h --- a/idlehomescreen/xmluirendering/renderingplugins/xntexteditorfactory/inc/xntexteditoradapter.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/renderingplugins/xntexteditorfactory/inc/xntexteditoradapter.h Fri Feb 19 22:42:37 2010 +0200 @@ -73,7 +73,15 @@ * @return Text, ownership is transfered */ HBufC* Text() const; - + + /** + * Handles editor events + * + * @since S60 5.2 + * @param aReason, editor event + */ + void HandleEditorEvent( TInt aReason ); + public: // from base classes /** @@ -151,6 +159,12 @@ TInt iMaxLines; /** Flag to indicate whether focus loss is refused */ TBool iRefusesFocusLoss; + /** Flag to indicate is partial input supported*/ + TBool iPartialInputEnabled; + /** Flag to indicate is partial input open*/ + TBool iPartialInputOpen; + /** Flag to indicate whether split input should be remove or not*/ + TBool iRemoveSplitInputFromStack; }; #endif // _XNTEXTEDITORADAPTER_H diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/renderingplugins/xntexteditorfactory/src/xntexteditor.cpp --- a/idlehomescreen/xmluirendering/renderingplugins/xntexteditorfactory/src/xntexteditor.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/renderingplugins/xntexteditorfactory/src/xntexteditor.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -85,7 +85,17 @@ { return (static_cast(ControlAdapter()))->Text(); } - + +// --------------------------------------------------------- +// CXnTextEditor::HandleEditorEvent +// --------------------------------------------------------- +// +void CXnTextEditor::HandleEditorEvent( TInt aReason ) + { + static_cast(ControlAdapter())-> + HandleEditorEvent( aReason ); + } + // --------------------------------------------------------- // --------------------------------------------------------- XnComponentInterface::MXnComponentInterface* CXnTextEditor::MakeInterfaceL(const TDesC8& aType) diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/renderingplugins/xntexteditorfactory/src/xntexteditoradapter.cpp --- a/idlehomescreen/xmluirendering/renderingplugins/xntexteditorfactory/src/xntexteditoradapter.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/renderingplugins/xntexteditorfactory/src/xntexteditoradapter.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -46,12 +46,14 @@ #include "xnnodepluginif.h" #include "xneditmode.h" #include "c_xnutils.h" +#include "xntexteditor.h" const TInt KMaxLength = 100; _LIT8( KCpsPublishing, "cpspublishing" ); _LIT8( KMaxLineAmount, "max-line-amount" ); _LIT8( KMaxCharAmount, "max-char-amount" ); +_LIT8( KEnablePartialInput, "splitinputenabled" ); _LIT( KEnterChar, "\x2029" ); @@ -170,7 +172,19 @@ iEditor->SetAknEditorNumericKeymap( EAknEditorPlainNumberModeKeymap ); iEditor->SetSuppressBackgroundDrawing( ETrue ); - + + // Enable partial Screen + CXnProperty* enablepartialinput( iNode.GetPropertyL( KEnablePartialInput ) ); + iPartialInputEnabled = EFalse; + iPartialInputOpen = EFalse; + + if ( enablepartialinput && + enablepartialinput->StringValue() == XnPropertyNames::KTrue ) + { + iEditor->SetAknEditorFlags( EAknEditorFlagEnablePartialScreen ); + iPartialInputEnabled = ETrue; + } + iEditor->SetObserver( this ); // Default not focused @@ -295,20 +309,38 @@ if ( isFocused ) { value = EPSAiDontForwardNumericKeysToPhone; - - TRAP_IGNORE( appui->AddToStackL( appui->View(), iEditor ) ); - - // AddToStackL calls iEditor->SetFocus( ETrue ); + + if( !iPartialInputEnabled ) + { + TRAP_IGNORE( appui->AddToStackL( appui->View(), iEditor ) ); + // AddToStackL calls iEditor->SetFocus( ETrue ); + } + } else { value = EPSAiForwardNumericKeysToPhone; - appui->RemoveFromStack( iEditor ); - - iEditor->SetFocus( EFalse, aDrawNow ); + if( !iPartialInputEnabled ) + { + appui->RemoveFromStack( iEditor ); + iEditor->SetFocus( EFalse, aDrawNow ); + } + else if(iPartialInputEnabled && iRemoveSplitInputFromStack ) + { + appui->RemoveFromStack( iEditor ); + iEditor->SetFocus( EFalse, aDrawNow ); + iPartialInputOpen = EFalse; + iRemoveSplitInputFromStack = EFalse; + } + } - + + if(iPartialInputOpen) + { + value = EPSAiDontForwardNumericKeysToPhone; + } + iRefusesFocusLoss = isFocused; RProperty::Set( KPSUidAiInformation, @@ -352,6 +384,7 @@ void CXnTextEditorAdapter::SetTextL( const TDesC& aText ) { iEditor->SetTextL( &aText ); + iNode.SetDirtyL(); } // ----------------------------------------------------------------------------- @@ -370,6 +403,53 @@ } // ----------------------------------------------------------------------------- +// CXnTextEditorAdapter::HandleEditorEvent +// ----------------------------------------------------------------------------- +// +void CXnTextEditorAdapter::HandleEditorEvent( TInt aReason ) + { + CXnAppUiAdapter* appui( + static_cast< CXnAppUiAdapter* >( iAvkonAppUi ) ); + + switch( aReason ) + { + case CXnTextEditor::KActivateTextEditor: + { + if( !iPartialInputOpen ) + { + iUiEngine->EnablePartialTouchInput(iNode , ETrue); + TRAP_IGNORE( appui->AddToStackL( appui->View(), iEditor ) ); + iPartialInputOpen = ETrue; + } + break; + } + case CXnTextEditor::KDeactivateTextEditor: + { + if( iPartialInputOpen ) + { + iUiEngine->EnablePartialTouchInput(iNode, EFalse); + iPartialInputOpen = EFalse; + appui->RemoveFromStack( iEditor ); + iEditor->SetFocus( EFalse ); + } + break; + } + case CXnTextEditor::KRemoveSplitInputFromStack: + { + iRemoveSplitInputFromStack = ETrue; + break; + } + case CXnTextEditor::KKeepSplitInputInStack: + { + iRemoveSplitInputFromStack = EFalse; + break; + } + default: + break; + } + } + +// ----------------------------------------------------------------------------- // CXnTextEditorAdapter::SetPropertiesL // Sets text properties // ----------------------------------------------------------------------------- diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/bwins/xn3layoutengineu.def --- a/idlehomescreen/xmluirendering/uiengine/bwins/xn3layoutengineu.def Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/bwins/xn3layoutengineu.def Fri Feb 19 22:42:37 2010 +0200 @@ -11,229 +11,234 @@ ?AppIfL@CXnNodePluginIf@@QAEAAVCXnNodeAppIf@@XZ @ 10 NONAME ; class CXnNodeAppIf & CXnNodePluginIf::AppIfL(void) ??1MXnComponentFactory@@UAE@XZ @ 11 NONAME ; MXnComponentFactory::~MXnComponentFactory(void) ?ParentL@CXnNodePluginIf@@QBEPAV1@XZ @ 12 NONAME ; class CXnNodePluginIf * CXnNodePluginIf::ParentL(void) const - ?EnterPowerSaveModeL@CXnControlAdapter@@QAEXW4TModeEvent@1@@Z @ 13 NONAME ; void CXnControlAdapter::EnterPowerSaveModeL(enum CXnControlAdapter::TModeEvent) - ??0CXnComponentNodeImpl@@IAE@XZ @ 14 NONAME ; CXnComponentNodeImpl::CXnComponentNodeImpl(void) - ?SetLocalUiZoomL@CXnControlAdapter@@UAEXW4TAknUiZoom@@@Z @ 15 NONAME ; void CXnControlAdapter::SetLocalUiZoomL(enum TAknUiZoom) - ?SetDirtyL@CXnNodePluginIf@@QAEXXZ @ 16 NONAME ; void CXnNodePluginIf::SetDirtyL(void) - ?Draw@CXnControlAdapter@@UBEXABVTRect@@AAVCWindowGc@@@Z @ 17 NONAME ; void CXnControlAdapter::Draw(class TRect const &, class CWindowGc &) const - ?ShowTooltipsL@CXnNodeAppIf@@QAEXXZ @ 18 NONAME ; void CXnNodeAppIf::ShowTooltipsL(void) - ?MakeInterfaceL@CXnNodePluginIf@@QAEPAVMXnComponentInterface@XnComponentInterface@@ABVTDesC8@@@Z @ 19 NONAME ; class XnComponentInterface::MXnComponentInterface * CXnNodePluginIf::MakeInterfaceL(class TDesC8 const &) - ?SetBorderRect@CXnNodePluginIf@@QAEXABVTRect@@@Z @ 20 NONAME ; void CXnNodePluginIf::SetBorderRect(class TRect const &) - ?RenderUIL@TXnUiEnginePluginIf@@QAEXPAVCXnNodePluginIf@@@Z @ 21 NONAME ; void TXnUiEnginePluginIf::RenderUIL(class CXnNodePluginIf *) - ?TextAlignment@CXnUtils@@SA?AW4TGulAlignmentValue@@AAVCXnNodePluginIf@@@Z @ 22 NONAME ; enum TGulAlignmentValue CXnUtils::TextAlignment(class CXnNodePluginIf &) - ?Property@CXnProperty@@QAEPAVCXnDomProperty@@XZ @ 23 NONAME ; class CXnDomProperty * CXnProperty::Property(void) - ?Namespace@CXnNodePluginIf@@QAEABVTDesC8@@XZ @ 24 NONAME ; class TDesC8 const & CXnNodePluginIf::Namespace(void) - ?AddDirtyNodeL@TXnUiEnginePluginIf@@QAEXAAVCXnNodePluginIf@@@Z @ 25 NONAME ; void TXnUiEnginePluginIf::AddDirtyNodeL(class CXnNodePluginIf &) - ?SetPropertyL@CXnNodePluginIf@@QAEXPAVCXnProperty@@@Z @ 26 NONAME ; void CXnNodePluginIf::SetPropertyL(class CXnProperty *) - ?HorizontalPixelValueL@TXnUiEnginePluginIf@@QAEHPAVCXnProperty@@H@Z @ 27 NONAME ; int TXnUiEnginePluginIf::HorizontalPixelValueL(class CXnProperty *, int) - ?HandlePowerSaveModeL@CXnUtils@@SAHPAVCXnNode@@HH@Z @ 28 NONAME ; int CXnUtils::HandlePowerSaveModeL(class CXnNode *, int, int) - ?ContentBitmaps@CXnControlAdapter@@QAEXAAPAVCFbsBitmap@@0@Z @ 29 NONAME ; void CXnControlAdapter::ContentBitmaps(class CFbsBitmap * &, class CFbsBitmap * &) - ?HandlePropertyChangeL@CXnControlAdapter@@QAEXPAVCXnProperty@@@Z @ 30 NONAME ; void CXnControlAdapter::HandlePropertyChangeL(class CXnProperty *) - ?FocusHorLoopingL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 31 NONAME ; class CXnProperty * CXnNodePluginIf::FocusHorLoopingL(void) - ?Control@CXnNodePluginIf@@QBEPAVCXnControlAdapter@@XZ @ 32 NONAME ; class CXnControlAdapter * CXnNodePluginIf::Control(void) const - ?GetPropertyL@CXnNodeAppIf@@QBEPAVCXnProperty@@AAV2@@Z @ 33 NONAME ; class CXnProperty * CXnNodeAppIf::GetPropertyL(class CXnProperty &) const - ?MakeInterfaceL@CXnComponentNodeImpl@@UAEPAVMXnComponentInterface@XnComponentInterface@@ABVTDesC8@@@Z @ 34 NONAME ; class XnComponentInterface::MXnComponentInterface * CXnComponentNodeImpl::MakeInterfaceL(class TDesC8 const &) - ?SkinChanged@CXnControlAdapter@@UAEXXZ @ 35 NONAME ; void CXnControlAdapter::SkinChanged(void) - ?SetContentBitmaps@CXnControlAdapter@@QAEXPAVCFbsBitmap@@0@Z @ 36 NONAME ; void CXnControlAdapter::SetContentBitmaps(class CFbsBitmap *, class CFbsBitmap *) - ?FindNodeByClassL@TXnUiEngineAppIf@@QAE?AV?$RPointerArray@VCXnNodeAppIf@@@@ABVTDesC16@@0@Z @ 37 NONAME ; class RPointerArray TXnUiEngineAppIf::FindNodeByClassL(class TDesC16 const &, class TDesC16 const &) - ?ComponentNodeImpl@CXnNodePluginIf@@QAEPAVCXnComponentNodeImpl@@XZ @ 38 NONAME ; class CXnComponentNodeImpl * CXnNodePluginIf::ComponentNodeImpl(void) - ??0CXnViewsNodeImpl@@IAE@XZ @ 39 NONAME ; CXnViewsNodeImpl::CXnViewsNodeImpl(void) - ?HandlePointerEventL@CXnControlAdapter@@UAEXABUTPointerEvent@@@Z @ 40 NONAME ; void CXnControlAdapter::HandlePointerEventL(struct TPointerEvent const &) - ??1CXnDocument@@UAE@XZ @ 41 NONAME ; CXnDocument::~CXnDocument(void) - ?HandleResourceChangeL@CXnAppUiAdapter@@MAEXH@Z @ 42 NONAME ; void CXnAppUiAdapter::HandleResourceChangeL(int) - ?DoEnterPowerSaveModeL@CXnControlAdapter@@UAEXW4TModeEvent@1@@Z @ 43 NONAME ; void CXnControlAdapter::DoEnterPowerSaveModeL(enum CXnControlAdapter::TModeEvent) - ?CloneL@CXnProperty@@QAEPAV1@XZ @ 44 NONAME ; class CXnProperty * CXnProperty::CloneL(void) - ?ReportTriggerEventL@CXnNodePluginIf@@QAEXABVTDesC8@@00@Z @ 45 NONAME ; void CXnNodePluginIf::ReportTriggerEventL(class TDesC8 const &, class TDesC8 const &, class TDesC8 const &) - ?FocusedNodeL@TXnUiEnginePluginIf@@QAEPAVCXnNodePluginIf@@XZ @ 46 NONAME ; class CXnNodePluginIf * TXnUiEnginePluginIf::FocusedNodeL(void) - ?FindContentSourceNodesL@TXnUiEngineAppIf@@QAE?AV?$RPointerArray@VCXnNodeAppIf@@@@ABVTDesC8@@@Z @ 47 NONAME ; class RPointerArray TXnUiEngineAppIf::FindContentSourceNodesL(class TDesC8 const &) - ?EqualsL@CXnProperty@@QBEHAAV1@@Z @ 48 NONAME ; int CXnProperty::EqualsL(class CXnProperty &) const - ?ScreenDeviceSize@TXnUiEnginePluginIf@@QAE?AVTSize@@XZ @ 49 NONAME ; class TSize TXnUiEnginePluginIf::ScreenDeviceSize(void) - ??0CXnControlAdapter@@IAE@XZ @ 50 NONAME ; CXnControlAdapter::CXnControlAdapter(void) - ?VisibleRowsL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 51 NONAME ; class CXnProperty * CXnNodePluginIf::VisibleRowsL(void) - ?UiEngineL@CXnNodeAppIf@@QAEPAVTXnUiEngineAppIf@@XZ @ 52 NONAME ; class TXnUiEngineAppIf * CXnNodeAppIf::UiEngineL(void) - ?LongTapDetector@CXnControlAdapter@@QBEPAVCAknLongTapDetector@@XZ @ 53 NONAME ; class CAknLongTapDetector * CXnControlAdapter::LongTapDetector(void) const - ??0CXnAppUiAdapter@@QAE@VTUid@@@Z @ 54 NONAME ; CXnAppUiAdapter::CXnAppUiAdapter(class TUid) - ?Rect@CXnNodePluginIf@@QAE?AVTRect@@XZ @ 55 NONAME ; class TRect CXnNodePluginIf::Rect(void) - ?AddChildL@CXnNodePluginIf@@QAEXPAV1@@Z @ 56 NONAME ; void CXnNodePluginIf::AddChildL(class CXnNodePluginIf *) - ?SetNode@CXnComponent@@QAEXAAVCXnNodePluginIf@@@Z @ 57 NONAME ; void CXnComponent::SetNode(class CXnNodePluginIf &) - ?ResetStylusCounter@CXnControlAdapter@@QAEXXZ @ 58 NONAME ; void CXnControlAdapter::ResetStylusCounter(void) - ?SetComponent@CXnComponentNodeImpl@@QAEXPAVCXnComponent@@@Z @ 59 NONAME ; void CXnComponentNodeImpl::SetComponent(class CXnComponent *) - ?LayoutUIL@TXnUiEnginePluginIf@@QAEXPAVCXnNodePluginIf@@@Z @ 60 NONAME ; void TXnUiEnginePluginIf::LayoutUIL(class CXnNodePluginIf *) - ?LoadDataPluginsL@CXnAppUiAdapter@@UAEXAAV?$RPointerArray@VCXnNodeAppIf@@@@@Z @ 61 NONAME ; void CXnAppUiAdapter::LoadDataPluginsL(class RPointerArray &) - ?FocusVisible@TXnUiEnginePluginIf@@QAEHXZ @ 62 NONAME ; int TXnUiEnginePluginIf::FocusVisible(void) - ?ExitPowerSaveModeL@CXnControlAdapter@@QAEXW4TModeEvent@1@@Z @ 63 NONAME ; void CXnControlAdapter::ExitPowerSaveModeL(enum CXnControlAdapter::TModeEvent) - ?GetThemeResource@TXnUiEngineAppIf@@QAEHABVTDesC16@@AAVRFile@@@Z @ 64 NONAME ; int TXnUiEngineAppIf::GetThemeResource(class TDesC16 const &, class RFile &) - ?ConstructL@CXnComponent@@IAEXXZ @ 65 NONAME ; void CXnComponent::ConstructL(void) - ?FindResource@CXnUtils@@SAPAVCXnResource@@AAV?$CArrayPtrSeg@VCXnResource@@@@ABVTDesC16@@AAH@Z @ 66 NONAME ; class CXnResource * CXnUtils::FindResource(class CArrayPtrSeg &, class TDesC16 const &, int &) - ?UnsetStateL@CXnNodeAppIf@@QAEXABVTDesC8@@@Z @ 67 NONAME ; void CXnNodeAppIf::UnsetStateL(class TDesC8 const &) - ?Uid@CXnDocument@@QAE?AVTUid@@XZ @ 68 NONAME ; class TUid CXnDocument::Uid(void) - ?FocusChanged@CXnControlAdapter@@UAEXW4TDrawNow@@@Z @ 69 NONAME ; void CXnControlAdapter::FocusChanged(enum TDrawNow) - ?SetBlank@CXnControlAdapter@@QAEXH@Z @ 70 NONAME ; void CXnControlAdapter::SetBlank(int) - ?SetLayoutCapable@CXnNodePluginIf@@QAEXH@Z @ 71 NONAME ; void CXnNodePluginIf::SetLayoutCapable(int) - ?MarginRect@CXnNodePluginIf@@QAE?AVTRect@@XZ @ 72 NONAME ; class TRect CXnNodePluginIf::MarginRect(void) - ?UiEngineL@CXnAppUiAdapter@@QAEPAVTXnUiEngineAppIf@@XZ @ 73 NONAME ; class TXnUiEngineAppIf * CXnAppUiAdapter::UiEngineL(void) - ?SwipeEnabledL@TXnUiEnginePluginIf@@QAEHXZ @ 74 NONAME ; int TXnUiEnginePluginIf::SwipeEnabledL(void) - ?SetFocusVisibleL@TXnUiEnginePluginIf@@QAEXH@Z @ 75 NONAME ; void TXnUiEnginePluginIf::SetFocusVisibleL(int) - ?ActiveView@TXnUiEngineAppIf@@QAEPAVCXnNodeAppIf@@XZ @ 76 NONAME ; class CXnNodeAppIf * TXnUiEngineAppIf::ActiveView(void) - ?GridOrientationL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 77 NONAME ; class CXnProperty * CXnNodePluginIf::GridOrientationL(void) - ?HandleXuikonEventL@CXnAppUiAdapter@@UAEXAAVCXnNodeAppIf@@0AAVCXnDomNode@@1@Z @ 78 NONAME ; void CXnAppUiAdapter::HandleXuikonEventL(class CXnNodeAppIf &, class CXnNodeAppIf &, class CXnDomNode &, class CXnDomNode &) - ?RenderUIL@TXnUiEngineAppIf@@QAEXPAVCXnNodeAppIf@@@Z @ 79 NONAME ; void TXnUiEngineAppIf::RenderUIL(class CXnNodeAppIf *) - ?DoHandlePropertyChangeL@CXnControlAdapter@@UAEXPAVCXnProperty@@@Z @ 80 NONAME ; void CXnControlAdapter::DoHandlePropertyChangeL(class CXnProperty *) - ?ConstructL@CXnControlAdapter@@IAEXAAVCXnNodePluginIf@@@Z @ 81 NONAME ; void CXnControlAdapter::ConstructL(class CXnNodePluginIf &) - ?FocusedNode@TXnUiEngineAppIf@@QAEPAVCXnNodeAppIf@@XZ @ 82 NONAME ; class CXnNodeAppIf * TXnUiEngineAppIf::FocusedNode(void) - ?OfferKeyEventL@CXnControlAdapter@@UAE?AW4TKeyResponse@@ABUTKeyEvent@@W4TEventCode@@@Z @ 83 NONAME ; enum TKeyResponse CXnControlAdapter::OfferKeyEventL(struct TKeyEvent const &, enum TEventCode) - ?IsDrawingAllowed@CXnControlAdapter@@QBEHXZ @ 84 NONAME ; int CXnControlAdapter::IsDrawingAllowed(void) const - ?DisplayL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 85 NONAME ; class CXnProperty * CXnNodePluginIf::DisplayL(void) - ?NewL@CXnProperty@@SAPAV1@ABVTDesC8@@PAVCXnDomPropertyValue@@AAVCXnDomStringPool@@@Z @ 86 NONAME ; class CXnProperty * CXnProperty::NewL(class TDesC8 const &, class CXnDomPropertyValue *, class CXnDomStringPool &) - ?Rect@CXnNodeAppIf@@QAE?AVTRect@@XZ @ 87 NONAME ; class TRect CXnNodeAppIf::Rect(void) - ?NewL@CXnComponentNodeImpl@@SAPAV1@PAVCXnType@@@Z @ 88 NONAME ; class CXnComponentNodeImpl * CXnComponentNodeImpl::NewL(class CXnType *) - ?GridVerDirectionL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 89 NONAME ; class CXnProperty * CXnNodePluginIf::GridVerDirectionL(void) - ?WidgetsVisible@TXnUiEngineAppIf@@QBEHXZ @ 90 NONAME ; int TXnUiEngineAppIf::WidgetsVisible(void) const - ?Type@CXnNodePluginIf@@QAEPAVCXnType@@XZ @ 91 NONAME ; class CXnType * CXnNodePluginIf::Type(void) - ?MakeXnComponentL@MXnComponentFactory@@EAE?AW4TXnComponentFactoryResponse@1@AAVCXnNodePluginIf@@AAPAVCXnComponent@@@Z @ 92 NONAME ; enum MXnComponentFactory::TXnComponentFactoryResponse MXnComponentFactory::MakeXnComponentL(class CXnNodePluginIf &, class CXnComponent * &) - ?ActivateViewL@TXnUiEngineAppIf@@QAEXAAVCXnNodeAppIf@@@Z @ 93 NONAME ; void TXnUiEngineAppIf::ActivateViewL(class CXnNodeAppIf &) - ?UnsetStateL@CXnNodePluginIf@@QAEXABVTDesC8@@@Z @ 94 NONAME ; void CXnNodePluginIf::UnsetStateL(class TDesC8 const &) - ?StringValueL@CXnProperty@@QAEPAVHBufC16@@XZ @ 95 NONAME ; class HBufC16 * CXnProperty::StringValueL(void) - ?DisableRenderUiLC@TXnUiEnginePluginIf@@QAEXXZ @ 96 NONAME ; void TXnUiEnginePluginIf::DisableRenderUiLC(void) - ?SetPropertyL@CXnNodeAppIf@@QAEXPAVCXnProperty@@@Z @ 97 NONAME ; void CXnNodeAppIf::SetPropertyL(class CXnProperty *) - ?View@CXnAppUiAdapter@@QBEAAVCAknView@@XZ @ 98 NONAME ; class CAknView & CXnAppUiAdapter::View(void) const - ?ViewNodeImpl@CXnNodePluginIf@@QAEPAVCXnViewNodeImpl@@XZ @ 99 NONAME ; class CXnViewNodeImpl * CXnNodePluginIf::ViewNodeImpl(void) - ?StripQuotes@CXnUtils@@SAXAAPAVHBufC16@@@Z @ 100 NONAME ; void CXnUtils::StripQuotes(class HBufC16 * &) - ?SetPCDataL@CXnNodePluginIf@@QAEXABVTDesC8@@@Z @ 101 NONAME ; void CXnNodePluginIf::SetPCDataL(class TDesC8 const &) - ?DestroyDataPluginsL@CXnAppUiAdapter@@UAEXAAV?$RPointerArray@VCXnNodeAppIf@@@@@Z @ 102 NONAME ; void CXnAppUiAdapter::DestroyDataPluginsL(class RPointerArray &) - ?VisibilityL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 103 NONAME ; class CXnProperty * CXnNodePluginIf::VisibilityL(void) - ?Draw@CXnControlAdapter@@MBEXABVTRect@@@Z @ 104 NONAME ; void CXnControlAdapter::Draw(class TRect const &) const - ??1CXnApplication@@UAE@XZ @ 105 NONAME ; CXnApplication::~CXnApplication(void) - ?DoesNodeNeedComponentImplL@MXnComponentFactory@@QAEHABVTDesC8@@@Z @ 106 NONAME ; int MXnComponentFactory::DoesNodeNeedComponentImplL(class TDesC8 const &) - ?ConstructL@CXnViewsNodeImpl@@IAEXPAVCXnType@@@Z @ 107 NONAME ; void CXnViewsNodeImpl::ConstructL(class CXnType *) - ?StringPool@TXnUiEngineAppIf@@QAEAAVCXnDomStringPool@@XZ @ 108 NONAME ; class CXnDomStringPool & TXnUiEngineAppIf::StringPool(void) - ?UiEngineL@CXnNodePluginIf@@QAEPAVTXnUiEnginePluginIf@@XZ @ 109 NONAME ; class TXnUiEnginePluginIf * CXnNodePluginIf::UiEngineL(void) - ?ShowFocus@TXnUiEnginePluginIf@@QAEHXZ @ 110 NONAME ; int TXnUiEnginePluginIf::ShowFocus(void) - ?ResolveSkinItemIDL@CXnUtils@@SAHABVTDesC16@@AAVTAknsItemID@@@Z @ 111 NONAME ; int CXnUtils::ResolveSkinItemIDL(class TDesC16 const &, class TAknsItemID &) - ?PluginNodeL@TXnUiEnginePluginIf@@QAEAAVCXnNodePluginIf@@PAV2@@Z @ 112 NONAME ; class CXnNodePluginIf & TXnUiEnginePluginIf::PluginNodeL(class CXnNodePluginIf *) - ?VerticalPixelValueL@TXnUiEnginePluginIf@@QAEHPAVCXnProperty@@H@Z @ 113 NONAME ; int TXnUiEnginePluginIf::VerticalPixelValueL(class CXnProperty *, int) - ?SetComponent@CXnControlAdapter@@QAEXPAVCXnComponent@@@Z @ 114 NONAME ; void CXnControlAdapter::SetComponent(class CXnComponent *) - ??0MXnNodePredicate@@QAE@XZ @ 115 NONAME ; MXnNodePredicate::MXnNodePredicate(void) - ??1CXnViewsNodeImpl@@UAE@XZ @ 116 NONAME ; CXnViewsNodeImpl::~CXnViewsNodeImpl(void) - ?HandleControlEventL@CXnControlAdapter@@UAEXPAVCCoeControl@@W4TCoeEvent@MCoeControlObserver@@@Z @ 117 NONAME ; void CXnControlAdapter::HandleControlEventL(class CCoeControl *, enum MCoeControlObserver::TCoeEvent) - ?ActivateViewL@TXnUiEnginePluginIf@@QAEXAAVCXnNodePluginIf@@@Z @ 118 NONAME ; void TXnUiEnginePluginIf::ActivateViewL(class CXnNodePluginIf &) - ?HandleScreenDeviceChangedL@CXnControlAdapter@@UAEXXZ @ 119 NONAME ; void CXnControlAdapter::HandleScreenDeviceChangedL(void) - ?SizeChanged@CXnControlAdapter@@MAEXXZ @ 120 NONAME ; void CXnControlAdapter::SizeChanged(void) - ?CountComponentControls@CXnControlAdapter@@MBEHXZ @ 121 NONAME ; int CXnControlAdapter::CountComponentControls(void) const - ?HideTooltipsL@CXnNodeAppIf@@QAEXXZ @ 122 NONAME ; void CXnNodeAppIf::HideTooltipsL(void) - ?GetPropertyL@CXnNodeAppIf@@QBEPAVCXnProperty@@ABVTDesC8@@@Z @ 123 NONAME ; class CXnProperty * CXnNodeAppIf::GetPropertyL(class TDesC8 const &) const - ?GridScrollBarWidthL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 124 NONAME ; class CXnProperty * CXnNodePluginIf::GridScrollBarWidthL(void) - ?DeactivateFocusedNodeL@TXnUiEnginePluginIf@@QAEXXZ @ 125 NONAME ; void TXnUiEnginePluginIf::DeactivateFocusedNodeL(void) - ?FindNodeByClassL@TXnUiEngineAppIf@@QAE?AV?$RPointerArray@VCXnNodeAppIf@@@@ABVTDesC8@@0@Z @ 126 NONAME ; class RPointerArray TXnUiEngineAppIf::FindNodeByClassL(class TDesC8 const &, class TDesC8 const &) - ?Match@MXnNodePredicate@@UAEHAAVCXnNode@@@Z @ 127 NONAME ; int MXnNodePredicate::Match(class CXnNode &) - ?GetBitmapAndMask@CXnControlAdapter@@QAEXABVTDesC16@@0AAPAVCFbsBitmap@@1@Z @ 128 NONAME ; void CXnControlAdapter::GetBitmapAndMask(class TDesC16 const &, class TDesC16 const &, class CFbsBitmap * &, class CFbsBitmap * &) - ?NewL@CXnViewsNodeImpl@@SAPAV1@PAVCXnType@@@Z @ 129 NONAME ; class CXnViewsNodeImpl * CXnViewsNodeImpl::NewL(class CXnType *) - ?PaddingRect@CXnNodeAppIf@@QAE?AVTRect@@XZ @ 130 NONAME ; class TRect CXnNodeAppIf::PaddingRect(void) - ?SetMarginRect@CXnNodePluginIf@@QAEXABVTRect@@@Z @ 131 NONAME ; void CXnNodePluginIf::SetMarginRect(class TRect const &) - ?IsDialogDisplaying@TXnUiEnginePluginIf@@QAEHXZ @ 132 NONAME ; int TXnUiEnginePluginIf::IsDialogDisplaying(void) - ?GetPropertyL@CXnNodePluginIf@@QBEPAVCXnProperty@@ABVTDesC8@@@Z @ 133 NONAME ; class CXnProperty * CXnNodePluginIf::GetPropertyL(class TDesC8 const &) const - ?SetPropertyArrayL@CXnNodeAppIf@@QAEXPAV?$RPointerArray@VCXnProperty@@@@@Z @ 134 NONAME ; void CXnNodeAppIf::SetPropertyArrayL(class RPointerArray *) - ?RestorePreviousFocusedNode@TXnUiEnginePluginIf@@QAEXXZ @ 135 NONAME ; void TXnUiEnginePluginIf::RestorePreviousFocusedNode(void) - ?EnterPowerSaveModeL@CXnComponent@@UAEXXZ @ 136 NONAME ; void CXnComponent::EnterPowerSaveModeL(void) - ?SetRect@CXnNodePluginIf@@QAEXABVTRect@@@Z @ 137 NONAME ; void CXnNodePluginIf::SetRect(class TRect const &) - ??0CXnComponent@@IAE@XZ @ 138 NONAME ; CXnComponent::CXnComponent(void) - ?CollapseWhiteSpace@CXnUtils@@SAXAAVCXnNodePluginIf@@AAVTDes16@@@Z @ 139 NONAME ; void CXnUtils::CollapseWhiteSpace(class CXnNodePluginIf &, class TDes16 &) - ?SetHandleTooltip@CXnNodePluginIf@@QAEXH@Z @ 140 NONAME ; void CXnNodePluginIf::SetHandleTooltip(int) - ??1CXnAppUiAdapter@@UAE@XZ @ 141 NONAME ; CXnAppUiAdapter::~CXnAppUiAdapter(void) - ?SetOnlineStateL@CXnAppUiAdapter@@UAEXAAV?$RPointerArray@VCXnNodeAppIf@@@@@Z @ 142 NONAME ; void CXnAppUiAdapter::SetOnlineStateL(class RPointerArray &) - ?NewL@CXnControlAdapter@@SAPAV1@AAVCXnNodePluginIf@@@Z @ 143 NONAME ; class CXnControlAdapter * CXnControlAdapter::NewL(class CXnNodePluginIf &) - ?EnableLongTapAnimation@CXnControlAdapter@@QAEXH@Z @ 144 NONAME ; void CXnControlAdapter::EnableLongTapAnimation(int) - ?RefL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 145 NONAME ; class CXnProperty * CXnNodePluginIf::RefL(void) - ?SetPaddingRect@CXnNodePluginIf@@QAEXABVTRect@@@Z @ 146 NONAME ; void CXnNodePluginIf::SetPaddingRect(class TRect const &) - ?FocusVerLoopingL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 147 NONAME ; class CXnProperty * CXnNodePluginIf::FocusVerLoopingL(void) - ?SetFocusedNode@TXnUiEnginePluginIf@@QAEXPAVCXnNodePluginIf@@@Z @ 148 NONAME ; void TXnUiEnginePluginIf::SetFocusedNode(class CXnNodePluginIf *) - ?ExitPowerSaveModeL@CXnComponent@@UAEXXZ @ 149 NONAME ; void CXnComponent::ExitPowerSaveModeL(void) - ?EnableSwipeL@TXnUiEnginePluginIf@@QAEXH@Z @ 150 NONAME ; void TXnUiEnginePluginIf::EnableSwipeL(int) - ?GetPCData@CXnNodeAppIf@@QBEABVTDesC8@@XZ @ 151 NONAME ; class TDesC8 const & CXnNodeAppIf::GetPCData(void) const - ?Namespace@CXnNodeAppIf@@QAEABVTDesC8@@XZ @ 152 NONAME ; class TDesC8 const & CXnNodeAppIf::Namespace(void) - ??1CXnComponentNodeImpl@@UAE@XZ @ 153 NONAME ; CXnComponentNodeImpl::~CXnComponentNodeImpl(void) - ?SetPropertyWithoutNotificationL@CXnNodePluginIf@@QAEXPAVCXnProperty@@@Z @ 154 NONAME ; void CXnNodePluginIf::SetPropertyWithoutNotificationL(class CXnProperty *) - ?GetPCData@CXnNodePluginIf@@QBEABVTDesC8@@XZ @ 155 NONAME ; class TDesC8 const & CXnNodePluginIf::GetPCData(void) const - ?SetPCDataL@CXnNodeAppIf@@QAEXABVTDesC8@@@Z @ 156 NONAME ; void CXnNodeAppIf::SetPCDataL(class TDesC8 const &) - ?Resources@TXnUiEnginePluginIf@@QAEAAV?$CArrayPtrSeg@VCXnResource@@@@XZ @ 157 NONAME ; class CArrayPtrSeg & TXnUiEnginePluginIf::Resources(void) - ?SetContentBitmaps@CXnControlAdapter@@QAEXABVTDesC16@@0@Z @ 158 NONAME ; void CXnControlAdapter::SetContentBitmaps(class TDesC16 const &, class TDesC16 const &) - ??1CXnControlAdapter@@UAE@XZ @ 159 NONAME ; CXnControlAdapter::~CXnControlAdapter(void) - ??1MXnNodePredicate@@UAE@XZ @ 160 NONAME ; MXnNodePredicate::~MXnNodePredicate(void) - ?HorizontalTwipValueL@TXnUiEnginePluginIf@@QAEHPAVCXnProperty@@H@Z @ 161 NONAME ; int TXnUiEnginePluginIf::HorizontalTwipValueL(class CXnProperty *, int) - ?ConstructL@CXnAppUiAdapter@@UAEXXZ @ 162 NONAME ; void CXnAppUiAdapter::ConstructL(void) - ?CreateFontL@CXnUtils@@SAXAAVCXnNodePluginIf@@AAPAVCFont@@AAH@Z @ 163 NONAME ; void CXnUtils::CreateFontL(class CXnNodePluginIf &, class CFont * &, int &) - ??0CXnApplication@@QAE@VTUid@@@Z @ 164 NONAME ; CXnApplication::CXnApplication(class TUid) - ?ComponentControl@CXnControlAdapter@@MBEPAVCCoeControl@@H@Z @ 165 NONAME ; class CCoeControl * CXnControlAdapter::ComponentControl(int) const - ?HandlePageSwitch@CXnAppUiAdapter@@UAEXXZ @ 166 NONAME ; void CXnAppUiAdapter::HandlePageSwitch(void) - ?HandleLongTapEventL@CXnControlAdapter@@UAEXABVTPoint@@0@Z @ 167 NONAME ; void CXnControlAdapter::HandleLongTapEventL(class TPoint const &, class TPoint const &) - ?ParentL@CXnNodeAppIf@@QBEPAV1@XZ @ 168 NONAME ; class CXnNodeAppIf * CXnNodeAppIf::ParentL(void) const - ??1CXnComponent@@UAE@XZ @ 169 NONAME ; CXnComponent::~CXnComponent(void) - ?ControlAdapter@CXnComponent@@QAEPAVCXnControlAdapter@@XZ @ 170 NONAME ; class CXnControlAdapter * CXnComponent::ControlAdapter(void) - ?DrawContentImage@CXnControlAdapter@@IBEXXZ @ 171 NONAME ; void CXnControlAdapter::DrawContentImage(void) const - ?Component@CXnComponentNodeImpl@@QAEPAVCXnComponent@@XZ @ 172 NONAME ; class CXnComponent * CXnComponentNodeImpl::Component(void) - ?GridScrollBarMarginL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 173 NONAME ; class CXnProperty * CXnNodePluginIf::GridScrollBarMarginL(void) - ?WidgetsVisible@TXnUiEnginePluginIf@@QBEHXZ @ 174 NONAME ; int TXnUiEnginePluginIf::WidgetsVisible(void) const - ?SetControlAdapter@CXnComponent@@QAEXPAVCXnControlAdapter@@@Z @ 175 NONAME ; void CXnComponent::SetControlAdapter(class CXnControlAdapter *) - ?GridColumnsL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 176 NONAME ; class CXnProperty * CXnNodePluginIf::GridColumnsL(void) - ?SetStateL@CXnNodePluginIf@@QAEXABVTDesC8@@@Z @ 177 NONAME ; void CXnNodePluginIf::SetStateL(class TDesC8 const &) - ?DoesComponentNeedCreation@CXnComponentNodeImpl@@QBEHXZ @ 178 NONAME ; int CXnComponentNodeImpl::DoesComponentNeedCreation(void) const - ??0CXnDocument@@QAE@AAVCEikApplication@@VTUid@@@Z @ 179 NONAME ; CXnDocument::CXnDocument(class CEikApplication &, class TUid) - ?FindNodeByClassL@TXnUiEnginePluginIf@@QAE?AV?$RPointerArray@VCXnNodePluginIf@@@@ABVTDesC16@@@Z @ 180 NONAME ; class RPointerArray TXnUiEnginePluginIf::FindNodeByClassL(class TDesC16 const &) - ?GridHorDirectionL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 181 NONAME ; class CXnProperty * CXnNodePluginIf::GridHorDirectionL(void) - ?InternalDomNodeType@CXnNodeAppIf@@QBEABVTDesC8@@XZ @ 182 NONAME ; class TDesC8 const & CXnNodeAppIf::InternalDomNodeType(void) const - ?StringPool@TXnUiEnginePluginIf@@QAEAAVCXnDomStringPool@@XZ @ 183 NONAME ; class CXnDomStringPool & TXnUiEnginePluginIf::StringPool(void) - ?SetStateL@CXnNodeAppIf@@QAEXABVTDesC8@@@Z @ 184 NONAME ; void CXnNodeAppIf::SetStateL(class TDesC8 const &) - ?Type@CXnNodeAppIf@@QAEPAVCXnType@@XZ @ 185 NONAME ; class CXnType * CXnNodeAppIf::Type(void) - ?BorderRect@CXnNodeAppIf@@QAE?AVTRect@@XZ @ 186 NONAME ; class TRect CXnNodeAppIf::BorderRect(void) - ?IdL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 187 NONAME ; class CXnProperty * CXnNodePluginIf::IdL(void) - ?RootNodeL@TXnUiEngineAppIf@@QAEAAVCXnNodeAppIf@@XZ @ 188 NONAME ; class CXnNodeAppIf & TXnUiEngineAppIf::RootNodeL(void) - ?CreateXnComponentL@MXnComponentFactory@@QAE?AW4TXnComponentFactoryResponse@1@AAVCXnNodePluginIf@@AAPAVCXnComponent@@@Z @ 189 NONAME ; enum MXnComponentFactory::TXnComponentFactoryResponse MXnComponentFactory::CreateXnComponentL(class CXnNodePluginIf &, class CXnComponent * &) - ?RefreshMenuL@TXnUiEngineAppIf@@QAEXXZ @ 190 NONAME ; void TXnUiEngineAppIf::RefreshMenuL(void) - ?PaddingRect@CXnNodePluginIf@@QAE?AVTRect@@XZ @ 191 NONAME ; class TRect CXnNodePluginIf::PaddingRect(void) - ?MeasureAdaptiveContentL@CXnControlAdapter@@UAE?AVTSize@@ABV2@@Z @ 192 NONAME ; class TSize CXnControlAdapter::MeasureAdaptiveContentL(class TSize const &) - ?NewL@CXnProperty@@SAPAV1@ABVTDesC8@@0W4TPrimitiveValueType@CXnDomPropertyValue@@AAVCXnDomStringPool@@@Z @ 193 NONAME ; class CXnProperty * CXnProperty::NewL(class TDesC8 const &, class TDesC8 const &, enum CXnDomPropertyValue::TPrimitiveValueType, class CXnDomStringPool &) - ?GetPropertyL@CXnNodePluginIf@@QBEPAVCXnProperty@@AAV2@@Z @ 194 NONAME ; class CXnProperty * CXnNodePluginIf::GetPropertyL(class CXnProperty &) const - ?HitRegion@TXnUiEnginePluginIf@@QBEPAVCXnControlAdapter@@XZ @ 195 NONAME ; class CXnControlAdapter * TXnUiEnginePluginIf::HitRegion(void) const - ?MarginRect@CXnNodeAppIf@@QAE?AVTRect@@XZ @ 196 NONAME ; class TRect CXnNodeAppIf::MarginRect(void) - ?MakeInterfaceL@CXnComponent@@UAEPAVMXnComponentInterface@XnComponentInterface@@ABVTDesC8@@@Z @ 197 NONAME ; class XnComponentInterface::MXnComponentInterface * CXnComponent::MakeInterfaceL(class TDesC8 const &) - ?EditMode@TXnUiEnginePluginIf@@QAEHXZ @ 198 NONAME ; int TXnUiEnginePluginIf::EditMode(void) - ?FindNodeByIdL@TXnUiEnginePluginIf@@QAEPAVCXnNodePluginIf@@ABVTDesC8@@0@Z @ 199 NONAME ; class CXnNodePluginIf * TXnUiEnginePluginIf::FindNodeByIdL(class TDesC8 const &, class TDesC8 const &) - ?EnableRenderUi@CXnUiEngineImpl@@CAXPAX@Z @ 200 NONAME ; void CXnUiEngineImpl::EnableRenderUi(void *) - ?IsMenuDisplaying@TXnUiEnginePluginIf@@QAEHXZ @ 201 NONAME ; int TXnUiEnginePluginIf::IsMenuDisplaying(void) - ?IsMenuDisplaying@TXnUiEngineAppIf@@QAEHXZ @ 202 NONAME ; int TXnUiEngineAppIf::IsMenuDisplaying(void) - ?NewL@CXnProperty@@SAPAV1@PAVCXnDomProperty@@@Z @ 203 NONAME ; class CXnProperty * CXnProperty::NewL(class CXnDomProperty *) - ?ConstructL@CXnComponentNodeImpl@@IAEXPAVCXnType@@@Z @ 204 NONAME ; void CXnComponentNodeImpl::ConstructL(class CXnType *) - ?ChildrenL@CXnNodeAppIf@@QAE?AV?$RPointerArray@VCXnNodeAppIf@@@@XZ @ 205 NONAME ; class RPointerArray CXnNodeAppIf::ChildrenL(void) - ?ConvertHslToRgb@CXnUtils@@SA?AVTRgb@@HHH@Z @ 206 NONAME ; class TRgb CXnUtils::ConvertHslToRgb(int, int, int) - ?LoadBitmap@CXnControlAdapter@@QAEPAVCFbsBitmap@@ABVTDesC16@@@Z @ 207 NONAME ; class CFbsBitmap * CXnControlAdapter::LoadBitmap(class TDesC16 const &) - ??0MXnComponentFactory@@IAE@XZ @ 208 NONAME ; MXnComponentFactory::MXnComponentFactory(void) - ?SetComponent@CXnViewsNodeImpl@@QAEXPAVCXnComponent@@@Z @ 209 NONAME ; void CXnViewsNodeImpl::SetComponent(class CXnComponent *) - ?BorderRect@CXnNodePluginIf@@QAE?AVTRect@@XZ @ 210 NONAME ; class TRect CXnNodePluginIf::BorderRect(void) - ?CreateDocumentL@CXnApplication@@MAEPAVCApaDocument@@XZ @ 211 NONAME ; class CApaDocument * CXnApplication::CreateDocumentL(void) - ?CreateFontL@CXnUtils@@SAXABVTDesC16@@HVTFontStyle@@AAPAVCFont@@AAH@Z @ 212 NONAME ; void CXnUtils::CreateFontL(class TDesC16 const &, int, class TFontStyle, class CFont * &, int &) - ?GetPluginNodeArrayL@TXnUiEngineAppIf@@QAEHAAV?$RPointerArray@VCXnNodeAppIf@@@@@Z @ 213 NONAME ; int TXnUiEngineAppIf::GetPluginNodeArrayL(class RPointerArray &) - ?MakeXnControlAdapterL@MXnComponentFactory@@EAEPAVCXnControlAdapter@@AAVCXnNodePluginIf@@PAV2@@Z @ 214 NONAME ; class CXnControlAdapter * MXnComponentFactory::MakeXnControlAdapterL(class CXnNodePluginIf &, class CXnControlAdapter *) - ?IsDrawingAllowed@CXnNodePluginIf@@QBEHXZ @ 215 NONAME ; int CXnNodePluginIf::IsDrawingAllowed(void) const - ?MakeInterfaceL@CXnNodeAppIf@@QAEPAVMXnComponentInterface@XnComponentInterface@@ABVTDesC8@@@Z @ 216 NONAME ; class XnComponentInterface::MXnComponentInterface * CXnNodeAppIf::MakeInterfaceL(class TDesC8 const &) - ?VerticalTwipValueL@TXnUiEnginePluginIf@@QAEHPAVCXnProperty@@H@Z @ 217 NONAME ; int TXnUiEnginePluginIf::VerticalTwipValueL(class CXnProperty *, int) - ?Component@CXnControlAdapter@@QAEPAVCXnComponent@@XZ @ 218 NONAME ; class CXnComponent * CXnControlAdapter::Component(void) - ?FloatValueL@CXnProperty@@QAENXZ @ 219 NONAME ; double CXnProperty::FloatValueL(void) - ?SetUiEngine@TXnUiEngineAppIf@@QAEXPAVCXnUiEngine@@@Z @ 220 NONAME ; void TXnUiEngineAppIf::SetUiEngine(class CXnUiEngine *) - ?FindNodeByIdL@TXnUiEngineAppIf@@QAEPAVCXnNodeAppIf@@ABVTDesC16@@0@Z @ 221 NONAME ; class CXnNodeAppIf * TXnUiEngineAppIf::FindNodeByIdL(class TDesC16 const &, class TDesC16 const &) - ?IsEditMode@TXnUiEngineAppIf@@QAEHXZ @ 222 NONAME ; int TXnUiEngineAppIf::IsEditMode(void) - ?ResolveSkinItemIDL@CXnUtils@@SAHABVTDesC16@@AAVTAknsItemID@@AAH@Z @ 223 NONAME ; int CXnUtils::ResolveSkinItemIDL(class TDesC16 const &, class TAknsItemID &, int &) - ?RootNodeL@TXnUiEnginePluginIf@@QAEAAVCXnNodePluginIf@@XZ @ 224 NONAME ; class CXnNodePluginIf & TXnUiEnginePluginIf::RootNodeL(void) - ?CreateAppUiL@CXnDocument@@UAEPAVCEikAppUi@@XZ @ 225 NONAME ; class CEikAppUi * CXnDocument::CreateAppUiL(void) - ?PathL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 226 NONAME ; class CXnProperty * CXnNodePluginIf::PathL(void) - ?NewL@CXnProperty@@SAPAV1@ABVTDesC8@@NW4TPrimitiveValueType@CXnDomPropertyValue@@AAVCXnDomStringPool@@@Z @ 227 NONAME ; class CXnProperty * CXnProperty::NewL(class TDesC8 const &, double, enum CXnDomPropertyValue::TPrimitiveValueType, class CXnDomStringPool &) - ?MaskPathL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 228 NONAME ; class CXnProperty * CXnNodePluginIf::MaskPathL(void) - ?AppDllUid@CXnApplication@@MBE?AVTUid@@XZ @ 229 NONAME ; class TUid CXnApplication::AppDllUid(void) const - ?DoExitPowerSaveModeL@CXnControlAdapter@@UAEXW4TModeEvent@1@@Z @ 230 NONAME ; void CXnControlAdapter::DoExitPowerSaveModeL(enum CXnControlAdapter::TModeEvent) - ?LabelL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 231 NONAME ; class CXnProperty * CXnNodePluginIf::LabelL(void) - ?Component@CXnViewsNodeImpl@@QAEPAVCXnComponent@@XZ @ 232 NONAME ; class CXnComponent * CXnViewsNodeImpl::Component(void) - ?GetRgbValue@CXnUtils@@SAHAAVTRgb@@ABVTDesC8@@@Z @ 233 NONAME ; int CXnUtils::GetRgbValue(class TRgb &, class TDesC8 const &) - ?StringValue@CXnProperty@@QAEABVTDesC8@@XZ @ 234 NONAME ; class TDesC8 const & CXnProperty::StringValue(void) - ?SetVisible@CXnControlAdapter@@QAEXH@Z @ 235 NONAME ; void CXnControlAdapter::SetVisible(int) - ?Node@CXnComponent@@QAEPAVCXnNodePluginIf@@XZ @ 236 NONAME ; class CXnNodePluginIf * CXnComponent::Node(void) - ?HandleEnterEditModeL@CXnAppUiAdapter@@UAEXH@Z @ 237 NONAME ; void CXnAppUiAdapter::HandleEnterEditModeL(int) + ?HandleEnterEditModeL@CXnAppUiAdapter@@UAEXH@Z @ 13 NONAME ; void CXnAppUiAdapter::HandleEnterEditModeL(int) + ?EnterPowerSaveModeL@CXnControlAdapter@@QAEXW4TModeEvent@1@@Z @ 14 NONAME ; void CXnControlAdapter::EnterPowerSaveModeL(enum CXnControlAdapter::TModeEvent) + ??0CXnComponentNodeImpl@@IAE@XZ @ 15 NONAME ; CXnComponentNodeImpl::CXnComponentNodeImpl(void) + ?SetLocalUiZoomL@CXnControlAdapter@@UAEXW4TAknUiZoom@@@Z @ 16 NONAME ; void CXnControlAdapter::SetLocalUiZoomL(enum TAknUiZoom) + ?SetDirtyL@CXnNodePluginIf@@QAEXXZ @ 17 NONAME ; void CXnNodePluginIf::SetDirtyL(void) + ?Draw@CXnControlAdapter@@UBEXABVTRect@@AAVCWindowGc@@@Z @ 18 NONAME ; void CXnControlAdapter::Draw(class TRect const &, class CWindowGc &) const + ?ShowTooltipsL@CXnNodeAppIf@@QAEXXZ @ 19 NONAME ; void CXnNodeAppIf::ShowTooltipsL(void) + ?MakeInterfaceL@CXnNodePluginIf@@QAEPAVMXnComponentInterface@XnComponentInterface@@ABVTDesC8@@@Z @ 20 NONAME ; class XnComponentInterface::MXnComponentInterface * CXnNodePluginIf::MakeInterfaceL(class TDesC8 const &) + ?SetBorderRect@CXnNodePluginIf@@QAEXABVTRect@@@Z @ 21 NONAME ; void CXnNodePluginIf::SetBorderRect(class TRect const &) + ?RenderUIL@TXnUiEnginePluginIf@@QAEXPAVCXnNodePluginIf@@@Z @ 22 NONAME ; void TXnUiEnginePluginIf::RenderUIL(class CXnNodePluginIf *) + ?TextAlignment@CXnUtils@@SA?AW4TGulAlignmentValue@@AAVCXnNodePluginIf@@@Z @ 23 NONAME ; enum TGulAlignmentValue CXnUtils::TextAlignment(class CXnNodePluginIf &) + ?Property@CXnProperty@@QAEPAVCXnDomProperty@@XZ @ 24 NONAME ; class CXnDomProperty * CXnProperty::Property(void) + ?Namespace@CXnNodePluginIf@@QAEABVTDesC8@@XZ @ 25 NONAME ; class TDesC8 const & CXnNodePluginIf::Namespace(void) + ?AddDirtyNodeL@TXnUiEnginePluginIf@@QAEXAAVCXnNodePluginIf@@@Z @ 26 NONAME ; void TXnUiEnginePluginIf::AddDirtyNodeL(class CXnNodePluginIf &) + ?SetPropertyL@CXnNodePluginIf@@QAEXPAVCXnProperty@@@Z @ 27 NONAME ; void CXnNodePluginIf::SetPropertyL(class CXnProperty *) + ?HorizontalPixelValueL@TXnUiEnginePluginIf@@QAEHPAVCXnProperty@@H@Z @ 28 NONAME ; int TXnUiEnginePluginIf::HorizontalPixelValueL(class CXnProperty *, int) + ?HandlePowerSaveModeL@CXnUtils@@SAHPAVCXnNode@@HH@Z @ 29 NONAME ; int CXnUtils::HandlePowerSaveModeL(class CXnNode *, int, int) + ?ContentBitmaps@CXnControlAdapter@@QAEXAAPAVCFbsBitmap@@0@Z @ 30 NONAME ; void CXnControlAdapter::ContentBitmaps(class CFbsBitmap * &, class CFbsBitmap * &) + ?HandlePropertyChangeL@CXnControlAdapter@@QAEXPAVCXnProperty@@@Z @ 31 NONAME ; void CXnControlAdapter::HandlePropertyChangeL(class CXnProperty *) + ?FocusHorLoopingL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 32 NONAME ; class CXnProperty * CXnNodePluginIf::FocusHorLoopingL(void) + ?Control@CXnNodePluginIf@@QBEPAVCXnControlAdapter@@XZ @ 33 NONAME ; class CXnControlAdapter * CXnNodePluginIf::Control(void) const + ?DestroyPublisher@CXnAppUiAdapter@@UAEHAAVCXnNodeAppIf@@H@Z @ 34 NONAME ; int CXnAppUiAdapter::DestroyPublisher(class CXnNodeAppIf &, int) + ?GetPropertyL@CXnNodeAppIf@@QBEPAVCXnProperty@@AAV2@@Z @ 35 NONAME ; class CXnProperty * CXnNodeAppIf::GetPropertyL(class CXnProperty &) const + ?MakeInterfaceL@CXnComponentNodeImpl@@UAEPAVMXnComponentInterface@XnComponentInterface@@ABVTDesC8@@@Z @ 36 NONAME ; class XnComponentInterface::MXnComponentInterface * CXnComponentNodeImpl::MakeInterfaceL(class TDesC8 const &) + ?SkinChanged@CXnControlAdapter@@UAEXXZ @ 37 NONAME ; void CXnControlAdapter::SkinChanged(void) + ?SetContentBitmaps@CXnControlAdapter@@QAEXPAVCFbsBitmap@@0@Z @ 38 NONAME ; void CXnControlAdapter::SetContentBitmaps(class CFbsBitmap *, class CFbsBitmap *) + ?FindNodeByClassL@TXnUiEngineAppIf@@QAE?AV?$RPointerArray@VCXnNodeAppIf@@@@ABVTDesC16@@0@Z @ 39 NONAME ; class RPointerArray TXnUiEngineAppIf::FindNodeByClassL(class TDesC16 const &, class TDesC16 const &) + ?SetDataL@CXnControlAdapter@@UAEXABVTDesC8@@ABVTDesC16@@H@Z @ 40 NONAME ; void CXnControlAdapter::SetDataL(class TDesC8 const &, class TDesC16 const &, int) + ?ComponentNodeImpl@CXnNodePluginIf@@QAEPAVCXnComponentNodeImpl@@XZ @ 41 NONAME ; class CXnComponentNodeImpl * CXnNodePluginIf::ComponentNodeImpl(void) + ??0CXnViewsNodeImpl@@IAE@XZ @ 42 NONAME ; CXnViewsNodeImpl::CXnViewsNodeImpl(void) + ?HandlePointerEventL@CXnControlAdapter@@UAEXABUTPointerEvent@@@Z @ 43 NONAME ; void CXnControlAdapter::HandlePointerEventL(struct TPointerEvent const &) + ??1CXnDocument@@UAE@XZ @ 44 NONAME ; CXnDocument::~CXnDocument(void) + ?HandleResourceChangeL@CXnAppUiAdapter@@MAEXH@Z @ 45 NONAME ; void CXnAppUiAdapter::HandleResourceChangeL(int) + ?DoEnterPowerSaveModeL@CXnControlAdapter@@UAEXW4TModeEvent@1@@Z @ 46 NONAME ; void CXnControlAdapter::DoEnterPowerSaveModeL(enum CXnControlAdapter::TModeEvent) + ?CloneL@CXnProperty@@QAEPAV1@XZ @ 47 NONAME ; class CXnProperty * CXnProperty::CloneL(void) + ?ReportTriggerEventL@CXnNodePluginIf@@QAEXABVTDesC8@@00@Z @ 48 NONAME ; void CXnNodePluginIf::ReportTriggerEventL(class TDesC8 const &, class TDesC8 const &, class TDesC8 const &) + ?FocusedNodeL@TXnUiEnginePluginIf@@QAEPAVCXnNodePluginIf@@XZ @ 49 NONAME ; class CXnNodePluginIf * TXnUiEnginePluginIf::FocusedNodeL(void) + ?FindContentSourceNodesL@TXnUiEngineAppIf@@QAE?AV?$RPointerArray@VCXnNodeAppIf@@@@ABVTDesC8@@@Z @ 50 NONAME ; class RPointerArray TXnUiEngineAppIf::FindContentSourceNodesL(class TDesC8 const &) + ?EqualsL@CXnProperty@@QBEHAAV1@@Z @ 51 NONAME ; int CXnProperty::EqualsL(class CXnProperty &) const + ?ScreenDeviceSize@TXnUiEnginePluginIf@@QAE?AVTSize@@XZ @ 52 NONAME ; class TSize TXnUiEnginePluginIf::ScreenDeviceSize(void) + ??0CXnControlAdapter@@IAE@XZ @ 53 NONAME ; CXnControlAdapter::CXnControlAdapter(void) + ?VisibleRowsL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 54 NONAME ; class CXnProperty * CXnNodePluginIf::VisibleRowsL(void) + ?UiEngineL@CXnNodeAppIf@@QAEPAVTXnUiEngineAppIf@@XZ @ 55 NONAME ; class TXnUiEngineAppIf * CXnNodeAppIf::UiEngineL(void) + ?LongTapDetector@CXnControlAdapter@@QBEPAVCAknLongTapDetector@@XZ @ 56 NONAME ; class CAknLongTapDetector * CXnControlAdapter::LongTapDetector(void) const + ??0CXnAppUiAdapter@@QAE@VTUid@@@Z @ 57 NONAME ; CXnAppUiAdapter::CXnAppUiAdapter(class TUid) + ?Rect@CXnNodePluginIf@@QAE?AVTRect@@XZ @ 58 NONAME ; class TRect CXnNodePluginIf::Rect(void) + ?AddChildL@CXnNodePluginIf@@QAEXPAV1@@Z @ 59 NONAME ; void CXnNodePluginIf::AddChildL(class CXnNodePluginIf *) + ?SetNode@CXnComponent@@QAEXAAVCXnNodePluginIf@@@Z @ 60 NONAME ; void CXnComponent::SetNode(class CXnNodePluginIf &) + ?ResetStylusCounter@CXnControlAdapter@@QAEXXZ @ 61 NONAME ; void CXnControlAdapter::ResetStylusCounter(void) + ?SetComponent@CXnComponentNodeImpl@@QAEXPAVCXnComponent@@@Z @ 62 NONAME ; void CXnComponentNodeImpl::SetComponent(class CXnComponent *) + ?LayoutUIL@TXnUiEnginePluginIf@@QAEXPAVCXnNodePluginIf@@@Z @ 63 NONAME ; void TXnUiEnginePluginIf::LayoutUIL(class CXnNodePluginIf *) + ?FocusVisible@TXnUiEnginePluginIf@@QAEHXZ @ 64 NONAME ; int TXnUiEnginePluginIf::FocusVisible(void) + ?ExitPowerSaveModeL@CXnControlAdapter@@QAEXW4TModeEvent@1@@Z @ 65 NONAME ; void CXnControlAdapter::ExitPowerSaveModeL(enum CXnControlAdapter::TModeEvent) + ?GetThemeResource@TXnUiEngineAppIf@@QAEHABVTDesC16@@AAVRFile@@@Z @ 66 NONAME ; int TXnUiEngineAppIf::GetThemeResource(class TDesC16 const &, class RFile &) + ?ConstructL@CXnComponent@@IAEXXZ @ 67 NONAME ; void CXnComponent::ConstructL(void) + ?FindResource@CXnUtils@@SAPAVCXnResource@@AAV?$CArrayPtrSeg@VCXnResource@@@@ABVTDesC16@@AAH@Z @ 68 NONAME ; class CXnResource * CXnUtils::FindResource(class CArrayPtrSeg &, class TDesC16 const &, int &) + ?UnsetStateL@CXnNodeAppIf@@QAEXABVTDesC8@@@Z @ 69 NONAME ; void CXnNodeAppIf::UnsetStateL(class TDesC8 const &) + ?Uid@CXnDocument@@QAE?AVTUid@@XZ @ 70 NONAME ; class TUid CXnDocument::Uid(void) + ?FocusChanged@CXnControlAdapter@@UAEXW4TDrawNow@@@Z @ 71 NONAME ; void CXnControlAdapter::FocusChanged(enum TDrawNow) + ?SetBlank@CXnControlAdapter@@QAEXH@Z @ 72 NONAME ; void CXnControlAdapter::SetBlank(int) + ?Component@CXnNodeAppIf@@QAEAAVCXnComponent@@XZ @ 73 NONAME ; class CXnComponent & CXnNodeAppIf::Component(void) + ?SetLayoutCapable@CXnNodePluginIf@@QAEXH@Z @ 74 NONAME ; void CXnNodePluginIf::SetLayoutCapable(int) + ?MarginRect@CXnNodePluginIf@@QAE?AVTRect@@XZ @ 75 NONAME ; class TRect CXnNodePluginIf::MarginRect(void) + ?UiEngineL@CXnAppUiAdapter@@QAEPAVTXnUiEngineAppIf@@XZ @ 76 NONAME ; class TXnUiEngineAppIf * CXnAppUiAdapter::UiEngineL(void) + ?SwipeEnabledL@TXnUiEnginePluginIf@@QAEHXZ @ 77 NONAME ; int TXnUiEnginePluginIf::SwipeEnabledL(void) + ?SetFocusVisibleL@TXnUiEnginePluginIf@@QAEXH@Z @ 78 NONAME ; void TXnUiEnginePluginIf::SetFocusVisibleL(int) + ?ActiveView@TXnUiEngineAppIf@@QAEPAVCXnNodeAppIf@@XZ @ 79 NONAME ; class CXnNodeAppIf * TXnUiEngineAppIf::ActiveView(void) + ?GridOrientationL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 80 NONAME ; class CXnProperty * CXnNodePluginIf::GridOrientationL(void) + ?HandleXuikonEventL@CXnAppUiAdapter@@UAEXAAVCXnNodeAppIf@@0AAVCXnDomNode@@1@Z @ 81 NONAME ; void CXnAppUiAdapter::HandleXuikonEventL(class CXnNodeAppIf &, class CXnNodeAppIf &, class CXnDomNode &, class CXnDomNode &) + ?RenderUIL@TXnUiEngineAppIf@@QAEXPAVCXnNodeAppIf@@@Z @ 82 NONAME ; void TXnUiEngineAppIf::RenderUIL(class CXnNodeAppIf *) + ?PrepareToExit@CXnAppUiAdapter@@MAEXXZ @ 83 NONAME ; void CXnAppUiAdapter::PrepareToExit(void) + ?DoHandlePropertyChangeL@CXnControlAdapter@@UAEXPAVCXnProperty@@@Z @ 84 NONAME ; void CXnControlAdapter::DoHandlePropertyChangeL(class CXnProperty *) + ?ConstructL@CXnControlAdapter@@IAEXAAVCXnNodePluginIf@@@Z @ 85 NONAME ; void CXnControlAdapter::ConstructL(class CXnNodePluginIf &) + ?FocusedNode@TXnUiEngineAppIf@@QAEPAVCXnNodeAppIf@@XZ @ 86 NONAME ; class CXnNodeAppIf * TXnUiEngineAppIf::FocusedNode(void) + ?SetDataL@CXnComponent@@QAEXABVTDesC8@@ABVTDesC16@@H@Z @ 87 NONAME ; void CXnComponent::SetDataL(class TDesC8 const &, class TDesC16 const &, int) + ?OfferKeyEventL@CXnControlAdapter@@UAE?AW4TKeyResponse@@ABUTKeyEvent@@W4TEventCode@@@Z @ 88 NONAME ; enum TKeyResponse CXnControlAdapter::OfferKeyEventL(struct TKeyEvent const &, enum TEventCode) + ?IsDrawingAllowed@CXnControlAdapter@@QBEHXZ @ 89 NONAME ; int CXnControlAdapter::IsDrawingAllowed(void) const + ?DisplayL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 90 NONAME ; class CXnProperty * CXnNodePluginIf::DisplayL(void) + ?NewL@CXnProperty@@SAPAV1@ABVTDesC8@@PAVCXnDomPropertyValue@@AAVCXnDomStringPool@@@Z @ 91 NONAME ; class CXnProperty * CXnProperty::NewL(class TDesC8 const &, class CXnDomPropertyValue *, class CXnDomStringPool &) + ?Rect@CXnNodeAppIf@@QAE?AVTRect@@XZ @ 92 NONAME ; class TRect CXnNodeAppIf::Rect(void) + ?NewL@CXnComponentNodeImpl@@SAPAV1@PAVCXnType@@@Z @ 93 NONAME ; class CXnComponentNodeImpl * CXnComponentNodeImpl::NewL(class CXnType *) + ?GridVerDirectionL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 94 NONAME ; class CXnProperty * CXnNodePluginIf::GridVerDirectionL(void) + ?WidgetsVisible@TXnUiEngineAppIf@@QBEHXZ @ 95 NONAME ; int TXnUiEngineAppIf::WidgetsVisible(void) const + ?Type@CXnNodePluginIf@@QAEPAVCXnType@@XZ @ 96 NONAME ; class CXnType * CXnNodePluginIf::Type(void) + ?MakeXnComponentL@MXnComponentFactory@@EAE?AW4TXnComponentFactoryResponse@1@AAVCXnNodePluginIf@@AAPAVCXnComponent@@@Z @ 97 NONAME ; enum MXnComponentFactory::TXnComponentFactoryResponse MXnComponentFactory::MakeXnComponentL(class CXnNodePluginIf &, class CXnComponent * &) + ?ActivateViewL@TXnUiEngineAppIf@@QAEXAAVCXnNodeAppIf@@@Z @ 98 NONAME ; void TXnUiEngineAppIf::ActivateViewL(class CXnNodeAppIf &) + ?UnsetStateL@CXnNodePluginIf@@QAEXABVTDesC8@@@Z @ 99 NONAME ; void CXnNodePluginIf::UnsetStateL(class TDesC8 const &) + ?StringValueL@CXnProperty@@QAEPAVHBufC16@@XZ @ 100 NONAME ; class HBufC16 * CXnProperty::StringValueL(void) + ?DisableRenderUiLC@TXnUiEnginePluginIf@@QAEXXZ @ 101 NONAME ; void TXnUiEnginePluginIf::DisableRenderUiLC(void) + ?SetPropertyL@CXnNodeAppIf@@QAEXPAVCXnProperty@@@Z @ 102 NONAME ; void CXnNodeAppIf::SetPropertyL(class CXnProperty *) + ?View@CXnAppUiAdapter@@QBEAAVCAknView@@XZ @ 103 NONAME ; class CAknView & CXnAppUiAdapter::View(void) const + ?ViewNodeImpl@CXnNodePluginIf@@QAEPAVCXnViewNodeImpl@@XZ @ 104 NONAME ; class CXnViewNodeImpl * CXnNodePluginIf::ViewNodeImpl(void) + ?StripQuotes@CXnUtils@@SAXAAPAVHBufC16@@@Z @ 105 NONAME ; void CXnUtils::StripQuotes(class HBufC16 * &) + ?SetPCDataL@CXnNodePluginIf@@QAEXABVTDesC8@@@Z @ 106 NONAME ; void CXnNodePluginIf::SetPCDataL(class TDesC8 const &) + ?VisibilityL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 107 NONAME ; class CXnProperty * CXnNodePluginIf::VisibilityL(void) + ?Draw@CXnControlAdapter@@MBEXABVTRect@@@Z @ 108 NONAME ; void CXnControlAdapter::Draw(class TRect const &) const + ??1CXnApplication@@UAE@XZ @ 109 NONAME ; CXnApplication::~CXnApplication(void) + ?DoesNodeNeedComponentImplL@MXnComponentFactory@@QAEHABVTDesC8@@@Z @ 110 NONAME ; int MXnComponentFactory::DoesNodeNeedComponentImplL(class TDesC8 const &) + ?ConstructL@CXnViewsNodeImpl@@IAEXPAVCXnType@@@Z @ 111 NONAME ; void CXnViewsNodeImpl::ConstructL(class CXnType *) + ?StringPool@TXnUiEngineAppIf@@QAEAAVCXnDomStringPool@@XZ @ 112 NONAME ; class CXnDomStringPool & TXnUiEngineAppIf::StringPool(void) + ?UiEngineL@CXnNodePluginIf@@QAEPAVTXnUiEnginePluginIf@@XZ @ 113 NONAME ; class TXnUiEnginePluginIf * CXnNodePluginIf::UiEngineL(void) + ?ShowFocus@TXnUiEnginePluginIf@@QAEHXZ @ 114 NONAME ; int TXnUiEnginePluginIf::ShowFocus(void) + ?ResolveSkinItemIDL@CXnUtils@@SAHABVTDesC16@@AAVTAknsItemID@@@Z @ 115 NONAME ; int CXnUtils::ResolveSkinItemIDL(class TDesC16 const &, class TAknsItemID &) + ?PluginNodeL@TXnUiEnginePluginIf@@QAEAAVCXnNodePluginIf@@PAV2@@Z @ 116 NONAME ; class CXnNodePluginIf & TXnUiEnginePluginIf::PluginNodeL(class CXnNodePluginIf *) + ?VerticalPixelValueL@TXnUiEnginePluginIf@@QAEHPAVCXnProperty@@H@Z @ 117 NONAME ; int TXnUiEnginePluginIf::VerticalPixelValueL(class CXnProperty *, int) + ?SetComponent@CXnControlAdapter@@QAEXPAVCXnComponent@@@Z @ 118 NONAME ; void CXnControlAdapter::SetComponent(class CXnComponent *) + ??0MXnNodePredicate@@QAE@XZ @ 119 NONAME ; MXnNodePredicate::MXnNodePredicate(void) + ??1CXnViewsNodeImpl@@UAE@XZ @ 120 NONAME ; CXnViewsNodeImpl::~CXnViewsNodeImpl(void) + ?HandleControlEventL@CXnControlAdapter@@UAEXPAVCCoeControl@@W4TCoeEvent@MCoeControlObserver@@@Z @ 121 NONAME ; void CXnControlAdapter::HandleControlEventL(class CCoeControl *, enum MCoeControlObserver::TCoeEvent) + ?ActivateViewL@TXnUiEnginePluginIf@@QAEXAAVCXnNodePluginIf@@@Z @ 122 NONAME ; void TXnUiEnginePluginIf::ActivateViewL(class CXnNodePluginIf &) + ?HandleScreenDeviceChangedL@CXnControlAdapter@@UAEXXZ @ 123 NONAME ; void CXnControlAdapter::HandleScreenDeviceChangedL(void) + ?SizeChanged@CXnControlAdapter@@MAEXXZ @ 124 NONAME ; void CXnControlAdapter::SizeChanged(void) + ?CountComponentControls@CXnControlAdapter@@MBEHXZ @ 125 NONAME ; int CXnControlAdapter::CountComponentControls(void) const + ?HideTooltipsL@CXnNodeAppIf@@QAEXXZ @ 126 NONAME ; void CXnNodeAppIf::HideTooltipsL(void) + ?GetPropertyL@CXnNodeAppIf@@QBEPAVCXnProperty@@ABVTDesC8@@@Z @ 127 NONAME ; class CXnProperty * CXnNodeAppIf::GetPropertyL(class TDesC8 const &) const + ?GridScrollBarWidthL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 128 NONAME ; class CXnProperty * CXnNodePluginIf::GridScrollBarWidthL(void) + ?DeactivateFocusedNodeL@TXnUiEnginePluginIf@@QAEXXZ @ 129 NONAME ; void TXnUiEnginePluginIf::DeactivateFocusedNodeL(void) + ?FindNodeByClassL@TXnUiEngineAppIf@@QAE?AV?$RPointerArray@VCXnNodeAppIf@@@@ABVTDesC8@@0@Z @ 130 NONAME ; class RPointerArray TXnUiEngineAppIf::FindNodeByClassL(class TDesC8 const &, class TDesC8 const &) + ?Match@MXnNodePredicate@@UAEHAAVCXnNode@@@Z @ 131 NONAME ; int MXnNodePredicate::Match(class CXnNode &) + ?GetBitmapAndMask@CXnControlAdapter@@QAEXABVTDesC16@@0AAPAVCFbsBitmap@@1@Z @ 132 NONAME ; void CXnControlAdapter::GetBitmapAndMask(class TDesC16 const &, class TDesC16 const &, class CFbsBitmap * &, class CFbsBitmap * &) + ?NewL@CXnViewsNodeImpl@@SAPAV1@PAVCXnType@@@Z @ 133 NONAME ; class CXnViewsNodeImpl * CXnViewsNodeImpl::NewL(class CXnType *) + ?PaddingRect@CXnNodeAppIf@@QAE?AVTRect@@XZ @ 134 NONAME ; class TRect CXnNodeAppIf::PaddingRect(void) + ?SetMarginRect@CXnNodePluginIf@@QAEXABVTRect@@@Z @ 135 NONAME ; void CXnNodePluginIf::SetMarginRect(class TRect const &) + ?IsDialogDisplaying@TXnUiEnginePluginIf@@QAEHXZ @ 136 NONAME ; int TXnUiEnginePluginIf::IsDialogDisplaying(void) + ?HandleEventL@CXnAppUiAdapter@@UAEXABVTDesC16@@AAVCXnNodeAppIf@@@Z @ 137 NONAME ; void CXnAppUiAdapter::HandleEventL(class TDesC16 const &, class CXnNodeAppIf &) + ?GetPropertyL@CXnNodePluginIf@@QBEPAVCXnProperty@@ABVTDesC8@@@Z @ 138 NONAME ; class CXnProperty * CXnNodePluginIf::GetPropertyL(class TDesC8 const &) const + ?SetPropertyArrayL@CXnNodeAppIf@@QAEXPAV?$RPointerArray@VCXnProperty@@@@@Z @ 139 NONAME ; void CXnNodeAppIf::SetPropertyArrayL(class RPointerArray *) + ?RestorePreviousFocusedNode@TXnUiEnginePluginIf@@QAEXXZ @ 140 NONAME ; void TXnUiEnginePluginIf::RestorePreviousFocusedNode(void) + ?RemoveViewL@CXnAppUiAdapter@@QAEXAAVCAknView@@@Z @ 141 NONAME ; void CXnAppUiAdapter::RemoveViewL(class CAknView &) + ?EnterPowerSaveModeL@CXnComponent@@UAEXXZ @ 142 NONAME ; void CXnComponent::EnterPowerSaveModeL(void) + ?SetRect@CXnNodePluginIf@@QAEXABVTRect@@@Z @ 143 NONAME ; void CXnNodePluginIf::SetRect(class TRect const &) + ??0CXnComponent@@IAE@XZ @ 144 NONAME ; CXnComponent::CXnComponent(void) + ?CollapseWhiteSpace@CXnUtils@@SAXAAVCXnNodePluginIf@@AAVTDes16@@@Z @ 145 NONAME ; void CXnUtils::CollapseWhiteSpace(class CXnNodePluginIf &, class TDes16 &) + ?SetHandleTooltip@CXnNodePluginIf@@QAEXH@Z @ 146 NONAME ; void CXnNodePluginIf::SetHandleTooltip(int) + ??1CXnAppUiAdapter@@UAE@XZ @ 147 NONAME ; CXnAppUiAdapter::~CXnAppUiAdapter(void) + ?NewL@CXnControlAdapter@@SAPAV1@AAVCXnNodePluginIf@@@Z @ 148 NONAME ; class CXnControlAdapter * CXnControlAdapter::NewL(class CXnNodePluginIf &) + ?EnableLongTapAnimation@CXnControlAdapter@@QAEXH@Z @ 149 NONAME ; void CXnControlAdapter::EnableLongTapAnimation(int) + ?RefL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 150 NONAME ; class CXnProperty * CXnNodePluginIf::RefL(void) + ?SetPaddingRect@CXnNodePluginIf@@QAEXABVTRect@@@Z @ 151 NONAME ; void CXnNodePluginIf::SetPaddingRect(class TRect const &) + ?FocusVerLoopingL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 152 NONAME ; class CXnProperty * CXnNodePluginIf::FocusVerLoopingL(void) + ?SetFocusedNode@TXnUiEnginePluginIf@@QAEXPAVCXnNodePluginIf@@@Z @ 153 NONAME ; void TXnUiEnginePluginIf::SetFocusedNode(class CXnNodePluginIf *) + ?ExitPowerSaveModeL@CXnComponent@@UAEXXZ @ 154 NONAME ; void CXnComponent::ExitPowerSaveModeL(void) + ?EnableSwipeL@TXnUiEnginePluginIf@@QAEXH@Z @ 155 NONAME ; void TXnUiEnginePluginIf::EnableSwipeL(int) + ?GetPCData@CXnNodeAppIf@@QBEABVTDesC8@@XZ @ 156 NONAME ; class TDesC8 const & CXnNodeAppIf::GetPCData(void) const + ?Namespace@CXnNodeAppIf@@QAEABVTDesC8@@XZ @ 157 NONAME ; class TDesC8 const & CXnNodeAppIf::Namespace(void) + ??1CXnComponentNodeImpl@@UAE@XZ @ 158 NONAME ; CXnComponentNodeImpl::~CXnComponentNodeImpl(void) + ?SetPropertyWithoutNotificationL@CXnNodePluginIf@@QAEXPAVCXnProperty@@@Z @ 159 NONAME ; void CXnNodePluginIf::SetPropertyWithoutNotificationL(class CXnProperty *) + ?GetPCData@CXnNodePluginIf@@QBEABVTDesC8@@XZ @ 160 NONAME ; class TDesC8 const & CXnNodePluginIf::GetPCData(void) const + ?SetPCDataL@CXnNodeAppIf@@QAEXABVTDesC8@@@Z @ 161 NONAME ; void CXnNodeAppIf::SetPCDataL(class TDesC8 const &) + ?Resources@TXnUiEnginePluginIf@@QAEAAV?$CArrayPtrSeg@VCXnResource@@@@XZ @ 162 NONAME ; class CArrayPtrSeg & TXnUiEnginePluginIf::Resources(void) + ?SetContentBitmaps@CXnControlAdapter@@QAEXABVTDesC16@@0@Z @ 163 NONAME ; void CXnControlAdapter::SetContentBitmaps(class TDesC16 const &, class TDesC16 const &) + ??1CXnControlAdapter@@UAE@XZ @ 164 NONAME ; CXnControlAdapter::~CXnControlAdapter(void) + ??1MXnNodePredicate@@UAE@XZ @ 165 NONAME ; MXnNodePredicate::~MXnNodePredicate(void) + ?HorizontalTwipValueL@TXnUiEnginePluginIf@@QAEHPAVCXnProperty@@H@Z @ 166 NONAME ; int TXnUiEnginePluginIf::HorizontalTwipValueL(class CXnProperty *, int) + ?ConstructL@CXnAppUiAdapter@@UAEXXZ @ 167 NONAME ; void CXnAppUiAdapter::ConstructL(void) + ?CreateFontL@CXnUtils@@SAXAAVCXnNodePluginIf@@AAPAVCFont@@AAH@Z @ 168 NONAME ; void CXnUtils::CreateFontL(class CXnNodePluginIf &, class CFont * &, int &) + ??0CXnApplication@@QAE@VTUid@@@Z @ 169 NONAME ; CXnApplication::CXnApplication(class TUid) + ?ComponentControl@CXnControlAdapter@@MBEPAVCCoeControl@@H@Z @ 170 NONAME ; class CCoeControl * CXnControlAdapter::ComponentControl(int) const + ?HandleLongTapEventL@CXnControlAdapter@@UAEXABVTPoint@@0@Z @ 171 NONAME ; void CXnControlAdapter::HandleLongTapEventL(class TPoint const &, class TPoint const &) + ?ParentL@CXnNodeAppIf@@QBEPAV1@XZ @ 172 NONAME ; class CXnNodeAppIf * CXnNodeAppIf::ParentL(void) const + ??1CXnComponent@@UAE@XZ @ 173 NONAME ; CXnComponent::~CXnComponent(void) + ?ControlAdapter@CXnComponent@@QAEPAVCXnControlAdapter@@XZ @ 174 NONAME ; class CXnControlAdapter * CXnComponent::ControlAdapter(void) + ?DrawContentImage@CXnControlAdapter@@IBEXXZ @ 175 NONAME ; void CXnControlAdapter::DrawContentImage(void) const + ?Component@CXnComponentNodeImpl@@QAEPAVCXnComponent@@XZ @ 176 NONAME ; class CXnComponent * CXnComponentNodeImpl::Component(void) + ?GridScrollBarMarginL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 177 NONAME ; class CXnProperty * CXnNodePluginIf::GridScrollBarMarginL(void) + ?WidgetsVisible@TXnUiEnginePluginIf@@QBEHXZ @ 178 NONAME ; int TXnUiEnginePluginIf::WidgetsVisible(void) const + ?SetControlAdapter@CXnComponent@@QAEXPAVCXnControlAdapter@@@Z @ 179 NONAME ; void CXnComponent::SetControlAdapter(class CXnControlAdapter *) + ?GridColumnsL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 180 NONAME ; class CXnProperty * CXnNodePluginIf::GridColumnsL(void) + ?SetStateL@CXnNodePluginIf@@QAEXABVTDesC8@@@Z @ 181 NONAME ; void CXnNodePluginIf::SetStateL(class TDesC8 const &) + ?DoesComponentNeedCreation@CXnComponentNodeImpl@@QBEHXZ @ 182 NONAME ; int CXnComponentNodeImpl::DoesComponentNeedCreation(void) const + ??0CXnDocument@@QAE@AAVCEikApplication@@VTUid@@@Z @ 183 NONAME ; CXnDocument::CXnDocument(class CEikApplication &, class TUid) + ?FindNodeByClassL@TXnUiEnginePluginIf@@QAE?AV?$RPointerArray@VCXnNodePluginIf@@@@ABVTDesC16@@@Z @ 184 NONAME ; class RPointerArray TXnUiEnginePluginIf::FindNodeByClassL(class TDesC16 const &) + ?GridHorDirectionL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 185 NONAME ; class CXnProperty * CXnNodePluginIf::GridHorDirectionL(void) + ?InternalDomNodeType@CXnNodeAppIf@@QBEABVTDesC8@@XZ @ 186 NONAME ; class TDesC8 const & CXnNodeAppIf::InternalDomNodeType(void) const + ?StringPool@TXnUiEnginePluginIf@@QAEAAVCXnDomStringPool@@XZ @ 187 NONAME ; class CXnDomStringPool & TXnUiEnginePluginIf::StringPool(void) + ?SetStateL@CXnNodeAppIf@@QAEXABVTDesC8@@@Z @ 188 NONAME ; void CXnNodeAppIf::SetStateL(class TDesC8 const &) + ?Type@CXnNodeAppIf@@QAEPAVCXnType@@XZ @ 189 NONAME ; class CXnType * CXnNodeAppIf::Type(void) + ?BorderRect@CXnNodeAppIf@@QAE?AVTRect@@XZ @ 190 NONAME ; class TRect CXnNodeAppIf::BorderRect(void) + ?IdL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 191 NONAME ; class CXnProperty * CXnNodePluginIf::IdL(void) + ?RootNodeL@TXnUiEngineAppIf@@QAEAAVCXnNodeAppIf@@XZ @ 192 NONAME ; class CXnNodeAppIf & TXnUiEngineAppIf::RootNodeL(void) + ?CreateXnComponentL@MXnComponentFactory@@QAE?AW4TXnComponentFactoryResponse@1@AAVCXnNodePluginIf@@AAPAVCXnComponent@@@Z @ 193 NONAME ; enum MXnComponentFactory::TXnComponentFactoryResponse MXnComponentFactory::CreateXnComponentL(class CXnNodePluginIf &, class CXnComponent * &) + ?RefreshMenuL@TXnUiEngineAppIf@@QAEXXZ @ 194 NONAME ; void TXnUiEngineAppIf::RefreshMenuL(void) + ?PaddingRect@CXnNodePluginIf@@QAE?AVTRect@@XZ @ 195 NONAME ; class TRect CXnNodePluginIf::PaddingRect(void) + ?MeasureAdaptiveContentL@CXnControlAdapter@@UAE?AVTSize@@ABV2@@Z @ 196 NONAME ; class TSize CXnControlAdapter::MeasureAdaptiveContentL(class TSize const &) + ?NewL@CXnProperty@@SAPAV1@ABVTDesC8@@0W4TPrimitiveValueType@CXnDomPropertyValue@@AAVCXnDomStringPool@@@Z @ 197 NONAME ; class CXnProperty * CXnProperty::NewL(class TDesC8 const &, class TDesC8 const &, enum CXnDomPropertyValue::TPrimitiveValueType, class CXnDomStringPool &) + ?GetPropertyL@CXnNodePluginIf@@QBEPAVCXnProperty@@AAV2@@Z @ 198 NONAME ; class CXnProperty * CXnNodePluginIf::GetPropertyL(class CXnProperty &) const + ?HitRegion@TXnUiEnginePluginIf@@QBEPAVCXnControlAdapter@@XZ @ 199 NONAME ; class CXnControlAdapter * TXnUiEnginePluginIf::HitRegion(void) const + ?MarginRect@CXnNodeAppIf@@QAE?AVTRect@@XZ @ 200 NONAME ; class TRect CXnNodeAppIf::MarginRect(void) + ?MakeInterfaceL@CXnComponent@@UAEPAVMXnComponentInterface@XnComponentInterface@@ABVTDesC8@@@Z @ 201 NONAME ; class XnComponentInterface::MXnComponentInterface * CXnComponent::MakeInterfaceL(class TDesC8 const &) + ?EditMode@TXnUiEnginePluginIf@@QAEHXZ @ 202 NONAME ; int TXnUiEnginePluginIf::EditMode(void) + ?FindNodeByIdL@TXnUiEnginePluginIf@@QAEPAVCXnNodePluginIf@@ABVTDesC8@@0@Z @ 203 NONAME ; class CXnNodePluginIf * TXnUiEnginePluginIf::FindNodeByIdL(class TDesC8 const &, class TDesC8 const &) + ?EnableRenderUi@CXnUiEngineImpl@@CAXPAX@Z @ 204 NONAME ; void CXnUiEngineImpl::EnableRenderUi(void *) + ?IsMenuDisplaying@TXnUiEnginePluginIf@@QAEHXZ @ 205 NONAME ; int TXnUiEnginePluginIf::IsMenuDisplaying(void) + ?IsMenuDisplaying@TXnUiEngineAppIf@@QAEHXZ @ 206 NONAME ; int TXnUiEngineAppIf::IsMenuDisplaying(void) + ?NewL@CXnProperty@@SAPAV1@PAVCXnDomProperty@@@Z @ 207 NONAME ; class CXnProperty * CXnProperty::NewL(class CXnDomProperty *) + ?ConstructL@CXnComponentNodeImpl@@IAEXPAVCXnType@@@Z @ 208 NONAME ; void CXnComponentNodeImpl::ConstructL(class CXnType *) + ?ChildrenL@CXnNodeAppIf@@QAE?AV?$RPointerArray@VCXnNodeAppIf@@@@XZ @ 209 NONAME ; class RPointerArray CXnNodeAppIf::ChildrenL(void) + ?LoadPublisher@CXnAppUiAdapter@@UAEHAAVCXnNodeAppIf@@H@Z @ 210 NONAME ; int CXnAppUiAdapter::LoadPublisher(class CXnNodeAppIf &, int) + ?ConvertHslToRgb@CXnUtils@@SA?AVTRgb@@HHH@Z @ 211 NONAME ; class TRgb CXnUtils::ConvertHslToRgb(int, int, int) + ?LoadBitmap@CXnControlAdapter@@QAEPAVCFbsBitmap@@ABVTDesC16@@@Z @ 212 NONAME ; class CFbsBitmap * CXnControlAdapter::LoadBitmap(class TDesC16 const &) + ??0MXnComponentFactory@@IAE@XZ @ 213 NONAME ; MXnComponentFactory::MXnComponentFactory(void) + ?SetComponent@CXnViewsNodeImpl@@QAEXPAVCXnComponent@@@Z @ 214 NONAME ; void CXnViewsNodeImpl::SetComponent(class CXnComponent *) + ?BorderRect@CXnNodePluginIf@@QAE?AVTRect@@XZ @ 215 NONAME ; class TRect CXnNodePluginIf::BorderRect(void) + ?CreateDocumentL@CXnApplication@@MAEPAVCApaDocument@@XZ @ 216 NONAME ; class CApaDocument * CXnApplication::CreateDocumentL(void) + ?CreateFontL@CXnUtils@@SAXABVTDesC16@@HVTFontStyle@@AAPAVCFont@@AAH@Z @ 217 NONAME ; void CXnUtils::CreateFontL(class TDesC16 const &, int, class TFontStyle, class CFont * &, int &) + ?GetPluginNodeArrayL@TXnUiEngineAppIf@@QAEHAAV?$RPointerArray@VCXnNodeAppIf@@@@@Z @ 218 NONAME ; int TXnUiEngineAppIf::GetPluginNodeArrayL(class RPointerArray &) + ?MakeXnControlAdapterL@MXnComponentFactory@@EAEPAVCXnControlAdapter@@AAVCXnNodePluginIf@@PAV2@@Z @ 219 NONAME ; class CXnControlAdapter * MXnComponentFactory::MakeXnControlAdapterL(class CXnNodePluginIf &, class CXnControlAdapter *) + ?IsDrawingAllowed@CXnNodePluginIf@@QBEHXZ @ 220 NONAME ; int CXnNodePluginIf::IsDrawingAllowed(void) const + ?MakeInterfaceL@CXnNodeAppIf@@QAEPAVMXnComponentInterface@XnComponentInterface@@ABVTDesC8@@@Z @ 221 NONAME ; class XnComponentInterface::MXnComponentInterface * CXnNodeAppIf::MakeInterfaceL(class TDesC8 const &) + ?VerticalTwipValueL@TXnUiEnginePluginIf@@QAEHPAVCXnProperty@@H@Z @ 222 NONAME ; int TXnUiEnginePluginIf::VerticalTwipValueL(class CXnProperty *, int) + ?Component@CXnControlAdapter@@QAEPAVCXnComponent@@XZ @ 223 NONAME ; class CXnComponent * CXnControlAdapter::Component(void) + ?FloatValueL@CXnProperty@@QAENXZ @ 224 NONAME ; double CXnProperty::FloatValueL(void) + ?SetUiEngine@TXnUiEngineAppIf@@QAEXPAVCXnUiEngine@@@Z @ 225 NONAME ; void TXnUiEngineAppIf::SetUiEngine(class CXnUiEngine *) + ?FindNodeByIdL@TXnUiEngineAppIf@@QAEPAVCXnNodeAppIf@@ABVTDesC16@@0@Z @ 226 NONAME ; class CXnNodeAppIf * TXnUiEngineAppIf::FindNodeByIdL(class TDesC16 const &, class TDesC16 const &) + ?IsEditMode@TXnUiEngineAppIf@@QAEHXZ @ 227 NONAME ; int TXnUiEngineAppIf::IsEditMode(void) + ?ResolveSkinItemIDL@CXnUtils@@SAHABVTDesC16@@AAVTAknsItemID@@AAH@Z @ 228 NONAME ; int CXnUtils::ResolveSkinItemIDL(class TDesC16 const &, class TAknsItemID &, int &) + ?RootNodeL@TXnUiEnginePluginIf@@QAEAAVCXnNodePluginIf@@XZ @ 229 NONAME ; class CXnNodePluginIf & TXnUiEnginePluginIf::RootNodeL(void) + ?CreateAppUiL@CXnDocument@@UAEPAVCEikAppUi@@XZ @ 230 NONAME ; class CEikAppUi * CXnDocument::CreateAppUiL(void) + ?PathL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 231 NONAME ; class CXnProperty * CXnNodePluginIf::PathL(void) + ?NewL@CXnProperty@@SAPAV1@ABVTDesC8@@NW4TPrimitiveValueType@CXnDomPropertyValue@@AAVCXnDomStringPool@@@Z @ 232 NONAME ; class CXnProperty * CXnProperty::NewL(class TDesC8 const &, double, enum CXnDomPropertyValue::TPrimitiveValueType, class CXnDomStringPool &) + ?MaskPathL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 233 NONAME ; class CXnProperty * CXnNodePluginIf::MaskPathL(void) + ?AppDllUid@CXnApplication@@MBE?AVTUid@@XZ @ 234 NONAME ; class TUid CXnApplication::AppDllUid(void) const + ?DoExitPowerSaveModeL@CXnControlAdapter@@UAEXW4TModeEvent@1@@Z @ 235 NONAME ; void CXnControlAdapter::DoExitPowerSaveModeL(enum CXnControlAdapter::TModeEvent) + ?LabelL@CXnNodePluginIf@@QAEPAVCXnProperty@@XZ @ 236 NONAME ; class CXnProperty * CXnNodePluginIf::LabelL(void) + ?Component@CXnViewsNodeImpl@@QAEPAVCXnComponent@@XZ @ 237 NONAME ; class CXnComponent * CXnViewsNodeImpl::Component(void) + ?GetRgbValue@CXnUtils@@SAHAAVTRgb@@ABVTDesC8@@@Z @ 238 NONAME ; int CXnUtils::GetRgbValue(class TRgb &, class TDesC8 const &) + ?StringValue@CXnProperty@@QAEABVTDesC8@@XZ @ 239 NONAME ; class TDesC8 const & CXnProperty::StringValue(void) + ?SetVisible@CXnControlAdapter@@QAEXH@Z @ 240 NONAME ; void CXnControlAdapter::SetVisible(int) + ?Node@CXnComponent@@QAEPAVCXnNodePluginIf@@XZ @ 241 NONAME ; class CXnNodePluginIf * CXnComponent::Node(void) + ?EnablePartialTouchInput@TXnUiEnginePluginIf@@QAEXAAVCXnNodePluginIf@@H@Z @ 242 NONAME ; void TXnUiEnginePluginIf::EnablePartialTouchInput(class CXnNodePluginIf &, int) diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/eabi/xn3layoutengineu.def --- a/idlehomescreen/xmluirendering/uiengine/eabi/xn3layoutengineu.def Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/eabi/xn3layoutengineu.def Fri Feb 19 22:42:37 2010 +0200 @@ -24,268 +24,273 @@ _ZN12CXnComponent4NewLEv @ 23 NONAME _ZN12CXnComponent4NodeEv @ 24 NONAME _ZN12CXnComponent7SetNodeER15CXnNodePluginIf @ 25 NONAME - _ZN12CXnComponentC1Ev @ 26 NONAME - _ZN12CXnComponentC2Ev @ 27 NONAME - _ZN12CXnComponentD0Ev @ 28 NONAME - _ZN12CXnComponentD1Ev @ 29 NONAME - _ZN12CXnComponentD2Ev @ 30 NONAME - _ZN12CXnNodeAppIf10BorderRectEv @ 31 NONAME - _ZN12CXnNodeAppIf10IsStateSetERK6TDesC8 @ 32 NONAME - _ZN12CXnNodeAppIf10MarginRectEv @ 33 NONAME - _ZN12CXnNodeAppIf10SetPCDataLERK6TDesC8 @ 34 NONAME - _ZN12CXnNodeAppIf11PaddingRectEv @ 35 NONAME - _ZN12CXnNodeAppIf11UnsetStateLERK6TDesC8 @ 36 NONAME - _ZN12CXnNodeAppIf12SetPropertyLEP11CXnProperty @ 37 NONAME - _ZN12CXnNodeAppIf13HideTooltipsLEv @ 38 NONAME - _ZN12CXnNodeAppIf13ShowTooltipsLEv @ 39 NONAME - _ZN12CXnNodeAppIf14MakeInterfaceLERK6TDesC8 @ 40 NONAME - _ZN12CXnNodeAppIf17SetPropertyArrayLEP13RPointerArrayI11CXnPropertyE @ 41 NONAME - _ZN12CXnNodeAppIf4RectEv @ 42 NONAME - _ZN12CXnNodeAppIf4TypeEv @ 43 NONAME - _ZN12CXnNodeAppIf9ChildrenLEv @ 44 NONAME - _ZN12CXnNodeAppIf9NamespaceEv @ 45 NONAME - _ZN12CXnNodeAppIf9SetStateLERK6TDesC8 @ 46 NONAME - _ZN12CXnNodeAppIf9UiEngineLEv @ 47 NONAME - _ZN14CXnApplication15CreateDocumentLEv @ 48 NONAME - _ZN14CXnApplicationC1E4TUid @ 49 NONAME - _ZN14CXnApplicationC2E4TUid @ 50 NONAME - _ZN14CXnApplicationD0Ev @ 51 NONAME - _ZN14CXnApplicationD1Ev @ 52 NONAME - _ZN14CXnApplicationD2Ev @ 53 NONAME - _ZN15CXnAppUiAdapter10ConstructLEv @ 54 NONAME - _ZN15CXnAppUiAdapter15SetOnlineStateLER13RPointerArrayI12CXnNodeAppIfE @ 55 NONAME - _ZN15CXnAppUiAdapter16DynInitMenuItemLERK7TDesC16P13RPointerArrayI12CXnNodeAppIfE @ 56 NONAME - _ZN15CXnAppUiAdapter16HandlePageSwitchEv @ 57 NONAME - _ZN15CXnAppUiAdapter16LoadDataPluginsLER13RPointerArrayI12CXnNodeAppIfE @ 58 NONAME - _ZN15CXnAppUiAdapter18HandleXuikonEventLER12CXnNodeAppIfS1_R10CXnDomNodeS3_ @ 59 NONAME - _ZN15CXnAppUiAdapter19DestroyDataPluginsLER13RPointerArrayI12CXnNodeAppIfE @ 60 NONAME - _ZN15CXnAppUiAdapter21HandleResourceChangeLEi @ 61 NONAME - _ZN15CXnAppUiAdapter9UiEngineLEv @ 62 NONAME - _ZN15CXnAppUiAdapterC1E4TUid @ 63 NONAME - _ZN15CXnAppUiAdapterC2E4TUid @ 64 NONAME - _ZN15CXnAppUiAdapterD0Ev @ 65 NONAME - _ZN15CXnAppUiAdapterD1Ev @ 66 NONAME - _ZN15CXnAppUiAdapterD2Ev @ 67 NONAME - _ZN15CXnNodePluginIf10BorderRectEv @ 68 NONAME - _ZN15CXnNodePluginIf10MarginRectEv @ 69 NONAME - _ZN15CXnNodePluginIf10SetPCDataLERK6TDesC8 @ 70 NONAME - _ZN15CXnNodePluginIf11PaddingRectEv @ 71 NONAME - _ZN15CXnNodePluginIf11UnsetStateLERK6TDesC8 @ 72 NONAME - _ZN15CXnNodePluginIf11VisibilityLEv @ 73 NONAME - _ZN15CXnNodePluginIf12GridColumnsLEv @ 74 NONAME - _ZN15CXnNodePluginIf12SetPropertyLEP11CXnProperty @ 75 NONAME - _ZN15CXnNodePluginIf12ViewNodeImplEv @ 76 NONAME - _ZN15CXnNodePluginIf12VisibleRowsLEv @ 77 NONAME - _ZN15CXnNodePluginIf13SetBorderRectERK5TRect @ 78 NONAME - _ZN15CXnNodePluginIf13SetMarginRectERK5TRect @ 79 NONAME - _ZN15CXnNodePluginIf14IsFocusedStateEv @ 80 NONAME - _ZN15CXnNodePluginIf14MakeInterfaceLERK6TDesC8 @ 81 NONAME - _ZN15CXnNodePluginIf14SetPaddingRectERK5TRect @ 82 NONAME - _ZN15CXnNodePluginIf16FocusHorLoopingLEv @ 83 NONAME - _ZN15CXnNodePluginIf16FocusVerLoopingLEv @ 84 NONAME - _ZN15CXnNodePluginIf16GridOrientationLEv @ 85 NONAME - _ZN15CXnNodePluginIf16SetHandleTooltipEi @ 86 NONAME - _ZN15CXnNodePluginIf16SetLayoutCapableEi @ 87 NONAME - _ZN15CXnNodePluginIf17ComponentNodeImplEv @ 88 NONAME - _ZN15CXnNodePluginIf17GridHorDirectionLEv @ 89 NONAME - _ZN15CXnNodePluginIf17GridVerDirectionLEv @ 90 NONAME - _ZN15CXnNodePluginIf19GridScrollBarWidthLEv @ 91 NONAME - _ZN15CXnNodePluginIf19ReportTriggerEventLERK6TDesC8S2_S2_ @ 92 NONAME - _ZN15CXnNodePluginIf20GridScrollBarMarginLEv @ 93 NONAME - _ZN15CXnNodePluginIf31SetPropertyWithoutNotificationLEP11CXnProperty @ 94 NONAME - _ZN15CXnNodePluginIf3IdLEv @ 95 NONAME - _ZN15CXnNodePluginIf4RectEv @ 96 NONAME - _ZN15CXnNodePluginIf4RefLEv @ 97 NONAME - _ZN15CXnNodePluginIf4TypeEv @ 98 NONAME - _ZN15CXnNodePluginIf5PathLEv @ 99 NONAME - _ZN15CXnNodePluginIf6AppIfLEv @ 100 NONAME - _ZN15CXnNodePluginIf6LabelLEv @ 101 NONAME - _ZN15CXnNodePluginIf7SetRectERK5TRect @ 102 NONAME - _ZN15CXnNodePluginIf8DisplayLEv @ 103 NONAME - _ZN15CXnNodePluginIf9AddChildLEPS_ @ 104 NONAME - _ZN15CXnNodePluginIf9ChildrenLEv @ 105 NONAME - _ZN15CXnNodePluginIf9MaskPathLEv @ 106 NONAME - _ZN15CXnNodePluginIf9NamespaceEv @ 107 NONAME - _ZN15CXnNodePluginIf9SetDirtyLEv @ 108 NONAME - _ZN15CXnNodePluginIf9SetStateLERK6TDesC8 @ 109 NONAME - _ZN15CXnNodePluginIf9UiEngineLEv @ 110 NONAME - _ZN15CXnUiEngineImpl14EnableRenderUiEPv @ 111 NONAME - _ZN16CXnViewsNodeImpl10ConstructLEP7CXnType @ 112 NONAME - _ZN16CXnViewsNodeImpl12SetComponentEP12CXnComponent @ 113 NONAME - _ZN16CXnViewsNodeImpl4NewLEP7CXnType @ 114 NONAME - _ZN16CXnViewsNodeImpl9ComponentEv @ 115 NONAME - _ZN16CXnViewsNodeImplC1Ev @ 116 NONAME - _ZN16CXnViewsNodeImplC2Ev @ 117 NONAME - _ZN16CXnViewsNodeImplD0Ev @ 118 NONAME - _ZN16CXnViewsNodeImplD1Ev @ 119 NONAME - _ZN16CXnViewsNodeImplD2Ev @ 120 NONAME - _ZN16MXnNodePredicate5MatchER7CXnNode @ 121 NONAME - _ZN16MXnNodePredicateC1Ev @ 122 NONAME - _ZN16MXnNodePredicateC2Ev @ 123 NONAME - _ZN16MXnNodePredicateD0Ev @ 124 NONAME - _ZN16MXnNodePredicateD1Ev @ 125 NONAME - _ZN16MXnNodePredicateD2Ev @ 126 NONAME - _ZN16TXnUiEngineAppIf10ActiveViewEv @ 127 NONAME - _ZN16TXnUiEngineAppIf10IsEditModeEv @ 128 NONAME - _ZN16TXnUiEngineAppIf10StringPoolEv @ 129 NONAME - _ZN16TXnUiEngineAppIf11FocusedNodeEv @ 130 NONAME - _ZN16TXnUiEngineAppIf11SetUiEngineEP11CXnUiEngine @ 131 NONAME - _ZN16TXnUiEngineAppIf12RefreshMenuLEv @ 132 NONAME - _ZN16TXnUiEngineAppIf13ActivateViewLER12CXnNodeAppIf @ 133 NONAME - _ZN16TXnUiEngineAppIf13FindNodeByIdLERK6TDesC8S2_ @ 134 NONAME - _ZN16TXnUiEngineAppIf13FindNodeByIdLERK7TDesC16S2_ @ 135 NONAME - _ZN16TXnUiEngineAppIf16FindNodeByClassLERK6TDesC8S2_ @ 136 NONAME - _ZN16TXnUiEngineAppIf16FindNodeByClassLERK7TDesC16S2_ @ 137 NONAME - _ZN16TXnUiEngineAppIf16GetThemeResourceERK7TDesC16R5RFile @ 138 NONAME - _ZN16TXnUiEngineAppIf16IsMenuDisplayingEv @ 139 NONAME - _ZN16TXnUiEngineAppIf19GetPluginNodeArrayLER13RPointerArrayI12CXnNodeAppIfE @ 140 NONAME - _ZN16TXnUiEngineAppIf23FindContentSourceNodesLERK6TDesC8 @ 141 NONAME - _ZN16TXnUiEngineAppIf9RenderUILEP12CXnNodeAppIf @ 142 NONAME - _ZN16TXnUiEngineAppIf9RootNodeLEv @ 143 NONAME - _ZN17CXnControlAdapter10ConstructLER15CXnNodePluginIf @ 144 NONAME - _ZN17CXnControlAdapter10LoadBitmapERK7TDesC16 @ 145 NONAME - _ZN17CXnControlAdapter10SetVisibleEi @ 146 NONAME - _ZN17CXnControlAdapter11SizeChangedEv @ 147 NONAME - _ZN17CXnControlAdapter11SkinChangedEv @ 148 NONAME - _ZN17CXnControlAdapter12FocusChangedE8TDrawNow @ 149 NONAME - _ZN17CXnControlAdapter12SetComponentEP12CXnComponent @ 150 NONAME - _ZN17CXnControlAdapter14ContentBitmapsERP10CFbsBitmapS2_ @ 151 NONAME - _ZN17CXnControlAdapter14OfferKeyEventLERK9TKeyEvent10TEventCode @ 152 NONAME - _ZN17CXnControlAdapter15SetLocalUiZoomLE10TAknUiZoom @ 153 NONAME - _ZN17CXnControlAdapter16GetBitmapAndMaskERK7TDesC16S2_RP10CFbsBitmapS5_ @ 154 NONAME - _ZN17CXnControlAdapter17SetContentBitmapsEP10CFbsBitmapS1_ @ 155 NONAME - _ZN17CXnControlAdapter17SetContentBitmapsERK7TDesC16S2_ @ 156 NONAME - _ZN17CXnControlAdapter18ExitPowerSaveModeLENS_10TModeEventE @ 157 NONAME - _ZN17CXnControlAdapter18ResetStylusCounterEv @ 158 NONAME - _ZN17CXnControlAdapter19EnterPowerSaveModeLENS_10TModeEventE @ 159 NONAME - _ZN17CXnControlAdapter19HandleControlEventLEP11CCoeControlN19MCoeControlObserver9TCoeEventE @ 160 NONAME - _ZN17CXnControlAdapter19HandleLongTapEventLERK6TPointS2_ @ 161 NONAME - _ZN17CXnControlAdapter19HandlePointerEventLERK13TPointerEvent @ 162 NONAME - _ZN17CXnControlAdapter20DoExitPowerSaveModeLENS_10TModeEventE @ 163 NONAME - _ZN17CXnControlAdapter21DoEnterPowerSaveModeLENS_10TModeEventE @ 164 NONAME - _ZN17CXnControlAdapter21HandlePropertyChangeLEP11CXnProperty @ 165 NONAME - _ZN17CXnControlAdapter22EnableLongTapAnimationEi @ 166 NONAME - _ZN17CXnControlAdapter23DoHandlePropertyChangeLEP11CXnProperty @ 167 NONAME - _ZN17CXnControlAdapter23MeasureAdaptiveContentLERK5TSize @ 168 NONAME - _ZN17CXnControlAdapter26HandleScreenDeviceChangedLEv @ 169 NONAME - _ZN17CXnControlAdapter4NewLER15CXnNodePluginIf @ 170 NONAME - _ZN17CXnControlAdapter8SetBlankEi @ 171 NONAME - _ZN17CXnControlAdapter9ComponentEv @ 172 NONAME - _ZN17CXnControlAdapterC1Ev @ 173 NONAME - _ZN17CXnControlAdapterC2Ev @ 174 NONAME - _ZN17CXnControlAdapterD0Ev @ 175 NONAME - _ZN17CXnControlAdapterD1Ev @ 176 NONAME - _ZN17CXnControlAdapterD2Ev @ 177 NONAME - _ZN19MXnComponentFactory16MakeXnComponentLER15CXnNodePluginIfRP12CXnComponent @ 178 NONAME - _ZN19MXnComponentFactory18CreateXnComponentLER15CXnNodePluginIfRP12CXnComponent @ 179 NONAME - _ZN19MXnComponentFactory21MakeXnControlAdapterLER15CXnNodePluginIfP17CXnControlAdapter @ 180 NONAME - _ZN19MXnComponentFactory26DoesNodeNeedComponentImplLERK6TDesC8 @ 181 NONAME - _ZN19MXnComponentFactoryC2Ev @ 182 NONAME - _ZN19MXnComponentFactoryD0Ev @ 183 NONAME - _ZN19MXnComponentFactoryD1Ev @ 184 NONAME - _ZN19MXnComponentFactoryD2Ev @ 185 NONAME - _ZN19TXnUiEnginePluginIf10StringPoolEv @ 186 NONAME - _ZN19TXnUiEnginePluginIf11PluginNodeLEP15CXnNodePluginIf @ 187 NONAME - _ZN19TXnUiEnginePluginIf12EnableSwipeLEi @ 188 NONAME - _ZN19TXnUiEnginePluginIf12FocusVisibleEv @ 189 NONAME - _ZN19TXnUiEnginePluginIf12FocusedNodeLEv @ 190 NONAME - _ZN19TXnUiEnginePluginIf13ActivateViewLER15CXnNodePluginIf @ 191 NONAME - _ZN19TXnUiEnginePluginIf13AddDirtyNodeLER15CXnNodePluginIf @ 192 NONAME - _ZN19TXnUiEnginePluginIf13FindNodeByIdLERK6TDesC8S2_ @ 193 NONAME - _ZN19TXnUiEnginePluginIf13FindNodeByIdLERK7TDesC16S2_ @ 194 NONAME - _ZN19TXnUiEnginePluginIf13SwipeEnabledLEv @ 195 NONAME - _ZN19TXnUiEnginePluginIf14SetFocusedNodeEP15CXnNodePluginIf @ 196 NONAME - _ZN19TXnUiEnginePluginIf16FindNodeByClassLERK7TDesC16 @ 197 NONAME - _ZN19TXnUiEnginePluginIf16IsMenuDisplayingEv @ 198 NONAME - _ZN19TXnUiEnginePluginIf16ScreenDeviceSizeEv @ 199 NONAME - _ZN19TXnUiEnginePluginIf16SetFocusVisibleLEi @ 200 NONAME - _ZN19TXnUiEnginePluginIf17DisableRenderUiLCEv @ 201 NONAME - _ZN19TXnUiEnginePluginIf18IsDialogDisplayingEv @ 202 NONAME - _ZN19TXnUiEnginePluginIf18VerticalTwipValueLEP11CXnPropertyi @ 203 NONAME - _ZN19TXnUiEnginePluginIf19VerticalPixelValueLEP11CXnPropertyi @ 204 NONAME - _ZN19TXnUiEnginePluginIf20HorizontalTwipValueLEP11CXnPropertyi @ 205 NONAME - _ZN19TXnUiEnginePluginIf21HorizontalPixelValueLEP11CXnPropertyi @ 206 NONAME - _ZN19TXnUiEnginePluginIf22DeactivateFocusedNodeLEv @ 207 NONAME - _ZN19TXnUiEnginePluginIf26RestorePreviousFocusedNodeEv @ 208 NONAME - _ZN19TXnUiEnginePluginIf8EditModeEv @ 209 NONAME - _ZN19TXnUiEnginePluginIf9LayoutUILEP15CXnNodePluginIf @ 210 NONAME - _ZN19TXnUiEnginePluginIf9RenderUILEP15CXnNodePluginIf @ 211 NONAME - _ZN19TXnUiEnginePluginIf9ResourcesEv @ 212 NONAME - _ZN19TXnUiEnginePluginIf9RootNodeLEv @ 213 NONAME - _ZN19TXnUiEnginePluginIf9ShowFocusEv @ 214 NONAME - _ZN20CXnComponentNodeImpl10ConstructLEP7CXnType @ 215 NONAME - _ZN20CXnComponentNodeImpl12SetComponentEP12CXnComponent @ 216 NONAME - _ZN20CXnComponentNodeImpl14MakeInterfaceLERK6TDesC8 @ 217 NONAME - _ZN20CXnComponentNodeImpl25SetComponentNeedsCreationEi @ 218 NONAME - _ZN20CXnComponentNodeImpl4NewLEP7CXnType @ 219 NONAME - _ZN20CXnComponentNodeImpl9ComponentEv @ 220 NONAME - _ZN20CXnComponentNodeImplC1Ev @ 221 NONAME - _ZN20CXnComponentNodeImplC2Ev @ 222 NONAME - _ZN20CXnComponentNodeImplD0Ev @ 223 NONAME - _ZN20CXnComponentNodeImplD1Ev @ 224 NONAME - _ZN20CXnComponentNodeImplD2Ev @ 225 NONAME - _ZN8CXnUtils11CreateFontLER15CXnNodePluginIfRP5CFontRi @ 226 NONAME - _ZN8CXnUtils11CreateFontLERK7TDesC16i10TFontStyleRP5CFontRi @ 227 NONAME - _ZN8CXnUtils11GetRgbValueER4TRgbRK6TDesC8 @ 228 NONAME - _ZN8CXnUtils11StripQuotesERP7HBufC16 @ 229 NONAME - _ZN8CXnUtils12FindResourceER12CArrayPtrSegI11CXnResourceERK7TDesC16Ri @ 230 NONAME - _ZN8CXnUtils12ScaleBitmapLERK5TRectP10CFbsBitmapS4_ @ 231 NONAME - _ZN8CXnUtils13TextAlignmentER15CXnNodePluginIf @ 232 NONAME - _ZN8CXnUtils15ConvertHslToRgbEiii @ 233 NONAME - _ZN8CXnUtils18CollapseWhiteSpaceER15CXnNodePluginIfR6TDes16 @ 234 NONAME - _ZN8CXnUtils18ResolveSkinItemIDLERK7TDesC16R11TAknsItemIDRi @ 235 NONAME - _ZN8CXnUtils20HandlePowerSaveModeLEP7CXnNodeii @ 236 NONAME - _ZNK11CXnProperty7EqualsLERS_ @ 237 NONAME - _ZNK12CXnNodeAppIf12GetPropertyLER11CXnProperty @ 238 NONAME - _ZNK12CXnNodeAppIf12GetPropertyLERK6TDesC8 @ 239 NONAME - _ZNK12CXnNodeAppIf19InternalDomNodeTypeEv @ 240 NONAME - _ZNK12CXnNodeAppIf7ParentLEv @ 241 NONAME - _ZNK12CXnNodeAppIf9GetPCDataEv @ 242 NONAME - _ZNK14CXnApplication9AppDllUidEv @ 243 NONAME - _ZNK15CXnAppUiAdapter4ViewEv @ 244 NONAME - _ZNK15CXnNodePluginIf12GetPropertyLER11CXnProperty @ 245 NONAME - _ZNK15CXnNodePluginIf12GetPropertyLERK6TDesC8 @ 246 NONAME - _ZNK15CXnNodePluginIf7ControlEv @ 247 NONAME - _ZNK15CXnNodePluginIf7ParentLEv @ 248 NONAME - _ZNK15CXnNodePluginIf9GetPCDataEv @ 249 NONAME - _ZNK16TXnUiEngineAppIf14WidgetsVisibleEv @ 250 NONAME - _ZNK17CXnControlAdapter15LongTapDetectorEv @ 251 NONAME - _ZNK17CXnControlAdapter16ComponentControlEi @ 252 NONAME - _ZNK17CXnControlAdapter16DrawContentImageEv @ 253 NONAME - _ZNK17CXnControlAdapter16IsDrawingAllowedEv @ 254 NONAME - _ZNK17CXnControlAdapter22CountComponentControlsEv @ 255 NONAME - _ZNK17CXnControlAdapter4DrawERK5TRect @ 256 NONAME - _ZNK17CXnControlAdapter4DrawERK5TRectR9CWindowGc @ 257 NONAME - _ZNK19TXnUiEnginePluginIf14WidgetsVisibleEv @ 258 NONAME - _ZNK19TXnUiEnginePluginIf9HitRegionEv @ 259 NONAME - _ZNK20CXnComponentNodeImpl25DoesComponentNeedCreationEv @ 260 NONAME - _ZTI11CXnDocument @ 261 NONAME - _ZTI11CXnProperty @ 262 NONAME - _ZTI12CXnComponent @ 263 NONAME - _ZTI14CXnApplication @ 264 NONAME - _ZTI15CXnAppUiAdapter @ 265 NONAME - _ZTI16CXnViewsNodeImpl @ 266 NONAME - _ZTI16MXnNodePredicate @ 267 NONAME - _ZTI17CXnControlAdapter @ 268 NONAME - _ZTI18CXnListQueryDialog @ 269 NONAME - _ZTI19MXnComponentFactory @ 270 NONAME - _ZTI20CXnComponentNodeImpl @ 271 NONAME - _ZTI27CXnNodeBreadthFirstIteratorI7CXnNodeE @ 272 NONAME - _ZTIN21CXnControlAdapterImpl13TIconProviderE @ 273 NONAME - _ZTV11CXnDocument @ 274 NONAME - _ZTV11CXnProperty @ 275 NONAME - _ZTV12CXnComponent @ 276 NONAME - _ZTV14CXnApplication @ 277 NONAME - _ZTV15CXnAppUiAdapter @ 278 NONAME - _ZTV16CXnViewsNodeImpl @ 279 NONAME - _ZTV16MXnNodePredicate @ 280 NONAME - _ZTV17CXnControlAdapter @ 281 NONAME - _ZTV18CXnListQueryDialog @ 282 NONAME - _ZTV19MXnComponentFactory @ 283 NONAME - _ZTV20CXnComponentNodeImpl @ 284 NONAME - _ZTV27CXnNodeBreadthFirstIteratorI7CXnNodeE @ 285 NONAME - _ZTVN21CXnControlAdapterImpl13TIconProviderE @ 286 NONAME - _ZThn52_N17CXnControlAdapter19HandleControlEventLEP11CCoeControlN19MCoeControlObserver9TCoeEventE @ 287 NONAME - _ZThn60_N17CXnControlAdapter19HandleLongTapEventLERK6TPointS2_ @ 288 NONAME - _ZN15CXnAppUiAdapter20HandleEnterEditModeLEi @ 289 NONAME + _ZN12CXnComponent8SetDataLERK6TDesC8RK7TDesC16i @ 26 NONAME + _ZN12CXnComponentC1Ev @ 27 NONAME + _ZN12CXnComponentC2Ev @ 28 NONAME + _ZN12CXnComponentD0Ev @ 29 NONAME + _ZN12CXnComponentD1Ev @ 30 NONAME + _ZN12CXnComponentD2Ev @ 31 NONAME + _ZN12CXnNodeAppIf10BorderRectEv @ 32 NONAME + _ZN12CXnNodeAppIf10IsStateSetERK6TDesC8 @ 33 NONAME + _ZN12CXnNodeAppIf10MarginRectEv @ 34 NONAME + _ZN12CXnNodeAppIf10SetPCDataLERK6TDesC8 @ 35 NONAME + _ZN12CXnNodeAppIf11PaddingRectEv @ 36 NONAME + _ZN12CXnNodeAppIf11UnsetStateLERK6TDesC8 @ 37 NONAME + _ZN12CXnNodeAppIf12SetPropertyLEP11CXnProperty @ 38 NONAME + _ZN12CXnNodeAppIf13HideTooltipsLEv @ 39 NONAME + _ZN12CXnNodeAppIf13ShowTooltipsLEv @ 40 NONAME + _ZN12CXnNodeAppIf14MakeInterfaceLERK6TDesC8 @ 41 NONAME + _ZN12CXnNodeAppIf17SetPropertyArrayLEP13RPointerArrayI11CXnPropertyE @ 42 NONAME + _ZN12CXnNodeAppIf4RectEv @ 43 NONAME + _ZN12CXnNodeAppIf4TypeEv @ 44 NONAME + _ZN12CXnNodeAppIf9ChildrenLEv @ 45 NONAME + _ZN12CXnNodeAppIf9ComponentEv @ 46 NONAME + _ZN12CXnNodeAppIf9NamespaceEv @ 47 NONAME + _ZN12CXnNodeAppIf9SetStateLERK6TDesC8 @ 48 NONAME + _ZN12CXnNodeAppIf9UiEngineLEv @ 49 NONAME + _ZN14CXnApplication15CreateDocumentLEv @ 50 NONAME + _ZN14CXnApplicationC1E4TUid @ 51 NONAME + _ZN14CXnApplicationC2E4TUid @ 52 NONAME + _ZN14CXnApplicationD0Ev @ 53 NONAME + _ZN14CXnApplicationD1Ev @ 54 NONAME + _ZN14CXnApplicationD2Ev @ 55 NONAME + _ZN15CXnAppUiAdapter10ConstructLEv @ 56 NONAME + _ZN15CXnAppUiAdapter11RemoveViewLER8CAknView @ 57 NONAME + _ZN15CXnAppUiAdapter12HandleEventLERK7TDesC16R12CXnNodeAppIf @ 58 NONAME + _ZN15CXnAppUiAdapter13LoadPublisherER12CXnNodeAppIfi @ 59 NONAME + _ZN15CXnAppUiAdapter13PrepareToExitEv @ 60 NONAME + _ZN15CXnAppUiAdapter16DestroyPublisherER12CXnNodeAppIfi @ 61 NONAME + _ZN15CXnAppUiAdapter16DynInitMenuItemLERK7TDesC16P13RPointerArrayI12CXnNodeAppIfE @ 62 NONAME + _ZN15CXnAppUiAdapter18HandleXuikonEventLER12CXnNodeAppIfS1_R10CXnDomNodeS3_ @ 63 NONAME + _ZN15CXnAppUiAdapter20HandleEnterEditModeLEi @ 64 NONAME + _ZN15CXnAppUiAdapter21HandleResourceChangeLEi @ 65 NONAME + _ZN15CXnAppUiAdapter9UiEngineLEv @ 66 NONAME + _ZN15CXnAppUiAdapterC1E4TUid @ 67 NONAME + _ZN15CXnAppUiAdapterC2E4TUid @ 68 NONAME + _ZN15CXnAppUiAdapterD0Ev @ 69 NONAME + _ZN15CXnAppUiAdapterD1Ev @ 70 NONAME + _ZN15CXnAppUiAdapterD2Ev @ 71 NONAME + _ZN15CXnNodePluginIf10BorderRectEv @ 72 NONAME + _ZN15CXnNodePluginIf10MarginRectEv @ 73 NONAME + _ZN15CXnNodePluginIf10SetPCDataLERK6TDesC8 @ 74 NONAME + _ZN15CXnNodePluginIf11PaddingRectEv @ 75 NONAME + _ZN15CXnNodePluginIf11UnsetStateLERK6TDesC8 @ 76 NONAME + _ZN15CXnNodePluginIf11VisibilityLEv @ 77 NONAME + _ZN15CXnNodePluginIf12GridColumnsLEv @ 78 NONAME + _ZN15CXnNodePluginIf12SetPropertyLEP11CXnProperty @ 79 NONAME + _ZN15CXnNodePluginIf12ViewNodeImplEv @ 80 NONAME + _ZN15CXnNodePluginIf12VisibleRowsLEv @ 81 NONAME + _ZN15CXnNodePluginIf13SetBorderRectERK5TRect @ 82 NONAME + _ZN15CXnNodePluginIf13SetMarginRectERK5TRect @ 83 NONAME + _ZN15CXnNodePluginIf14IsFocusedStateEv @ 84 NONAME + _ZN15CXnNodePluginIf14MakeInterfaceLERK6TDesC8 @ 85 NONAME + _ZN15CXnNodePluginIf14SetPaddingRectERK5TRect @ 86 NONAME + _ZN15CXnNodePluginIf16FocusHorLoopingLEv @ 87 NONAME + _ZN15CXnNodePluginIf16FocusVerLoopingLEv @ 88 NONAME + _ZN15CXnNodePluginIf16GridOrientationLEv @ 89 NONAME + _ZN15CXnNodePluginIf16SetHandleTooltipEi @ 90 NONAME + _ZN15CXnNodePluginIf16SetLayoutCapableEi @ 91 NONAME + _ZN15CXnNodePluginIf17ComponentNodeImplEv @ 92 NONAME + _ZN15CXnNodePluginIf17GridHorDirectionLEv @ 93 NONAME + _ZN15CXnNodePluginIf17GridVerDirectionLEv @ 94 NONAME + _ZN15CXnNodePluginIf19GridScrollBarWidthLEv @ 95 NONAME + _ZN15CXnNodePluginIf19ReportTriggerEventLERK6TDesC8S2_S2_ @ 96 NONAME + _ZN15CXnNodePluginIf20GridScrollBarMarginLEv @ 97 NONAME + _ZN15CXnNodePluginIf31SetPropertyWithoutNotificationLEP11CXnProperty @ 98 NONAME + _ZN15CXnNodePluginIf3IdLEv @ 99 NONAME + _ZN15CXnNodePluginIf4RectEv @ 100 NONAME + _ZN15CXnNodePluginIf4RefLEv @ 101 NONAME + _ZN15CXnNodePluginIf4TypeEv @ 102 NONAME + _ZN15CXnNodePluginIf5PathLEv @ 103 NONAME + _ZN15CXnNodePluginIf6AppIfLEv @ 104 NONAME + _ZN15CXnNodePluginIf6LabelLEv @ 105 NONAME + _ZN15CXnNodePluginIf7SetRectERK5TRect @ 106 NONAME + _ZN15CXnNodePluginIf8DisplayLEv @ 107 NONAME + _ZN15CXnNodePluginIf9AddChildLEPS_ @ 108 NONAME + _ZN15CXnNodePluginIf9ChildrenLEv @ 109 NONAME + _ZN15CXnNodePluginIf9MaskPathLEv @ 110 NONAME + _ZN15CXnNodePluginIf9NamespaceEv @ 111 NONAME + _ZN15CXnNodePluginIf9SetDirtyLEv @ 112 NONAME + _ZN15CXnNodePluginIf9SetStateLERK6TDesC8 @ 113 NONAME + _ZN15CXnNodePluginIf9UiEngineLEv @ 114 NONAME + _ZN15CXnUiEngineImpl14EnableRenderUiEPv @ 115 NONAME + _ZN16CXnViewsNodeImpl10ConstructLEP7CXnType @ 116 NONAME + _ZN16CXnViewsNodeImpl12SetComponentEP12CXnComponent @ 117 NONAME + _ZN16CXnViewsNodeImpl4NewLEP7CXnType @ 118 NONAME + _ZN16CXnViewsNodeImpl9ComponentEv @ 119 NONAME + _ZN16CXnViewsNodeImplC1Ev @ 120 NONAME + _ZN16CXnViewsNodeImplC2Ev @ 121 NONAME + _ZN16CXnViewsNodeImplD0Ev @ 122 NONAME + _ZN16CXnViewsNodeImplD1Ev @ 123 NONAME + _ZN16CXnViewsNodeImplD2Ev @ 124 NONAME + _ZN16MXnNodePredicate5MatchER7CXnNode @ 125 NONAME + _ZN16MXnNodePredicateC1Ev @ 126 NONAME + _ZN16MXnNodePredicateC2Ev @ 127 NONAME + _ZN16MXnNodePredicateD0Ev @ 128 NONAME + _ZN16MXnNodePredicateD1Ev @ 129 NONAME + _ZN16MXnNodePredicateD2Ev @ 130 NONAME + _ZN16TXnUiEngineAppIf10ActiveViewEv @ 131 NONAME + _ZN16TXnUiEngineAppIf10IsEditModeEv @ 132 NONAME + _ZN16TXnUiEngineAppIf10StringPoolEv @ 133 NONAME + _ZN16TXnUiEngineAppIf11FocusedNodeEv @ 134 NONAME + _ZN16TXnUiEngineAppIf11SetUiEngineEP11CXnUiEngine @ 135 NONAME + _ZN16TXnUiEngineAppIf12RefreshMenuLEv @ 136 NONAME + _ZN16TXnUiEngineAppIf13ActivateViewLER12CXnNodeAppIf @ 137 NONAME + _ZN16TXnUiEngineAppIf13FindNodeByIdLERK6TDesC8S2_ @ 138 NONAME + _ZN16TXnUiEngineAppIf13FindNodeByIdLERK7TDesC16S2_ @ 139 NONAME + _ZN16TXnUiEngineAppIf16FindNodeByClassLERK6TDesC8S2_ @ 140 NONAME + _ZN16TXnUiEngineAppIf16FindNodeByClassLERK7TDesC16S2_ @ 141 NONAME + _ZN16TXnUiEngineAppIf16GetThemeResourceERK7TDesC16R5RFile @ 142 NONAME + _ZN16TXnUiEngineAppIf16IsMenuDisplayingEv @ 143 NONAME + _ZN16TXnUiEngineAppIf19GetPluginNodeArrayLER13RPointerArrayI12CXnNodeAppIfE @ 144 NONAME + _ZN16TXnUiEngineAppIf23FindContentSourceNodesLERK6TDesC8 @ 145 NONAME + _ZN16TXnUiEngineAppIf9RenderUILEP12CXnNodeAppIf @ 146 NONAME + _ZN16TXnUiEngineAppIf9RootNodeLEv @ 147 NONAME + _ZN17CXnControlAdapter10ConstructLER15CXnNodePluginIf @ 148 NONAME + _ZN17CXnControlAdapter10LoadBitmapERK7TDesC16 @ 149 NONAME + _ZN17CXnControlAdapter10SetVisibleEi @ 150 NONAME + _ZN17CXnControlAdapter11SizeChangedEv @ 151 NONAME + _ZN17CXnControlAdapter11SkinChangedEv @ 152 NONAME + _ZN17CXnControlAdapter12FocusChangedE8TDrawNow @ 153 NONAME + _ZN17CXnControlAdapter12SetComponentEP12CXnComponent @ 154 NONAME + _ZN17CXnControlAdapter14ContentBitmapsERP10CFbsBitmapS2_ @ 155 NONAME + _ZN17CXnControlAdapter14OfferKeyEventLERK9TKeyEvent10TEventCode @ 156 NONAME + _ZN17CXnControlAdapter15SetLocalUiZoomLE10TAknUiZoom @ 157 NONAME + _ZN17CXnControlAdapter16GetBitmapAndMaskERK7TDesC16S2_RP10CFbsBitmapS5_ @ 158 NONAME + _ZN17CXnControlAdapter17SetContentBitmapsEP10CFbsBitmapS1_ @ 159 NONAME + _ZN17CXnControlAdapter17SetContentBitmapsERK7TDesC16S2_ @ 160 NONAME + _ZN17CXnControlAdapter18ExitPowerSaveModeLENS_10TModeEventE @ 161 NONAME + _ZN17CXnControlAdapter18ResetStylusCounterEv @ 162 NONAME + _ZN17CXnControlAdapter19EnterPowerSaveModeLENS_10TModeEventE @ 163 NONAME + _ZN17CXnControlAdapter19HandleControlEventLEP11CCoeControlN19MCoeControlObserver9TCoeEventE @ 164 NONAME + _ZN17CXnControlAdapter19HandleLongTapEventLERK6TPointS2_ @ 165 NONAME + _ZN17CXnControlAdapter19HandlePointerEventLERK13TPointerEvent @ 166 NONAME + _ZN17CXnControlAdapter20DoExitPowerSaveModeLENS_10TModeEventE @ 167 NONAME + _ZN17CXnControlAdapter21DoEnterPowerSaveModeLENS_10TModeEventE @ 168 NONAME + _ZN17CXnControlAdapter21HandlePropertyChangeLEP11CXnProperty @ 169 NONAME + _ZN17CXnControlAdapter22EnableLongTapAnimationEi @ 170 NONAME + _ZN17CXnControlAdapter23DoHandlePropertyChangeLEP11CXnProperty @ 171 NONAME + _ZN17CXnControlAdapter23MeasureAdaptiveContentLERK5TSize @ 172 NONAME + _ZN17CXnControlAdapter26HandleScreenDeviceChangedLEv @ 173 NONAME + _ZN17CXnControlAdapter4NewLER15CXnNodePluginIf @ 174 NONAME + _ZN17CXnControlAdapter8SetBlankEi @ 175 NONAME + _ZN17CXnControlAdapter8SetDataLERK6TDesC8RK7TDesC16i @ 176 NONAME + _ZN17CXnControlAdapter9ComponentEv @ 177 NONAME + _ZN17CXnControlAdapterC1Ev @ 178 NONAME + _ZN17CXnControlAdapterC2Ev @ 179 NONAME + _ZN17CXnControlAdapterD0Ev @ 180 NONAME + _ZN17CXnControlAdapterD1Ev @ 181 NONAME + _ZN17CXnControlAdapterD2Ev @ 182 NONAME + _ZN19MXnComponentFactory16MakeXnComponentLER15CXnNodePluginIfRP12CXnComponent @ 183 NONAME + _ZN19MXnComponentFactory18CreateXnComponentLER15CXnNodePluginIfRP12CXnComponent @ 184 NONAME + _ZN19MXnComponentFactory21MakeXnControlAdapterLER15CXnNodePluginIfP17CXnControlAdapter @ 185 NONAME + _ZN19MXnComponentFactory26DoesNodeNeedComponentImplLERK6TDesC8 @ 186 NONAME + _ZN19MXnComponentFactoryC2Ev @ 187 NONAME + _ZN19MXnComponentFactoryD0Ev @ 188 NONAME + _ZN19MXnComponentFactoryD1Ev @ 189 NONAME + _ZN19MXnComponentFactoryD2Ev @ 190 NONAME + _ZN19TXnUiEnginePluginIf10StringPoolEv @ 191 NONAME + _ZN19TXnUiEnginePluginIf11PluginNodeLEP15CXnNodePluginIf @ 192 NONAME + _ZN19TXnUiEnginePluginIf12EnableSwipeLEi @ 193 NONAME + _ZN19TXnUiEnginePluginIf12FocusVisibleEv @ 194 NONAME + _ZN19TXnUiEnginePluginIf12FocusedNodeLEv @ 195 NONAME + _ZN19TXnUiEnginePluginIf13ActivateViewLER15CXnNodePluginIf @ 196 NONAME + _ZN19TXnUiEnginePluginIf13AddDirtyNodeLER15CXnNodePluginIf @ 197 NONAME + _ZN19TXnUiEnginePluginIf13FindNodeByIdLERK6TDesC8S2_ @ 198 NONAME + _ZN19TXnUiEnginePluginIf13FindNodeByIdLERK7TDesC16S2_ @ 199 NONAME + _ZN19TXnUiEnginePluginIf13SwipeEnabledLEv @ 200 NONAME + _ZN19TXnUiEnginePluginIf14SetFocusedNodeEP15CXnNodePluginIf @ 201 NONAME + _ZN19TXnUiEnginePluginIf16FindNodeByClassLERK7TDesC16 @ 202 NONAME + _ZN19TXnUiEnginePluginIf16IsMenuDisplayingEv @ 203 NONAME + _ZN19TXnUiEnginePluginIf16ScreenDeviceSizeEv @ 204 NONAME + _ZN19TXnUiEnginePluginIf16SetFocusVisibleLEi @ 205 NONAME + _ZN19TXnUiEnginePluginIf17DisableRenderUiLCEv @ 206 NONAME + _ZN19TXnUiEnginePluginIf18IsDialogDisplayingEv @ 207 NONAME + _ZN19TXnUiEnginePluginIf18VerticalTwipValueLEP11CXnPropertyi @ 208 NONAME + _ZN19TXnUiEnginePluginIf19VerticalPixelValueLEP11CXnPropertyi @ 209 NONAME + _ZN19TXnUiEnginePluginIf20HorizontalTwipValueLEP11CXnPropertyi @ 210 NONAME + _ZN19TXnUiEnginePluginIf21HorizontalPixelValueLEP11CXnPropertyi @ 211 NONAME + _ZN19TXnUiEnginePluginIf22DeactivateFocusedNodeLEv @ 212 NONAME + _ZN19TXnUiEnginePluginIf26RestorePreviousFocusedNodeEv @ 213 NONAME + _ZN19TXnUiEnginePluginIf8EditModeEv @ 214 NONAME + _ZN19TXnUiEnginePluginIf9LayoutUILEP15CXnNodePluginIf @ 215 NONAME + _ZN19TXnUiEnginePluginIf9RenderUILEP15CXnNodePluginIf @ 216 NONAME + _ZN19TXnUiEnginePluginIf9ResourcesEv @ 217 NONAME + _ZN19TXnUiEnginePluginIf9RootNodeLEv @ 218 NONAME + _ZN19TXnUiEnginePluginIf9ShowFocusEv @ 219 NONAME + _ZN20CXnComponentNodeImpl10ConstructLEP7CXnType @ 220 NONAME + _ZN20CXnComponentNodeImpl12SetComponentEP12CXnComponent @ 221 NONAME + _ZN20CXnComponentNodeImpl14MakeInterfaceLERK6TDesC8 @ 222 NONAME + _ZN20CXnComponentNodeImpl25SetComponentNeedsCreationEi @ 223 NONAME + _ZN20CXnComponentNodeImpl4NewLEP7CXnType @ 224 NONAME + _ZN20CXnComponentNodeImpl9ComponentEv @ 225 NONAME + _ZN20CXnComponentNodeImplC1Ev @ 226 NONAME + _ZN20CXnComponentNodeImplC2Ev @ 227 NONAME + _ZN20CXnComponentNodeImplD0Ev @ 228 NONAME + _ZN20CXnComponentNodeImplD1Ev @ 229 NONAME + _ZN20CXnComponentNodeImplD2Ev @ 230 NONAME + _ZN8CXnUtils11CreateFontLER15CXnNodePluginIfRP5CFontRi @ 231 NONAME + _ZN8CXnUtils11CreateFontLERK7TDesC16i10TFontStyleRP5CFontRi @ 232 NONAME + _ZN8CXnUtils11GetRgbValueER4TRgbRK6TDesC8 @ 233 NONAME + _ZN8CXnUtils11StripQuotesERP7HBufC16 @ 234 NONAME + _ZN8CXnUtils12FindResourceER12CArrayPtrSegI11CXnResourceERK7TDesC16Ri @ 235 NONAME + _ZN8CXnUtils12ScaleBitmapLERK5TRectP10CFbsBitmapS4_ @ 236 NONAME + _ZN8CXnUtils13TextAlignmentER15CXnNodePluginIf @ 237 NONAME + _ZN8CXnUtils15ConvertHslToRgbEiii @ 238 NONAME + _ZN8CXnUtils18CollapseWhiteSpaceER15CXnNodePluginIfR6TDes16 @ 239 NONAME + _ZN8CXnUtils18ResolveSkinItemIDLERK7TDesC16R11TAknsItemIDRi @ 240 NONAME + _ZN8CXnUtils20HandlePowerSaveModeLEP7CXnNodeii @ 241 NONAME + _ZNK11CXnProperty7EqualsLERS_ @ 242 NONAME + _ZNK12CXnNodeAppIf12GetPropertyLER11CXnProperty @ 243 NONAME + _ZNK12CXnNodeAppIf12GetPropertyLERK6TDesC8 @ 244 NONAME + _ZNK12CXnNodeAppIf19InternalDomNodeTypeEv @ 245 NONAME + _ZNK12CXnNodeAppIf7ParentLEv @ 246 NONAME + _ZNK12CXnNodeAppIf9GetPCDataEv @ 247 NONAME + _ZNK14CXnApplication9AppDllUidEv @ 248 NONAME + _ZNK15CXnAppUiAdapter4ViewEv @ 249 NONAME + _ZNK15CXnNodePluginIf12GetPropertyLER11CXnProperty @ 250 NONAME + _ZNK15CXnNodePluginIf12GetPropertyLERK6TDesC8 @ 251 NONAME + _ZNK15CXnNodePluginIf7ControlEv @ 252 NONAME + _ZNK15CXnNodePluginIf7ParentLEv @ 253 NONAME + _ZNK15CXnNodePluginIf9GetPCDataEv @ 254 NONAME + _ZNK16TXnUiEngineAppIf14WidgetsVisibleEv @ 255 NONAME + _ZNK17CXnControlAdapter15LongTapDetectorEv @ 256 NONAME + _ZNK17CXnControlAdapter16ComponentControlEi @ 257 NONAME + _ZNK17CXnControlAdapter16DrawContentImageEv @ 258 NONAME + _ZNK17CXnControlAdapter16IsDrawingAllowedEv @ 259 NONAME + _ZNK17CXnControlAdapter22CountComponentControlsEv @ 260 NONAME + _ZNK17CXnControlAdapter4DrawERK5TRect @ 261 NONAME + _ZNK17CXnControlAdapter4DrawERK5TRectR9CWindowGc @ 262 NONAME + _ZNK19TXnUiEnginePluginIf14WidgetsVisibleEv @ 263 NONAME + _ZNK19TXnUiEnginePluginIf9HitRegionEv @ 264 NONAME + _ZNK20CXnComponentNodeImpl25DoesComponentNeedCreationEv @ 265 NONAME + _ZTI11CXnDocument @ 266 NONAME + _ZTI11CXnProperty @ 267 NONAME + _ZTI12CXnComponent @ 268 NONAME + _ZTI14CXnApplication @ 269 NONAME + _ZTI15CXnAppUiAdapter @ 270 NONAME + _ZTI16CXnViewsNodeImpl @ 271 NONAME + _ZTI16MXnNodePredicate @ 272 NONAME + _ZTI17CXnControlAdapter @ 273 NONAME + _ZTI18CXnListQueryDialog @ 274 NONAME + _ZTI19MXnComponentFactory @ 275 NONAME + _ZTI20CXnComponentNodeImpl @ 276 NONAME + _ZTI27CXnNodeBreadthFirstIteratorI7CXnNodeE @ 277 NONAME + _ZTIN21CXnControlAdapterImpl13TIconProviderE @ 278 NONAME + _ZTV11CXnDocument @ 279 NONAME + _ZTV11CXnProperty @ 280 NONAME + _ZTV12CXnComponent @ 281 NONAME + _ZTV14CXnApplication @ 282 NONAME + _ZTV15CXnAppUiAdapter @ 283 NONAME + _ZTV16CXnViewsNodeImpl @ 284 NONAME + _ZTV16MXnNodePredicate @ 285 NONAME + _ZTV17CXnControlAdapter @ 286 NONAME + _ZTV18CXnListQueryDialog @ 287 NONAME + _ZTV19MXnComponentFactory @ 288 NONAME + _ZTV20CXnComponentNodeImpl @ 289 NONAME + _ZTV27CXnNodeBreadthFirstIteratorI7CXnNodeE @ 290 NONAME + _ZTVN21CXnControlAdapterImpl13TIconProviderE @ 291 NONAME + _ZThn52_N17CXnControlAdapter19HandleControlEventLEP11CCoeControlN19MCoeControlObserver9TCoeEventE @ 292 NONAME + _ZThn60_N17CXnControlAdapter19HandleLongTapEventLERK6TPointS2_ @ 293 NONAME + _ZN19TXnUiEnginePluginIf23EnablePartialTouchInputER15CXnNodePluginIfi @ 294 NONAME diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/inc/xnbackgroundmanager.h --- a/idlehomescreen/xmluirendering/uiengine/inc/xnbackgroundmanager.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/inc/xnbackgroundmanager.h Fri Feb 19 22:42:37 2010 +0200 @@ -20,7 +20,7 @@ // System includes #include -#include +#include #include #include @@ -174,7 +174,8 @@ TInt AddCommonWallpaperL( const TDesC& aFileName, TBool aSave = ETrue ); void ReadWallpaperFromCenrepL(); void UpdateScreen(); - + void DrawEditModeBackgroundSkin() const; + private: // data /** diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/inc/xnextrenderingpluginwrapper.h --- a/idlehomescreen/xmluirendering/uiengine/inc/xnextrenderingpluginwrapper.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/inc/xnextrenderingpluginwrapper.h Fri Feb 19 22:42:37 2010 +0200 @@ -21,6 +21,7 @@ // System includes #include #include +#include // User includes #include "xncontroladapter.h" @@ -39,7 +40,7 @@ * @lib extrenderingplugin.lib * @since S60 v5.0 */ -NONSHARABLE_CLASS( CXnExtRenderingPluginWrapper ) : public CXnControlAdapter +NONSHARABLE_CLASS( CXnExtRenderingPluginWrapper ) : public CXnControlAdapter, public MXnExtEventHandler { public: // Constructor and destructor /** @@ -83,6 +84,16 @@ TKeyResponse OfferKeyEventL(const TKeyEvent& aKeyEvent,TEventCode aType); + /** + * Routes the data stream for the external rendering plugin. + * + * @since Series 60 5.2 + * @param aData Data stream. + * @param aType Type of the stream. + * @param aIndex Index of the data. + */ + void SetDataL( const TDesC8& aData, const TDesC& aType, TInt aIndex ); + public: // New functions /** @@ -93,8 +104,16 @@ /** * @see CXnControlAdapter */ - void DoExitPowerSaveModeL( TModeEvent aEvent ); - + void DoExitPowerSaveModeL( TModeEvent aEvent ); + + /** + * Routes the events from the external rendering plug-ins to content plug-ins + * @since Series 60 5.2 + * @param aEvent Event string + * @param aDestination Destination content plug-in. + */ + void HandleEventL( const TDesC& aEvent, const TDesC8& aDestination ); + private: // Data /** diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/inc/xnplugindata.h --- a/idlehomescreen/xmluirendering/uiengine/inc/xnplugindata.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/inc/xnplugindata.h Fri Feb 19 22:42:37 2010 +0200 @@ -30,9 +30,9 @@ class CXnControlAdapter; class CXnViewData; class CXnODT; -class CXnDataPluginLoader; class CXnViewManager; class CPeriodic; + // Constants // Class declaration @@ -56,8 +56,7 @@ EIsEmpty, EIsRemovable, EIsActive, - EIsInitial, - EIsDataPluginsReady + EIsInitial }; public: @@ -112,9 +111,11 @@ // New functions /** - * Loads content to plugin + * Loads content to plugin + * + * @return KErrNone if succesful, error code otherwise */ - virtual void LoadL(); + virtual TInt Load(); /** * Destroys content from plugin @@ -242,25 +243,6 @@ inline const TDesC8& Type() const; /** - * Sets new plugin state - * - * @param aConfigurationState Plugin state - */ - void SetPluginStateL( const TDesC8& aPluginState ); - - /* - * Reverts plugin state back to confirmed from wait for confirmation - */ - void RevertPluginState(); - - /** - * Returns plugin state - * - * @return Plugin state - */ - inline const TDesC8& PluginState() const; - - /** * void SetPublisherNameL( const TDesC8& aPublisherName ) * Sets the name of the publisher * @@ -405,14 +387,13 @@ * @param aVisible sets the popup visible or invisible * @param aNode a pointer to the popup node */ - void SetIsDisplayingPopup ( TBool aVisible, CXnNode* aNode ); + void SetIsDisplayingPopup( TBool aVisible, CXnNode* aNode ); /** * Checks if the popup is displayed */ - TBool IsDisplayingPopup () const; - - + TBool IsDisplayingPopup() const; + /** * Returns list of plugindata * @@ -421,45 +402,47 @@ inline RPointerArray< CXnPluginData >& PluginData() const; /** - * Loads data plugins associated to the plugin data + * Loads publishers, called by CXnViewData + * + * @param aReason Load reason + */ + TInt LoadPublishers( TInt aReason ); + + /** + * Queries whether this plugins publishers are virgin * + * @return ETrue if virgin, EFalse otherwise */ - virtual void LoadDataPluginsL(); + TBool VirginPublishers() const; + + /** + * Show content removed error note + */ + void ShowContentRemovedError(); /** - * Deletes data plugins associated to the plugin data - */ - virtual void DestroyDataPluginsL(); - - /** - * Indicates that all data plugins are loaded by data plugin loader - * - * @param aStatus Loading status - */ - virtual void DataPluginsLoadCompletedL( TInt aStatus ); - - /** - * Returns data plugin loading status - * - * @return ETrue if data plugins are loaded or there is no data - * plugins associated to the plugin. - * EFalse otherwise - */ - virtual TBool DataPluginsLoaded() const; - - + * Show oom error note + */ + void ShowOutOfMemError(); + private: // New functions + + void LoadPublishers(); - static TInt RunL( TAny* aAny ); + void DestroyPublishers(); + + void DoDestroyPublishersL(); + + void DoShowContentRemovedErrorL(); + + static TInt PeriodicEventL( TAny* aAny ); protected: // data - /** Data plugin loader, Owned */ + /** Data publisher loader, Owned */ CPeriodic* iLoader; - /** Data plugin load index */ - TInt iLoadIndex; /** Plugins data */ mutable RPointerArray< CXnPluginData > iPluginsData; /** List of plugin resources, Owned */ @@ -474,7 +457,6 @@ RPointerArray< CXnNode > iInitialFocusNodes; /** List of popup focus nodes, Not owned */ RPointerArray< CXnNode > iPopupNodes; - /** Parent, Not owned */ CXnPluginData* iParent; /** View manager, Not owned */ @@ -493,12 +475,12 @@ HBufC8* iPluginName; /** Plugin type, Owned */ HBufC8* iPluginType; - /** Plugin state, Owned */ - HBufC8* iPluginState; /** Publisher name, Owned */ HBufC* iPublisherName; /** Flags to define this plugin's state */ TBitFlags32 iFlags; + /** Flag to indicate whether this data's publishers are virgins */ + TBool iVirginPublishers; }; // Inline functions diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/inc/xnplugindata.inl --- a/idlehomescreen/xmluirendering/uiengine/inc/xnplugindata.inl Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/inc/xnplugindata.inl Fri Feb 19 22:42:37 2010 +0200 @@ -135,15 +135,6 @@ }; // --------------------------------------------------------------------------- -// Returns plugin state -// --------------------------------------------------------------------------- -// -inline const TDesC8& CXnPluginData::PluginState() const - { - return iPluginState ? *iPluginState : KNullDesC8(); - }; - -// --------------------------------------------------------------------------- // Returns the publisher name // --------------------------------------------------------------------------- // diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/inc/xnpopupcontroladapter.h --- a/idlehomescreen/xmluirendering/uiengine/inc/xnpopupcontroladapter.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/inc/xnpopupcontroladapter.h Fri Feb 19 22:42:37 2010 +0200 @@ -30,6 +30,7 @@ class CXnNodePluginIf; class CXnNode; class CXnUiEngine; +class CXnPluginData; class CAknStylusPopUpMenu; // Class declaration @@ -103,8 +104,8 @@ private: // New functions - void PopulateMenuL( CXnNode* aItem, CXnNode& aPlugin ); - void ShowMenuL( CXnNode& aPlugin, TPoint aPosition ); + void PopulateMenuL( CXnPluginData& aPlugin, CXnNode* aItem ); + void ShowMenuL( CXnPluginData& aPlugin, TPoint aPosition ); void HideMenuL(); private: diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/inc/xnrootdata.h --- a/idlehomescreen/xmluirendering/uiengine/inc/xnrootdata.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/inc/xnrootdata.h Fri Feb 19 22:42:37 2010 +0200 @@ -80,7 +80,7 @@ /** * @see CXnPluginData */ - void LoadL(); + TInt Load(); /** * @see CXnPluginData diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/inc/xnuiengineimpl.h --- a/idlehomescreen/xmluirendering/uiengine/inc/xnuiengineimpl.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/inc/xnuiengineimpl.h Fri Feb 19 22:42:37 2010 +0200 @@ -58,8 +58,7 @@ const TInt ERefreshMenu = 0x04; const TInt EIgnoreState = 0x08; const TInt EViewDirty = 0x10; - const TInt EEffectStarted = 0x20; - const TInt EFirstPassDraw = 0x40; + const TInt EEffectStarted = 0x20; } NONSHARABLE_STRUCT( TXnDirtyRegion ) @@ -72,7 +71,25 @@ iRegion.Close(); } }; - + + +NONSHARABLE_STRUCT( TXnSplitScreenState ) + { + /** Partial screen editor node. Not own */ + CXnNode* iPartialScreenEditorNode; + /** Is partial screen input open */ + TBool isPartialScreenOpen; + /** Partial screen block progression. Own. */ + HBufC8* iPartialScreenBlock; + /** Is partial screen enabled*/ + TBool isPartialScreenEnabled; + + ~TXnSplitScreenState() + { + delete iPartialScreenBlock; + } + }; + // Class declaration @@ -451,17 +468,6 @@ CXnHitTest& HitTest() const; /** - * Positions stylus popup according given position - * - * @since S60 5.1 - * @param aNode stylus popup node - * @param aReference a reference node where popup should fit - * @param aPosition stylus popup position to set. - */ - void PositionStylusPopupL( CXnNode& aNode, CXnNode& aReference, - const TPoint& aPosition ); - - /** * Gets theme resource file * * @since S60 5.1 @@ -495,7 +501,24 @@ * @param aDispather Event dispatcher */ void SetEventDispatcher( CXnKeyEventDispatcher* aDispatcher ); - + + /** + * Enables partial touch input + * + * @since Series 60 5.2 + * @param aNode Editor Node + * @param TBool Partial input is enabled + */ + void EnablePartialTouchInput( CXnNode& aNode, TBool aEnable ); + + /** + * Is partial input active + * + * @since Series 60 5.2 + * @return TBool is partial input active + */ + TBool IsPartialInputActive(); + private: IMPORT_C static void EnableRenderUi( TAny* aAny ); @@ -553,6 +576,39 @@ void AddRedrawRectL( TRect aRect, CXnNode& aNode ); void ReportScreenDeviceChangeL(); + + /** + * Handle partial touch input + * + * @since Series 60 5.2 + * @param TInt aType + */ + void HandlePartialTouchInputL( TInt aType ); + + /** + * Set node visible + * + * @since Series 60 5.2 + * @param aNode node to hide/show + * @param TBool aVisible boolean to set node visible + */ + void SetNodeVisibleL( CXnNode* aNode, TBool aVisible ); + + /** + * Set partial screen block + * + * @since Series 60 5.2 + * @param TDesC8 aBlockProgression set layout direction + */ + void SetPartialScreenBlockProgressionL( const TDesC8& aBlockProgression ); + + /** + * Store partial screen block + * + * @since Series 60 5.2 + * @param TDesC8 aBlockProgression set layout direction + */ + void StorePartialScreenBlockProgressionL(); private: //Derived functions @@ -668,6 +724,8 @@ CXnHitTest* iHitTest; /** Disable count */ TInt iDisableCount; + /**Split screen states*/ + TXnSplitScreenState iSplitScreenState; }; #endif // _CXNUIENGINEIMPL_H diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/inc/xnviewdata.h --- a/idlehomescreen/xmluirendering/uiengine/inc/xnviewdata.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/inc/xnviewdata.h Fri Feb 19 22:42:37 2010 +0200 @@ -62,7 +62,7 @@ /** * @see CXnPluginData */ - void LoadL(); + TInt Load(); /** * @see CXnPluginData @@ -93,36 +93,16 @@ * @see CXnPluginData */ void AppearanceNodesL( RPointerArray< CXnNode >& aList ) const; - - /* - * @see CXnPluginData - */ - void LoadDataPluginsL(); - - /* - * @see CXnPluginData - */ - void DataPluginsLoadCompletedL( TInt aStatus ); - - /* - * @see CXnPluginData - */ - void DestroyDataPluginsL(); - - /* - * @see CXnPluginData - */ - TBool DataPluginsLoaded() const; - + public: // New functions /** * Sets viewdata to active/ not active * - * @param aActive ETrue active, EFalse not active + * @param aActive ETrue active, EFalse not active */ - void SetActiveL( TBool aActive ); + void SetActive( TBool aActive ); /** * Returns if active or not @@ -144,20 +124,6 @@ inline TBool Initial() const; /** - * Sets focused node - * - * @param aNode Focused node - */ - inline void SetFocusedNode( CXnNode* aNode ); - - /** - * Returns focused node - * - * @return focused node - */ - inline CXnNode* FocusedNode() const; - - /** * Sets this view data to use empty widget * * @param aUse ETrue use, EFalse don't use @@ -238,18 +204,29 @@ * @param aLockingStatusString attr. locking_status ("locked"/"none") */ void SetLockingStatus( const TDesC8& aLockingStatusString ); + +private: + // new functions + + void LoadPublishers(); + + void DestroyPublishers( TInt aReason ); + + static TInt DoLoadPublishersL( TAny* aAny ); + + void DoDestroyPublishersL( TInt aReason ); private: // data - /** Focused Node, Not owned */ - CXnNode* iFocusedNode; - /** Pointer to wallpaper image, Owned */ - CFbsBitmap* iBgImage; - + CFbsBitmap* iBgImage; /** Path of the wallpaper image, including filename */ - HBufC* iBgImagePath; + HBufC* iBgImagePath; + /** Publisher load index */ + TInt iLoadIndex; + /** Flag to indicate whether content removed error should be shown */ + TBool iShowContentRemoved; }; #include "xnviewdata.inl" diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/inc/xnviewdata.inl --- a/idlehomescreen/xmluirendering/uiengine/inc/xnviewdata.inl Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/inc/xnviewdata.inl Fri Feb 19 22:42:37 2010 +0200 @@ -47,24 +47,6 @@ }; // --------------------------------------------------------------------------- -// Sets focused node -// --------------------------------------------------------------------------- -// -inline void CXnViewData::SetFocusedNode( CXnNode* aNode ) - { - iFocusedNode = aNode; - }; - -// --------------------------------------------------------------------------- -// Returns focused node -// --------------------------------------------------------------------------- -// -inline CXnNode* CXnViewData::FocusedNode() const - { - return iFocusedNode; - }; - -// --------------------------------------------------------------------------- // Sets to use empty widget // --------------------------------------------------------------------------- // diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/inc/xnwidgetextensionadapter.h --- a/idlehomescreen/xmluirendering/uiengine/inc/xnwidgetextensionadapter.h Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/inc/xnwidgetextensionadapter.h Fri Feb 19 22:42:37 2010 +0200 @@ -18,9 +18,12 @@ #ifndef __XNWIDGETEXTENSIONADAPTER_H__ #define __XNWIDGETEXTENSIONADAPTER_H__ -// INCLUDES +// System includes +#include + +// User includes #include "xncontroladapter.h" -#include +#include "xnuistatelistener.h" // Forward declarations class CXnAppUiAdapter; @@ -35,81 +38,98 @@ * @lib xnlayoutengine.lib * @since Series 60 5.0 */ -NONSHARABLE_CLASS( CXnWidgetExtensionAdapter ) : public CXnControlAdapter/*, - public MCoeMessageMonitorObserver*/ +NONSHARABLE_CLASS( CXnWidgetExtensionAdapter ) : public CXnControlAdapter, + public MXnUiStateObserver { - public: // Constructors and destructor +public: // Constructors and destructor - enum TPositionHint - { - ENone, - EAboveLeft, - EAboveRight, - EBelowLeft, - EBelowRight, - ELeft, - ERight - }; - /** - * Two-phased constructor. - */ - static CXnWidgetExtensionAdapter* NewL( CXnNodePluginIf& aNode ); - - /** - * Destructor. - */ - ~CXnWidgetExtensionAdapter(); - - private: // Functions from base classes - /** - * @see CCoeControl documentation - */ - void MakeVisible( TBool aVisible ); + enum TPositionHint + { + ENone, + EAboveLeft, + EAboveRight, + EBelowLeft, + EBelowRight, + ELeft, + ERight + }; + /** + * Two-phased constructor. + */ + static CXnWidgetExtensionAdapter* NewL( CXnNodePluginIf& aNode ); + + /** + * Destructor. + */ + ~CXnWidgetExtensionAdapter(); + +private: + // Functions from base classes + /** + * @see CCoeControl documentation + */ + void MakeVisible( TBool aVisible ); - /** - * see CCoeControl - */ - void HandlePointerEventL(const TPointerEvent& aPointerEvent); + /** + * see CCoeControl + */ + void HandlePointerEventL(const TPointerEvent& aPointerEvent); + + /** + * see CCoeControl + */ + void Draw(const TRect& aRect) const; - /** - * see CCoeControl - */ - void Draw(const TRect& aRect) const; +private: + // from MXnUiStateObserver + + /** + * @see MXnUiStateObserver + */ + void NotifyForegroundChanged( TForegroundStatus aStatus ); - private: // Constructors - /** - * C++ default constructor. - */ - CXnWidgetExtensionAdapter( CXnNodePluginIf& aNode ); + /** + * @see MXnUiStateObserver + */ + void NotifyLightStatusChanged( TBool aLightsOn ); + + /** + * @see MXnUiStateObserver + */ + void NotifyInCallStateChaged( TBool aInCall ); + +private: + // Constructors + /** + * C++ default constructor. + */ + CXnWidgetExtensionAdapter( CXnNodePluginIf& aNode ); - /** - * Two-phased constructor. - */ - void ConstructL(); - - private: // New functions - /** - * Hides this control - */ - void HidePopupL(); - - void CalculatePosition(); + /** + * Two-phased constructor. + */ + void ConstructL(); + +private: + // New functions + + void HidePopupL(); - private: - - // Data - // UiEngine, not owned - CXnUiEngine* iUiEngine; - - // Node - CXnNodePluginIf& iNode; - - // position hint - TPositionHint iPositionHint; - - CXnAppUiAdapter* iAppUiAdapter; - - + void CalculatePosition(); + +private: + // Data + + /** UiEngine, not owned */ + CXnUiEngine* iUiEngine; + /** Node, not owned */ + CXnNodePluginIf& iNode; + /** Position hint */ + TPositionHint iPositionHint; + /** AppUi, not owned */ + CXnAppUiAdapter* iAppUiAdapter; + /** Flag to indicate whether is permanent */ + TBool iPermanent; }; #endif // __XNWIDGETEXTENSIONADAPTER_H__ diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnappuiadapter.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnappuiadapter.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnappuiadapter.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -41,7 +41,7 @@ // ----------------------------------------------------------------------------- // EXPORT_C CXnAppUiAdapter::CXnAppUiAdapter( TUid aApplicationUid ) - : iApplicationUid( aApplicationUid ) + : iExitingApp( EFalse ), iApplicationUid( aApplicationUid ) { } @@ -97,7 +97,8 @@ // ----------------------------------------------------------------------------- // EXPORT_C CXnAppUiAdapter::~CXnAppUiAdapter() - { + { + iExitingApp = ETrue; delete iUiEngineAppIf; delete iImpl; @@ -155,14 +156,15 @@ } // ----------------------------------------------------------------------------- -// CXnAppUiAdapter::LoadDataPluginsL +// CXnAppUiAdapter::LoadPublisher // // ----------------------------------------------------------------------------- // -EXPORT_C void CXnAppUiAdapter::LoadDataPluginsL( - RPointerArray< CXnNodeAppIf >& /*aList*/ ) +EXPORT_C TInt CXnAppUiAdapter::LoadPublisher( CXnNodeAppIf& /*aPublisher*/, + TInt /*aReason*/ ) { // Default empty implementation + return KErrNone; } // ----------------------------------------------------------------------------- @@ -170,10 +172,11 @@ // // ----------------------------------------------------------------------------- // -EXPORT_C void CXnAppUiAdapter::DestroyDataPluginsL( - RPointerArray< CXnNodeAppIf >& /*aList*/ ) +EXPORT_C TInt CXnAppUiAdapter::DestroyPublisher( CXnNodeAppIf& /*aPublisher*/, + TInt /*aReason*/ ) { // Default empty implementation + return KErrNone; } // ----------------------------------------------------------------------------- @@ -189,17 +192,6 @@ } // ----------------------------------------------------------------------------- -// CXnAppUiAdapter::SetOnlineStateL -// -// ----------------------------------------------------------------------------- -// -EXPORT_C void CXnAppUiAdapter::SetOnlineStateL( - RPointerArray< CXnNodeAppIf >& /*aList*/ ) - { - // Default empty implementation - } - -// ----------------------------------------------------------------------------- // CXnAppUiAdapter::View // // ----------------------------------------------------------------------------- @@ -210,16 +202,6 @@ } // ----------------------------------------------------------------------------- -// CXnAppUiAdapter::HandlePageSwitch -// -// ----------------------------------------------------------------------------- -// -EXPORT_C void CXnAppUiAdapter::HandlePageSwitch() - { - // Default empty implementation - } - -// ----------------------------------------------------------------------------- // CXnAppUiAdapter::HandleEnterEditModeL // // ----------------------------------------------------------------------------- @@ -228,7 +210,84 @@ { // Default empty implementation } - + +// ----------------------------------------------------------------------------- +// CXnAppUiAdapter::HandleEventL +// +// ----------------------------------------------------------------------------- +// +EXPORT_C void CXnAppUiAdapter::HandleEventL( const TDesC& /*aEvent*/, + CXnNodeAppIf& /*aDestination*/ ) + { + // Default empty implementation + } + +// ----------------------------------------------------------------------------- +// CXnAppUiAdapter::RemoveViewL +// +// ----------------------------------------------------------------------------- +// +EXPORT_C void CXnAppUiAdapter::RemoveViewL( CAknView& aView ) + { + if ( iExitingApp ) return; // framework will destroy view + TVwsViewId activeViewId(KNullUid,KNullUid); + TBool activateDefaultView( EFalse ); + if ( GetActiveViewId( activeViewId ) == KErrNone && + activeViewId.iViewUid == aView.Id() ) + { + // currently active, deactivate + activateDefaultView = ETrue; + DeactivateActiveViewIfOwnerMatchL(); + } + + if ( iView == &aView ) { iView = NULL; } + CCoeAppUi::DeregisterView( aView ); + + const TInt count( iViews->Count() ); + for ( TInt i = 0; i < count; ++i ) + { + CAknView* view( iViews->At( i ) ); + if ( view == &aView && + view->Id() == aView.Id() ) + { + iViews->Delete( i ); + delete view; + view = NULL; + break; + } + } + + if ( activateDefaultView ) + { + // check which view is active now. + activeViewId = TVwsViewId(KNullUid,KNullUid); + GetActiveViewId( activeViewId ); + + TVwsViewId defaultViewId( KNullUid,KNullUid ); + // activate default if needed + if ( GetDefaultViewId( defaultViewId ) == KErrNone && + activeViewId != defaultViewId ) + { + ActivateViewL( defaultViewId ); + } + } + } + +// ----------------------------------------------------------------------------- +// CXnAppUiAdapter::PrepareToExit +// +// ----------------------------------------------------------------------------- +// +EXPORT_C void CXnAppUiAdapter::PrepareToExit() + { + iExitingApp = ETrue; + delete iUiEngineAppIf; + iUiEngineAppIf = NULL; + delete iImpl; + iImpl = NULL; + CAknViewAppUi::PrepareToExit(); + } + // ----------------------------------------------------------------------------- // CXnAppUiAdapter::ReloadUiL // @@ -335,7 +394,7 @@ // // ----------------------------------------------------------------------------- // -void CXnAppUiAdapter::ShowFocus() +void CXnAppUiAdapter::ShowFocus() { return iImpl->ViewAdapter().FocusControl().MakeVisible( ETrue ); } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnappuiadapterimpl.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnappuiadapterimpl.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnappuiadapterimpl.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -85,7 +85,7 @@ iResourceOffset = CCoeEnv::Static()->AddResourceFileL( resFile ); - iContentControlFactory = CHsContentControlFactory::NewL(); + iContentControlFactory = CHsContentControlFactory::NewL( iAdapter ); iUiStateListener = CXnUiStateListener::NewL( iAdapter ); @@ -139,13 +139,13 @@ // CXnAppUiAdapterImpl::~CXnAppUiAdapterImpl() { + delete iContentControlFactory; + if ( iViewAdapter ) { iViewAdapter->PrepareDestroy(); } - delete iContentControlFactory; - delete iUiEngine; delete iUiStateListener; diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnbackgroundmanager.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnbackgroundmanager.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnbackgroundmanager.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -26,26 +26,28 @@ #include "xnappuiadapter.h" #include "xnwallpaperview.h" #include "xnrootdata.h" +#include "xnuiengine.h" // SYSTEM INCLUDE FILES #include #include -#include +#include #include -#include +#include #include #include -#include -#include -#include -#include +#include +#include +#include +#include #include using namespace hspswrapper; _LIT8( KSingle, "single" ); const TUid KDummyUid = { 0x0000000 }; +const TInt KSkinGfxInnerRectShrink = 5; // ============================ MEMBER FUNCTIONS =============================== @@ -67,8 +69,9 @@ { CreateWindowL(); + iRect = TRect(); iBgContext = CAknsLayeredBackgroundControlContext::NewL( - KAknsIIDQsnBgScreenIdle, TRect(), ETrue, 1 ); + KAknsIIDQsnBgScreenIdle, iRect, ETrue, 1 ); TRect bgRect; AknLayoutUtils::LayoutMetricsRect( AknLayoutUtils::EScreen, bgRect ); @@ -134,18 +137,66 @@ CXnViewData& viewData( iViewManager.ActiveViewData() ); CFbsBitmap* wallpaper = viewData.WallpaperImage(); if( wallpaper ) - { - SystemGc().BitBlt( TPoint(0, 0), wallpaper ); + { + TSize bitmapSize = wallpaper->SizeInPixels(); + + if( iRect.Height() > bitmapSize.iHeight && iRect.Width() > bitmapSize.iWidth ) + { + TInt width = bitmapSize.iWidth / 2; + TInt height = bitmapSize.iHeight / 2; + + TPoint point = iRect.Center(); + point.SetXY( point.iX - width, point.iY - height ); + + SystemGc().SetBrushColor( KRgbBlack ); + SystemGc().Clear( aRect ); + SystemGc().BitBlt( point, wallpaper ); + } + else + { + SystemGc().BitBlt( TPoint( 0, 0 ), wallpaper ); + } + + if( iViewManager.UiEngine().IsEditMode() ) + { + DrawEditModeBackgroundSkin(); + } return; } } else if( iBgImage ) { - SystemGc().BitBlt( TPoint(0, 0), iBgImage ); + TSize bitmapSize = iBgImage->SizeInPixels(); + + if( iRect.Height() > bitmapSize.iHeight && iRect.Width() > bitmapSize.iWidth ) + { + TInt width = bitmapSize.iWidth / 2; + TInt height = bitmapSize.iHeight / 2; + + TPoint point = iRect.Center(); + point.SetXY( point.iX - width, point.iY - height ); + + SystemGc().SetBrushColor( KRgbBlack ); + SystemGc().Clear( aRect ); + SystemGc().BitBlt( point, iBgImage ); + } + else + { + SystemGc().BitBlt( TPoint( 0, 0 ), iBgImage ); + } + if( iViewManager.UiEngine().IsEditMode() ) + { + DrawEditModeBackgroundSkin(); + } return; } MAknsSkinInstance* skin( AknsUtils::SkinInstance() ); AknsDrawUtils::Background( skin, iBgContext, this, SystemGc(), aRect ); + + if( iViewManager.UiEngine().IsEditMode() ) + { + DrawEditModeBackgroundSkin(); + } } // ----------------------------------------------------------------------------- @@ -687,7 +738,8 @@ else { viewData.SetWallpaperImagePathL( KNullDesC ); - viewData.SetWallpaperImage( NULL ); + viewData.SetWallpaperImage( NULL ); + SaveWallpaperL(); // to HSPS } // Update screen @@ -836,4 +888,20 @@ } } +// ----------------------------------------------------------------------------- +// CXnBackgroundManager::DrawEditModeBackgroundSkin +// ----------------------------------------------------------------------------- +// +void CXnBackgroundManager::DrawEditModeBackgroundSkin() const + { + TRect shrunkRect = iRect; + + shrunkRect.Shrink( + KSkinGfxInnerRectShrink, + KSkinGfxInnerRectShrink ); + + AknsDrawUtils::DrawFrame( AknsUtils::SkinInstance(), SystemGc(), + iRect, shrunkRect, KAknsIIDQgnHomeEditBg, KAknsIIDDefault ); + } + // End of File diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xncomponent.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xncomponent.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xncomponent.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -150,3 +150,16 @@ { return NULL; } + +// ----------------------------------------------------------------------------- +// CXnComponent::SetDataL +// Set data stream +// ----------------------------------------------------------------------------- +// +EXPORT_C void CXnComponent::SetDataL( const TDesC8& aData, const TDesC& aType, TInt aIndex ) + { + if ( iAdapter ) + { + iAdapter->SetDataL( aData, aType, aIndex ); + } + } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xncomposer.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xncomposer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xncomposer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -38,7 +38,6 @@ #include "xnbackgroundmanager.h" // Constants -_LIT8( KStateWaitConfirmation, "WaitForConfirmation" ); _LIT8( KStateError, "Error" ); _LIT8( KXmluiml, "xmluiml" ); @@ -61,7 +60,8 @@ // Get property value from configuration. // -------------------------------------------------------------------------- // -static HBufC* ItemValueL( CHspsConfiguration& aConfiguration, const TDesC8& aItemId, const TDesC8& aName ) +static HBufC* ItemValueL( CHspsConfiguration& aConfiguration, + const TDesC8& aItemId, const TDesC8& aName ) { HBufC* ret = NULL; @@ -567,8 +567,7 @@ } aViewData.SetConfigurationIdL( configuration->ConfId() ); - aViewData.SetPluginStateL( KStateWaitConfirmation ); - + // Find a resource which can be internalized const CObjectMap* resourceObject = FindObject( configuration->Resources(), KTagXuikon ); @@ -713,8 +712,7 @@ } aPluginData.SetConfigurationIdL( configuration->ConfId() ); - aPluginData.SetPluginStateL( KStateWaitConfirmation ); - + // Find a resource which can be internalized const CObjectMap* resourceObject = FindObject( configuration->Resources(), KTagXuikon ); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xncontroladapter.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xncontroladapter.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xncontroladapter.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -127,6 +127,8 @@ iLongTapDetector->SetTimeDelayBeforeAnimation( KLongTapStartDelay ); iLongTapDetector->SetLongTapDelay( KLongTapTimeDelay ); + iCurrentLongTapStartDelay = KLongTapStartDelay; + iCurrentLongTapTimeDelay = KLongTapTimeDelay; } } @@ -582,3 +584,32 @@ { return iImpl->ChildAdapters(); } + +// ----------------------------------------------------------------------------- +// CXnControlAdapter::SetLongTapDelay +// ----------------------------------------------------------------------------- +// +void CXnControlAdapter::SetLongTapDelays( const TInt aStartDelay, + const TInt aLongTapDelay ) + { + if ( iCurrentLongTapTimeDelay != aLongTapDelay) + { + iLongTapDetector->SetLongTapDelay( aLongTapDelay ); + iCurrentLongTapTimeDelay = aLongTapDelay; + } + if ( iCurrentLongTapStartDelay != aStartDelay ) + { + iLongTapDetector->SetTimeDelayBeforeAnimation( aStartDelay ); + iCurrentLongTapStartDelay = aStartDelay; + } + } + +// ----------------------------------------------------------------------------- +// CXnControlAdapter::SetDataL +// Empty default implemenatation for setting the data stream. +// ----------------------------------------------------------------------------- +// +EXPORT_C void CXnControlAdapter::SetDataL( const TDesC8& /*aData*/, const TDesC& /*aType*/, TInt /*aIndex*/ ) + { + + } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xncontroladapterimpl.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xncontroladapterimpl.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xncontroladapterimpl.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -71,6 +71,11 @@ const TInt KSkinGfxInnerRectShrink = 5; const TInt KFocusGrowValue = 3; +const TInt KLongTapStartShortDelay( 150000 ); // 0.15s for Sk +const TInt KLongTapStartLongDelay( 500000 ); // 0.5s +const TInt KLongTapTimeShortDelay( 600000 ); // 0.6s for SK +const TInt KLongTapTimeLongDelay( 1500000 ); // 1.5s +_LIT( KWidgetBg, "SKIN(268458534 9916)" ); // LOCAL FUNCTION PROTOTYPES static TRgb ConvertHslToRgb( TInt aHue, TInt aSaturation, TInt aLightness ); @@ -358,7 +363,7 @@ CXnResource& aResource, CFbsBitmap*& aBitmap, CFbsBitmap*& aBitmapMask, - TRect /*aRect*/, + TRect aRect, RFs& aFsSession ) { RFile file; @@ -371,7 +376,9 @@ CFbsBitmap* frameBuffer = new ( ELeave ) CFbsBitmap; CleanupStack::PushL( frameBuffer ); - frameBuffer->Create( TSize( 0, 0 ), EColor16M ); + TSize contentSize( aRect.Size() ); + + frameBuffer->Create( contentSize, EColor16M ); TFontSpec fontSpec; CSvgEngineInterfaceImpl* svgEngine = @@ -381,14 +388,9 @@ svgEngine->Load( file ); - TSize contentSize = svgEngine->ContentDimensions(); - TInt domHandle; svgEngine->PrepareDom( file, domHandle ); - svgEngine->SetSvgDimensionToFrameBuffer( - contentSize.iWidth, contentSize.iHeight ); - CFbsBitmap* target = new ( ELeave ) CFbsBitmap; target->Create( contentSize, EColor16M ); svgEngine->RenderDom( domHandle, target ); @@ -3931,18 +3933,20 @@ CXnNode* node( &iNode.Node() ); CXnUiEngine* engine( node->UiEngine() ); + if(!engine->IsPartialInputActive()) + { + // Forward event to gesture helper + if( PassEventToGestureHelperL( aPointerEvent ) ) + { + CXnAppUiAdapter& appui( engine->AppUiAdapter() ); + CCoeControl& bg( appui.ViewAdapter().BgControl() ); + static_cast(&bg)->ResetGrabbingL(); + + // Swipe took place, consume this event + return ETrue; + } + } - // Forward event to gesture helper - if( PassEventToGestureHelperL( aPointerEvent ) ) - { - CXnAppUiAdapter& appui( engine->AppUiAdapter() ); - CCoeControl& bg( appui.ViewAdapter().BgControl() ); - static_cast(&bg)->ResetGrabbingL(); - - // Swipe took place, consume this event - return ETrue; - } - TBool menuBar( node == engine->MenuBarNode() ); if ( menuBar ) @@ -3959,7 +3963,7 @@ CAknLongTapDetector* detector( iAdapter->LongTapDetector() ); - if ( detector ) + if ( detector && !engine->IsPartialInputActive()) { if ( menuBar ) { @@ -3972,11 +3976,15 @@ if ( prop && prop->StringValue() == XnPropertyNames::KTrue ) { + iAdapter->SetLongTapDelays( KLongTapStartShortDelay, + KLongTapTimeShortDelay ); detector->PointerEventL( event ); } } else { + iAdapter->SetLongTapDelays( KLongTapStartLongDelay, + KLongTapTimeLongDelay ); detector->PointerEventL( event ); } } @@ -4111,9 +4119,7 @@ { // For widgets and plugins, drawing is handled differently in edit mode const TDesC8& widgetType = aNode.DomNode()->Name(); - if( ( widgetType == XnPropertyNames::KWidget || - widgetType == XnPropertyNames::KPlugin ) && - aNode.UiEngine()->EditMode()->EditState() ) + if( aNode.UiEngine()->EditMode()->EditState() ) { DrawEditModeBgData( aNode, aGc ); return; @@ -4288,6 +4294,14 @@ HBufC* skinID = colorProperty->StringValueL(); CleanupStack::PushL( skinID ); + // Widget background should not be drawn in edit mode + if( aNode.UiEngine()->EditMode()->EditState() && + skinID->Des() == KWidgetBg ) + { + CleanupStack::PopAndDestroy( skinID ); + return; + } + if ( skinID->Length() != 0 ) { TAknsItemID itemID; diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xneditmode.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xneditmode.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xneditmode.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -799,7 +799,7 @@ iState = aState; iUiEngine.AppUiAdapter().HandleEnterEditModeL( ETrue ); - SetStatusPaneTitleL(); + SetStatusPaneTitleL( ETrue ); MakeVisible( ETrue ); } @@ -811,7 +811,9 @@ iTargetNode = NULL; iState = aState; - + + SetStatusPaneTitleL( EFalse ); + iUiEngine.AppUiAdapter().HandleEnterEditModeL( EFalse ); MakeVisible( EFalse ); @@ -829,10 +831,10 @@ } // ----------------------------------------------------------------------------- -// CXnEditMode::SetStatusPaneTitleL() +// CXnEditMode::SetStatusPaneTitleL( TBool aEdit ) // ----------------------------------------------------------------------------- // -void CXnEditMode::SetStatusPaneTitleL() +void CXnEditMode::SetStatusPaneTitleL( TBool aEdit ) { TUid titlePaneUid = TUid::Uid( EEikStatusPaneUidTitle ); CEikStatusPaneBase::TPaneCapabilities subPaneTitle = @@ -841,11 +843,19 @@ { CAknTitlePane* title = static_cast< CAknTitlePane* >( iUiEngine.AppUiAdapter().StatusPane()->ControlL( titlePaneUid ) ); - TResourceReader reader; - CEikonEnv::Static()->CreateResourceReaderLC( + if( aEdit ) + { + TResourceReader reader; + CEikonEnv::Static()->CreateResourceReaderLC( reader, R_QTN_HS_TITLE_EDITMODE ); - title->SetFromResourceL( reader ); - CleanupStack::PopAndDestroy(); // reader internal state + title->SetFromResourceL( reader ); + CleanupStack::PopAndDestroy(); // reader internal state + } + else + { + title->SetTextL( KNullDesC ); + } + } } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnextrenderingpluginwrapper.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnextrenderingpluginwrapper.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnextrenderingpluginwrapper.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -18,6 +18,10 @@ // System include files // User include files +#include "xnnode.h" +#include "xnuiengine.h" +#include "xnappuiadapter.h" + #include "xnextrenderingpluginwrapper.h" // ======== MEMBER FUNCTIONS ======== @@ -49,6 +53,7 @@ iNode = &aNode; CXnControlAdapter::ConstructL( aNode ); + iAdapter->SetEventHandler( this ); } // ---------------------------------------------------------------------------- @@ -210,5 +215,28 @@ { iAdapter->ExitPowerSaveModeL(); } - + +// ---------------------------------------------------------------------------- +// CXnExtRenderingPluginWrapper::HandleEventL() +// +// ---------------------------------------------------------------------------- +// +void CXnExtRenderingPluginWrapper::HandleEventL( const TDesC& aEvent, const TDesC8& aDestination ) + { + + CXnNode* node = iNode->Node().UiEngine()->FindNodeByIdL( aDestination ); + CXnAppUiAdapter* appui = static_cast(iAvkonAppUi); + appui->HandleEventL( aEvent, node->AppIfL() ); + } + +// ---------------------------------------------------------------------------- +// CXnExtRenderingPluginWrapper::SetDataL() +// +// ---------------------------------------------------------------------------- +// +void CXnExtRenderingPluginWrapper::SetDataL( const TDesC8& aData, const TDesC& aType, TInt aIndex ) + { + iAdapter->SetDataL( aData, aType, aIndex ); + } + // End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnnodeappif.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnnodeappif.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnnodeappif.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -21,6 +21,8 @@ #include "xntype.h" #include "xnuiengine.h" #include "xndomnode.h" +#include "xncomponent.h" +#include "xncomponentnodeimpl.h" // ============================ MEMBER FUNCTIONS =============================== @@ -279,3 +281,12 @@ } return KNullDesC8; } + +// ----------------------------------------------------------------------------- +// CXnNodeAppIf::Component +// ----------------------------------------------------------------------------- +// +EXPORT_C CXnComponent& CXnNodeAppIf::Component() + { + return *iNode->ComponentNodeImpl()->Component(); + } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnnodeimpl.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnnodeimpl.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnnodeimpl.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -51,6 +51,7 @@ #include "xneffectmanager.h" #include "xnviewadapter.h" #include "xnbackgroundmanager.h" +#include "xntexteditor.h" // Local constants _LIT8( KRef, "ref" ); @@ -58,6 +59,7 @@ _LIT8( KName, "name" ); _LIT8( KToolTip, "tooltip" ); _LIT8( KMenuBar, "menubar" ); +_LIT8( KTextEditor, "texteditor" ); _LIT8( KActionsHandler, "actionshandler" ); @@ -297,12 +299,14 @@ CXnUiEngine& aEngine, CXnDomNode& aEventNode ); static void RunActivateViewL( CXnNodeImpl* aThis, CXnUiEngine& aEngine, CXnDomNode& aEventNode ); -static void RunActivateNextViewL( CXnUiEngine& aEngine ); -static void RunActivatePreviousViewL( CXnUiEngine& aEngine ); -static void RunAddViewL( CXnUiEngine& aEngine ); -static void RunRemoveViewL( CXnUiEngine& aEngine ); +static void RunActivateNextViewL( CXnUiEngine& aEngine, CXnDomNode& aEventNode ); +static void RunActivatePreviousViewL( CXnUiEngine& aEngine, CXnDomNode& aEventNode ); +static void RunAddViewL( CXnUiEngine& aEngine, CXnDomNode& aEventNode ); +static void RunRemoveViewL( CXnUiEngine& aEngine, CXnDomNode& aEventNode ); static void RunActivateL( CXnNodeImpl* aThis, CXnUiEngine& aEngine, CXnDomNode& aEventNode ); +static void RunActivateEditorL( CXnNodeImpl* aThis, CXnNode& aLayoutNode, + CXnUiEngine& aEngine, CXnDomNode& aEventNode, TBool aActivate ); static void RunDeactivateL( CXnNodeImpl* aThis, CXnUiEngine& aEngine, CXnDomNode& aEventNode ); static void RunSystemSetPCDataL( @@ -461,6 +465,23 @@ // ============================= LOCAL FUNCTIONS =============================== // ----------------------------------------------------------------------------- +// ResolveEffectId +// ----------------------------------------------------------------------------- +// +static TInt ResolveEffectId( CXnDomNode& aEventNode ) + { + TInt effect( 0 ); + const TDesC8& value( aEventNode.AttributeValue( + XnPropertyNames::common::KEffectId ) ); + if( value != KNullDesC8 ) + { + TLex8 lex( value ); + lex.Val( effect ); + } + return effect; + } + +// ----------------------------------------------------------------------------- // Checks whether trigger is runnable // ----------------------------------------------------------------------------- // @@ -3104,7 +3125,7 @@ else if ( aString == XnPropertyNames::action::event::KSetActiveFocus ) { CXnNode* previousNode = aEngine.FocusedNode(); - if ( previousNode != node ) + if ( previousNode && previousNode != node ) { if ( IsNodeNavigableL( *node ) ) { @@ -3154,22 +3175,11 @@ // static void RunFullScreenEffectL( CXnUiEngine& aEngine, CXnDomNode& aEventNode ) { - CXnDomList& list( aEventNode.AttributeList() ); - const TDesC8& effectid( XnPropertyNames::common::KEffectId ); - CXnDomAttribute* attribute( static_cast< CXnDomAttribute* > - ( list.FindByName( effectid ) ) ); - - if ( attribute ) - { - - const TDesC8& value( attribute->Value() ); - TLex8 lex( value ); - TInt effect; - lex.Val( effect ); - + TInt effectId = ResolveEffectId( aEventNode ); + if( effectId ) + { aEngine.AppUiAdapter().EffectManager()->BeginFullscreenEffectL( - effect, aEngine.ViewManager()->ActiveViewData() ); - + effectId, aEngine.ViewManager()->ActiveViewData() ); } } @@ -3210,36 +3220,40 @@ // RunActivateNextViewL // ----------------------------------------------------------------------------- // -static void RunActivateNextViewL( CXnUiEngine& aEngine ) - { - aEngine.ViewManager()->ActivateNextViewL(); +static void RunActivateNextViewL( CXnUiEngine& aEngine, CXnDomNode& aEventNode ) + { + TInt effectid = ResolveEffectId( aEventNode ); + aEngine.ViewManager()->ActivateNextViewL( effectid ); } // ----------------------------------------------------------------------------- // RunActivatePreviousViewL // ----------------------------------------------------------------------------- // -static void RunActivatePreviousViewL( CXnUiEngine& aEngine ) - { - aEngine.ViewManager()->ActivatePreviousViewL(); +static void RunActivatePreviousViewL( CXnUiEngine& aEngine, CXnDomNode& aEventNode ) + { + TInt effectid = ResolveEffectId( aEventNode ); + aEngine.ViewManager()->ActivatePreviousViewL( effectid ); } // ----------------------------------------------------------------------------- // RunAddViewL // ----------------------------------------------------------------------------- // -static void RunAddViewL( CXnUiEngine& aEngine ) - { - aEngine.ViewManager()->AddViewL(); +static void RunAddViewL( CXnUiEngine& aEngine, CXnDomNode& aEventNode ) + { + TInt effectid = ResolveEffectId( aEventNode ); + aEngine.ViewManager()->AddViewL( effectid ); } // ----------------------------------------------------------------------------- // RunRemoveViewL // ----------------------------------------------------------------------------- // -static void RunRemoveViewL( CXnUiEngine& aEngine ) - { - aEngine.ViewManager()->RemoveViewL(); +static void RunRemoveViewL( CXnUiEngine& aEngine, CXnDomNode& aEventNode ) + { + TInt effectid = ResolveEffectId( aEventNode ); + aEngine.ViewManager()->RemoveViewL( effectid ); } // ----------------------------------------------------------------------------- @@ -3278,6 +3292,60 @@ } // ----------------------------------------------------------------------------- +// RunActivateEditorL +// ----------------------------------------------------------------------------- +// +static void RunActivateEditorL( + CXnNodeImpl* aThis, + CXnNode& aLayoutNode, + CXnUiEngine& aEngine, + CXnDomNode& aEventNode, + TBool aActivate ) + { + CXnNode* editorNode( NULL ); + CXnDomList& children = aEventNode.ChildNodes(); + TInt count = children.Length(); + for ( TInt i = 0; i < count; ++i ) + { + CXnDomNode* dnode = static_cast< CXnDomNode* >( children.Item( i ) ); + const TDesC8& type = dnode->Name(); + if ( type == XnPropertyNames::action::KProperty ) + { + const TDesC8& id = dnode->AttributeValue( KId ); + CXnNode* node = aEngine.FindNodeByIdL( id, aThis->Namespace() ); + if( node && node->Type()->Type() == KTextEditor ) + { + editorNode = node; + break; + } + } + } + + if( !editorNode && aLayoutNode.Type()->Type() == KTextEditor ) + { + editorNode = &aLayoutNode; + } + + if( editorNode ) + { + XnTextEditorInterface::MXnTextEditorInterface* editorControl = NULL; + + XnComponentInterface::MakeInterfaceL( editorControl, editorNode->AppIfL() ); + if( editorControl ) + { + if( aActivate ) + { + editorControl->HandleEditorEvent(CXnTextEditor::KActivateTextEditor); + } + else + { + editorControl->HandleEditorEvent(CXnTextEditor::KDeactivateTextEditor); + } + } + } + } + +// ----------------------------------------------------------------------------- // RunEditL // ----------------------------------------------------------------------------- // @@ -3412,6 +3480,7 @@ } aEngine.EditMode()->SetEditModeL( CXnEditMode::EDragAndDrop ); + aEngine.AppUiAdapter().ViewAdapter().BgManager().DrawNow(); } CleanupStack::PopAndDestroy(); @@ -3521,7 +3590,8 @@ } } - aEngine.EditMode()->SetEditModeL( CXnEditMode::ENone ); + aEngine.EditMode()->SetEditModeL( CXnEditMode::ENone ); + aEngine.AppUiAdapter().ViewAdapter().BgManager().DrawNow(); aEngine.AppUiAdapter().ViewAdapter().UpdateRskByModeL(); } @@ -3871,6 +3941,37 @@ { *aClassId = &value; } + else + { + // Everyting is within the same property tag + // e.g. + + // Save name... + *aName = &name; + + // ...and value + if ( aValues ) + { + HBufC8* valueH = HBufC8::NewLC( value.Length() + KUnitMaxLen ); + TPtr8 ptr( valueH->Des() ); + ptr.Append( value ); + aValues->AppendL( valueH ); //take ownership + CleanupStack::Pop( valueH ); + } + + // ...and type + const TDesC8& type = node->AttributeValue( + XnPropertyNames::action::event::systemset::KType ); + *aType = &type; + + // ...and id + const TDesC8& id = node->AttributeValue( + XnPropertyNames::action::event::systemset::KId ); + HBufC8* utfName = HBufC8::NewL( id.Length() ); + TPtr8 ptr = utfName->Des(); + ptr = id; + aId = utfName; + } } } } @@ -4322,30 +4423,21 @@ { aEngine.Editor()->RemoveWidgetL( aEngine.FocusedNode() ); } - else if ( nameString == XnPropertyNames::action::event::KRunFullScreenEffect ) - { - TInt viewCount( aEngine.ViewManager()->ViewAmount() ); - - if ( viewCount > KOneView ) - { - RunFullScreenEffectL( aEngine, aEventNode ); - } - } else if ( nameString == XnPropertyNames::action::event::KActivateNextView ) { - RunActivateNextViewL( aEngine ); + RunActivateNextViewL( aEngine, aEventNode ); } else if ( nameString == XnPropertyNames::action::event::KActivatePreviousView ) { - RunActivatePreviousViewL( aEngine ); + RunActivatePreviousViewL( aEngine, aEventNode ); } else if ( nameString == XnPropertyNames::action::event::KAddView ) { - RunAddViewL( aEngine ); + RunAddViewL( aEngine, aEventNode ); } else if ( nameString == XnPropertyNames::action::event::KRemoveView ) { - RunRemoveViewL( aEngine ); + RunRemoveViewL( aEngine, aEventNode ); } else if ( nameString == XnPropertyNames::action::event::KActivateView ) { @@ -4408,6 +4500,8 @@ else if ( nameString == XnPropertyNames::action::event::KReportEnterEditMode ) { + RunFullScreenEffectL( aEngine, aEventNode ); + CXnNode* trigger( BuildTriggerNodeL( aEngine, XnPropertyNames::action::trigger::name::KEditMode ) ); CleanupStack::PushL( trigger ); @@ -4431,6 +4525,8 @@ } else if( nameString == XnPropertyNames::action::event::KReportExitEditMode ) { + RunFullScreenEffectL( aEngine, aEventNode ); + CXnNode* trigger( BuildTriggerNodeL( aEngine, XnPropertyNames::action::trigger::name::KEditMode ) ); CleanupStack::PushL( trigger ); @@ -4480,7 +4576,16 @@ aEngine.AppUiAdapter().ViewAdapter().BgManager().SetWallpaperL(); return ETrue; } - + else if ( nameString == XnPropertyNames::action::event::KActivateTextEditor) + { + RunActivateEditorL( aThis, aNode, aEngine, aEventNode, ETrue ); + return ETrue; + } + else if ( nameString == XnPropertyNames::action::event::KDeactivateTextEditor) + { + RunActivateEditorL( aThis, aNode, aEngine, aEventNode, EFalse ); + return ETrue; + } return EFalse; } diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnodtparser.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnodtparser.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnodtparser.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -51,7 +51,7 @@ #include "xnodtparser.h" -_LIT8( KWidgetBgSkinId, "SKIN(268458534 9886)" ); +_LIT8( KWidgetBgSkinId, "SKIN(268458534 9916)" ); // CONSTANTS _LIT8( KXMLUIMLNodeName, "xmluiml" ); @@ -770,6 +770,15 @@ CXnNode* owner( widgetNode->Parent() ); + CXnControlAdapter* widgetControl( widgetNode->Control() ); + + RPointerArray< CXnControlAdapter >& + childAdapters( owner->Control()->ChildAdapters() ); + + childAdapters.Remove( childAdapters.Find( widgetControl ) ); + + childAdapters.Compress(); + RPointerArray< CXnNode >& children( owner->Children() ); TInt index( children.Find( widgetNode ) ); @@ -784,9 +793,7 @@ CXnDomNode* owner( aPluginData.Owner() ); owner->DeleteChild( aPluginData.Node() ); - } - - owner->Control()->RemoveChildAdapters(); + } } // ----------------------------------------------------------------------------- diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnplugindata.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnplugindata.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnplugindata.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -17,8 +17,12 @@ // System includes #include +#include +#include +#include // User includes +#include #include "xnappuiadapter.h" #include "xncomposer.h" #include "xnodtparser.h" @@ -29,11 +33,9 @@ #include "xnviewdata.h" #include "xnviewmanager.h" #include "xnoomsyshandler.h" +#include "xnpanic.h" // Constants -_LIT8( KStateWaitConfirmation, "WaitForConfirmation" ); -_LIT8( KStateConfirmed, "Confirmed" ); -_LIT8( KStateError, "Error" ); // ============================ LOCAL FUNCTIONS ================================ @@ -73,8 +75,6 @@ { // Plugin data is removable by default iFlags.Set( EIsRemovable ); - // Assume plugins ready - iFlags.Set( EIsDataPluginsReady ); } // ----------------------------------------------------------------------------- @@ -86,8 +86,6 @@ : iParent( NULL ), iManager( aManager ) { // This constructor overload is used by CXnRootData - // Assume plugins are ready - iFlags.Set( EIsDataPluginsReady ); } // ----------------------------------------------------------------------------- @@ -97,8 +95,6 @@ // CXnPluginData::~CXnPluginData() { - RevertPluginState(); - if ( iLoader ) { iLoader->Cancel(); @@ -120,62 +116,48 @@ } // ----------------------------------------------------------------------------- -// CXnPluginData::LoadL() +// CXnPluginData::Load() // ----------------------------------------------------------------------------- // -void CXnPluginData::LoadL() +TInt CXnPluginData::Load() { - if ( Occupied() || PluginState().CompareF( KStateError ) == 0 ) + if ( Occupied() ) { - return; + return KErrInUse; } if ( !CXnOomSysHandler::HeapAvailable( WIDGET_MIN_MEM ) ) - { - ViewManager().OomSysHandler().HandlePotentialOomL(); - return; + { + return KErrNoMemory; } iFlags.Clear( EIsEmpty ); iFlags.Set( EIsRemovable ); + + TInt err( KErrNone ); - TRAPD( error, - - if ( iManager.Composer().ComposeWidgetL( *this ) == KErrNone ) - { - iManager.Parser().LoadWidgetL( *this ); - } - ); - - if ( Empty() ) + TRAP( err, err = iManager.Composer().ComposeWidgetL( *this ) ); + + if ( err == KErrNone ) { - // All done - return; + TRAP( err, iManager.Parser().LoadWidgetL( *this ) ); } - if ( error || !Occupied() ) + if ( err == KErrNone ) { - if( error == KErrNoMemory ) - { - ViewManager().OomSysHandler().HandlePotentialOomL(); - } + // Mark publishers as virgin + iVirginPublishers = ETrue; - // Mark this plugin ready, View Manager will remove it - DataPluginsLoadCompletedL( KErrGeneral ); + // Succesfully composed, try schedule publishers' loading + LoadPublishers(); } - else - { - if ( Active() ) - { - // Load data plugins will set confirmation state to "wait" - LoadDataPluginsL(); - } - else - { - // Composed succesfully to inactive page. Set confirmed - SetPluginStateL( KStateConfirmed ); - } - } + else if ( err == KXnErrPluginFailure ) + { + // Widget's configuration is broken, remove it + TRAP_IGNORE( iManager.UnloadWidgetFromPluginL( *this, ETrue ) ); + } + + return err; } // ----------------------------------------------------------------------------- @@ -186,112 +168,137 @@ { if ( Occupied() ) { - TRAP_IGNORE( - DestroyDataPluginsL(); - iManager.Parser().DestroyWidgetL( *this ); - ); + DestroyPublishers(); + + TRAP_IGNORE( iManager.Parser().DestroyWidgetL( *this ) ); } Flush(); } // ----------------------------------------------------------------------------- -// CXnPluginData::LoadDataPluginsL +// CXnPluginData::LoadPublishers // Loads data plugins associated to the plugin // ----------------------------------------------------------------------------- // -void CXnPluginData::LoadDataPluginsL() +void CXnPluginData::LoadPublishers() { - if ( !Active() || !Occupied() ) - { - iFlags.Set( EIsDataPluginsReady ); - + if ( !Active() || !Occupied() || iContentSourceNodes.Count() == 0 ) + { return; } - if ( iContentSourceNodes.Count() == 0 ) - { - DataPluginsLoadCompletedL( KErrNone ); - } - else + iLoader->Cancel(); + + iLoader->Start( TTimeIntervalMicroSeconds32( 50 ), + TTimeIntervalMicroSeconds32( 50 ), + TCallBack( PeriodicEventL, this ) ); + } + +// ----------------------------------------------------------------------------- +// CXnPluginData::PeriodicEventL() +// +// ----------------------------------------------------------------------------- +// +/* static */ TInt CXnPluginData::PeriodicEventL( TAny* aAny ) + { + CXnPluginData* self = static_cast< CXnPluginData* >( aAny ); + + self->iLoader->Cancel(); + + TInt reason( EAiFwPluginStartup ); + + if ( self->LoadPublishers( reason ) != KErrNone ) { - iLoader->Cancel(); + self->iManager.UnloadWidgetFromPluginL( *self, ETrue ); - iFlags.Clear( EIsDataPluginsReady ); - - iLoadIndex = 0; - - iLoader->Start( TTimeIntervalMicroSeconds32( 0 ), - TTimeIntervalMicroSeconds32( 0 ), - TCallBack( RunL, this ) ); - } + self->ShowContentRemovedError(); + } + + return KErrNone; } // ----------------------------------------------------------------------------- -// CXnPluginData::DataPluginsLoadCompletedL -// Indicates that all data plugins are loaded +// CXnPluginData::LoadPublishers() +// // ----------------------------------------------------------------------------- // -void CXnPluginData::DataPluginsLoadCompletedL( TInt aStatus ) - { - iFlags.Set( EIsDataPluginsReady ); +TInt CXnPluginData::LoadPublishers( TInt aReason ) + { + TInt err( KErrNone ); - const TDesC8& state( aStatus == KErrNone - ? KStateConfirmed() : KStateError() ); + TRAP( err, + for ( TInt i = 0; i < iContentSourceNodes.Count(); i++ ) + { + CXnNodeAppIf& plugin( iContentSourceNodes[i]->AppIfL() ); + + TInt retval( + iManager.AppUiAdapter().LoadPublisher( plugin, aReason ) ); + + if ( !err ) + { + err = retval; + } + } + ); + + iVirginPublishers = EFalse; - SetPluginStateL( state ); - - iManager.SetDataPluginLoadCompleteL( *this ); + if ( !Removable() ) + { + // Not allowed to remove even it fails + return KErrNone; + } + + return err; } // ----------------------------------------------------------------------------- -// CXnPluginData::DataPluginsLoaded -// Queries whether all data plugins are loaded -// ----------------------------------------------------------------------------- -// -TBool CXnPluginData::DataPluginsLoaded() const - { - return ( iFlags.IsSet( EIsDataPluginsReady ) ? ETrue : EFalse ); - } - -// ----------------------------------------------------------------------------- -// CXnPluginData::DestroyDataPluginsL +// CXnPluginData::DestroyPublishers // Remove data plugins associated to the plugin // ----------------------------------------------------------------------------- // -void CXnPluginData::DestroyDataPluginsL() +void CXnPluginData::DestroyPublishers() { if ( Occupied() ) { - iFlags.Set( EIsDataPluginsReady ); - - if ( iLoader->IsActive() ) - { - // Not all plugins loaded yet - iLoader->Cancel(); - - RevertPluginState(); - } + // If not all plugins loaded yet + iLoader->Cancel(); - // Create list of data plugins to be removed - RPointerArray< CXnNodeAppIf > list; - CleanupClosePushL( list ); - - for ( TInt i = 0; i < iContentSourceNodes.Count(); i++ ) - { - list.AppendL( &iContentSourceNodes[i]->AppIfL() ); - } - - // Destruction is synchronous - iManager.AppUiAdapter().DestroyDataPluginsL( list ); - - CleanupStack::PopAndDestroy( &list ); + TRAP_IGNORE( DoDestroyPublishersL() ); User::Heap().Compress(); } } // ----------------------------------------------------------------------------- +// CXnPluginData::VirginPublishers +// +// ----------------------------------------------------------------------------- +// +TBool CXnPluginData::VirginPublishers() const + { + return iVirginPublishers; + } + +// ----------------------------------------------------------------------------- +// CXnPluginData::DoDestroyPublishersL +// Remove data plugins associated to the plugin +// ----------------------------------------------------------------------------- +// +void CXnPluginData::DoDestroyPublishersL() + { + for ( TInt i = 0; i < iContentSourceNodes.Count(); i++ ) + { + CXnNodeAppIf& plugin( iContentSourceNodes[i]->AppIfL() ); + + // Destruction is synchronous + iManager.AppUiAdapter().DestroyPublisher( + plugin, EAiFwPluginShutdown ); + } + } + +// ----------------------------------------------------------------------------- // CXnPluginData::SetConfigurationIdL() // ----------------------------------------------------------------------------- // @@ -379,38 +386,6 @@ } // ----------------------------------------------------------------------------- -// CXnPluginData::SetPluginStateL() -// ----------------------------------------------------------------------------- -// -void CXnPluginData::SetPluginStateL( const TDesC8& aPluginState ) - { - if ( PluginState().CompareF( aPluginState ) != 0 ) - { - delete iPluginState; - iPluginState = NULL; - - iPluginState = aPluginState.AllocL(); - - // Tell new state to HSPS as well - iManager.UpdatePluginStateL( *this ); - } - } - -// ----------------------------------------------------------------------------- -// CXnPluginData::RevertPluginState() -// ----------------------------------------------------------------------------- -// -void CXnPluginData::RevertPluginState() - { - // Need to change state if it is not error - if ( Occupied() && PluginState().CompareF( KStateError ) != 0 ) - { - // For now on it is confirmed - TRAP_IGNORE( SetPluginStateL( KStateConfirmed ) ); - } - } - -// ----------------------------------------------------------------------------- // CXnPluginData::SetResources() // ----------------------------------------------------------------------------- // @@ -540,12 +515,9 @@ iFlags.ClearAll(); // This is default - iFlags.Set( EIsRemovable ); - iFlags.Set( EIsDataPluginsReady ); + iFlags.Set( EIsRemovable ); iNode = NULL; - - iLoadIndex = 0; delete iConfigurationId; iConfigurationId = NULL; @@ -562,9 +534,6 @@ delete iPluginType; iPluginType = NULL; - delete iPluginState; - iPluginState = NULL; - delete iPublisherName; iPublisherName = NULL; @@ -624,8 +593,7 @@ // ----------------------------------------------------------------------------- // void CXnPluginData::SetIsDisplayingPopup ( TBool aVisible, CXnNode* aNode ) - { - + { if ( aVisible ) { iPopupNodes.InsertInAddressOrder( aNode ); @@ -633,6 +601,7 @@ else { TInt index( iPopupNodes.Find( aNode ) ); + if ( index != KErrNotFound ) { iPopupNodes.Remove( index ); @@ -640,7 +609,6 @@ } } - //------------------------------------------------------------------------------ // CXnPluginData::IsDisplayingPopup() // @@ -651,42 +619,42 @@ return ( iPopupNodes.Count() > 0 ); } -// ----------------------------------------------------------------------------- -// CXnPluginData::RunL() -// -// ----------------------------------------------------------------------------- +//------------------------------------------------------------------------------ +// CXnPluginData::ShowContentRemovedError() // -/* static */ TInt CXnPluginData::RunL( TAny* aAny ) +//------------------------------------------------------------------------------ +// +void CXnPluginData::ShowContentRemovedError() { - CXnPluginData* self = static_cast< CXnPluginData* >( aAny ); - - self->iLoader->Cancel(); - - RPointerArray< CXnNodeAppIf >list; - CleanupClosePushL( list ); + TRAP_IGNORE( DoShowContentRemovedErrorL() ); + } - for ( TInt i = 0; i < self->iContentSourceNodes.Count(); i++ ) - { - list.AppendL( &self->iContentSourceNodes[i]->AppIfL() ); - } +//------------------------------------------------------------------------------ +// CXnPluginData::DoShowContentRemovedErrorL() +// +//------------------------------------------------------------------------------ +// +void CXnPluginData::DoShowContentRemovedErrorL() + { + HBufC* msg( StringLoader::LoadLC( R_QTN_HS_ERROR_WIDGETS_REMOVED ) ); - // State is "wait" until data plugins are loaded - self->SetPluginStateL( KStateWaitConfirmation ); - - TRAPD( err, self->iManager.AppUiAdapter().LoadDataPluginsL( list ) ); + CAknErrorNote* note = new ( ELeave ) CAknErrorNote; + CleanupStack::PushL( note ); + + note->ExecuteLD( *msg ); + + CleanupStack::Pop( note ); + CleanupStack::PopAndDestroy( msg ); + } - if ( err && self->Removable() ) - { - self->DataPluginsLoadCompletedL( err ); - } - else - { - self->DataPluginsLoadCompletedL( KErrNone ); - } - - CleanupStack::PopAndDestroy( &list ); - - return KErrNone; +//------------------------------------------------------------------------------ +// CXnPluginData::ShowOutOfMemErrorL() +// +//------------------------------------------------------------------------------ +// +void CXnPluginData::ShowOutOfMemError() + { + TRAP_IGNORE( ViewManager().OomSysHandler().HandlePotentialOomL() ); } // End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnpopupcontroladapter.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnpopupcontroladapter.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnpopupcontroladapter.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -24,8 +24,12 @@ // User includes #include "xnappuiadapter.h" +#include "xnviewmanager.h" +#include "xnviewdata.h" +#include "xnplugindata.h" #include "xnproperty.h" #include "xncontroladapter.h" +#include "xndomnode.h" #include "xnnodepluginif.h" #include "xnnode.h" #include "xntype.h" @@ -49,18 +53,20 @@ // ----------------------------------------------------------------------------- // FindWidgetMenuItemL +// // ----------------------------------------------------------------------------- // -CXnNode* FindWidgetMenuItemL( const TDesC8& aSource, - CXnNode& aPlugin ) - { - if( aPlugin.Children().Count() == 0 ) +static CXnNode* FindWidgetMenuItemL( CXnPluginData& aPlugin, + const TDesC8& aSource ) + { + if ( !aPlugin.Occupied() ) { return NULL; } - - // Get element from the element - RPointerArray< CXnNode >& children( aPlugin.Children()[0]->Children() ); + + CXnNode* widget( aPlugin.Node()->LayoutNode() ); + + RPointerArray< CXnNode >& children( widget->Children() ); for ( TInt i = children.Count() - 1; i >= 0; i-- ) { @@ -190,6 +196,10 @@ // void CXnPopupControlAdapter::TryDisplayingStylusPopupL( CXnNode& aPlugin ) { + CXnViewManager* manager( iUiEngine->ViewManager() ); + + CXnPluginData& plugin( manager->ActiveViewData().Plugin( &aPlugin ) ); + HideMenuL(); TPointerEvent event( iUiEngine->HitTest().PointerEvent() ); @@ -204,10 +214,10 @@ for ( TInt i = 0; i < children.Count(); i++ ) { - PopulateMenuL( children[i], aPlugin ); + PopulateMenuL( plugin, children[i] ); } - ShowMenuL( aPlugin, event.iParentPosition ); + ShowMenuL( plugin, event.iParentPosition ); } // ----------------------------------------------------------------------------- @@ -223,7 +233,8 @@ // CXnPopupControlAdapter::PopulateMenuL // ----------------------------------------------------------------------------- // -void CXnPopupControlAdapter::PopulateMenuL( CXnNode* aItem, CXnNode& aPlugin ) +void CXnPopupControlAdapter::PopulateMenuL( CXnPluginData& aPlugin, + CXnNode* aItem ) { CXnNode* menuitem( NULL ); CXnProperty* prop( NULL ); @@ -240,7 +251,7 @@ if ( source ) { CXnNode* widgetItem( - FindWidgetMenuItemL( source->StringValue(), aPlugin ) ); + FindWidgetMenuItemL( aPlugin, source->StringValue() ) ); if ( widgetItem ) { @@ -248,11 +259,13 @@ // Get label from the view item prop = aItem->LabelL(); + if ( !prop ) { // no localization in view, check from widget prop = widgetItem->LabelL(); } + // Pretend the original item is this widget item aItem = widgetItem; } @@ -268,8 +281,10 @@ } else if ( type == KDynMenuItem && iObserver ) { + CXnNode* plugin( aPlugin.Owner()->LayoutNode() ); + // Let observer decide whether dynmenuitem is visible or not - if ( iObserver->DynInitMenuItemL( aItem->AppIfL(), &aPlugin.AppIfL() ) ) + if ( iObserver->DynInitMenuItemL( aItem->AppIfL(), &plugin->AppIfL() ) ) { menuitem = aItem; } @@ -277,8 +292,10 @@ if ( menuitem ) { - CXnProperty* display = menuitem->DisplayL(); - if ( display && display->StringValue() == XnPropertyNames::style::common::display::KNone ) + CXnProperty* display( menuitem->DisplayL() ); + + if ( display && display->StringValue() == + XnPropertyNames::style::common::display::KNone ) { return; } @@ -305,23 +322,26 @@ // CXnPopupControlAdapter::ShowMenuL // ----------------------------------------------------------------------------- // -void CXnPopupControlAdapter::ShowMenuL( CXnNode& aPlugin, TPoint aPosition ) +void CXnPopupControlAdapter::ShowMenuL( CXnPluginData& aPlugin, + TPoint aPosition ) { if ( iMenuItems.Count() > 0 && !iMenuShown ) { iUiEngine->AppUiAdapter().HideFocus(); - - iUiEngine->Editor()->SetTargetPlugin( &aPlugin ); + + CXnNode* plugin( aPlugin.Owner()->LayoutNode() ); + + iUiEngine->Editor()->SetTargetPlugin( plugin ); if ( AknLayoutUtils::LayoutMirrored() ) { iStylusPopupMenu->SetPosition( aPosition, - CAknStylusPopUpMenu::EPositionTypeRightBottom ); + CAknStylusPopUpMenu::EPositionTypeRightBottom ); } else { iStylusPopupMenu->SetPosition( aPosition, - CAknStylusPopUpMenu::EPositionTypeLeftBottom ); + CAknStylusPopUpMenu::EPositionTypeLeftBottom ); } iStylusPopupMenu->ShowMenu(); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnrootdata.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnrootdata.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnrootdata.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -39,7 +39,7 @@ #include "xnrootdata.h" // Constants -const TInt KScheduleInterval( 1000000 ); +const TInt KScheduleInterval( 2000000 ); // ============================ LOCAL FUNCTIONS ================================ @@ -130,109 +130,96 @@ iParser = CXnODTParser::NewL( iManager, *iEcomHandler ); - iLoadTimer = CPeriodic::NewL( CActive::EPriorityStandard ); - iDestroyTimer = CPeriodic::NewL( CActive::EPriorityStandard ); + iLoadTimer = CPeriodic::NewL( CActive::EPriorityLow ); + iDestroyTimer = CPeriodic::NewL( CActive::EPriorityLow ); } // ----------------------------------------------------------------------------- -// CXnRootData::LoadL() +// CXnRootData::Load() // // ----------------------------------------------------------------------------- // -void CXnRootData::LoadL() +TInt CXnRootData::Load() { if ( Occupied() ) { - return; - } - - // Load application root configuration - TRAPD( error, - - iODT = iManager.Composer().ComposeRootL( *this ); - - if ( iODT ) - { - iManager.Parser().LoadRootL( *this, iApplicationUid ); - } - ); - - if ( !iODT || error || !Occupied() ) - { - // Can't recover - Panic( EXnInvalidConfiguration ); + return KErrInUse; } - RPointerArray< CXnViewData > failedPlugins; - CleanupClosePushL( failedPlugins ); - - TBool succeed( EFalse ); - - for ( TInt i = 0; i < iPluginsData.Count(); i++ ) - { - CXnViewData* plugin( - static_cast< CXnViewData* >( iPluginsData[ i ] ) ); + TInt err( KErrNone ); - if ( plugin->Initial() ) - { - plugin->LoadL(); + // Load application root configuration + TRAP( err, iODT = iManager.Composer().ComposeRootL( *this ) ); - if ( plugin->Occupied() ) - { - succeed = ETrue; - } - else - { - // Failed to load - failedPlugins.AppendL( plugin ); - } - - break; - } - } - - for ( TInt i = 0; !succeed && i < iPluginsData.Count(); i++ ) - { - CXnViewData* plugin( - static_cast< CXnViewData* >( iPluginsData[ i ] ) ); - - if ( failedPlugins.Find( plugin ) == KErrNotFound ) - { - plugin->SetInitial(); - - plugin->LoadL(); - - if ( plugin->Occupied() ) - { - succeed = ETrue; - } - else - { - // Failed to load - failedPlugins.AppendL( plugin ); - } - } - } - - if ( !succeed ) + if ( !iODT ) { // Can't recover Panic( EXnInvalidConfiguration ); } - - for ( TInt i = failedPlugins.Count() - 1; i >= 0; i-- ) - { - CXnPluginData* toDestroy( failedPlugins[i] ); - - TInt index( iPluginsData.Find( toDestroy ) ); - - iPluginsData.Remove( index ); - - delete toDestroy; - toDestroy = NULL; + + if ( !err ) + { + TRAP( err, iManager.Parser().LoadRootL( *this, iApplicationUid ) ); } - CleanupStack::PopAndDestroy( &failedPlugins ); + if ( !err ) + { + for ( TInt i = 0; i < iPluginsData.Count(); i++ ) + { + CXnViewData* plugin( + static_cast< CXnViewData* >( iPluginsData[ i ] ) ); + + if ( plugin->Initial() ) + { + err = plugin->Load(); + + if ( plugin->Occupied() ) + { + // Initial view is succesfully composed. Some plugins + // may have failed but it doesn't matter as those are removed + return KErrNone; + } + + // Initial view failed, remove it + iPluginsData.Remove( i ); + + delete plugin; + plugin = NULL; + break; + } + } + + // Initial view loading failed, fallback to load any of the views + while( iPluginsData.Count() ) + { + CXnViewData* plugin( + static_cast< CXnViewData* >( iPluginsData[ 0 ] ) ); + + // Ignore error + plugin->Load(); + + if ( plugin->Occupied() ) + { + // Return error because of fallback condition + return KXnErrPluginFailure; + } + + // View failed, remove it + iPluginsData.Remove( 0 ); + + delete plugin; + plugin = NULL; + } + } + else if ( err == KErrNoMemory ) + { + ShowOutOfMemError(); + } + + // Configuration loading failed totally + Panic( EXnInvalidConfiguration ); + + return err; } // ----------------------------------------------------------------------------- @@ -542,7 +529,10 @@ if ( !self->AllViewsLoaded() && toLoad ) { - toLoad->LoadL(); + if ( toLoad->Load() == KErrNoMemory ) + { + self->ShowOutOfMemError(); + } } if ( self->AllViewsLoaded() ) diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnuiengine.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnuiengine.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnuiengine.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -496,16 +496,6 @@ } // ----------------------------------------------------------------------------- -// CXnUiEngine::PositionStylusPopupL -// ----------------------------------------------------------------------------- -// -void CXnUiEngine::PositionStylusPopupL( CXnNode& aNode, - CXnNode& aReference, const TPoint& aPosition ) - { - iUiEngineImpl->PositionStylusPopupL( aNode, aReference, aPosition ); - } - -// ----------------------------------------------------------------------------- // CXnUiEngine::GetThemeResource // ----------------------------------------------------------------------------- // @@ -539,6 +529,25 @@ iUiEngineImpl->SetEventDispatcher( aDispatcher ); } +// ----------------------------------------------------------------------------- +// CXnUiEngine::EnablePartialTouchInput( ) +// ----------------------------------------------------------------------------- +// +void CXnUiEngine::EnablePartialTouchInput( CXnNode& aNode, TBool aEnable ) + { + iUiEngineImpl->EnablePartialTouchInput(aNode, aEnable); + } + +// ----------------------------------------------------------------------------- +// CXnUiEngine::isPartialInputActive() +// ----------------------------------------------------------------------------- +// +TBool CXnUiEngine::IsPartialInputActive() + { + return iUiEngineImpl->IsPartialInputActive(); + } + + #ifndef EKA2 GLDEF_C TInt E32Dll( TDllReason ) { diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnuiengineimpl.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnuiengineimpl.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnuiengineimpl.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -21,6 +21,7 @@ #include #include #include +#include // User includes #include "xnuiengine.h" @@ -54,6 +55,7 @@ #include "xneffectmanager.h" #include "xneditor.h" #include "xnbackgroundmanager.h" +#include "xntexteditor.h" #ifdef _XN_PERFORMANCE_TEST_ #include "xntimemon.h" @@ -282,6 +284,24 @@ #endif // ============================= LOCAL FUNCTIONS =============================== + +// ----------------------------------------------------------------------------- +// ----------------------------------------------------------------------------- +// +CXnNode* FindPlugin( CXnNode& aNode ) + { + CXnNode* pluginNode( NULL ); + for( CXnNode* node = &aNode; node; node = node->Parent() ) + { + if( node->DomNode()->Name() == KPlugin ) + { + pluginNode = node; + break; + } + } + return pluginNode; + } + // ----------------------------------------------------------------------------- // GrowIfNeeded() // When a plugin is focused, the focus is a bit bigger than its control @@ -8128,6 +8148,7 @@ delete iEditMode; delete iHitTest; + delete iSplitScreenState.iPartialScreenBlock; iFocusCandidateList.Reset(); iRedrawRegions.ResetAndDestroy(); @@ -8395,12 +8416,6 @@ RefreshMenuL(); - if ( iLayoutControl & XnLayoutControl::EFirstPassDraw ) - { - iViewManager.SetFirstPassDrawCompleteL(); - iLayoutControl &= ~XnLayoutControl::EFirstPassDraw; - } - iLayoutControl &= ~XnLayoutControl::ERenderUI; iAppUiAdapter.EffectManager()->UiRendered(); @@ -8561,8 +8576,6 @@ iControlAdapterList = &iViewManager.Controls(); iCurrentViewControlAdapter = iCurrentView->Control(); - iLayoutControl |= XnLayoutControl::EFirstPassDraw; - iDirtyList.Reset(); iRedrawRegions.ResetAndDestroy(); @@ -8639,7 +8652,6 @@ void CXnUiEngineImpl::NotifyWidgetAdditionL( const CXnPluginData& /*aPluginData*/ ) { - iLayoutControl |= XnLayoutControl::EFirstPassDraw; } // ----------------------------------------------------------------------------- @@ -8916,7 +8928,30 @@ // ----------------------------------------------------------------------------- // void CXnUiEngineImpl::HandleResourceChangeL( TInt aType ) - { + { + + if ( aType == KAknSplitInputEnabled ) + { + if(!iSplitScreenState.isPartialScreenEnabled ) + { + DisableRenderUiLC(); + HandlePartialTouchInputL( aType ); + RootNode()->SetDirtyL(); + CleanupStack::PopAndDestroy(); + } + } + + if ( aType == KAknSplitInputDisabled ) + { + if( iSplitScreenState.isPartialScreenEnabled ) + { + DisableRenderUiLC(); + HandlePartialTouchInputL( aType ); + RootNode()->SetDirtyL(); + CleanupStack::PopAndDestroy(); + } + } + if ( iMenuNode ) { CXnControlAdapter* adapter( iMenuNode->Control() ); @@ -9514,239 +9549,6 @@ } // ----------------------------------------------------------------------------- -// CXnUiEngineImpl::PositionStylusPopupL -// ----------------------------------------------------------------------------- -// -void CXnUiEngineImpl::PositionStylusPopupL( CXnNode& aNode, - CXnNode& aReference, const TPoint& aPosition ) - { - CXnDomStringPool* sp( aNode.DomNode()->StringPool() ); - TXnDirtyRegion* dirtyRegion = FindDirtyRegionL( *iCurrentView ); - RRegion region; - region.Copy( dirtyRegion->iRegion ); - CleanupClosePushL( region ); - - // Set initial position to (0, 0) to calculate popup metrics - CXnProperty* top = CXnProperty::NewL( - XnPropertyNames::style::common::KTop, 0, - CXnDomPropertyValue::EPx, *sp ); - CleanupStack::PushL( top ); - aNode.SetPropertyL( top ); - CleanupStack::Pop( top ); - top = NULL; - CXnProperty* left = CXnProperty::NewL( - XnPropertyNames::style::common::KLeft, 0, - CXnDomPropertyValue::EPx, *sp ); - CleanupStack::PushL( left ); - aNode.SetPropertyL( left ); - CleanupStack::Pop( left ); - left = NULL; - - // Make it visible - CXnProperty* display = CXnProperty::NewL( - XnPropertyNames::style::common::KDisplay, - XnPropertyNames::style::common::display::KBlock, - CXnDomPropertyValue::EString, *sp ); - CleanupStack::PushL( display ); - aNode.SetPropertyL( display ); - CleanupStack::Pop( display ); - - if ( !aNode.IsLaidOut() || !aReference.IsLaidOut() ) - { - ForceRenderUIL( ETrue ); - } - - if ( !aNode.IsLaidOut() || !aReference.IsLaidOut() ) - { - // Something went wrong - CleanupStack::PopAndDestroy( ®ion ); - - return; - } - - TRect rectToFit( aReference.MarginRect() ); - TRect marginRect( aNode.MarginRect() ); - - if ( marginRect.Height() > rectToFit.Height() || - marginRect.Width() > rectToFit.Width() ) - { - // Won't fit even how much is moved - CleanupStack::PopAndDestroy( ®ion ); - - return; - } - - TPoint tl; - TPoint br; - - // Remove the initial 0,0 from redraw region and rects - dirtyRegion->iRegion.Clear(); - ClearRects( aNode, ETrue ); - CXnProperty* positionHint( aNode.GetPropertyL( - XnPropertyNames::styluspopup::KPositionHint ) ); - - // Default - const TDesC8* value( &XnPropertyNames::styluspopup::positionhint::KAbove ); - - if ( positionHint ) - { - value = &positionHint->StringValue(); - } - - if ( *value == XnPropertyNames::styluspopup::positionhint::KAbove ) - { - if ( AknLayoutUtils::LayoutMirrored() ) - { - tl = aPosition; - tl.iY -= marginRect.Height(); - tl.iX -= marginRect.Width(); - - // Will the popup float out? - if ( !rectToFit.Contains( tl ) ) - { - // top left floated out - TInt y( rectToFit.iTl.iY - tl.iY + 1 ); - - if ( y >= 0 ) - { - // y-coordinate floated out, move it position - // so that it will be inside reference rect - tl.iY = tl.iY + y; - } - - TInt x( rectToFit.iTl.iX - tl.iX + 1 ); - - if ( x >= 0 ) - { - // x-coordinate floated out, move it position - // so that it will be inside reference rect - tl.iX = tl.iX + x; - } - } - } - else - { - tl = aPosition; - tl.iY -= marginRect.Height(); - - // Will the popup float out? - if ( !rectToFit.Contains( tl ) ) - { - // top left floated out - TInt y( rectToFit.iTl.iY - tl.iY + 1 ); - - if ( y >= 0 ) - { - // y-coordinate floated out, move it position - // so that it will be inside reference rect - tl.iY = tl.iY + y; - } - } - - br = TPoint( tl.iX + marginRect.Width(), - tl.iY + marginRect.Height() ); - - if ( !rectToFit.Contains( br ) ) - { - // bottom right floated out - TInt x( br.iX - rectToFit.iBr.iX + 1 ); - - if ( x >= 0 ) - { - // x-coordinate floated out, move it position - // so that it will be inside reference rect - tl.iX = tl.iX - x; - } - } - } - } - else // value == XnPropertyNames::styluspopup::positionhint::KBelow - { - if ( AknLayoutUtils::LayoutMirrored() ) - { - tl = aPosition; - tl.iX = tl.iX - marginRect.Width(); - - if ( !rectToFit.Contains( tl ) ) - { - // Top left floated out - TInt x( rectToFit.iTl.iX - tl.iX + 1 ); - - if ( x >= 0 ) - { - // x-coordinate floated out, move it position - // so that it will be inside reference rect - tl.iX = tl.iX + x; - } - } - - br = TPoint( tl.iX + marginRect.Width(), - tl.iY + marginRect.Height() ); - - if ( !rectToFit.Contains( br ) ) - { - // bottom right floated out - TInt y( br.iY - rectToFit.iBr.iY + 1 ); - - if ( y >= 0 ) - { - // y-coordinate floated out, move it position - // so that it will be inside reference rect - tl.iY = tl.iY - y; - } - } - } - else - { - tl = aPosition; - br = TPoint( tl.iX + marginRect.Width(), - tl.iY + marginRect.Height() ); - - // Will the popup float out? - if ( !rectToFit.Contains( br ) ) - { - // Bottom right floated out - TInt x( br.iX - rectToFit.iBr.iX + 1 ); - - if ( x >= 0 ) - { - // x-coordinate floated out, move it position - // so that it will be inside reference rect - tl.iX = tl.iX - x; - } - - TInt y( br.iY - rectToFit.iBr.iY + 1 ); - - if ( y >= 0 ) - { - // y-coordinate floated out, move it position - // so that it will be inside reference rect - tl.iY = tl.iY - y; - } - } - } - } - - // Set positions - top = CXnProperty::NewL( - XnPropertyNames::style::common::KTop, tl.iY, - CXnDomPropertyValue::EPx, *sp ); - CleanupStack::PushL( top ); - aNode.SetPropertyL( top ); - CleanupStack::Pop( top ); - left = CXnProperty::NewL( - XnPropertyNames::style::common::KLeft, tl.iX, - CXnDomPropertyValue::EPx, *sp ); - CleanupStack::PushL( left ); - aNode.SetPropertyL( left ); - CleanupStack::Pop( left ); - - // Copy stored region back - dirtyRegion->iRegion.Copy( region ); - CleanupStack::PopAndDestroy( ®ion ); - } - -// ----------------------------------------------------------------------------- // CXnUiEngineImpl::GetThemeResource // ----------------------------------------------------------------------------- // @@ -9947,6 +9749,89 @@ } // ----------------------------------------------------------------------------- +// CXnUiEngineImpl::HandlePartialTouchInputL() +// ----------------------------------------------------------------------------- +void CXnUiEngineImpl::HandlePartialTouchInputL( TInt aType ) + { + if( !iSplitScreenState.iPartialScreenEditorNode ) + { + return; + } + if ( aType == KAknSplitInputEnabled ) + { + // don't remove input from stack if split input is enabled + XnTextEditorInterface::MXnTextEditorInterface* editorControl = NULL; + XnComponentInterface::MakeInterfaceL( editorControl, + iSplitScreenState.iPartialScreenEditorNode->AppIfL() ); + if( editorControl ) + { + editorControl->HandleEditorEvent(CXnTextEditor::KKeepSplitInputInStack); + } + + RPointerArray plugins = *Plugins(); + + for( TInt i=0; iMakeVisible( EFalse ); + } + + if ( aType == KAknSplitInputDisabled ) + { + + // set remove stack true if disable event does not come from widget controls + if(iSplitScreenState.isPartialScreenOpen) + { + XnTextEditorInterface::MXnTextEditorInterface* editorControl = NULL; + XnComponentInterface::MakeInterfaceL( editorControl, + iSplitScreenState.iPartialScreenEditorNode->AppIfL() ); + if( editorControl ) + { + editorControl->HandleEditorEvent(CXnTextEditor::KRemoveSplitInputFromStack); + } + } + + RPointerArray plugins = *Plugins(); + + for( TInt i=0; iDes()); + } + + iSplitScreenState.isPartialScreenEnabled = EFalse; + iAppUiAdapter.StatusPane()->MakeVisible(ETrue); + } + } + +// ----------------------------------------------------------------------------- // ----------------------------------------------------------------------------- CCoeControl* CXnUiEngineImpl::WindowOwningControl( CXnNode& aNode ) { @@ -10038,4 +9923,104 @@ TRAP_IGNORE( HandleResourceChangeL( aType ) ); } +// ----------------------------------------------------------------------------- +// EnablePartialTouchInput +// ----------------------------------------------------------------------------- +void CXnUiEngineImpl::EnablePartialTouchInput( CXnNode& aNode, TBool aEnable ) + { + iSplitScreenState.iPartialScreenEditorNode = &aNode; + iSplitScreenState.isPartialScreenOpen = aEnable; + } + +// ----------------------------------------------------------------------------- +// SetNodeVisibleL +// ----------------------------------------------------------------------------- +void CXnUiEngineImpl::SetNodeVisibleL( CXnNode* aNode , TBool aVisible ) + { + CXnDomStringPool* sp( iUiEngine->ODT()->DomDocument().StringPool()); + + if(!aVisible) + { + CXnProperty* display = CXnProperty::NewL( + XnPropertyNames::style::common::KDisplay, + XnPropertyNames::style::common::display::KNone, + CXnDomPropertyValue::EString, *sp ); + + CleanupStack::PushL( display ); + aNode->SetPropertyL(display); + CleanupStack::Pop( display ); + } + else + { + CXnProperty* visible = CXnProperty::NewL( + XnPropertyNames::style::common::KDisplay, + XnPropertyNames::style::common::display::KBlock, + CXnDomPropertyValue::EString, *sp ); + + CleanupStack::PushL( visible ); + aNode->SetPropertyL(visible); + CleanupStack::Pop( visible ); + } + } + +// ----------------------------------------------------------------------------- +// SetPartialScreenBlockProgressionL +// ----------------------------------------------------------------------------- +void CXnUiEngineImpl::SetPartialScreenBlockProgressionL( const TDesC8& aBlockProgression ) + { + CXnNode* plugin = FindPlugin( *iSplitScreenState.iPartialScreenEditorNode ); + CXnNode* parent( NULL ); + if( plugin ) + { + parent = plugin->Parent(); + } + + CXnDomStringPool* sp( iUiEngine->ODT()->DomDocument().StringPool()); + if(parent) + { + CXnProperty* block_progression = CXnProperty::NewL( + XnPropertyNames::style::common::KBlockProgression, + aBlockProgression, + CXnDomPropertyValue::EString, *sp ); + + CleanupStack::PushL( block_progression ); + parent->SetPropertyL(block_progression); + CleanupStack::Pop( block_progression ); + } + } + +// ----------------------------------------------------------------------------- +// SetPartialScreenBlockProgressionL +// ----------------------------------------------------------------------------- +void CXnUiEngineImpl::StorePartialScreenBlockProgressionL() + { + CXnNode* parent = iSplitScreenState.iPartialScreenEditorNode->Parent(); + + if(parent) + { + CXnProperty* blocProgressionProperty( + parent->GetPropertyL( XnPropertyNames::style::common::KBlockProgression ) ); + + HBufC* blocProgressionValue (blocProgressionProperty->StringValueL()); + CleanupStack::PushL( blocProgressionValue ); + if(iSplitScreenState.iPartialScreenBlock) + { + delete iSplitScreenState.iPartialScreenBlock; + iSplitScreenState.iPartialScreenBlock = NULL; + } + iSplitScreenState.iPartialScreenBlock = + CnvUtfConverter::ConvertFromUnicodeToUtf8L(blocProgressionValue->Des() ); + CleanupStack::PopAndDestroy( blocProgressionValue ); + } + } + +// ----------------------------------------------------------------------------- +// isPartialInputActive +// ----------------------------------------------------------------------------- +TBool CXnUiEngineImpl::IsPartialInputActive() + { + return iSplitScreenState.isPartialScreenEnabled; + } + + // End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnuienginepluginif.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnuienginepluginif.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnuienginepluginif.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -437,5 +437,18 @@ iUiEngine->DisableRenderUiLC(); } +// ----------------------------------------------------------------------------- +// TXnUiEnginePluginIf::EnablePartialTouchInput +// +// ----------------------------------------------------------------------------- +// +EXPORT_C void TXnUiEnginePluginIf::EnablePartialTouchInput( + CXnNodePluginIf& aNode, TBool aEnable ) + { + iUiEngine->EnablePartialTouchInput(aNode.Node(), aEnable); + } + + + // End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnviewadapter.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnviewadapter.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnviewadapter.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -189,7 +189,8 @@ // Base class CAknViewAppUi takes ownership of iViewAdapter iAppUiAdapter.AddViewL( this ); - + iAppUiAdapter.SetDefaultViewL( *this ); + iBgControl = CXnBgControl::NewL(); iBgControl->SetMopParent( this ); diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnviewdata.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnviewdata.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnviewdata.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -17,8 +17,10 @@ // System includes #include +#include // User includes +#include "xnappuiadapter.h" #include "xncomposer.h" #include "xnodtparser.h" #include "xnviewmanager.h" @@ -27,10 +29,9 @@ #include "xndomnode.h" #include "xnnode.h" #include "xnoomsyshandler.h" +#include "xnpanic.h" // Constants -_LIT8( KStateConfirmed, "Confirmed" ); -_LIT8( KStateError, "Error" ); _LIT8( KLockingStatusLocked, "locked" ); // ============================ LOCAL FUNCTIONS ================================ @@ -94,11 +95,11 @@ } // ----------------------------------------------------------------------------- -// CXnViewData::SetActiveL() +// CXnViewData::SetActive() // // ----------------------------------------------------------------------------- // -void CXnViewData::SetActiveL( TBool aActive ) +void CXnViewData::SetActive( TBool aActive ) { TBool active( Active() ); @@ -106,81 +107,81 @@ { return; } - + if ( aActive ) { iFlags.Clear( EIsInitial ); iFlags.Set( EIsActive ); - LoadDataPluginsL(); + LoadPublishers(); } else { - DestroyDataPluginsL(); + DestroyPublishers( EAiFwPageShutdown ); iFlags.Clear( EIsActive ); } } // ----------------------------------------------------------------------------- -// CXnViewData::LoadL() +// CXnViewData::Load() // ----------------------------------------------------------------------------- // -void CXnViewData::LoadL() +TInt CXnViewData::Load() { - if ( Occupied() || PluginState().CompareF( KStateError ) == 0 ) + if ( Occupied() ) { - return; + return KErrInUse; } if ( !CXnOomSysHandler::HeapAvailable( VIEW_MIN_MEM ) ) + { + return KErrNoMemory; + } + + TInt err( KErrNone ); + + TRAP( err, err = iManager.Composer().ComposeViewL( *this ) ); + + if ( err == KErrNone ) { - ViewManager().OomSysHandler().HandlePotentialOomL(); - return; + TRAP( err, iManager.Parser().LoadViewL( *this ) ); } - TRAPD( error, - - if( iManager.Composer().ComposeViewL( *this ) == KErrNone ) - { - iManager.Parser().LoadViewL( *this ); - } - ); - - if ( error || !Occupied() ) - { - if( error == KErrNoMemory ) - { - ViewManager().OomSysHandler().HandlePotentialOomL(); - } + if ( err == KErrNone ) + { + iVirginPublishers = ETrue; - // Set error state - iFlags.Clear( EIsInitial ); - - SetPluginStateL( KStateError ); - } - else - { - // Must confirm here, as widgets loading may fail, which - // then results his view to be doomed unnceccesarily - SetPluginStateL( KStateConfirmed ); - - // Load view initial widgets + // Load view's initial widgets for ( TInt i = 0; i < iPluginsData.Count(); i++ ) { if ( iPluginsData[i]->PluginId() != KNullDesC8 ) - { - iPluginsData[i]->LoadL(); + { + TInt err2( iPluginsData[i]->Load() ); + + if ( err2 == KXnErrPluginFailure ) + { + // Content removed error note must be + // displayed once when this view is activated + iShowContentRemoved = ETrue; + + err = err2; + } + else if ( err2 == KErrNoMemory ) + { + err = err2; + break; + } } - } - - if ( Active() ) - { - LoadDataPluginsL(); } - } + + // Succesfully enough composed, publishers + // will be loaded when view is activated + } + + return err; } // ----------------------------------------------------------------------------- @@ -191,16 +192,20 @@ void CXnViewData::Destroy() { if ( Occupied() ) - { - TRAP_IGNORE( DestroyDataPluginsL() ); + { + // View is deleted, pretend plugin is removed from UI + DestroyPublishers( EAiFwPluginShutdown ); iManager.Parser().DestroyView( *this ); } + delete iBgImage; iBgImage = NULL; - Flush(); + delete iBgImagePath; iBgImagePath = NULL; + + Flush(); } // ----------------------------------------------------------------------------- @@ -303,9 +308,12 @@ // void CXnViewData::SetWallpaperImagePathL( const TDesC& aFileName ) { - delete iBgImagePath; - iBgImagePath = NULL; - iBgImagePath = aFileName.AllocL(); + if( !iBgImagePath || iBgImagePath->Des() != aFileName ) + { + delete iBgImagePath; + iBgImagePath = NULL; + iBgImagePath = aFileName.AllocL(); + } } // ----------------------------------------------------------------------------- @@ -397,12 +405,12 @@ // void CXnViewData::ContentSourceNodesL( RPointerArray< CXnNode >& aList ) const { - // Get my data provider nodes + // Get my data publisher nodes CXnPluginData::ContentSourceNodesL( aList ); for ( TInt i = 0; i < iPluginsData.Count(); i++ ) { - // And appearance nodes which my plugin holds + // And publisher nodes which my plugin holds iPluginsData[i]->ContentSourceNodesL( aList ); } } @@ -422,81 +430,144 @@ } // ----------------------------------------------------------------------------- -// CXnViewData::LoadDataPluginsL +// CXnViewData::LoadPublishers // Loads data plugins associated to the plugin // ----------------------------------------------------------------------------- // -void CXnViewData::LoadDataPluginsL() +void CXnViewData::LoadPublishers() + { + if( !Active() || !Occupied() ) + { + return; + } + + iLoader->Cancel(); + + iLoadIndex = 0; + + iLoader->Start( TTimeIntervalMicroSeconds32( 50 ), + TTimeIntervalMicroSeconds32( 50 ), + TCallBack( DoLoadPublishersL, this ) ); + } + +// ----------------------------------------------------------------------------- +// CXnViewData::DoLoadPublishersL() +// +// ----------------------------------------------------------------------------- +// +/* static */ TInt CXnViewData::DoLoadPublishersL( TAny* aAny ) { - if( Occupied() && Active() ) - { - // Load own plugins first, and after that data plugins for widgets - CXnPluginData::LoadDataPluginsL(); + CXnViewData* self = static_cast< CXnViewData* >( aAny ); + + RPointerArray< CXnPluginData >& plugins( self->PluginData() ); + + for ( TInt i = self->iLoadIndex; i < plugins.Count(); i++ ) + { + if ( !plugins[i]->Occupied() ) + { + self->iLoadIndex++; + } + else + { + break; + } + } + + if ( self->iLoadIndex < plugins.Count() ) + { + CXnPluginData* plugin( plugins[self->iLoadIndex] ); + + self->iLoadIndex++; + + TInt reason( plugin->VirginPublishers() ? + EAiFwSystemStartup : EAiFwPageStartup ); + + if( plugin->LoadPublishers( reason ) != KErrNone ) + { + self->iManager.UnloadWidgetFromPluginL( *plugin, ETrue ); + + self->iShowContentRemoved = ETrue; + } + + } + else + { + TInt reason( self->VirginPublishers() ? + EAiFwSystemStartup : EAiFwPageStartup ); + + self->iVirginPublishers = EFalse; + + self->iLoader->Cancel(); + + self->iLoadIndex = 0; + + for ( TInt i = 0; i < self->iContentSourceNodes.Count(); i++ ) + { + CXnNodeAppIf& plugin( self->iContentSourceNodes[i]->AppIfL() ); + + self->iManager.AppUiAdapter().LoadPublisher( plugin, reason ); + } + + if ( self->iShowContentRemoved ) + { + self->ShowContentRemovedError(); + self->iShowContentRemoved = EFalse; + } + } + + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CXnViewData::DestroyPublishers +// Remove data plugins associated to the plugin +// ----------------------------------------------------------------------------- +// +void CXnViewData::DestroyPublishers( TInt aReason ) + { + if ( Occupied() ) + { + // If not all plugins loaded yet + iLoader->Cancel(); + + TRAP_IGNORE( DoDestroyPublishersL( aReason ) ); + + User::Heap().Compress(); } } // ----------------------------------------------------------------------------- -// CXnPluginData::DataPluginsLoadCompletedL -// Indicates that all data plugins are loaded -// ----------------------------------------------------------------------------- -// -void CXnViewData::DataPluginsLoadCompletedL( TInt aStatus ) - { - if ( aStatus == KErrNone ) - { - for( TInt i = 0; i < iPluginsData.Count(); i++ ) - { - iPluginsData[i]->LoadDataPluginsL(); - } - } - - CXnPluginData::DataPluginsLoadCompletedL( aStatus ); - } - -// ----------------------------------------------------------------------------- -// CXnViewData::DestroyDataPluginsL +// CXnPluginData::DoDestroyPublishersL // Remove data plugins associated to the plugin // ----------------------------------------------------------------------------- // -void CXnViewData::DestroyDataPluginsL() +void CXnViewData::DoDestroyPublishersL( TInt aReason ) { - CXnPluginData::DestroyDataPluginsL(); + // Create list of data plugins to be removed + RPointerArray< CXnNode > publishers; + CleanupClosePushL( publishers ); + + TRAP_IGNORE( ContentSourceNodesL( publishers ) ); - for( TInt i = 0; i < iPluginsData.Count(); i++ ) + for ( TInt i = 0; i < publishers.Count(); i++ ) { - iPluginsData[i]->DestroyDataPluginsL(); + // Destruction is synchronous + iManager.AppUiAdapter().DestroyPublisher( + publishers[i]->AppIfL(), aReason ); } + + CleanupStack::PopAndDestroy( &publishers ); } // ----------------------------------------------------------------------------- -// CXnPluginData::DataPluginsLoaded() -// ----------------------------------------------------------------------------- -// -TBool CXnViewData::DataPluginsLoaded() const - { - TBool loaded( CXnPluginData::DataPluginsLoaded() ); - - for( TInt i = 0; loaded && i < iPluginsData.Count(); i++ ) - { - CXnPluginData* plugin( iPluginsData[i] ); - - if( plugin->Occupied() ) - { - loaded = plugin->DataPluginsLoaded(); - } - } - - return loaded; - } - -// ----------------------------------------------------------------------------- +// CXnViewData::SetLockingStatus // Sets view's locking_status attribute ("locked"/"none") // ----------------------------------------------------------------------------- // void CXnViewData::SetLockingStatus( const TDesC8& aLockingStatusString ) { if( ( aLockingStatusString != KNullDesC8 ) && - ( aLockingStatusString.Match( KLockingStatusLocked ) == 0 ) ) + ( aLockingStatusString.Match( KLockingStatusLocked ) == 0 ) ) { iFlags.Clear( EIsRemovable ); } @@ -505,4 +576,5 @@ iFlags.Set( EIsRemovable ); } } + // End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnviewmanager.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnviewmanager.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnviewmanager.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -22,7 +22,6 @@ #include #include #include - #include // User includes @@ -51,51 +50,17 @@ #include "xnnodepluginif.h" #include "xnoomsyshandler.h" #include "xnbackgroundmanager.h" +#include "xneffectmanager.h" // Constants _LIT8( KEmptyWidgetUid, "0x2001f47f" ); -_LIT8( KStateError, "Error" ); - - _LIT8( KTemplateViewUID, "0x20026f50" ); -enum - { - EFirstPassDrawComplete, - EDataPluginsComplete, - EViewIsValid, - }; - - -/* -const TAknsItemID KSkinIds[] = { - KAknsIIDQgnHomePage11, - KAknsIIDQgnHomePage21, - KAknsIIDQgnHomePage22, - KAknsIIDQgnHomePage31, - KAknsIIDQgnHomePage32, - KAknsIIDQgnHomePage33, - KAknsIIDQgnHomePage41, - KAknsIIDQgnHomePage42, - KAknsIIDQgnHomePage43, - KAknsIIDQgnHomePage44, - KAknsIIDQgnHomePage51, - KAknsIIDQgnHomePage52, - KAknsIIDQgnHomePage53, - KAknsIIDQgnHomePage54, - KAknsIIDQgnHomePage55, - KAknsIIDQgnHomePage61, - KAknsIIDQgnHomePage62, - KAknsIIDQgnHomePage63, - KAknsIIDQgnHomePage64, - KAknsIIDQgnHomePage65, - KAknsIIDQgnHomePage66 - }; -*/ - +const TInt KPSCategoryUid = 0x200286E3; +const TInt KPSCrashCountKey = 1; +const TInt KStabilityInterval = 60000000; // 1 minute +const TInt KCrashRestoreThreshold = 3; // ============================ LOCAL FUNCTIONS =============================== - - // ----------------------------------------------------------------------------- // BuildTriggerL // Builds a trigger node @@ -140,38 +105,6 @@ } // ----------------------------------------------------------------------------- -// SetOnlineStateL -// -// ----------------------------------------------------------------------------- -// -static void SetOnlineStateL( CXnAppUiAdapter& aAdapter, - CXnViewData& aViewData ) - { - if( !aViewData.Active() ) - { - // Only active view can change online/offline state - return; - } - - RPointerArray< CXnNode > nodes; - CleanupClosePushL( nodes ); - - RPointerArray< CXnNodeAppIf > list; - CleanupClosePushL( list ); - - aViewData.ContentSourceNodesL( nodes ); - - for ( TInt i = 0; i < nodes.Count(); i++ ) - { - list.AppendL( &nodes[i]->AppIfL() ); - } - - aAdapter.SetOnlineStateL( list ); - - CleanupStack::PopAndDestroy( 2, &nodes ); // &list - } - -// ----------------------------------------------------------------------------- // resolveIconId // ----------------------------------------------------------------------------- // @@ -339,6 +272,13 @@ // CXnViewManager::~CXnViewManager() { + if( iStabilityTimer ) + { + iStabilityTimer->Cancel(); + delete iStabilityTimer; + iStabilityTimer = NULL; + } + iObservers.Reset(); delete iRootData; @@ -354,9 +294,7 @@ iControls.Reset(); iAppearanceNodes.Reset(); - - iFailedPlugins.Reset(); - + delete iComposer; delete iEditor; delete iOomSysHandler; @@ -385,6 +323,29 @@ iHspsWrapper = &iEditor->HspsWrapper(); iComposer = CXnComposer::NewL( *iHspsWrapper ); + + // Robustness checks. + TInt crashCount = 0; + RProperty::Get( TUid::Uid( KPSCategoryUid ), + KPSCrashCountKey, + crashCount ); + + if( crashCount >= KCrashRestoreThreshold ) + { + iHspsWrapper->RestoreRootL(); + ResetCrashCount(); + ShowErrorNoteL( R_QTN_HS_ERROR_WIDGETS_REMOVED ); + } + else if( crashCount > 0 ) + { + // Start stability timer to ensure that + // if system is stabile at least KStabilityInterval + // then crash count is reset to 0. + iStabilityTimer = CPeriodic::NewL( CActive::EPriorityStandard ); + iStabilityTimer->Start( KStabilityInterval, + KStabilityInterval, + TCallBack( SystemStabileTimerCallback, this ) ); + } } // ----------------------------------------------------------------------------- @@ -400,8 +361,8 @@ iRootData = CXnRootData::NewL( *this, iApplicationUid ); // Load root configuration and initial view. - iRootData->LoadL(); - + iRootData->Load(); + CleanupStack::PopAndDestroy(); // DisableRenderUiLC(); } @@ -426,9 +387,7 @@ // Schedule application configuration destroyal iRootData->Destroy(); iRootData = NULL; - - iFlags.ClearAll(); - + User::Heap().Compress(); LoadUiL(); @@ -502,14 +461,25 @@ NotifyConfigureWidgetL( aContentInfo, aPluginData ); - aPluginData.LoadL(); - - UpdateCachesL(); - - NotifyWidgetAdditionL( aPluginData ); + retval = aPluginData.Load(); + + if ( retval == KErrNone ) + { + UpdateCachesL(); + + NotifyWidgetAdditionL( aPluginData ); - // Report widget amount in the view - ReportWidgetAmountL( viewData ); + // Report widget amount in the view + ReportWidgetAmountL( viewData ); + } + else if ( retval == KErrNoMemory ) + { + aPluginData.ShowOutOfMemError(); + } + else if ( retval == KXnErrPluginFailure ) + { + aPluginData.ShowContentRemovedError(); + } CleanupStack::PopAndDestroy(); // DisableRenderUiLC } @@ -521,12 +491,10 @@ // CXnViewManager::UnloadWidgetFromPluginL() // ----------------------------------------------------------------------------- // -TInt CXnViewManager::UnloadWidgetFromPluginL( CXnPluginData& aPluginData ) - { - TBool error( aPluginData.PluginState().CompareF( KStateError ) == 0 ); - - // Plugins in error state are always removed - if ( !error && !aPluginData.Occupied() ) +TInt CXnViewManager::UnloadWidgetFromPluginL( CXnPluginData& aPluginData, + TBool aForce ) + { + if ( !aForce && !aPluginData.Occupied() ) { // Plugin must have widget when about to remove return KErrNotFound; @@ -585,8 +553,7 @@ if ( active ) { - iUiEngine->RenderUIL(); - SetOnlineStateL( iAppUiAdapter, ActiveViewData() ); + iUiEngine->RenderUIL(); } CleanupStack::PopAndDestroy(); // DisableRenderUiLC @@ -602,17 +569,17 @@ TInt CXnViewManager::ReplaceWidgetToPluginL( CHsContentInfo& aContentInfo, CXnPluginData& aPluginData, TBool aUseHsps ) { - TInt ret = KErrNone; + TInt retval( KErrNone ); // if aUseHsps is false, the plugin was already replaced by // another process if( aUseHsps ) { - ret = iHspsWrapper->ReplacePluginL( aPluginData.PluginId(), + retval = iHspsWrapper->ReplacePluginL( aPluginData.PluginId(), aContentInfo.Uid() ); } - if ( ret == KErrNone ) + if ( retval == KErrNone ) { iUiEngine->DisableRenderUiLC(); @@ -628,28 +595,39 @@ NotifyConfigureWidgetL( aContentInfo, aPluginData ); - aPluginData.LoadL(); - - UpdateCachesL(); + retval = aPluginData.Load(); - // notify addition if not replaced with empty widget - // NotifyWidgetAdditionL will call RenderUIL() - if( uid != KEmptyWidgetUid ) + if ( retval == KErrNone ) { - NotifyWidgetAdditionL( aPluginData ); + UpdateCachesL(); + + // notify addition if not replaced with empty widget + // NotifyWidgetAdditionL will call RenderUIL() + if( uid != KEmptyWidgetUid ) + { + NotifyWidgetAdditionL( aPluginData ); + } + else + { + if( aPluginData.Active() ) + { + iUiEngine->RenderUIL(); + } + } } - else + else if ( retval == KErrNoMemory ) { - if( aPluginData.Active() ) - { - iUiEngine->RenderUIL(); - } + aPluginData.ShowOutOfMemError(); } - + else if ( retval == KXnErrPluginFailure ) + { + aPluginData.ShowContentRemovedError(); + } + CleanupStack::PopAndDestroy(); // DisableRenderUiLC } - return ret; + return retval; } // ----------------------------------------------------------------------------- @@ -858,19 +836,26 @@ // Activates the next view // ----------------------------------------------------------------------------- // -void CXnViewManager::ActivateNextViewL() - { - CXnViewData& current( ActiveViewData() ); +void CXnViewManager::ActivateNextViewL( TInt aEffectId ) + { CXnViewData& next( NextViewData() ); - + if ( !next.Occupied() ) - { - next.LoadL(); + { + if ( next.Load() == KErrNoMemory ) + { + next.ShowOutOfMemError(); + } } // Activate view if ( next.Occupied() && !next.Active() ) - { + { + if( aEffectId ) + { + iUiEngine->AppUiAdapter().EffectManager()->BeginFullscreenEffectL( + aEffectId, iUiEngine->ViewManager()->ActiveViewData() ); + } iAppUiAdapter.ViewAdapter().ActivateContainerL( next ); } } @@ -880,19 +865,26 @@ // Activates the previous view // ----------------------------------------------------------------------------- // -void CXnViewManager::ActivatePreviousViewL() - { - CXnViewData& current( ActiveViewData() ); +void CXnViewManager::ActivatePreviousViewL( TInt aEffectId ) + { CXnViewData& prev( PreviousViewData() ); if ( !prev.Occupied() ) { - prev.LoadL(); + if ( prev.Load() == KErrNoMemory ) + { + prev.ShowOutOfMemError(); + } } // Activate view if ( prev.Occupied() && !prev.Active() ) - { + { + if( aEffectId ) + { + iUiEngine->AppUiAdapter().EffectManager()->BeginFullscreenEffectL( + aEffectId, iUiEngine->ViewManager()->ActiveViewData() ); + } iAppUiAdapter.ViewAdapter().ActivateContainerL( prev ); } } @@ -930,8 +922,13 @@ newView->SetOwner( iRootData->Node() ); - newView->LoadL(); + retval = newView->Load(); + if ( retval == KErrNoMemory ) + { + newView->ShowOutOfMemError(); + } + if ( newView->Occupied() ) { // Load succeed, add the new view behind the current view @@ -974,7 +971,7 @@ // Adds a new view // ----------------------------------------------------------------------------- // -void CXnViewManager::AddViewL() +void CXnViewManager::AddViewL( TInt aEffectId ) { if ( iRootData->PluginData().Count() >= iRootData->MaxPages() ) { @@ -1013,10 +1010,22 @@ newView->SetOwner( iRootData->Node() ); - newView->LoadL(); - + status = newView->Load(); + + if ( status == KErrNoMemory ) + { + newView->ShowOutOfMemError(); + } + if ( newView->Occupied() ) { + // Start transition effect + if( aEffectId ) + { + iUiEngine->AppUiAdapter().EffectManager()->BeginFullscreenEffectL( + aEffectId, iUiEngine->ViewManager()->ActiveViewData() ); + } + // Load succeed, add the new view behind the current view RPointerArray< CXnPluginData >& views( iRootData->PluginData() ); @@ -1106,7 +1115,7 @@ // Removes active view if more than one view. // ----------------------------------------------------------------------------- // -void CXnViewManager::RemoveViewL() +void CXnViewManager::RemoveViewL( TInt aEffectId ) { if ( iRootData->PluginData().Count() <= 1 || !ActiveViewData().Removable() ) @@ -1131,9 +1140,21 @@ if ( query->RunLD() ) { + // Start transition effect + if( aEffectId ) + { + iUiEngine->AppUiAdapter().EffectManager()->BeginFullscreenEffectL( + aEffectId, iUiEngine->ViewManager()->ActiveViewData() ); + } + // Activate the next view, or first if in the last view CXnViewData& next( NextViewData() ); + if ( !next.Occupied() ) + { + next.Load(); + } + iAppUiAdapter.ViewAdapter().ActivateContainerL( next ); CXnViewData* view( static_cast< CXnViewData* >( views[ index ] ) ); @@ -1251,7 +1272,6 @@ return iRootData->PluginData().Count(); } - // ----------------------------------------------------------------------------- // CXnViewManager::ViewIndex() // Gets index of current view @@ -1266,6 +1286,16 @@ } // ----------------------------------------------------------------------------- +// CXnViewManager::MaxPages() +// Gets the maximum allowed page count for this app configuration +// ----------------------------------------------------------------------------- +// +TInt CXnViewManager::MaxPages() const + { + return iRootData->MaxPages(); + } + +// ----------------------------------------------------------------------------- // CXnViewManager::NotifyContainerChangedL() // Notifies container is changed, this is called always by CXnViewAdapter // ----------------------------------------------------------------------------- @@ -1274,28 +1304,15 @@ #ifdef _XN_PERFORMANCE_TEST_ RDebug::Print( _L( "CXnViewManager::NotifyContainerChangedL - start" ) ); #endif //_XN_PERFORMANCE_TEST_ - - InvalidateActiveView(); - + CXnViewData& viewToDeactivate( ActiveViewData() ); if ( &aViewToActivate != &viewToDeactivate ) - { - // Store focus - CXnNode* focused( iUiEngine->FocusedNode() ); - - if ( focused ) - { - viewToDeactivate.SetFocusedNode( focused ); - } - + { NotifyViewDeactivatedL( viewToDeactivate ); - - // Switch active view data - iAppUiAdapter.HandlePageSwitch(); - - viewToDeactivate.SetActiveL( EFalse ); - aViewToActivate.SetActiveL( ETrue ); + + viewToDeactivate.SetActive( EFalse ); + aViewToActivate.SetActive( ETrue ); iHspsWrapper->SetActivePluginL( aViewToActivate.PluginId() ); @@ -1306,10 +1323,13 @@ else { // Activate first view - aViewToActivate.SetActiveL( ETrue ); + aViewToActivate.SetActive( ETrue ); // Cache update is needed after view activation UpdateCachesL(); + + // Schedule remainngs views load + iRootData->LoadRemainingViews(); } NotifyViewActivatedL( aViewToActivate ); @@ -1386,12 +1406,6 @@ for ( TInt i = 0; i < iObservers.Count(); i++ ) { iObservers[i]->NotifyConfigureWidgetL( aContentInfo, aPluginData ); - } - - if ( aPluginData.Active() ) - { - // Active view configuration is about to change - InvalidateActiveView(); } } @@ -1445,136 +1459,6 @@ } // ----------------------------------------------------------------------------- -// CXnViewManager::SetFirstPassDrawCompleteL() -// ----------------------------------------------------------------------------- -// -void CXnViewManager::SetFirstPassDrawCompleteL() - { - if ( iFlags.IsClear( EFirstPassDrawComplete ) ) - { - iFlags.Set( EFirstPassDrawComplete ); - - ValidateActiveViewL(); - } - } - -// ----------------------------------------------------------------------------- -// CXnViewManager::SetDataPluginLoadCompleteL() -// ----------------------------------------------------------------------------- -// -void CXnViewManager::SetDataPluginLoadCompleteL( - const CXnPluginData& aPluginData ) - { - if ( !aPluginData.Active() ) - { - // Not interested - return; - } - - if ( ActiveViewData().DataPluginsLoaded() ) - { - if ( iFlags.IsClear( EDataPluginsComplete ) ) - { - iFlags.Set( EDataPluginsComplete ); - - ValidateActiveViewL(); - } - } - } - -// ----------------------------------------------------------------------------- -// CXnViewManager::ValidateActiveViewL() -// ----------------------------------------------------------------------------- -// -void CXnViewManager::ValidateActiveViewL() - { - if ( iFlags.IsSet( EViewIsValid ) ) - { - // Already ok - return; - } - - if ( iFlags.IsClear( EFirstPassDrawComplete ) || - iFlags.IsClear( EDataPluginsComplete ) ) - { - // Not able to confirm yet - return; - } - - RPointerArray< CXnPluginData >& plugins( ActiveViewData().PluginData() ); - - TInt count( iFailedPlugins.Count() ); - - for ( TInt i = 0; i < plugins.Count(); i++ ) - { - CXnPluginData* plugin( plugins[i] ); - - const TDesC8& state( plugin->PluginState() ); - - if ( state.CompareF( KStateError ) == 0 && plugin->Removable() ) - { - if ( iFailedPlugins.Find( plugin ) == KErrNotFound ) - { - iFailedPlugins.AppendL( plugin ); - } - } - } - - // This condition prevents recursion - if ( iFailedPlugins.Count() > 0 && count == 0 ) - { - // Disable layout and redraw until all plugins are removed - iUiEngine->DisableRenderUiLC(); - - for ( TInt i = 0; i < iFailedPlugins.Count(); i++ ) - { - UnloadWidgetFromPluginL( *iFailedPlugins[i] ); - } - - HBufC* msg( StringLoader::LoadLC( R_QTN_HS_ERROR_WIDGETS_REMOVED ) ); - - CAknErrorNote* note = new ( ELeave ) CAknErrorNote; - CleanupStack::PushL( note ); - - note->ExecuteLD( *msg ); - - CleanupStack::Pop( note ); - CleanupStack::PopAndDestroy( msg ); - - iUiEngine->RenderUIL(); - - CleanupStack::PopAndDestroy(); // DisableRenderUiLC() - - iFailedPlugins.Reset(); - } - - // All failed plugins are handled - if( iFailedPlugins.Count() == 0 ) - { - iFlags.Set( EViewIsValid ); - - SetOnlineStateL( iAppUiAdapter, ActiveViewData() ); - - // Remaining views can be now loaded - iRootData->LoadRemainingViews(); - } - } - -// ----------------------------------------------------------------------------- -// CXnViewManager::InvalidateActiveView() -// ----------------------------------------------------------------------------- -// -void CXnViewManager::InvalidateActiveView() - { - // Need to cancel async activities while view is invalidated - iRootData->CancelLoadRemainingViews(); - - iFlags.Clear( EFirstPassDrawComplete ); - iFlags.Clear( EDataPluginsComplete ); - iFlags.Clear( EViewIsValid ); - } - -// ----------------------------------------------------------------------------- // CXnViewManager::ReportWidgetAmountL() // ----------------------------------------------------------------------------- // @@ -1676,7 +1560,7 @@ } // ----------------------------------------------------------------------------- -// CXnViewManager::UpdateViewSwitcherInformationL() +// CXnViewManager::UpdatePageManagementInformationL() // ----------------------------------------------------------------------------- // void CXnViewManager::UpdatePageManagementInformationL() @@ -1720,40 +1604,6 @@ } // ----------------------------------------------------------------------------- -// CXnViewManager::UpdatePluginStateL() -// ----------------------------------------------------------------------------- -// -void CXnViewManager::UpdatePluginStateL( CXnPluginData& aPluginData ) - { - if ( aPluginData.ConfigurationId().Length() == 0 && - aPluginData.PluginId().Length() ) - { - CHspsConfiguration* configuration( - iHspsWrapper->GetPluginConfigurationL( aPluginData.PluginId() ) ); - CleanupStack::PushL( configuration ); - aPluginData.SetConfigurationIdL( configuration->ConfId() ); - CleanupStack::PopAndDestroy( configuration ); - } - - if ( aPluginData.ConfigurationId().Length() && - aPluginData.PluginId().Length() ) - { - iHspsWrapper->SetConfStateL( - aPluginData.ConfigurationId(), aPluginData.PluginState() ); - } - } - -// ----------------------------------------------------------------------------- -// CXnViewManager::MaxPages() -// -// ----------------------------------------------------------------------------- -// -TInt32 CXnViewManager::MaxPages() - { - return iRootData->MaxPages(); - } - -// ----------------------------------------------------------------------------- // CXnViewManager::ResolveIconIndex // // ----------------------------------------------------------------------------- @@ -1771,4 +1621,46 @@ return index; } + +// ----------------------------------------------------------------------------- +// CXnViewManager::SystemStabileTimerCallback +// ----------------------------------------------------------------------------- +TInt CXnViewManager::SystemStabileTimerCallback( TAny* aAny ) + { + CXnViewManager* self = static_cast( aAny ); + + self->ResetCrashCount(); + + if( self->iStabilityTimer ) + { + self->iStabilityTimer->Cancel(); + } + + return KErrNone; + } + +// ----------------------------------------------------------------------------- +// CXnViewManager::ResetCrashCount +// ----------------------------------------------------------------------------- +void CXnViewManager::ResetCrashCount() + { + RProperty::Set( TUid::Uid( KPSCategoryUid ), KPSCrashCountKey, 0 ); + } + +// ----------------------------------------------------------------------------- +// CXnViewManager::ShowErrorNoteL +// ----------------------------------------------------------------------------- +void CXnViewManager::ShowErrorNoteL( const TInt aResourceId ) + { + HBufC* msg( StringLoader::LoadLC( aResourceId ) ); + + CAknErrorNote* note = new ( ELeave ) CAknErrorNote; + CleanupStack::PushL( note ); + + note->ExecuteLD( *msg ); + + CleanupStack::Pop( note ); + CleanupStack::PopAndDestroy( msg ); + } + // End of file diff -r c743ef5928ba -r f966699dea19 idlehomescreen/xmluirendering/uiengine/src/xnwidgetextensionadapter.cpp --- a/idlehomescreen/xmluirendering/uiengine/src/xnwidgetextensionadapter.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/idlehomescreen/xmluirendering/uiengine/src/xnwidgetextensionadapter.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -13,14 +13,14 @@ * */ - +// System includes #include #include #include #include - #include +// User includes #include "xnwidgetextensionadapter.h" #include "xncontroladapter.h" @@ -46,13 +46,14 @@ #include "xnviewdata.h" #include "xnplugindata.h" - -_LIT8( KPopUpText, "popup" ); +// Constants +_LIT8( KPopup, "popup" ); _LIT8( KPositionHint, "_s60-position-hint" ); _LIT8( KWidgetNodeName, "widget" ); _LIT8( KParentIdName, "parentid" ); _LIT8( KDisplay, "display" ); _LIT8( KNone, "none" ); + // ============================ MEMBER FUNCTIONS =============================== // ----------------------------------------------------------------------------- @@ -78,6 +79,10 @@ // CXnWidgetExtensionAdapter::~CXnWidgetExtensionAdapter() { + if ( iAppUiAdapter ) + { + iAppUiAdapter->UiStateListener().RemoveObserver( *this ); + } } // ----------------------------------------------------------------------------- @@ -97,7 +102,10 @@ // void CXnWidgetExtensionAdapter::ConstructL() { + iAppUiAdapter = static_cast< CXnAppUiAdapter* >( iAvkonAppUi ); + CreateWindowL(); + Window().SetRequiredDisplayMode( EColor16MA ); // this adapter handles both widgetextension and popup nodes @@ -106,17 +114,29 @@ CXnType* typeInfo = iNode.Node().Type(); const TDesC8& type = typeInfo->Type(); - if ( ( type != KPopUpText ) && - ( Window().SetTransparencyAlphaChannel() == KErrNone ) ) + if ( type == KPopup ) { - Window().SetBackgroundColor( ~0 ); + CXnProperty* prop( iNode.Node().GetPropertyL( + XnPropertyNames::popup::KPopupType ) ); + + if ( prop && prop->StringValue() == + XnPropertyNames::popup::popuptype::KPermanent ) + { + iPermanent = ETrue; + } } + else + { + if ( Window().SetTransparencyAlphaChannel() == KErrNone ) + { + Window().SetBackgroundColor( ~0 ); + } + } + iUiEngine = iNode.Node().UiEngine(); CXnControlAdapter::ConstructL( iNode ); - EnableDragEvents(); - - iAppUiAdapter = static_cast< CXnAppUiAdapter* >( iAvkonAppUi ); - + + EnableDragEvents(); } // ----------------------------------------------------------------------------- @@ -125,9 +145,9 @@ // ----------------------------------------------------------------------------- // void CXnWidgetExtensionAdapter::MakeVisible( TBool aVisible ) - { - + { TBool visible( IsVisible() ? ETrue : EFalse ); + if ( visible == aVisible ) { return; @@ -143,12 +163,28 @@ CXnType* typeInfo = iNode.Node().Type(); const TDesC8& type = typeInfo->Type(); - if ( type != KPopUpText ) + TBool popup( type == KPopup ); + + if ( !popup ) { DrawableWindow()->FadeBehind( aVisible ); } + else + { + if ( !iPermanent ) + { + if ( aVisible ) + { + iAppUiAdapter->UiStateListener().AddObserver( *this ); + } + else + { + iAppUiAdapter->UiStateListener().RemoveObserver( *this ); + } + } + } - if ( aVisible && type == KPopUpText ) + if ( aVisible && popup ) { // read position-hint property and set-up its variable CXnProperty* positionHintProp = NULL; @@ -214,17 +250,15 @@ // void CXnWidgetExtensionAdapter::HandlePointerEventL( const TPointerEvent& aPointerEvent ) - { - + { CXnType* typeInfo = iNode.Node().Type(); const TDesC8& type = typeInfo->Type(); // in case of popup, we have to make sure that // it will be closed after tapping outside of the // area of itself and its parent - if ( type == KPopUpText ) - { - + if ( type == KPopup ) + { // check if the tap was inside of popup TRect popupRect = this->Rect(); popupRect.Move(this->Position() ); @@ -232,12 +266,11 @@ aPointerEvent.iParentPosition ); if ( !isInPopupWindow ) - { - + { // if tap was outside of window, check if tap was // inside of the parrent - CXnProperty* parentIdProp = iNode.Node().GetPropertyL( - KParentIdName ); + CXnProperty* parentIdProp( iNode.Node().GetPropertyL( + KParentIdName ) ); if ( parentIdProp ) { @@ -258,13 +291,7 @@ // we can close it if ( aPointerEvent.iType == TPointerEvent::EButton1Down ) { - CXnDomStringPool* sp = - iNode.Node().DomNode()->StringPool(); - CXnProperty* prop = CXnProperty::NewL( KDisplay, KNone, - CXnDomPropertyValue::EString, *sp ); - CleanupStack::PushL( prop ); - iNode.Node().SetPropertyL( prop ); - CleanupStack::Pop( prop ); + HidePopupL(); return; } } @@ -282,11 +309,14 @@ } } } + else + { + HidePopupL(); + } } } - CXnControlAdapter::HandlePointerEventL( aPointerEvent ); - + CXnControlAdapter::HandlePointerEventL( aPointerEvent ); } // ----------------------------------------------------------------------------- @@ -296,7 +326,7 @@ // void CXnWidgetExtensionAdapter::Draw( const TRect& aRect ) const { - CXnControlAdapter::Draw( aRect ); + CXnControlAdapter::Draw( aRect ); } // ----------------------------------------------------------------------------- @@ -305,7 +335,6 @@ // ----------------------------------------------------------------------------- void CXnWidgetExtensionAdapter::CalculatePosition() { - // widget's rectangle TRect controlRect; @@ -513,7 +542,67 @@ { rect.Move( contentRect.iBr.iX - rect.iBr.iX, 0 ); } + this->SetRect( rect ); } + +// ----------------------------------------------------------------------------- +// CXnWidgetExtensionAdapter::NotifyForegroundChanged +// +// ----------------------------------------------------------------------------- +// +void CXnWidgetExtensionAdapter::NotifyForegroundChanged( + TForegroundStatus aStatus ) + { + if ( aStatus != EForeground ) + { + TRAP_IGNORE( HidePopupL() ); + } + } + +// ----------------------------------------------------------------------------- +// CXnWidgetExtensionAdapter::NotifyLightStatusChanged +// +// ----------------------------------------------------------------------------- +// +void CXnWidgetExtensionAdapter::NotifyLightStatusChanged( TBool aLightsOn ) + { + if ( !aLightsOn ) + { + TRAP_IGNORE( HidePopupL() ); + } + } + +// ----------------------------------------------------------------------------- +// CXnWidgetExtensionAdapter::NotifyInCallStateChaged +// +// ----------------------------------------------------------------------------- +// +void CXnWidgetExtensionAdapter::NotifyInCallStateChaged( TBool /*aInCall*/ ) + { + } + +// ----------------------------------------------------------------------------- +// CXnWidgetExtensionAdapter::HidePopupL +// +// ----------------------------------------------------------------------------- +// +void CXnWidgetExtensionAdapter::HidePopupL() + { + if ( IsVisible() ) + { + CXnDomStringPool* sp( iNode.Node().DomNode()->StringPool() ); + + CXnProperty* prop = CXnProperty::NewL( + KDisplay, KNone, CXnDomPropertyValue::EString, *sp ); + + CleanupStack::PushL( prop ); + + iNode.Node().SetPropertyL( prop ); + + CleanupStack::Pop( prop ); + } + } + // End of File diff -r c743ef5928ba -r f966699dea19 menufw/hierarchynavigator/hnpresentationmodel/inc/hneventhandler.h --- a/menufw/hierarchynavigator/hnpresentationmodel/inc/hneventhandler.h Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/hierarchynavigator/hnpresentationmodel/inc/hneventhandler.h Fri Feb 19 22:42:37 2010 +0200 @@ -184,6 +184,12 @@ * Reference to App UI - Event observer. */ MHnControllerInterface& iControllerInterface; + + /** + * ETrue if a standard asynchroneous action is being executed by + * this event handler. + */ + TBool iIsExecutingStandardAsyncAction; }; diff -r c743ef5928ba -r f966699dea19 menufw/hierarchynavigator/hnpresentationmodel/src/hneventhandler.cpp --- a/menufw/hierarchynavigator/hnpresentationmodel/src/hneventhandler.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/hierarchynavigator/hnpresentationmodel/src/hneventhandler.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -32,7 +32,7 @@ // --------------------------------------------------------------------------- -// Safe constructor. Initializes refrerece to the Meta Data Model in which +// Safe constructor. Initializes refrerece to the Meta Data Model in which // the event-to-action mappings are stored. // --------------------------------------------------------------------------- // @@ -43,7 +43,7 @@ } // --------------------------------------------------------------------------- -// +// // --------------------------------------------------------------------------- // CHnEventHandler::~CHnEventHandler() @@ -52,10 +52,10 @@ } // --------------------------------------------------------------------------- -// +// // --------------------------------------------------------------------------- // -CHnEventHandler* CHnEventHandler::NewLC( +CHnEventHandler* CHnEventHandler::NewLC( MHnMdModelEventObserver& aModelObserver, MHnControllerInterface& aController ) { @@ -67,21 +67,21 @@ } // --------------------------------------------------------------------------- -// +// // --------------------------------------------------------------------------- // -CHnEventHandler* CHnEventHandler::NewL( +CHnEventHandler* CHnEventHandler::NewL( MHnMdModelEventObserver& aModelObserver, MHnControllerInterface& aController ) { - CHnEventHandler* self=CHnEventHandler::NewLC( aModelObserver, + CHnEventHandler* self=CHnEventHandler::NewLC( aModelObserver, aController ); - CleanupStack::Pop(self); + CleanupStack::Pop(self); return self; } // --------------------------------------------------------------------------- -// +// // --------------------------------------------------------------------------- // void CHnEventHandler::ConstructL() @@ -89,45 +89,70 @@ } // --------------------------------------------------------------------------- -// +// // --------------------------------------------------------------------------- // - TInt CHnEventHandler::ExecuteStandardActionL( CHnActionModel* aActionModel ) { - delete iServiceHandler; - iServiceHandler = NULL; - iServiceHandler = CHnServiceHandler::NewL( - aActionModel->Service(), - aActionModel->Interface(), - aActionModel->CommandName(), - aActionModel->ServiceMode(), - aActionModel->ConstructorLC(), - aActionModel->CommandLC() ); + const TDesC8& service = aActionModel->Service(); + const TDesC8& interface = aActionModel->Interface(); + const TDesC8& commandName = aActionModel->CommandName(); + const TServiceMode mode = aActionModel->ServiceMode(); + CLiwGenericParamList* constructor = aActionModel->ConstructorLC(); + CLiwGenericParamList* serviceCommand = aActionModel->CommandLC(); + + if ( iServiceHandler && ( iIsExecutingStandardAsyncAction + || !iServiceHandler->ServiceHandlerMatchesModel( + service, interface, constructor ) ) ) + { + delete iServiceHandler; // this will cancel async. action execution + iServiceHandler = NULL; + iIsExecutingStandardAsyncAction = EFalse; + } + + if ( !iServiceHandler ) + { + iServiceHandler = CHnServiceHandler::NewL( service, interface, + commandName, mode, constructor, serviceCommand ); + CleanupStack::Pop( serviceCommand ); + CleanupStack::Pop( constructor ); + } + else + { + iServiceHandler->PrepareForNextExecutionL( + commandName, mode, serviceCommand ); + CleanupStack::Pop( serviceCommand ); + CleanupStack::PopAndDestroy( constructor ); + constructor = NULL; + } - CleanupStack::Pop( 2 ); - TInt res = iServiceHandler->ExecuteL( this, 0 ); + __ASSERT_DEBUG( !iIsExecutingStandardAsyncAction, User::Invariant() ); + if ( mode == EServiceModeAsynchronous ) + { + iIsExecutingStandardAsyncAction = ETrue; + } + TInt res = iServiceHandler->ExecuteL( this, 0 ); return res; } // --------------------------------------------------------------------------- -// +// // --------------------------------------------------------------------------- // -TInt CHnEventHandler::ExtractUidFromActionL( const TDesC8& aInterface, +TInt CHnEventHandler::ExtractUidFromActionL( const TDesC8& aInterface, TUid& aUid ) { DEBUG16(("_MM_: CHnEventHandler::ExtractUidFromActionL UIext - uid %S", &aInterface )); - + TLex8 lex( aInterface ); lex.Inc( 2 ); return lex.Val( (TUint32 &) aUid.iUid, EHex ); } - + // --------------------------------------------------------------------------- -// +// // --------------------------------------------------------------------------- // TInt CHnEventHandler::ExecuteInternalActionL( CHnActionModel* aActionModel ) @@ -136,32 +161,32 @@ CLiwGenericParamList* params = aActionModel->CommandLC(); if ( aActionModel->CommandName() == KServiceOpenSuite ) { - ret = iEventObserver.HandleModelEventL( KNewSuiteLoadedMdEvent(), + ret = iEventObserver.HandleModelEventL( KNewSuiteLoadedMdEvent(), *params ); } else if ( aActionModel->CommandName() == KServiceSwitchWidget ) { - ret = iEventObserver.HandleModelEventL( KSwitchWidgetMdEvent(), + ret = iEventObserver.HandleModelEventL( KSwitchWidgetMdEvent(), *params ); } else if ( aActionModel->CommandName() == KServiceStartEditMode ) { - ret = iEventObserver.HandleModelEventL( KStartEditModeMdEvent(), + ret = iEventObserver.HandleModelEventL( KStartEditModeMdEvent(), *params ); } else if ( aActionModel->CommandName() == KServiceStopEditMode ) { - ret = iEventObserver.HandleModelEventL( KStopEditModeMdEvent(), + ret = iEventObserver.HandleModelEventL( KStopEditModeMdEvent(), *params ); } else if ( aActionModel->CommandName() == KServiceBack ) { - ret = iEventObserver.HandleModelEventL( KBackMdEvent(), + ret = iEventObserver.HandleModelEventL( KBackMdEvent(), *params ); } else if ( aActionModel->CommandName() == KSetFocus ) { - ret = iEventObserver.HandleModelEventL( KSetFocusEvent(), + ret = iEventObserver.HandleModelEventL( KSetFocusEvent(), *params ); } @@ -170,7 +195,7 @@ } // --------------------------------------------------------------------------- -// +// // --------------------------------------------------------------------------- // TInt CHnEventHandler::ExecuteExtensionManagerActionL( @@ -178,28 +203,28 @@ { TUid uid; TInt err = ExtractUidFromActionL( aActionModel->Interface(), uid ); - + if ( KErrNone == err ) { HBufC* cmd = HnConvUtils::Str8ToStrFastLC( aActionModel->CommandName() ); CLiwGenericParamList* command = aActionModel->CommandLC(); - err = iControllerInterface.ExecuteExtensionActionL( uid, *cmd, command ); + err = iControllerInterface.ExecuteExtensionActionL( uid, *cmd, command ); CleanupStack::PopAndDestroy( command ); CleanupStack::PopAndDestroy( cmd ); } - + return err; } // --------------------------------------------------------------------------- -// +// // --------------------------------------------------------------------------- // EXPORT_C TInt CHnEventHandler::ExecuteActionL( CHnActionModel* aActionModel ) { ASSERT( aActionModel ); TInt err( KErrNone ); - + if( aActionModel->Service() == KServiceMultimediaMenu ) { if ( aActionModel->Interface().Length() == 0 ) @@ -215,7 +240,7 @@ { err = ExecuteStandardActionL( aActionModel ); } - + return err; } @@ -226,5 +251,6 @@ CLiwGenericParamList& /*aEventParamList*/, const CLiwGenericParamList& /*aInParamList*/ ) { + iIsExecutingStandardAsyncAction = EFalse; return KErrNone; } diff -r c743ef5928ba -r f966699dea19 menufw/hierarchynavigator/hnutilities/bwins/hnutilitiesu.def --- a/menufw/hierarchynavigator/hnutilities/bwins/hnutilitiesu.def Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/hierarchynavigator/hnutilities/bwins/hnutilitiesu.def Fri Feb 19 22:42:37 2010 +0200 @@ -5,39 +5,41 @@ ?ToGenericParamListL@CHnMdBaseKey@@UBEXAAVCLiwGenericParamList@@@Z @ 4 NONAME ; void CHnMdBaseKey::ToGenericParamListL(class CLiwGenericParamList &) const ?NumToStr8LC@HnConvUtils@@SAPAVHBufC8@@ABH@Z @ 5 NONAME ; class HBufC8 * HnConvUtils::NumToStr8LC(int const &) ?StoreSuiteWidgetTypeL@CHnRepositoryManager@@QAEHABVTDesC16@@W4THnSuiteWidgetType@@@Z @ 6 NONAME ; int CHnRepositoryManager::StoreSuiteWidgetTypeL(class TDesC16 const &, enum THnSuiteWidgetType) - ?StrToStr8L@HnConvUtils@@SAPAVHBufC8@@ABVTDesC16@@@Z @ 7 NONAME ; class HBufC8 * HnConvUtils::StrToStr8L(class TDesC16 const &) - ?NewL@CHnRepositoryManager@@SAPAV1@XZ @ 8 NONAME ; class CHnRepositoryManager * CHnRepositoryManager::NewL(void) - ?VariantToStringL@HnLiwUtils@@SAHAAVTLiwVariant@@AAVRBuf16@@@Z @ 9 NONAME ; int HnLiwUtils::VariantToStringL(class TLiwVariant &, class RBuf16 &) - ?SetGenericParamListL@HnLiwUtils@@SAXABV?$RPointerArray@VCHnMdBaseKey@@@@AAVCLiwGenericParamList@@@Z @ 10 NONAME ; void HnLiwUtils::SetGenericParamListL(class RPointerArray const &, class CLiwGenericParamList &) - ?GetStringL@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@HAAVRBuf8@@@Z @ 11 NONAME ; int HnLiwUtils::GetStringL(class CLiwGenericParamList const &, class TDesC8 const &, int, class RBuf8 &) - ?CreateL@HnMdKeyFactory@@SAPAVCHnMdBaseKey@@ABVTDesC8@@00@Z @ 12 NONAME ; class CHnMdBaseKey * HnMdKeyFactory::CreateL(class TDesC8 const &, class TDesC8 const &, class TDesC8 const &) - ?CreateL@HnMdKeyFactory@@SAPAVCHnMdBaseKey@@VTXmlEngElement@@@Z @ 13 NONAME ; class CHnMdBaseKey * HnMdKeyFactory::CreateL(class TXmlEngElement) - ?Str8ToStrLC@HnConvUtils@@SAPAVHBufC16@@ABVTDesC8@@@Z @ 14 NONAME ; class HBufC16 * HnConvUtils::Str8ToStrLC(class TDesC8 const &) - ?GetIterableItemCountL@HnLiwUtils@@SAHAAVCLiwIterable@@@Z @ 15 NONAME ; int HnLiwUtils::GetIterableItemCountL(class CLiwIterable &) - ?ReadSuiteWidgetTypeL@CHnRepositoryManager@@QAEHABVTDesC16@@AAW4THnSuiteWidgetType@@@Z @ 16 NONAME ; int CHnRepositoryManager::ReadSuiteWidgetTypeL(class TDesC16 const &, enum THnSuiteWidgetType &) - ?StrToInt@HnConvUtils@@SAHABVTDesC16@@AAJ@Z @ 17 NONAME ; int HnConvUtils::StrToInt(class TDesC16 const &, long &) - ??1CHnServiceHandler@@UAE@XZ @ 18 NONAME ; CHnServiceHandler::~CHnServiceHandler(void) - ?NewLC@CHnServiceHandler@@SAPAV1@ABVTDesC8@@00W4TServiceMode@@PAVCLiwGenericParamList@@2@Z @ 19 NONAME ; class CHnServiceHandler * CHnServiceHandler::NewLC(class TDesC8 const &, class TDesC8 const &, class TDesC8 const &, enum TServiceMode, class CLiwGenericParamList *, class CLiwGenericParamList *) - ?Str8ToUint@HnConvUtils@@SAHABVTDesC8@@AAI@Z @ 20 NONAME ; int HnConvUtils::Str8ToUint(class TDesC8 const &, unsigned int &) - ?Str8ToInt@HnConvUtils@@SAHABVTDesC8@@AAJ@Z @ 21 NONAME ; int HnConvUtils::Str8ToInt(class TDesC8 const &, long &) - ?NewL@CHnServiceHandler@@SAPAV1@ABVTDesC8@@00W4TServiceMode@@PAVCLiwGenericParamList@@2@Z @ 22 NONAME ; class CHnServiceHandler * CHnServiceHandler::NewL(class TDesC8 const &, class TDesC8 const &, class TDesC8 const &, enum TServiceMode, class CLiwGenericParamList *, class CLiwGenericParamList *) - ?AddSubKeyL@CHnMdBaseKey@@QAEXPAV1@@Z @ 23 NONAME ; void CHnMdBaseKey::AddSubKeyL(class CHnMdBaseKey *) - ?Str8ToInt@HnConvUtils@@SAHABVTDesC8@@AAH@Z @ 24 NONAME ; int HnConvUtils::Str8ToInt(class TDesC8 const &, int &) - ?ToVariantL@CHnMdBaseKey@@UBEXAAVTLiwVariant@@@Z @ 25 NONAME ; void CHnMdBaseKey::ToVariantL(class TLiwVariant &) const - ?Str8ToStr@HnConvUtils@@SAPAVHBufC16@@ABVTDesC8@@@Z @ 26 NONAME ; class HBufC16 * HnConvUtils::Str8ToStr(class TDesC8 const &) - ?HandleNotifyL@CHnServiceHandler@@EAEHHHAAVCLiwGenericParamList@@ABV2@@Z @ 27 NONAME ; int CHnServiceHandler::HandleNotifyL(int, int, class CLiwGenericParamList &, class CLiwGenericParamList const &) - ?DeleteSuiteRelatedL@CHnRepositoryManager@@QAEHABVTDesC16@@@Z @ 28 NONAME ; int CHnRepositoryManager::DeleteSuiteRelatedL(class TDesC16 const &) - ?GetInt64L@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@HAA_J@Z @ 29 NONAME ; int HnLiwUtils::GetInt64L(class CLiwGenericParamList const &, class TDesC8 const &, int, long long &) - ??1CHnRepositoryManager@@UAE@XZ @ 30 NONAME ; CHnRepositoryManager::~CHnRepositoryManager(void) - ?CreateL@HnMdKeyFactory@@SAPAVCHnMdBaseKey@@ABVTDesC8@@0ABVTDesC16@@@Z @ 31 NONAME ; class CHnMdBaseKey * HnMdKeyFactory::CreateL(class TDesC8 const &, class TDesC8 const &, class TDesC16 const &) - ?GetVariantL@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@HAAVTLiwVariant@@@Z @ 32 NONAME ; int HnLiwUtils::GetVariantL(class CLiwGenericParamList const &, class TDesC8 const &, int, class TLiwVariant &) - ?GetStringL@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@AAVRBuf16@@@Z @ 33 NONAME ; int HnLiwUtils::GetStringL(class CLiwGenericParamList const &, class TDesC8 const &, class RBuf16 &) - ?GetStringL@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@HAAVRBuf16@@@Z @ 34 NONAME ; int HnLiwUtils::GetStringL(class CLiwGenericParamList const &, class TDesC8 const &, int, class RBuf16 &) - ?ExecuteL@CHnServiceHandler@@QAEHAAVCLiwGenericParamList@@AAVTRequestStatus@@@Z @ 35 NONAME ; int CHnServiceHandler::ExecuteL(class CLiwGenericParamList &, class TRequestStatus &) - ?VariantToStringL@HnLiwUtils@@SAHAAVTLiwVariant@@AAVRBuf8@@@Z @ 36 NONAME ; int HnLiwUtils::VariantToStringL(class TLiwVariant &, class RBuf8 &) - ?StrToInt@HnConvUtils@@SAHABVTDesC16@@AAH@Z @ 37 NONAME ; int HnConvUtils::StrToInt(class TDesC16 const &, int &) - ?CreateLC@HnMdKeyFactory@@SAPAVCHnMdBaseKey@@VTXmlEngElement@@@Z @ 38 NONAME ; class CHnMdBaseKey * HnMdKeyFactory::CreateLC(class TXmlEngElement) - ?StrToStr8LC@HnConvUtils@@SAPAVHBufC8@@ABVTDesC16@@@Z @ 39 NONAME ; class HBufC8 * HnConvUtils::StrToStr8LC(class TDesC16 const &) - ?EvaluateLC@CHnMdBaseKey@@QAEPAV1@ABVCLiwGenericParamList@@H@Z @ 40 NONAME ; class CHnMdBaseKey * CHnMdBaseKey::EvaluateLC(class CLiwGenericParamList const &, int) - ?GetVariantL@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@AAVTLiwVariant@@@Z @ 41 NONAME ; int HnLiwUtils::GetVariantL(class CLiwGenericParamList const &, class TDesC8 const &, class TLiwVariant &) + ?PrepareForNextExecutionL@CHnServiceHandler@@QAEXABVTDesC8@@W4TServiceMode@@PAVCLiwGenericParamList@@@Z @ 7 NONAME ; void CHnServiceHandler::PrepareForNextExecutionL(class TDesC8 const &, enum TServiceMode, class CLiwGenericParamList *) + ?StrToStr8L@HnConvUtils@@SAPAVHBufC8@@ABVTDesC16@@@Z @ 8 NONAME ; class HBufC8 * HnConvUtils::StrToStr8L(class TDesC16 const &) + ?NewL@CHnRepositoryManager@@SAPAV1@XZ @ 9 NONAME ; class CHnRepositoryManager * CHnRepositoryManager::NewL(void) + ?VariantToStringL@HnLiwUtils@@SAHAAVTLiwVariant@@AAVRBuf16@@@Z @ 10 NONAME ; int HnLiwUtils::VariantToStringL(class TLiwVariant &, class RBuf16 &) + ?SetGenericParamListL@HnLiwUtils@@SAXABV?$RPointerArray@VCHnMdBaseKey@@@@AAVCLiwGenericParamList@@@Z @ 11 NONAME ; void HnLiwUtils::SetGenericParamListL(class RPointerArray const &, class CLiwGenericParamList &) + ?GetStringL@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@HAAVRBuf8@@@Z @ 12 NONAME ; int HnLiwUtils::GetStringL(class CLiwGenericParamList const &, class TDesC8 const &, int, class RBuf8 &) + ?CreateL@HnMdKeyFactory@@SAPAVCHnMdBaseKey@@ABVTDesC8@@00@Z @ 13 NONAME ; class CHnMdBaseKey * HnMdKeyFactory::CreateL(class TDesC8 const &, class TDesC8 const &, class TDesC8 const &) + ?CreateL@HnMdKeyFactory@@SAPAVCHnMdBaseKey@@VTXmlEngElement@@@Z @ 14 NONAME ; class CHnMdBaseKey * HnMdKeyFactory::CreateL(class TXmlEngElement) + ?Str8ToStrLC@HnConvUtils@@SAPAVHBufC16@@ABVTDesC8@@@Z @ 15 NONAME ; class HBufC16 * HnConvUtils::Str8ToStrLC(class TDesC8 const &) + ?GetIterableItemCountL@HnLiwUtils@@SAHAAVCLiwIterable@@@Z @ 16 NONAME ; int HnLiwUtils::GetIterableItemCountL(class CLiwIterable &) + ?ReadSuiteWidgetTypeL@CHnRepositoryManager@@QAEHABVTDesC16@@AAW4THnSuiteWidgetType@@@Z @ 17 NONAME ; int CHnRepositoryManager::ReadSuiteWidgetTypeL(class TDesC16 const &, enum THnSuiteWidgetType &) + ?StrToInt@HnConvUtils@@SAHABVTDesC16@@AAJ@Z @ 18 NONAME ; int HnConvUtils::StrToInt(class TDesC16 const &, long &) + ?ServiceHandlerMatchesModel@CHnServiceHandler@@QBEHABVTDesC8@@0PBVCLiwGenericParamList@@@Z @ 19 NONAME ; int CHnServiceHandler::ServiceHandlerMatchesModel(class TDesC8 const &, class TDesC8 const &, class CLiwGenericParamList const *) const + ??1CHnServiceHandler@@UAE@XZ @ 20 NONAME ; CHnServiceHandler::~CHnServiceHandler(void) + ?NewLC@CHnServiceHandler@@SAPAV1@ABVTDesC8@@00W4TServiceMode@@PAVCLiwGenericParamList@@2@Z @ 21 NONAME ; class CHnServiceHandler * CHnServiceHandler::NewLC(class TDesC8 const &, class TDesC8 const &, class TDesC8 const &, enum TServiceMode, class CLiwGenericParamList *, class CLiwGenericParamList *) + ?Str8ToUint@HnConvUtils@@SAHABVTDesC8@@AAI@Z @ 22 NONAME ; int HnConvUtils::Str8ToUint(class TDesC8 const &, unsigned int &) + ?Str8ToInt@HnConvUtils@@SAHABVTDesC8@@AAJ@Z @ 23 NONAME ; int HnConvUtils::Str8ToInt(class TDesC8 const &, long &) + ?NewL@CHnServiceHandler@@SAPAV1@ABVTDesC8@@00W4TServiceMode@@PAVCLiwGenericParamList@@2@Z @ 24 NONAME ; class CHnServiceHandler * CHnServiceHandler::NewL(class TDesC8 const &, class TDesC8 const &, class TDesC8 const &, enum TServiceMode, class CLiwGenericParamList *, class CLiwGenericParamList *) + ?AddSubKeyL@CHnMdBaseKey@@QAEXPAV1@@Z @ 25 NONAME ; void CHnMdBaseKey::AddSubKeyL(class CHnMdBaseKey *) + ?Str8ToInt@HnConvUtils@@SAHABVTDesC8@@AAH@Z @ 26 NONAME ; int HnConvUtils::Str8ToInt(class TDesC8 const &, int &) + ?ToVariantL@CHnMdBaseKey@@UBEXAAVTLiwVariant@@@Z @ 27 NONAME ; void CHnMdBaseKey::ToVariantL(class TLiwVariant &) const + ?Str8ToStr@HnConvUtils@@SAPAVHBufC16@@ABVTDesC8@@@Z @ 28 NONAME ; class HBufC16 * HnConvUtils::Str8ToStr(class TDesC8 const &) + ?HandleNotifyL@CHnServiceHandler@@EAEHHHAAVCLiwGenericParamList@@ABV2@@Z @ 29 NONAME ; int CHnServiceHandler::HandleNotifyL(int, int, class CLiwGenericParamList &, class CLiwGenericParamList const &) + ?DeleteSuiteRelatedL@CHnRepositoryManager@@QAEHABVTDesC16@@@Z @ 30 NONAME ; int CHnRepositoryManager::DeleteSuiteRelatedL(class TDesC16 const &) + ?GetInt64L@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@HAA_J@Z @ 31 NONAME ; int HnLiwUtils::GetInt64L(class CLiwGenericParamList const &, class TDesC8 const &, int, long long &) + ??1CHnRepositoryManager@@UAE@XZ @ 32 NONAME ; CHnRepositoryManager::~CHnRepositoryManager(void) + ?CreateL@HnMdKeyFactory@@SAPAVCHnMdBaseKey@@ABVTDesC8@@0ABVTDesC16@@@Z @ 33 NONAME ; class CHnMdBaseKey * HnMdKeyFactory::CreateL(class TDesC8 const &, class TDesC8 const &, class TDesC16 const &) + ?GetVariantL@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@HAAVTLiwVariant@@@Z @ 34 NONAME ; int HnLiwUtils::GetVariantL(class CLiwGenericParamList const &, class TDesC8 const &, int, class TLiwVariant &) + ?GetStringL@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@AAVRBuf16@@@Z @ 35 NONAME ; int HnLiwUtils::GetStringL(class CLiwGenericParamList const &, class TDesC8 const &, class RBuf16 &) + ?GetStringL@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@HAAVRBuf16@@@Z @ 36 NONAME ; int HnLiwUtils::GetStringL(class CLiwGenericParamList const &, class TDesC8 const &, int, class RBuf16 &) + ?ExecuteL@CHnServiceHandler@@QAEHAAVCLiwGenericParamList@@AAVTRequestStatus@@@Z @ 37 NONAME ; int CHnServiceHandler::ExecuteL(class CLiwGenericParamList &, class TRequestStatus &) + ?VariantToStringL@HnLiwUtils@@SAHAAVTLiwVariant@@AAVRBuf8@@@Z @ 38 NONAME ; int HnLiwUtils::VariantToStringL(class TLiwVariant &, class RBuf8 &) + ?StrToInt@HnConvUtils@@SAHABVTDesC16@@AAH@Z @ 39 NONAME ; int HnConvUtils::StrToInt(class TDesC16 const &, int &) + ?CreateLC@HnMdKeyFactory@@SAPAVCHnMdBaseKey@@VTXmlEngElement@@@Z @ 40 NONAME ; class CHnMdBaseKey * HnMdKeyFactory::CreateLC(class TXmlEngElement) + ?StrToStr8LC@HnConvUtils@@SAPAVHBufC8@@ABVTDesC16@@@Z @ 41 NONAME ; class HBufC8 * HnConvUtils::StrToStr8LC(class TDesC16 const &) + ?EvaluateLC@CHnMdBaseKey@@QAEPAV1@ABVCLiwGenericParamList@@H@Z @ 42 NONAME ; class CHnMdBaseKey * CHnMdBaseKey::EvaluateLC(class CLiwGenericParamList const &, int) + ?GetVariantL@HnLiwUtils@@SAHABVCLiwGenericParamList@@ABVTDesC8@@AAVTLiwVariant@@@Z @ 43 NONAME ; int HnLiwUtils::GetVariantL(class CLiwGenericParamList const &, class TDesC8 const &, class TLiwVariant &) diff -r c743ef5928ba -r f966699dea19 menufw/hierarchynavigator/hnutilities/eabi/hnutilitiesu.def --- a/menufw/hierarchynavigator/hnutilities/eabi/hnutilitiesu.def Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/hierarchynavigator/hnutilities/eabi/hnutilitiesu.def Fri Feb 19 22:42:37 2010 +0200 @@ -27,22 +27,24 @@ _ZN14HnMdKeyFactory7CreateLERK6TDesC8S2_S2_ @ 26 NONAME _ZN14HnMdKeyFactory8CreateLCE14TXmlEngElement @ 27 NONAME _ZN17CHnServiceHandler13HandleNotifyLEiiR20CLiwGenericParamListRKS0_ @ 28 NONAME - _ZN17CHnServiceHandler4NewLERK6TDesC8S2_S2_12TServiceModeP20CLiwGenericParamListS5_ @ 29 NONAME - _ZN17CHnServiceHandler5NewLCERK6TDesC8S2_S2_12TServiceModeP20CLiwGenericParamListS5_ @ 30 NONAME - _ZN17CHnServiceHandler8ExecuteLEP18MLiwNotifyCallbacki @ 31 NONAME - _ZN17CHnServiceHandler8ExecuteLER20CLiwGenericParamListR14TRequestStatus @ 32 NONAME - _ZN17CHnServiceHandlerD0Ev @ 33 NONAME - _ZN17CHnServiceHandlerD1Ev @ 34 NONAME - _ZN17CHnServiceHandlerD2Ev @ 35 NONAME - _ZN20CHnRepositoryManager19DeleteSuiteRelatedLERK7TDesC16 @ 36 NONAME - _ZN20CHnRepositoryManager20ReadSuiteWidgetTypeLERK7TDesC16R18THnSuiteWidgetType @ 37 NONAME - _ZN20CHnRepositoryManager21StoreSuiteWidgetTypeLERK7TDesC1618THnSuiteWidgetType @ 38 NONAME - _ZN20CHnRepositoryManager4NewLEv @ 39 NONAME - _ZN20CHnRepositoryManager5NewLCEv @ 40 NONAME - _ZN20CHnRepositoryManagerD0Ev @ 41 NONAME - _ZN20CHnRepositoryManagerD1Ev @ 42 NONAME - _ZN20CHnRepositoryManagerD2Ev @ 43 NONAME - _ZNK12CHnMdBaseKey10ToVariantLER11TLiwVariant @ 44 NONAME - _ZNK12CHnMdBaseKey19ToGenericParamListLER20CLiwGenericParamList @ 45 NONAME - _ZThn4_N17CHnServiceHandler13HandleNotifyLEiiR20CLiwGenericParamListRKS0_ @ 46 NONAME + _ZN17CHnServiceHandler24PrepareForNextExecutionLERK6TDesC812TServiceModeP20CLiwGenericParamList @ 29 NONAME + _ZN17CHnServiceHandler4NewLERK6TDesC8S2_S2_12TServiceModeP20CLiwGenericParamListS5_ @ 30 NONAME + _ZN17CHnServiceHandler5NewLCERK6TDesC8S2_S2_12TServiceModeP20CLiwGenericParamListS5_ @ 31 NONAME + _ZN17CHnServiceHandler8ExecuteLEP18MLiwNotifyCallbacki @ 32 NONAME + _ZN17CHnServiceHandler8ExecuteLER20CLiwGenericParamListR14TRequestStatus @ 33 NONAME + _ZN17CHnServiceHandlerD0Ev @ 34 NONAME + _ZN17CHnServiceHandlerD1Ev @ 35 NONAME + _ZN17CHnServiceHandlerD2Ev @ 36 NONAME + _ZN20CHnRepositoryManager19DeleteSuiteRelatedLERK7TDesC16 @ 37 NONAME + _ZN20CHnRepositoryManager20ReadSuiteWidgetTypeLERK7TDesC16R18THnSuiteWidgetType @ 38 NONAME + _ZN20CHnRepositoryManager21StoreSuiteWidgetTypeLERK7TDesC1618THnSuiteWidgetType @ 39 NONAME + _ZN20CHnRepositoryManager4NewLEv @ 40 NONAME + _ZN20CHnRepositoryManager5NewLCEv @ 41 NONAME + _ZN20CHnRepositoryManagerD0Ev @ 42 NONAME + _ZN20CHnRepositoryManagerD1Ev @ 43 NONAME + _ZN20CHnRepositoryManagerD2Ev @ 44 NONAME + _ZNK12CHnMdBaseKey10ToVariantLER11TLiwVariant @ 45 NONAME + _ZNK12CHnMdBaseKey19ToGenericParamListLER20CLiwGenericParamList @ 46 NONAME + _ZNK17CHnServiceHandler26ServiceHandlerMatchesModelERK6TDesC8S2_PK20CLiwGenericParamList @ 47 NONAME + _ZThn4_N17CHnServiceHandler13HandleNotifyLEiiR20CLiwGenericParamListRKS0_ @ 48 NONAME diff -r c743ef5928ba -r f966699dea19 menufw/hierarchynavigator/hnutilities/inc/hnservicehandler.h --- a/menufw/hierarchynavigator/hnutilities/inc/hnservicehandler.h Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/hierarchynavigator/hnutilities/inc/hnservicehandler.h Fri Feb 19 22:42:37 2010 +0200 @@ -11,7 +11,7 @@ * * Contributors: * -* Description: +* Description: * */ @@ -22,7 +22,7 @@ //#include #include #include -#include +#include #include "hnglobals.h" @@ -36,7 +36,7 @@ class CHnServiceHandler; /** - * Class represeting request to LIW service. + * Class represeting request to LIW service. * The request can be synchronous or asynchronous. * * @since S60 5.0 @@ -59,7 +59,7 @@ * @return Fully cosntructed object. */ IMPORT_C static CHnServiceHandler* NewL( - const TDesC8& aService, const TDesC8& aInterface, + const TDesC8& aService, const TDesC8& aInterface, const TDesC8& aCommand, TServiceMode aMode, CLiwGenericParamList* aConstructor, CLiwGenericParamList* aServiceCommand ); @@ -98,7 +98,7 @@ * @return Error code. */ IMPORT_C TInt ExecuteL( CLiwGenericParamList& aOutParamList, TRequestStatus& aStatus ); - + /** * Executes the query on the service, with external * notification callback. @@ -110,17 +110,42 @@ */ IMPORT_C TInt ExecuteL( MLiwNotifyCallback* aCallback, TInt aCmdOptions = 0 ); - - + + /** * Executes the query on the service. * Deprecated - Do not Use this method!!!! Will be removed asap. - * + * * since S60 v5.0 * @return Error code. */ IMPORT_C TInt ExecuteL(); + + /** + * Checks if an action model matches an existing service. + * + * since S60 v5.0 + * @param aService service. + * @param aInterface interface. + * @param aConstructor constructor. + * @return true if an action model matches the service. + */ + IMPORT_C TBool ServiceHandlerMatchesModel( + const TDesC8& aService, + const TDesC8& aInterface, + const CLiwGenericParamList* aConstructor ) const; + /** + * Allows for reusing the object when a request needs to be invoked on + * the same interface of the same service. + * + * @param aCommand Request to the Service. + * @param aMode Asynchronous or Synchronous Request. + * @param aServiceCommand Additional Parameters for the Request. + */ + IMPORT_C void PrepareForNextExecutionL( const TDesC8& aCommand, + TServiceMode aMode, CLiwGenericParamList* aServiceCommand ); + private: /** @@ -129,7 +154,7 @@ * @since S60 5.0 * @param aMode Synchronous or asynchronous. */ - CHnServiceHandler( TServiceMode aMode ); + CHnServiceHandler( TServiceMode aMode ); /** @@ -140,7 +165,7 @@ * @param aInterface Interface name. * @param aCommandName Request to the Service. * @param aConstructor Parameters used during Service construction. - * @param aServiceCommand Additional Parameters for the Request. + * @param aServiceCommand Additional Parameters for the Request. */ void ConstructL( const TDesC8& aService, const TDesC8& aInterface, @@ -148,7 +173,7 @@ CLiwGenericParamList* aConstructor, CLiwGenericParamList* aServiceCommand ); - + /** * Handles notifications caused by an asynchronous Request. * @@ -168,12 +193,12 @@ /** * Creates interface. - * + * * @param aConstructor constructor * @return Error code. */ TInt SetServiceInterfaceL( CLiwGenericParamList* aConstructor ); - + private: // data /** @@ -187,7 +212,7 @@ * Own. */ RBuf8 iInterfaceName; - + /** * Command (Request) name. * Own. @@ -198,62 +223,62 @@ * Service mode. */ TServiceMode iMode; - + /** * Stores input parameters (not data) of the service search method\ * (ExecuteServiceCmdL). - * Own. + * Own. */ CLiwGenericParamList* iConstructor; /** - * + * * Own. */ CLiwGenericParamList* iCommand; - + /** * Parameters for the Request. * Own. */ CLiwGenericParamList* iInput; - + /** * Request results from ExecuteL(); * Own. */ CLiwGenericParamList* iOutputForAS; - + /** - * Request results from + * Request results from * ExecuteL( CLiwGenericParamList& aOutParamList, TRequestStatus& aStatus ). * Own. */ CLiwGenericParamList* iOutputForAO; - + /** - * Service interface. + * Service interface. */ MLiwInterface* iServiceInterface; - + /** * Service Handler. * Own. */ CLiwServiceHandler* iServiceHandler; - + /** * Client status. * Not Own. */ TRequestStatus* iClientStatus; - + /** * Waits for asynchronous queries. * Own. */ CActiveSchedulerWait* iWait; - + }; #endif // C_HNMDSERVICEHANDLER_H diff -r c743ef5928ba -r f966699dea19 menufw/hierarchynavigator/hnutilities/src/hnservicehandler.cpp --- a/menufw/hierarchynavigator/hnutilities/src/hnservicehandler.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/hierarchynavigator/hnutilities/src/hnservicehandler.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -119,7 +119,7 @@ delete iConstructor; delete iCommand; delete iOutputForAS; - + if ( iServiceHandler ) { iServiceHandler->Reset(); @@ -131,6 +131,59 @@ // // --------------------------------------------------------------------------- // +EXPORT_C TBool CHnServiceHandler::ServiceHandlerMatchesModel( + const TDesC8& aService, + const TDesC8& aInterface, + const CLiwGenericParamList* aConstructor ) const + { + __ASSERT_DEBUG( aConstructor, User::Invariant() ); + + TBool ret = ( aInterface == iInterfaceName && aService == iServiceName ); + + if ( ret ) + { + const TInt count = iConstructor->Count(); + ret = ( count == aConstructor->Count() ); + for ( TInt i = 0; ret && i < count; ++i ) + { + ret = ( ( *iConstructor )[i] == ( *aConstructor )[i] ); + } + } + + return ret; + } + +// --------------------------------------------------------------------------- +// +// --------------------------------------------------------------------------- +// +EXPORT_C void CHnServiceHandler::PrepareForNextExecutionL( + const TDesC8& aCommand, TServiceMode aMode, + CLiwGenericParamList* aServiceCommand ) + { + __ASSERT_DEBUG( aServiceCommand && aServiceCommand != iCommand, + User::Invariant() ); + + { // braces for scope only + RBuf8 copy; + CleanupClosePushL( copy ); + copy.CreateL( aCommand ); + iCommandName.Swap( copy ); + CleanupStack::PopAndDestroy( © ); + } + + iMode = aMode; + + delete iCommand; + iCommand = aServiceCommand; + // Ownership of aServiceCommand has been taken. Do not add any piece of + // code that could leave after this line. + } + +// --------------------------------------------------------------------------- +// +// --------------------------------------------------------------------------- +// EXPORT_C TInt CHnServiceHandler::ExecuteL( MLiwNotifyCallback* aCallback, TInt aCmdOptions) { @@ -205,7 +258,7 @@ else { // KErrNone ensures that CHnQueryResultCollector::HandleQueryResultsL() - // is called, empty results are added to list, and + // is called, empty results are added to list, and // CHnMdItem::ResultsCollectedL doesn't get confused User::RequestComplete( iClientStatus, KErrNone ); } @@ -227,7 +280,7 @@ { iOutputForAO->Reset(); iOutputForAO->AppendL( aEventParamList ); - + TLiwGenericParam param; TInt error(KErrNone); param.PushL(); diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/matrixmenu/src/mmappui.cpp --- a/menufw/menufwui/matrixmenu/src/mmappui.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/matrixmenu/src/mmappui.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -12,8 +12,8 @@ * Contributors: * * Description: Application UI class -* Version : %version: MM_176.1.28.1.61 % << Don't touch! Updated by Synergy at check-out. -* Version : %version: MM_176.1.28.1.61 % << Don't touch! Updated by Synergy at check-out. +* Version : %version: MM_176.1.28.1.65 % << Don't touch! Updated by Synergy at check-out. +* Version : %version: MM_176.1.28.1.65 % << Don't touch! Updated by Synergy at check-out. * */ @@ -611,7 +611,7 @@ GfxTransEffect::BeginFullScreen( effect, rect, AknTransEffect::EParameterType, - AknTransEffect::GfxTransParam( appUid ) ); + AknTransEffect::GfxTransParam( appUid , KUidMatrixMenuApp ) ); } } @@ -1131,14 +1131,6 @@ iCurrentContainer->HandleItemRemovalL(); iCurrentContainer->CancelDragL( EFalse ); - if( typeCurr == EItemTypeParentFolder ) - { - StartLayoutSwitchFullScreen( EMenuCloseFolderEffect ); - } - else - { - StartLayoutSwitchFullScreen( EMenuOpenFolderEffect ); - } iHNInterface->TriggerHnEventL( KKeyIdMoveInto, itemId, eventParameters ); iMakeHightlightedItemFullyVisible = ETrue; } @@ -2833,6 +2825,10 @@ paramList->AppendL(command); HandleRequestL(*paramList); CleanupStack::PopAndDestroy(paramList); + if( iCurrentContainer ) + { + iCurrentContainer->HandleResourceChange( KAknsMessageSkinChange ); + } } // --------------------------------------------------------------------------- @@ -2957,7 +2953,7 @@ } if( IsEditMode() && iCurrentContainer->IsDraggable() ) { - iCurrentContainer->CancelDragL( EFalse ); + HandleDragStopL( iCurrentContainer->GetHighlight() ); iCurrentContainer->DrawNow(); } iCurrentContainer->SetHasFocusL( EFalse ); @@ -2990,6 +2986,7 @@ if (skinInstance && !skinInstance->IsUpdateInProgress()) { RefreshIconsL(); + } } } diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/inc/mmcacheforitem.h --- a/menufw/menufwui/mmwidgets/inc/mmcacheforitem.h Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/inc/mmcacheforitem.h Fri Feb 19 22:42:37 2010 +0200 @@ -77,11 +77,14 @@ inline TBool IsValid() const; /** - * Marks this cache as valid or invalid. - * - * @param aValid (Self-explanatory). - */ - inline void SetValidL( TBool aValid ); + * Marks this cache object as valid. + */ + inline void MarkAsValidL(); + + /** + * Marks this cache object as invalid. + */ + inline void MarkAsInvalid(); /** * Returns information whether at the moment of updating this cache object @@ -249,7 +252,7 @@ /** * Array of icons stored in the icon holders which are in iIconHolderList. * This member is only valid when this cache object is marked as valid - * using the SetValidL method. + * using the MarkAsValidL method. * Own. */ CArrayPtr* iIconList; diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/inc/mmcacheforitem.inl --- a/menufw/menufwui/mmwidgets/inc/mmcacheforitem.inl Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/inc/mmcacheforitem.inl Fri Feb 19 22:42:37 2010 +0200 @@ -48,15 +48,12 @@ // // ----------------------------------------------------------------------------- // -inline void CMmCacheForItem::SetValidL( TBool aValid ) +inline void CMmCacheForItem::MarkAsValidL() { - if ( !!iIsValid != !!aValid ) // Ex-OR + if ( !iIsValid ) { - iIsValid = aValid; - if ( iIsValid ) - { - UpdateIconListL(); - } + iIsValid = ETrue; + UpdateIconListL(); } } @@ -64,6 +61,15 @@ // // ----------------------------------------------------------------------------- // +inline void CMmCacheForItem::MarkAsInvalid() + { + iIsValid = EFalse; + } + +// ----------------------------------------------------------------------------- +// +// ----------------------------------------------------------------------------- +// inline TBool CMmCacheForItem::IsCurrent() { return iIsCurrent; diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/inc/mmgrid.h --- a/menufw/menufwui/mmwidgets/inc/mmgrid.h Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/inc/mmgrid.h Fri Feb 19 22:42:37 2010 +0200 @@ -12,7 +12,7 @@ * Contributors: * * Description: CMmGrid declaration -* Version : %version: MM_32.1.22 % << Don't touch! Updated by Synergy at check-out. +* Version : %version: MM_32.1.23 % << Don't touch! Updated by Synergy at check-out. * */ @@ -415,12 +415,12 @@ * This function typically calls @c ProcessScrollEventL, * which actually scrolls the view and causes a redraw. */ - void HandleRedrawTimerEvent(); + void HandleRedrawTimerEventL(); private: /** * Callback function for @c iRedrawTimer. - * It simply calls @c HandleRedrawTimerEvent and returns 0. + * It simply calls @c HandleRedrawTimerEventL and returns 0. * * @param aPtr A pointer to CMmGrid object. * @return 0 (always). diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/inc/mmlistbox.h --- a/menufw/menufwui/mmwidgets/inc/mmlistbox.h Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/inc/mmlistbox.h Fri Feb 19 22:42:37 2010 +0200 @@ -12,7 +12,7 @@ * Contributors: * * Description: CMmListBox -* Version : %version: MM_22.1.16 % << Don't touch! Updated by Synergy at check-out. +* Version : %version: MM_22.1.17 % << Don't touch! Updated by Synergy at check-out. * */ @@ -389,12 +389,12 @@ * This function typically calls @c ProcessScrollEventL, * which actually scrolls the view and causes a redraw. */ - void HandleRedrawTimerEvent(); + void HandleRedrawTimerEventL(); private: /** * Callback function for @c iRedrawTimer. - * It simply calls @c HandleRedrawTimerEvent and returns 0. + * It simply calls @c HandleRedrawTimerEventL and returns 0. * * @param aPtr A pointer to CMmListBox object. * @return 0 (always). diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/inc/mmwidgetcontainer.h --- a/menufw/menufwui/mmwidgets/inc/mmwidgetcontainer.h Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/inc/mmwidgetcontainer.h Fri Feb 19 22:42:37 2010 +0200 @@ -12,7 +12,7 @@ * Contributors: * * Description: -* Version : %version: MM_48.1.37 % << Don't touch! Updated by Synergy at check-out. +* Version : %version: MM_48.1.38 % << Don't touch! Updated by Synergy at check-out. * */ @@ -1000,6 +1000,16 @@ * Observer to notify about long tap events. */ MMmLongTapObserver* iLongTapObserver; + + /** + * Stores previously set highlight visibility. + * ETrue - hightlight visible, EFalse - highlight disabled. + * Please note that in most cases it is better to read + * ESingleClickDisabledHighlight flag of itemdrawer than rely + * on this member variable to determine if highlight is visible + * (@c IsHighlightVisible). + */ + TBool iPreviousHighlightVisibility; }; diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/inc/mmwidgetsconstants.h --- a/menufw/menufwui/mmwidgets/inc/mmwidgetsconstants.h Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/inc/mmwidgetsconstants.h Fri Feb 19 22:42:37 2010 +0200 @@ -12,7 +12,7 @@ * Contributors: * * Description: Constants for the matrixmenu -* Version : %version: 33.1.11 % << Don't touch! Updated by Synergy at check-out. +* Version : %version: 33.1.12 % << Don't touch! Updated by Synergy at check-out. * */ @@ -136,7 +136,11 @@ * Number of columns in landscape/non-zoom mode; */ const TInt KColsLandscapeZoomNormal(4); - + + /** + * Focus based scrolling item threshold for grid. + */ + const TReal KFocusScrollingThreshold( 0.27 ); } /** @@ -154,6 +158,11 @@ * Default highlight in 4x5 grid. */ const TInt KCols(1); + + /** + * Focus based scrolling item threshold for list. + */ + const TReal KFocusScrollingThreshold( 0.55 ); } /** @@ -202,16 +211,6 @@ const TInt KDragTextAlpha( 50 ); /** - * Focus based scrolling item threshold. - */ - const TReal KFocusScrollingThreshold( 0.55 ); - - /** - * Focus based scrolling item threshold for listbox landscape mode. - */ - const TReal KFocusScrollingThresholdListboxLanscape( 1.0 ); - - /** * Value of drag ignore. */ const TInt KDragIgnoreRectValue(200); diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/src/mmcacheforitem.cpp --- a/menufw/menufwui/mmwidgets/src/mmcacheforitem.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/src/mmcacheforitem.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -133,7 +133,7 @@ if ( iSubcellsSetupCode != aSubcellsSetupCode || (!!iIsCurrent) != (!!aIsItemCurrent) ) { - SetValidL( EFalse ); + MarkAsInvalid(); } } diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/src/mmgrid.cpp --- a/menufw/menufwui/mmwidgets/src/mmgrid.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/src/mmgrid.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -12,7 +12,7 @@ * Contributors: * * Description: -* Version : %version: MM_98 % << Don't touch! Updated by Synergy at check-out. +* Version : %version: MM_101 % << Don't touch! Updated by Synergy at check-out. * */ @@ -257,13 +257,13 @@ // void CMmGrid::HandlePointerEventInEditModeL( const TPointerEvent& aPointerEvent ) { + CMmWidgetContainer* parent = static_cast( Parent() ); if ( aPointerEvent.iType == TPointerEvent::EButton1Down ) { iButton1DownPos = aPointerEvent.iPosition; } else if ( aPointerEvent.iType == TPointerEvent::EButton1Up ) { - CMmWidgetContainer* parent = static_cast( Parent() ); TPoint dragDelta = iButton1DownPos - aPointerEvent.iPosition; if ( Abs( dragDelta.iY ) > KDragTreshold || parent->LongTapInProgress() ) { @@ -275,7 +275,17 @@ if ( aPointerEvent.iType == TPointerEvent::EButton1Up || aPointerEvent.iType == TPointerEvent::EButton1Down ) { + TBool highlightWasVisible = parent->IsHighlightVisible(); CAknGrid::HandlePointerEventL( aPointerEvent ); + // Tricky: Do not allow the base class implementation of HandlePointerEventL + // to remove the highlight on EButton1Up event when context menu + // is displayed for an item + if ( aPointerEvent.iType == TPointerEvent::EButton1Up && + highlightWasVisible && parent->LongTapInProgress() + && !parent->IsHighlightVisible() ) + { + ItemDrawer()->ClearFlags( CListItemDrawer::ESingleClickDisabledHighlight ); + } } else if ( View()->XYPosToItemIndex( aPointerEvent.iPosition, itemUnderPointerIndex ) ) @@ -408,7 +418,7 @@ const TPointerEvent& aPointerEvent ) const { TInt topScrollingTreshold = Rect().iTl.iY - + ( MmEffects::KFocusScrollingThreshold + + ( MmGrid::KFocusScrollingThreshold * TReal( View()->ItemSize().iHeight ) ); return ( aPointerEvent.iPosition.iY < topScrollingTreshold ); @@ -422,7 +432,7 @@ const TPointerEvent& aPointerEvent ) const { TInt bottomScrollingTreshold = Rect().iBr.iY - - ( MmEffects::KFocusScrollingThreshold + - ( MmGrid::KFocusScrollingThreshold * TReal( View()->ItemSize().iHeight ) ); return ( aPointerEvent.iPosition.iY > bottomScrollingTreshold ); @@ -1016,7 +1026,7 @@ // // ----------------------------------------------------------------------------- // -void CMmGrid::HandleRedrawTimerEvent() +void CMmGrid::HandleRedrawTimerEventL() { if ( iSkippedScrollbarEventsCount ) { @@ -1033,7 +1043,9 @@ TInt CMmGrid::RedrawTimerCallback( TAny* aPtr ) { CMmGrid* self = static_cast( aPtr ); - self->HandleRedrawTimerEvent(); + TRAP_IGNORE( self->HandleRedrawTimerEventL() ); + // Do not bother returning a meaningful error code, CPeriodic will ignore it + // anyway. return 0; } diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/src/mmitemsdatacache.cpp --- a/menufw/menufwui/mmwidgets/src/mmitemsdatacache.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/src/mmitemsdatacache.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -110,7 +110,7 @@ const TInt count = iItemCacheArr.Count(); for ( TInt i = 0; i < count; ++i ) { - iItemCacheArr[i]->SetValidL( EFalse ); + iItemCacheArr[i]->MarkAsInvalid(); } } diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/src/mmlistbox.cpp --- a/menufw/menufwui/mmwidgets/src/mmlistbox.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/src/mmlistbox.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -135,13 +135,13 @@ void CMmListBox::HandlePointerEventInEditModeL( const TPointerEvent& aPointerEvent ) { + CMmWidgetContainer* parent = static_cast( Parent() ); if ( aPointerEvent.iType == TPointerEvent::EButton1Down ) { iButton1DownPos = aPointerEvent.iPosition; } else if ( aPointerEvent.iType == TPointerEvent::EButton1Up ) { - CMmWidgetContainer* parent = static_cast( Parent() ); TPoint dragDelta = iButton1DownPos - aPointerEvent.iPosition; if ( Abs( dragDelta.iY ) > KDragTreshold || parent->LongTapInProgress() ) { @@ -153,7 +153,17 @@ if ( aPointerEvent.iType == TPointerEvent::EButton1Up || aPointerEvent.iType == TPointerEvent::EButton1Down ) { + TBool highlightWasVisible = parent->IsHighlightVisible(); CEikFormattedCellListBoxTypedef::HandlePointerEventL( aPointerEvent ); + // Tricky: Do not allow the base class implementation of HandlePointerEventL + // to remove the highlight on EButton1Up event when context menu + // is displayed for an item + if ( aPointerEvent.iType == TPointerEvent::EButton1Up && + highlightWasVisible && parent->LongTapInProgress() + && !parent->IsHighlightVisible() ) + { + ItemDrawer()->ClearFlags( CListItemDrawer::ESingleClickDisabledHighlight ); + } } else if ( View()->XYPosToItemIndex( aPointerEvent.iPosition, itemUnderPointerIndex ) ) @@ -200,7 +210,7 @@ const TPointerEvent& aPointerEvent ) const { TInt topScrollingTreshold = Rect().iTl.iY - + ( MmEffects::KFocusScrollingThreshold + + ( MmListBox::KFocusScrollingThreshold * TReal( View()->ItemSize().iHeight ) ); return ( aPointerEvent.iPosition.iY < topScrollingTreshold ); @@ -214,7 +224,7 @@ const TPointerEvent& aPointerEvent ) const { TInt bottomScrollingTreshold = Rect().iBr.iY - - ( MmEffects::KFocusScrollingThreshold + - ( MmListBox::KFocusScrollingThreshold * TReal( View()->ItemSize().iHeight ) ); return ( aPointerEvent.iPosition.iY > bottomScrollingTreshold ); @@ -384,7 +394,7 @@ // // ----------------------------------------------------------------------------- // -void CMmListBox::HandleRedrawTimerEvent() +void CMmListBox::HandleRedrawTimerEventL() { if ( iSkippedScrollbarEventsCount ) { @@ -401,7 +411,9 @@ TInt CMmListBox::RedrawTimerCallback( TAny* aPtr ) { CMmListBox* self = static_cast( aPtr ); - self->HandleRedrawTimerEvent(); + TRAP_IGNORE( self->HandleRedrawTimerEventL() ); + // Do not bother returning a meaningful error code, CPeriodic will ignore it + // anyway. return 0; } diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/src/mmlistboxitemdrawer.cpp --- a/menufw/menufwui/mmwidgets/src/mmlistboxitemdrawer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/src/mmlistboxitemdrawer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -129,6 +129,7 @@ { iItemsDataCache->Invalidate(); // this is needed to get iColors initialized on first use: + iLastDrawnItemWasFloating = ETrue; } // ----------------------------------------------------------------------------- @@ -800,17 +801,7 @@ const TDesC8& mm_template = iMmModel->GetAttributeAsText (aItemIndex, KMmTemplate8); TRect viewRect = iWidget->View()->ViewRect(); - - TBool landscapeOrientation = viewRect.Width() > viewRect.Height(); - // Layout_Meta_Data::IsLandscapeOrientation cannot be used here because it - // might happen that GetSize (this method) gets called immediately after - // layout change but before AppUi calls SetRect on the container of iWidget - // (Layout_Meta_Data::IsLandscapeOrientation always reflects the current state, - // whereas ViewRect might sometimes be out of date). - // In such situation iTemplateLibrary->GetSize (called just below) would - // cause the template library to fill the internal cache for landscape mode - // with parameters calculated according to the outdated ViewRect. - + TBool landscapeOrientation = Layout_Meta_Data::IsLandscapeOrientation(); if ( iTemplateLibrary->GetSize( size, iWidgetType, mm_template, landscapeOrientation, aItemIsCurrent, viewRect ) @@ -1340,7 +1331,7 @@ TInt aItemIndex ) const { CMmCacheForItem* cache = iItemsDataCache->GetItemCacheL( aItemIndex ); - cache->SetValidL( EFalse ); + cache->MarkAsInvalid(); const TDesC8& mmTemplate = iMmModel->GetAttributeAsText( aItemIndex, KMmTemplate8 ); if ( !mmTemplate.Compare( KNullDesC8 ) || !mmTemplate.Compare( KEmpty8 ) ) @@ -1420,7 +1411,7 @@ cache->SetSubcellsSetupCode( iLastSubcellsSetupCode ); // the line below is here only to make the cached information complete GetItemSize( aItemIndex, aItemIsCurrent ); - cache->SetValidL( ETrue ); + cache->MarkAsValidL(); } // ----------------------------------------------------------------------------- diff -r c743ef5928ba -r f966699dea19 menufw/menufwui/mmwidgets/src/mmwidgetcontainer.cpp --- a/menufw/menufwui/mmwidgets/src/mmwidgetcontainer.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menufwui/mmwidgets/src/mmwidgetcontainer.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -12,7 +12,7 @@ * Contributors: * * Description: -* Version : %version: MM_71.1.17.1.51 % << Don't touch! Updated by Synergy at check-out. +* Version : %version: MM_71.1.17.1.55 % << Don't touch! Updated by Synergy at check-out. * */ @@ -237,7 +237,7 @@ if ( aType == KEikDynamicLayoutVariantSwitch && !IsHighlightVisible() ) { - SetDefaultHighlightL( EFalse ); + TRAP_IGNORE( SetDefaultHighlightL( EFalse ) ); } } @@ -612,7 +612,7 @@ TInt index = KErrNotFound; TBool itemExists = iWidget->View()->XYPosToItemIndex( aPointerEvent.iPosition, index ); - + if ( iLongTapDetector ) { if ( aPointerEvent.iType == TPointerEvent::EButton1Down ) @@ -733,38 +733,43 @@ { // activate the model CHnSuiteModel* suiteModel = GetMmModel()->GetSuiteModel(); - if ( suiteModel ) { suiteModel->SetActiveL( aEnable ); } -#ifdef RD_UI_TRANSITION_EFFECTS_LIST - MAknListBoxTfxInternal *transApi = CAknListLoader::TfxApiInternal( - iDrawer->Gc() ); -#endif - if ( !aEnable ) + + if ( ( !!aEnable != !!iPreviousHighlightVisibility ) // Ex-OR + || ( !!aEnable != !!IsHighlightVisible() ) ) // Ex-OR { - iWidget->View()->ItemDrawer()->SetFlags( - CListItemDrawer::ESingleClickDisabledHighlight ); #ifdef RD_UI_TRANSITION_EFFECTS_LIST - if ( transApi ) - { - transApi->Remove( MAknListBoxTfxInternal::EListHighlight ); - } + MAknListBoxTfxInternal *transApi = CAknListLoader::TfxApiInternal( + iDrawer->Gc() ); #endif - } - else - { - iWidget->View()->ItemDrawer()->ClearFlags( - CListItemDrawer::ESingleClickDisabledHighlight ); - } + if ( !aEnable ) + { + iWidget->View()->ItemDrawer()->SetFlags( + CListItemDrawer::ESingleClickDisabledHighlight ); +#ifdef RD_UI_TRANSITION_EFFECTS_LIST + if ( transApi ) + { + transApi->Remove( MAknListBoxTfxInternal::EListHighlight ); + } +#endif + } + else + { + iWidget->View()->ItemDrawer()->ClearFlags( + CListItemDrawer::ESingleClickDisabledHighlight ); + } - if ( IsVisible() ) - { - TInt highlight = GetHighlight(); - CListBoxView* view = Widget()->View(); - Widget()->DrawNow( TRect( view->ItemPos( highlight ), - view->ItemSize( highlight ) ) ); + if ( IsVisible() ) + { + TInt highlight = GetHighlight(); + CListBoxView* view = Widget()->View(); + Widget()->DrawNow( TRect( view->ItemPos( highlight ), + view->ItemSize( highlight ) ) ); + } + iPreviousHighlightVisibility = aEnable; } } @@ -774,7 +779,7 @@ // EXPORT_C TBool CMmWidgetContainer::IsHighlightVisible() { - return !( iWidget->View()->ItemDrawer()->Flags() & + return !( iWidget->View()->ItemDrawer()->Flags() & CListItemDrawer::ESingleClickDisabledHighlight ); } @@ -1595,7 +1600,7 @@ iWidget->MakeVisible(aVisible); if ( !aVisible ) { - SetHighlightVisibilityL( EFalse ); + TRAP_IGNORE( SetHighlightVisibilityL( EFalse ) ); } } diff -r c743ef5928ba -r f966699dea19 menufw/menusuites/foldersuite/data/matrixmenudata.xml --- a/menufw/menusuites/foldersuite/data/matrixmenudata.xml Tue Feb 02 00:04:13 2010 +0200 +++ b/menufw/menusuites/foldersuite/data/matrixmenudata.xml Fri Feb 19 22:42:37 2010 +0200 @@ -17,6 +17,8 @@ + + - - - - - + + + + + + + + diff -r c743ef5928ba -r f966699dea19 taskswitcher/contextengine/tsfswserver/engine/inc/tsfswengine.h --- a/taskswitcher/contextengine/tsfswserver/engine/inc/tsfswengine.h Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/contextengine/tsfswserver/engine/inc/tsfswengine.h Fri Feb 19 22:42:37 2010 +0200 @@ -190,6 +190,13 @@ TInt FindParentWgId( TInt aWgId ); /** + * Returns the most top parent's wg id or KErrNotFound. + * @param aWgId a valid window group id + * @return parent wg id or KErrNotFound if there is no parent + */ + TInt FindMostTopParentWgId( TInt aWgId ); + + /** * Finds out the application name. * @param aWindowName window group name or NULL * @param aAppUId application uid @@ -217,6 +224,16 @@ void AssignScreenshotHandle( TInt aWgIdForScreenshot, TInt aBitmapHandle ); /** + * Checks if the app to which the screenshot belongs is in the task list + * and updates the entry when found. + * @param aWgIdForScreenshot wgid for the screenshot + * @param aBitmapHandle handle for screenshot bitmap + * @param aAsigned result of operation + */ + void AssignScreenshotHandle( TInt aWgIdForScreenshot, + TInt aBitmapHandle, TBool& aAsigned ); + + /** * Returns the bitmap handle for the screenshot belonging to the given app * or 0 if not (yet) found. * @param aWgIdForApp a window group id (from the window group list) diff -r c743ef5928ba -r f966699dea19 taskswitcher/contextengine/tsfswserver/engine/src/tsfswengine.cpp --- a/taskswitcher/contextengine/tsfswserver/engine/src/tsfswengine.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/contextengine/tsfswserver/engine/src/tsfswengine.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -680,7 +680,7 @@ for ( TInt i( 0 ); i < count; i++ ) { RWsSession::TWindowGroupChainInfo info = allWgIds[i]; - if ( info.iId == aWgId ) + if ( info.iId == aWgId && info.iParentId > 0) { parent = info.iParentId; break; @@ -692,6 +692,25 @@ } // -------------------------------------------------------------------------- +// CTsFswEngine::FindMostTopParentWgId +// -------------------------------------------------------------------------- +// +TInt CTsFswEngine::FindMostTopParentWgId( TInt aWgId ) + { + TInt parent( KErrNotFound ); + parent = FindParentWgId( aWgId ); + if( parent != KErrNotFound) + { + TInt topParent = FindMostTopParentWgId(parent); + if( topParent != KErrNotFound ) + { + parent = topParent; + } + } + return parent; + } + +// -------------------------------------------------------------------------- // CTsFswEngine::FindAppNameLC // -------------------------------------------------------------------------- // @@ -901,30 +920,24 @@ // -------------------------------------------------------------------------- // CTsFswEngine::AssignScreenshotHandle // Called when a screenshot arrives to check if there is a corresponding -// application in the task list. +// application in the task list. Firstly try to match screenshot into parental +// application then into standalone one. // -------------------------------------------------------------------------- // void CTsFswEngine::AssignScreenshotHandle( TInt aWgIdForScreenshot, TInt aBitmapHandle ) { TBool changed = EFalse; - TInt parentWgId = FindParentWgId( aWgIdForScreenshot ); + TInt parentWgId = FindMostTopParentWgId( aWgIdForScreenshot ); // now parentWgId is a valid wgid or KErrNotFound (-1) - for ( TInt i = 0, ie = iData.Count(); i != ie; ++i ) - { - if ( iData[i]->Widget() ) - { - // Do not do anything for now => no screenshot for widgets. - continue; - } - TInt appWgId = iData[i]->WgId(); - if ( appWgId == aWgIdForScreenshot || appWgId == parentWgId ) - { - iData[i]->SetScreenshotHandle( aBitmapHandle ); - changed = ETrue; - break; - } - } + if (parentWgId != KErrNotFound) + { + AssignScreenshotHandle( parentWgId, aBitmapHandle, changed ); + } + if (!changed) + { + AssignScreenshotHandle( aWgIdForScreenshot, aBitmapHandle, changed ); + } if ( changed ) { iObserver.FswDataChanged(); @@ -932,6 +945,34 @@ } // -------------------------------------------------------------------------- +// CTsFswEngine::AssignScreenshotHandle +// Called when a screenshot arrives to check if there is a corresponding +// application in the task list. It might be tried to be match into parental +// or standalone application. +// -------------------------------------------------------------------------- +// +void CTsFswEngine::AssignScreenshotHandle(TInt aWgIdForScreenshot, + TInt aBitmapHandle, TBool& aAsigned) + { + aAsigned = EFalse; + for (TInt i = 0, ie = iData.Count(); i != ie; ++i) + { + if (iData[i]->Widget()) + { + // Do not do anything for now => no screenshot for widgets. + continue; + } + TInt appWgId = iData[i]->WgId(); + if (appWgId == aWgIdForScreenshot) + { + iData[i]->SetScreenshotHandle(aBitmapHandle); + aAsigned = ETrue; + break; + } + } + } + +// -------------------------------------------------------------------------- // CTsFswEngine::LookupScreenshotHandle // Called to check if there is a screenshot already stored for the given // app. (or a screenshot with a wgid for which aWgIdForApp is the parent) diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/rom/taskswitcher.iby --- a/taskswitcher/taskswitcherui/rom/taskswitcher.iby Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/rom/taskswitcher.iby Fri Feb 19 22:42:37 2010 +0200 @@ -20,8 +20,8 @@ // AknCapServer alternate fast swap plugin ECOM_PLUGIN( tsappecom.dll, tsappecom.rsc ) -data=DATAZ_/private/10003a3f/apps/tstaskswitcher_reg.rsc private/10003a3f/import/apps/tstaskswitcher_reg.rsc -file=ABI_DIR/BUILD_DIR/taskswitcher.exe PROGRAMS_DIR/hgteleport.exe +data=DATAZ_/private/10003a3f/apps/taskswitcher_reg.rsc private/10003a3f/import/apps/taskswitcher_reg.rsc +file=ABI_DIR/BUILD_DIR/taskswitcher.exe PROGRAMS_DIR/taskswitcher.exe // backup registration data=DATAZ_/private/20016BF0/backup_registration.xml private/20016BF0/backup_registration.xml diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/rom/taskswitcherresources.iby --- a/taskswitcher/taskswitcherui/rom/taskswitcherresources.iby Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/rom/taskswitcherresources.iby Fri Feb 19 22:42:37 2010 +0200 @@ -18,6 +18,6 @@ #define TASKSWITCHERRES_IBY // resources for taskswitcher app -data=DATAZ_/APP_RESOURCE_DIR/tstaskswitcher.rsc APP_RESOURCE_DIR/hgteleport.rsc +data=DATAZ_/APP_RESOURCE_DIR/taskswitcher.rsc APP_RESOURCE_DIR/taskswitcher.rsc #endif diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/sis/stubs/taskswitcher_stub.pkg --- a/taskswitcher/taskswitcherui/sis/stubs/taskswitcher_stub.pkg Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/sis/stubs/taskswitcher_stub.pkg Fri Feb 19 22:42:37 2010 +0200 @@ -32,9 +32,9 @@ ;Unique Vendor name :"Nokia" -""-"Z:\sys\bin\hgteleport.exe" -""-"Z:\resource\apps\hgteleport.r??" -""-"Z:\private\10003a3f\import\apps\tstaskswitcher_reg.rsc" +""-"Z:\sys\bin\taskswitcher.exe" +""-"Z:\resource\apps\taskswitcher.r??" +""-"Z:\private\10003a3f\import\apps\taskswitcher_reg.rsc" ""-"Z:\sys\bin\tsappecom.dll" ""-"Z:\resource\plugins\tsappecom.rsc" diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/sis/stubs/taskswitcher_stub.sis Binary file taskswitcher/taskswitcherui/sis/stubs/taskswitcher_stub.sis has changed diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/sis/taskswitcher.pkg --- a/taskswitcher/taskswitcherui/sis/taskswitcher.pkg Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/sis/taskswitcher.pkg Fri Feb 19 22:42:37 2010 +0200 @@ -25,9 +25,9 @@ ;Unique Vendor name :"Nokia" -"/epoc32/release/armv5/urel/taskswitcher.exe" - "!:\sys\bin\hgteleport.exe" -"/epoc32/data/z/resource/apps/tstaskswitcher.rsc" - "!:\resource\apps\hgteleport.rsc" -"/epoc32/data/z/private/10003a3f/apps/tstaskswitcher_reg.rsc" - "!:\private\10003a3f\import\apps\tstaskswitcher_reg.rsc" +"/epoc32/release/armv5/urel/taskswitcher.exe" - "!:\sys\bin\taskswitcher.exe" +"/epoc32/data/z/resource/apps/taskswitcher.rsc" - "!:\resource\apps\taskswitcher.rsc" +"/epoc32/data/z/private/10003a3f/apps/taskswitcher_reg.rsc" - "!:\private\10003a3f\import\apps\taskswitcher_reg.rsc" "/epoc32/release/armv5/urel/tsappecom.dll" - "!:\sys\bin\tsappecom.dll" "/epoc32/data/z/resource/plugins/tsappecom.rsc" - "!:\resource\plugins\tsappecom.rsc" diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/data/taskswitcher.rss --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/data/taskswitcher.rss Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,282 @@ +/* +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: Resource files for task switcher app +* +*/ + + +NAME HGTL + +#include +#include +#include +#include +#include + +#include +#include + +#include "tscommands.hrh" + +// --------------------------------------------------------- +// +// Define the resource file signature +// This resource should be empty. +// +// --------------------------------------------------------- +// +RESOURCE RSS_SIGNATURE { } + +// --------------------------------------------------------- +// +// Default Document Name +// +// --------------------------------------------------------- +// +RESOURCE TBUF r_default_document_name { buf=""; } + +// --------------------------------------------------------- +// +// Define default menu and CBA key. +// +// --------------------------------------------------------- +// +RESOURCE EIK_APP_INFO + { + menubar = r_ts_menubar; + cba = r_ts_cba_nontouch; + } + +// --------------------------------------------------------- +// +// CBA for non-touch. +// +// --------------------------------------------------------- +// +RESOURCE CBA r_ts_cba_nontouch + { + flags = 0; + buttons = + { + CBA_BUTTON {id=EAknSoftkeySelect; txt=text_softkey_select;}, // left softkey + CBA_BUTTON {id=EAknSoftkeyBack; txt=text_softkey_back;}, // right softkey + CBA_BUTTON {id=EAknSoftkeySelect; txt=text_softkey_select;} // middle softkey, same as lsk, label is not shown in touch + }; + } + +// --------------------------------------------------------- +// +// CBA for touch. +// +// --------------------------------------------------------- +// +RESOURCE CBA r_ts_cba_touch + { + flags = 0; + buttons = + { + CBA_BUTTON {id=EAknSoftkeySelect; txt=text_softkey_empty;}, // left softkey, no label + CBA_BUTTON {id=EAknSoftkeyBack; txt=text_softkey_back;}, // right softkey + CBA_BUTTON {id=EAknSoftkeySelect; txt=text_softkey_select;} // middle softkey, same as lsk, label is not shown in touch + }; + } + + +// --------------------------------------------------------- +// +// r_ts_menubar +// Menubar for ts +// +// --------------------------------------------------------- +// +RESOURCE MENU_BAR r_ts_menubar + { + titles = + { + MENU_TITLE {menu_pane = r_ts_menu;} + }; + } + + +// --------------------------------------------------------- +// +// r_ts_menu +// Menu for "Options" +// +// --------------------------------------------------------- +// +RESOURCE MENU_PANE r_ts_menu + { + items = + { + MENU_ITEM { command = ETsCmdHelp; txt = qtn_options_help; }, + MENU_ITEM { command = EAknSoftkeyExit; txt = text_softkey_exit; } + }; + } + +// --------------------------------------------------------- +// +// r_ts_panel__name +// task switcher panel name +// +// --------------------------------------------------------- +// +RESOURCE TBUF r_ts_panel_name + { + buf="Task Switcher"; + } + +// --------------------------------------------------------- +// +// r_ts_message_dialog_okcancel +// message dialog with ok and cancel softkeys labels +// +// --------------------------------------------------------- +// +RESOURCE DIALOG r_ts_message_dialog_okcancel + { + flags = EGeneralQueryFlags; + buttons = R_AVKON_SOFTKEYS_OK_CANCEL; + items = + { + DLG_LINE + { + type = EAknCtPopupHeadingPane; + id = EAknMessageQueryHeaderId; + control = AVKON_HEADING + { + headinglayout = 0; + }; + }, + DLG_LINE + { + type = EAknCtMessageQuery; + id = EAknMessageQueryContentId; + control = AVKON_MESSAGE_QUERY { }; + } + }; + } + +// --------------------------------------------------------- +// +// r_ts_message_dialog_yesno +// message dialog with yes and no softkeys labels +// +// --------------------------------------------------------- +// +RESOURCE DIALOG r_ts_message_dialog_yesno + { + flags = EGeneralQueryFlags; + buttons = R_AVKON_SOFTKEYS_YES_NO; + items = + { + DLG_LINE + { + type = EAknCtPopupHeadingPane; + id = EAknMessageQueryHeaderId; + control = AVKON_HEADING + { + headinglayout = 0; + }; + }, + DLG_LINE + { + type = EAknCtMessageQuery; + id = EAknMessageQueryContentId; + control = AVKON_MESSAGE_QUERY { }; + } + }; + } + +// --------------------------------------------------------- +// +// r_ts_message_dialog_ok +// message dialog with ok softkey label +// +// --------------------------------------------------------- +// +RESOURCE DIALOG r_ts_message_dialog_ok + { + flags = EGeneralQueryFlags; + buttons = R_AVKON_SOFTKEYS_OK_EMPTY; + items = + { + DLG_LINE + { + type = EAknCtPopupHeadingPane; + id = EAknMessageQueryHeaderId; + control = AVKON_HEADING + { + headinglayout = 0; + }; + }, + DLG_LINE + { + type = EAknCtMessageQuery; + id = EAknMessageQueryContentId; + control = AVKON_MESSAGE_QUERY { }; + } + }; + } + +// --------------------------------------------------------- +// +// r_ts_fsw_confirm_close_query +// shown when Clear key is pressed in FSW +// +// --------------------------------------------------------- +// +RESOURCE DIALOG r_ts_fsw_confirm_close_query + { + flags = EGeneralQueryFlags; + buttons = R_AVKON_SOFTKEYS_YES_NO; + items = + { + DLG_LINE + { + type = EAknCtQuery; + id = EGeneralQuery; + control = AVKON_CONFIRMATION_QUERY + { + layout = EConfirmationQueryLayout; + }; + } + }; + } + + + +RESOURCE LOCALISABLE_APP_INFO r_localisable_app_info + { + short_caption = "Task Switcher"; + caption_and_icon = + { + CAPTION_AND_ICON_INFO + { + caption="Task Switcher"; + } + }; + } + + +RESOURCE TBUF r_ts_title { buf = "Task Switcher"; } + +RESOURCE TBUF r_ts_fsw_activate { buf = qtn_task_switcher_popup_open_app; } +RESOURCE TBUF r_ts_fsw_close { buf = qtn_task_switcher_popup_close_app; } +RESOURCE TBUF r_ts_fsw_close_all { buf = qtn_task_switcher_popup_close_all; } +RESOURCE TBUF r_ts_fsw_confirm_close { buf = qtn_memlo_confirm_close; } + +RESOURCE TBUF r_task_switcher_heading_applications { buf = qtn_task_switcher_heading_applications; } + +// end of file diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/data/taskswitcher_reg.rss --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/data/taskswitcher_reg.rss Fri Feb 19 22:42:37 2010 +0200 @@ -0,0 +1,31 @@ +/* +* Copyright (c) 2008-2008 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: task switcher application's registration resource file +* +*/ + + +#include +#include + +UID2 KUidAppRegistrationResourceFile +UID3 0x20016BF0 + +RESOURCE APP_REGISTRATION_INFO + { + app_file="taskswitcher"; + localisable_resource_file="\\resource\\apps\\taskswitcher"; + localisable_resource_id = R_LOCALISABLE_APP_INFO; + hidden=KAppIsHidden; + } diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/data/tstaskswitcher.rss --- a/taskswitcher/taskswitcherui/taskswitcherapp/data/tstaskswitcher.rss Tue Feb 02 00:04:13 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,282 +0,0 @@ -/* -* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: Resource files for task switcher app -* -*/ - - -NAME HGTL - -#include -#include -#include -#include -#include - -#include -#include - -#include "tscommands.hrh" - -// --------------------------------------------------------- -// -// Define the resource file signature -// This resource should be empty. -// -// --------------------------------------------------------- -// -RESOURCE RSS_SIGNATURE { } - -// --------------------------------------------------------- -// -// Default Document Name -// -// --------------------------------------------------------- -// -RESOURCE TBUF r_default_document_name { buf=""; } - -// --------------------------------------------------------- -// -// Define default menu and CBA key. -// -// --------------------------------------------------------- -// -RESOURCE EIK_APP_INFO - { - menubar = r_ts_menubar; - cba = r_ts_cba_nontouch; - } - -// --------------------------------------------------------- -// -// CBA for non-touch. -// -// --------------------------------------------------------- -// -RESOURCE CBA r_ts_cba_nontouch - { - flags = 0; - buttons = - { - CBA_BUTTON {id=EAknSoftkeySelect; txt=text_softkey_select;}, // left softkey - CBA_BUTTON {id=EAknSoftkeyBack; txt=text_softkey_back;}, // right softkey - CBA_BUTTON {id=EAknSoftkeySelect; txt=text_softkey_select;} // middle softkey, same as lsk, label is not shown in touch - }; - } - -// --------------------------------------------------------- -// -// CBA for touch. -// -// --------------------------------------------------------- -// -RESOURCE CBA r_ts_cba_touch - { - flags = 0; - buttons = - { - CBA_BUTTON {id=EAknSoftkeySelect; txt=text_softkey_empty;}, // left softkey, no label - CBA_BUTTON {id=EAknSoftkeyBack; txt=text_softkey_back;}, // right softkey - CBA_BUTTON {id=EAknSoftkeySelect; txt=text_softkey_select;} // middle softkey, same as lsk, label is not shown in touch - }; - } - - -// --------------------------------------------------------- -// -// r_ts_menubar -// Menubar for ts -// -// --------------------------------------------------------- -// -RESOURCE MENU_BAR r_ts_menubar - { - titles = - { - MENU_TITLE {menu_pane = r_ts_menu;} - }; - } - - -// --------------------------------------------------------- -// -// r_ts_menu -// Menu for "Options" -// -// --------------------------------------------------------- -// -RESOURCE MENU_PANE r_ts_menu - { - items = - { - MENU_ITEM { command = ETsCmdHelp; txt = qtn_options_help; }, - MENU_ITEM { command = EAknSoftkeyExit; txt = text_softkey_exit; } - }; - } - -// --------------------------------------------------------- -// -// r_ts_panel__name -// task switcher panel name -// -// --------------------------------------------------------- -// -RESOURCE TBUF r_ts_panel_name - { - buf="Task Switcher"; - } - -// --------------------------------------------------------- -// -// r_ts_message_dialog_okcancel -// message dialog with ok and cancel softkeys labels -// -// --------------------------------------------------------- -// -RESOURCE DIALOG r_ts_message_dialog_okcancel - { - flags = EGeneralQueryFlags; - buttons = R_AVKON_SOFTKEYS_OK_CANCEL; - items = - { - DLG_LINE - { - type = EAknCtPopupHeadingPane; - id = EAknMessageQueryHeaderId; - control = AVKON_HEADING - { - headinglayout = 0; - }; - }, - DLG_LINE - { - type = EAknCtMessageQuery; - id = EAknMessageQueryContentId; - control = AVKON_MESSAGE_QUERY { }; - } - }; - } - -// --------------------------------------------------------- -// -// r_ts_message_dialog_yesno -// message dialog with yes and no softkeys labels -// -// --------------------------------------------------------- -// -RESOURCE DIALOG r_ts_message_dialog_yesno - { - flags = EGeneralQueryFlags; - buttons = R_AVKON_SOFTKEYS_YES_NO; - items = - { - DLG_LINE - { - type = EAknCtPopupHeadingPane; - id = EAknMessageQueryHeaderId; - control = AVKON_HEADING - { - headinglayout = 0; - }; - }, - DLG_LINE - { - type = EAknCtMessageQuery; - id = EAknMessageQueryContentId; - control = AVKON_MESSAGE_QUERY { }; - } - }; - } - -// --------------------------------------------------------- -// -// r_ts_message_dialog_ok -// message dialog with ok softkey label -// -// --------------------------------------------------------- -// -RESOURCE DIALOG r_ts_message_dialog_ok - { - flags = EGeneralQueryFlags; - buttons = R_AVKON_SOFTKEYS_OK_EMPTY; - items = - { - DLG_LINE - { - type = EAknCtPopupHeadingPane; - id = EAknMessageQueryHeaderId; - control = AVKON_HEADING - { - headinglayout = 0; - }; - }, - DLG_LINE - { - type = EAknCtMessageQuery; - id = EAknMessageQueryContentId; - control = AVKON_MESSAGE_QUERY { }; - } - }; - } - -// --------------------------------------------------------- -// -// r_ts_fsw_confirm_close_query -// shown when Clear key is pressed in FSW -// -// --------------------------------------------------------- -// -RESOURCE DIALOG r_ts_fsw_confirm_close_query - { - flags = EGeneralQueryFlags; - buttons = R_AVKON_SOFTKEYS_YES_NO; - items = - { - DLG_LINE - { - type = EAknCtQuery; - id = EGeneralQuery; - control = AVKON_CONFIRMATION_QUERY - { - layout = EConfirmationQueryLayout; - }; - } - }; - } - - - -RESOURCE LOCALISABLE_APP_INFO r_localisable_app_info - { - short_caption = "Task Switcher"; - caption_and_icon = - { - CAPTION_AND_ICON_INFO - { - caption="Task Switcher"; - } - }; - } - - -RESOURCE TBUF r_ts_title { buf = "Task Switcher"; } - -RESOURCE TBUF r_ts_fsw_activate { buf = qtn_task_switcher_popup_open_app; } -RESOURCE TBUF r_ts_fsw_close { buf = qtn_task_switcher_popup_close_app; } -RESOURCE TBUF r_ts_fsw_close_all { buf = qtn_task_switcher_popup_close_all; } -RESOURCE TBUF r_ts_fsw_confirm_close { buf = qtn_memlo_confirm_close; } - -RESOURCE TBUF r_task_switcher_heading_applications { buf = qtn_task_switcher_heading_applications; } - -// end of file diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/data/tstaskswitcher_reg.rss --- a/taskswitcher/taskswitcherui/taskswitcherapp/data/tstaskswitcher_reg.rss Tue Feb 02 00:04:13 2010 +0200 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,30 +0,0 @@ -/* -* Copyright (c) 2008-2008 Nokia Corporation and/or its subsidiary(-ies). -* All rights reserved. -* This component and the accompanying materials are made available -* under the terms of "Eclipse Public License v1.0" -* which accompanies this distribution, and is available -* at the URL "http://www.eclipse.org/legal/epl-v10.html". -* -* Initial Contributors: -* Nokia Corporation - initial contribution. -* -* Contributors: -* -* Description: task switcher application's registration resource file -* -*/ - - -#include -#include - -UID2 KUidAppRegistrationResourceFile -UID3 0x20016BF0 - -RESOURCE APP_REGISTRATION_INFO - { - app_file="hgteleport"; - localisable_resource_file="\\resource\\apps\\hgteleport"; - localisable_resource_id = R_LOCALISABLE_APP_INFO; - } diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/group/tsapp.mmp --- a/taskswitcher/taskswitcherui/taskswitcherapp/group/tsapp.mmp Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/group/tsapp.mmp Fri Feb 19 22:42:37 2010 +0200 @@ -24,6 +24,7 @@ EPOCSTACKSIZE 0x5000 // 20KB TARGET taskswitcher.exe + TARGETTYPE exe UID 0x100039CE KTsAppUidValue CAPABILITY CAP_APPLICATION NetworkControl PowerMgmt @@ -88,14 +89,14 @@ LIBRARY tsfswutils.lib SOURCEPATH ../data -START RESOURCE tstaskswitcher.rss +START RESOURCE taskswitcher.rss HEADER TARGETPATH APP_RESOURCE_DIR LANGUAGE_IDS END SOURCEPATH ../data -START RESOURCE tstaskswitcher_reg.rss -DEPENDS tstaskswitcher.rsg +START RESOURCE taskswitcher_reg.rss +DEPENDS taskswitcher.rsg TARGETPATH /private/10003a3f/apps END diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/inc/tsappui.h --- a/taskswitcher/taskswitcherui/taskswitcherapp/inc/tsappui.h Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/inc/tsappui.h Fri Feb 19 22:42:37 2010 +0200 @@ -44,6 +44,16 @@ { public: + enum { + //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + //TODO make maping to NGA transition id + //!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + ENoneTransition = 0, + EForegroundTransition = 3, + EBackgroundTransition = 4, + EActivationTransition = 5 + + }; /** * Perform the second phase construction of a CTsAppUi object * this needs to be public due to the way the framework constructs the AppUi @@ -80,6 +90,12 @@ void MoveAppToForeground( TUint aTransitionType ); void MoveAppToBackground( TUint aTransitionType ); + /** + * Functions for showing/hiding popups. + */ + void RequestPopUpL(); + void DisablePopUpL(); + public: /** * From MTsCenrepChangeObserver @@ -139,6 +155,9 @@ // Listener for app key long press P&S, owned CTsPropertyListener* iPropListener; + // Listener for orientation layout changes + CTsPropertyListener* iLayoutListener; + // Tells if Taskswitcher is in foreground or in background TBool iForeground; @@ -159,6 +178,13 @@ * Cenrep listener for the tfxserver enabled/disabled key. */ CTsCenrepListener* iThemeEffectsEnabledWatcher; + + // Owned window for showing controls + RWindowGroup iWg; + + // Monitors popup mode + TBool iIsPopUpShown; + }; #endif // TSAPPUI_H diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/inc/tsappview.h --- a/taskswitcher/taskswitcherui/taskswitcherapp/inc/tsappview.h Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/inc/tsappview.h Fri Feb 19 22:42:37 2010 +0200 @@ -22,6 +22,7 @@ #include #include #include +#include #include "tsdevicestate.h" #include "tsdatachangeobserver.h" #include "tseventcontrolerobserver.h" @@ -49,13 +50,15 @@ * @param aRect Area where view should draw itself. */ static CTsAppView* NewL(const TRect& aRect, - CTsDeviceState& aDeviceState); + CTsDeviceState& aDeviceState, + RWindowGroup& aWg); /** * @copydoc NewL */ static CTsAppView* NewLC(const TRect& aRect, - CTsDeviceState& aDeviceState); + CTsDeviceState& aDeviceState, + RWindowGroup& aWg); /** * Destructor. @@ -93,6 +96,12 @@ * Forward app key handling to fasswaparea control. */ void HandleAppKey(TInt aType); + + /** + * Orders window invalidation to perform full + * background redraw. + */ + void OrderFullWindowRedraw(); protected: // from MCoeControlObserver @@ -116,7 +125,7 @@ /** * @copydoc NewL */ - void ConstructL( const TRect& aRect ); + void ConstructL( const TRect& aRect, RWindowGroup& aWg ); /** * C++ constructor. @@ -164,6 +173,20 @@ */ void DisableAppSwitchEffects(); + /** + * Launches feedback through MTouchFeedback::Instance() + * + * @param aType - The logical feedback type to play. + * @param aFeedbackType - Feedback types to be played as a bitmask + * combination of enumeration items from + * TTouchFeedbackType + * @param aPointerEvent - Pointer event, which triggered this feedback. + */ + void LaunchFeedback( TTouchLogicalFeedback aType, + TTouchFeedbackType aFeedbackType, + const TPointerEvent& aPointerEvent); + + public://From MTsEventControlerObserver /** @@ -187,7 +210,7 @@ /** * */ - virtual void Drag( + virtual void DragL( const AknTouchGestureFw::MAknTouchGestureFwDragEvent& aEvent); /** diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/inc/tseventcontrolerobserver.h --- a/taskswitcher/taskswitcherui/taskswitcherapp/inc/tseventcontrolerobserver.h Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/inc/tseventcontrolerobserver.h Fri Feb 19 22:42:37 2010 +0200 @@ -51,7 +51,7 @@ * Declare drag gesture handling. * @param aEvent - drag event */ - virtual void Drag(const AknTouchGestureFw::MAknTouchGestureFwDragEvent& aEvent) =0; + virtual void DragL(const AknTouchGestureFw::MAknTouchGestureFwDragEvent& aEvent) =0; /** * Declare animation stop handling diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/inc/tsfastswaparea.h --- a/taskswitcher/taskswitcherui/taskswitcherapp/inc/tsfastswaparea.h Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/inc/tsfastswaparea.h Fri Feb 19 22:42:37 2010 +0200 @@ -196,7 +196,7 @@ * Implements drag gesture handling * @see MTsEventControlerObserver */ - void Drag(const AknTouchGestureFw::MAknTouchGestureFwDragEvent& aEvent); + void DragL(const AknTouchGestureFw::MAknTouchGestureFwDragEvent& aEvent); /** * Implements animation stop handling @@ -256,7 +256,7 @@ /** * Shows the content from iArray on the screen. */ - void RenderContentL(); + void RenderContentL( TBool aSuppressAnimation = EFalse ); /** * Creates the ganes grid control. @@ -313,11 +313,6 @@ void SelectNextItem(); /** - * Highlight current grid'd item and redraw - */ - void ShowHighlight(); - - /** * Centralise most centered item so it was most exposed on the view. * Centered element is being selected by grid. * Animation to the centered element is made after aRedrawDelay time. @@ -400,9 +395,6 @@ CAknStylusPopUpMenu* iPopup; // the aIndex argument of ShowPopupL is stored here TInt iAppIndexForPopup; - - // Timestamp of the last application close operation - TTime iTimeOfLastClose; // Observer ptr, may be NULL, not owned MTsDataChangeObserver* iDcObserver; @@ -417,6 +409,9 @@ TPointerEvent iTapEvent; CTsFastSwapTimer* iHighlightTimer; + //Ignore physics move when request is cased by drag outside owned area + TBool iIgnorePhysicsMove; + // Grid scrolling TInt iGridItemWidth; TInt iGridItemGap; diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/inc/tsfastswapgrid.h --- a/taskswitcher/taskswitcherui/taskswitcherapp/inc/tsfastswapgrid.h Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/inc/tsfastswapgrid.h Fri Feb 19 22:42:37 2010 +0200 @@ -239,6 +239,7 @@ // Feedback support TBool iTactileFeedbackSupport; + CTsFastSwapTimer* iFeedbackTimer; mutable RArray iFullyVisibleItems; mutable RArray iPartialVisibleItems; diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/src/tsappui.cpp --- a/taskswitcher/taskswitcherui/taskswitcherapp/src/tsappui.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/src/tsappui.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -27,12 +27,13 @@ #include #include #include -#include +#include #include #include #include #include #include +#include // AknCapServer UID, used for P&S category @@ -41,6 +42,8 @@ // Taskswitcher UI, used as P&S key const TInt KTaskswitcherStateKey = KTsAppUidValue; +const TUid KTransitionsUid = {0x10281F90}; + // Values for Taskswitcher launching P&S const TInt KTaskswitcherBackgroundValue = 1; const TInt KTaskswitcherForegroundValue = KTaskswitcherBackgroundValue << 1; @@ -82,7 +85,10 @@ #endif // Initialise app UI with standard value. - BaseConstructL( CAknAppUi::EAknEnableSkin | CAknAppUi::EAknEnableMSK ); + BaseConstructL( CAknAppUi::EAknEnableSkin | + CAknAppUi::EAknEnableMSK | + CAknAppUi::EAknSingleClickCompatible); + SetFullScreenApp(EFalse); #ifndef _DEBUG // set as system application (in release build) so we never get closed @@ -110,26 +116,40 @@ // Create commonly used instances (device state only?) iDeviceState = CTsDeviceState::NewL(); + // Create custom window group + iWg = RWindowGroup(CCoeEnv::Static()->WsSession()); + iWg.Construct((TUint32)&iWg, ETrue); + // Create UI - iAppView = CTsAppView::NewL( ApplicationRect(), *iDeviceState ); + iAppView = CTsAppView::NewL( ApplicationRect(), *iDeviceState, iWg ); AddToStackL( iAppView ); //Enable effects GfxTransEffect::Enable(); - GfxTransEffect::Register(iAppView,TUid::Uid(KTsAppUidValue)); + GfxTransEffect::Register(iAppView,KTransitionsUid); GfxTransEffect::SetTransitionObserver(this); // Listen for change in the value of the ts state property. iPropListener = new ( ELeave ) CTsPropertyListener( KTaskswitcherStateCategory, KTaskswitcherStateKey, *this ); + + // Listen for layout changes + iLayoutListener = new ( ELeave ) CTsPropertyListener( + KPSUidUikon, KUikLayoutState, *this ); // Initialise the application task object with the window group id of // our application ( so that it represent our app ) - iApplicationTask.SetWgId( iCoeEnv->RootWin().Identifier() ); + //iApplicationTask.SetWgId( iCoeEnv->RootWin().Identifier() ); + iApplicationTask.SetWgId( iWg.Identifier() ); // And finally, go to background. - MoveAppToBackground( AknTransEffect::ENone ); - + MoveAppToBackground( ENoneTransition ); + + iEikonEnv->RootWin().SetOrdinalPosition(-1); + iEikonEnv->RootWin().EnableReceiptOfFocus(EFalse); + + iIsPopUpShown = EFalse; + TSLOG_OUT(); } @@ -160,6 +180,7 @@ delete iGoToBackgroundTimer; delete iPropListener; + delete iLayoutListener; // destroy UI first if ( iAppView ) @@ -171,6 +192,8 @@ delete iDeviceState; delete iMemAllocBuf; delete iThemeEffectsEnabledWatcher; + + iWg.Close(); } // ----------------------------------------------------------------------------- @@ -194,19 +217,19 @@ } switch(aTransitionType) { - case AknTransEffect::EApplicationStart: + case EForegroundTransition: StartTransition( aTransitionType, ETrue, EFalse, CAknTransitionUtils::EForceVisible); break; - case AknTransEffect::EApplicationExit: + case EBackgroundTransition: StartTransition( aTransitionType, EFalse, EFalse, CAknTransitionUtils::EForceInvisible ); break; - case AknTransEffect::EApplicationStartRect: + case EActivationTransition: StartTransition( aTransitionType, EFalse, ETrue, @@ -224,6 +247,7 @@ TBool /*aLayers*/, TUint aSubCom ) { + this->RequestPopUpL(); const TDesC8* ptr = reinterpret_cast(iAppView); GfxTransEffect::Abort(iAppView); GfxTransEffect::Begin( iAppView, aTranstionId ); @@ -244,6 +268,7 @@ void CTsAppUi::TransitionFinished(const CCoeControl* /*aControl*/, TUint /*aAction*/) { + DisablePopUpL(); /*if( aControl == iAppView ) { @TODO IMPLEMENT @@ -267,12 +292,12 @@ case EAknSoftkeyExit: case EAknSoftkeyBack: // RSK => just hide - MoveAppToBackground( AknTransEffect::EApplicationExit ); + MoveAppToBackground( EBackgroundTransition ); break; case ETsCmdHelp: { - MoveAppToBackground( AknTransEffect::EApplicationExit ); + MoveAppToBackground( EBackgroundTransition ); CArrayFix* buf = CCoeAppUi::AppHelpContextL(); HlpLauncher::LaunchHelpApplicationL( iCoeEnv->WsSession(), buf ); } @@ -318,7 +343,8 @@ { HandleSwitchToForegroundEvent(); } - else + // exclude cases with dialogs like power menu, memory card + else if( !IsFaded()) { HandleSwitchToBackgroundEvent(); } @@ -340,31 +366,40 @@ TInt value( 0 ); - if ( RProperty::Get( aCategory, aKey, value ) == KErrNone ) + if ( aCategory == KTaskswitcherStateCategory ) { - if ( iForeground && (value & KTaskswitcherBackgroundValue) ) - { - MoveAppToBackground( AknTransEffect::EApplicationExit ); - } - else if ( !iForeground && (value & KTaskswitcherForegroundValue) ) + if ( RProperty::Get( aCategory, aKey, value ) == KErrNone ) { - MoveAppToForeground( AknTransEffect::EApplicationStart ); - } - else if( value & KTaskswitcherLongAppKeyPressed ) - { - if(!iForeground) + if ( iForeground && (value & KTaskswitcherBackgroundValue) ) + { + MoveAppToBackground( EBackgroundTransition ); + } + else if ( !iForeground && (value & KTaskswitcherForegroundValue) ) + { + MoveAppToForeground( EForegroundTransition ); + } + else if( value & KTaskswitcherLongAppKeyPressed ) { - MoveAppToBackground( AknTransEffect::EApplicationExit ); + if(!iForeground) + { + MoveAppToBackground( EBackgroundTransition ); + } + else + { + iAppView->HandleAppKey(KAppKeyTypeLong); + } } - else + else if( value & KTaskswitcherShortAppKeyPressed ) { - iAppView->HandleAppKey(KAppKeyTypeLong); + iAppView->HandleAppKey(KAppKeyTypeShort); } } - else if( value & KTaskswitcherShortAppKeyPressed ) - { - iAppView->HandleAppKey(KAppKeyTypeShort); - } + } + else if ( aCategory == KPSUidUikon && iIsPopUpShown ) + { + TRAP_IGNORE( + DisablePopUpL(); + HandleResourceChangeL(KEikDynamicLayoutVariantSwitch) ); } TSLOG_OUT(); @@ -376,12 +411,23 @@ // void CTsAppUi::HandleResourceChangeL( TInt aType ) { + TSLOG_CONTEXT( CTsAppUi::HandleResourceChangeL, TSLOG_LOCAL ); + TSLOG_IN(); // Must call base class implementation first, // sizes from LayoutMetricsRect etc. will only be correct after this. CAknAppUi::HandleResourceChangeL( aType ); if( aType == KEikDynamicLayoutVariantSwitch && iAppView ) { - iAppView->SetRect( ApplicationRect() ); + // Check if layout switch is necessary + TSizeMode mode = iEikonEnv->ScreenDevice()->GetCurrentScreenModeAttributes(); + TBool isLandscape = mode.iScreenSize.iWidth > mode.iScreenSize.iHeight; + TRect appRect = ApplicationRect(); + TBool isAppLandscape = appRect.Width() > appRect.Height(); + if(isLandscape != isAppLandscape) + { + // Keep displayed orientation + return; + } } // forward event iDeviceState->HandleResourceChange( aType ); @@ -389,6 +435,7 @@ { iAppView->HandleResourceChange( aType ); } + TSLOG_OUT(); } // ----------------------------------------------------------------------------- @@ -400,13 +447,13 @@ TSLOG_CONTEXT( MoveAppToBackground, TSLOG_LOCAL ); TSLOG_IN(); - if ( AknTransEffect::ENone == aTransitionType || !EffectsEnabled() ) + if ( ENoneTransition == aTransitionType || !EffectsEnabled() ) { GoToBackgroundTimerCallback( this ); } else { - StartTransion(AknTransEffect::EApplicationExit); + StartTransion(aTransitionType); iGoToBackgroundTimer->Cancel(); iGoToBackgroundTimer->Start( KWaitBeforeGoingToBackground, @@ -476,8 +523,9 @@ TSLOG_IN(); // must not do anything if iForeground is already up-to-date - // exclude cases with dialogs like power menu, memory card - if( iForeground && !IsFaded() ) + + + if( iForeground ) { iForeground = EFalse; SetTaskswitcherStateProperty( KTaskswitcherBackgroundValue ); @@ -581,4 +629,50 @@ } +// ----------------------------------------------------------------------------- +// CTsAppUi::RequestPopUpL +// ----------------------------------------------------------------------------- +// +void CTsAppUi::RequestPopUpL() + { + TSLOG_CONTEXT( CTsAppUi::RequestPopUpL, TSLOG_LOCAL ); + TSLOG_IN(); + if(!iIsPopUpShown) + { + iIsPopUpShown = ETrue; + TSizeMode mode = iEikonEnv->ScreenDevice()->GetCurrentScreenModeAttributes(); + TInt isLandscape = mode.iScreenSize.iWidth > mode.iScreenSize.iHeight; + SetFullScreenApp(ETrue); + if(isLandscape) + { + SetOrientationL(EAppUiOrientationLandscape); + } + else + { + SetOrientationL(EAppUiOrientationPortrait); + } + iEikonEnv->RootWin().SetOrdinalPosition(0, ECoeWinPriorityAlwaysAtFront); + } + TSLOG_OUT(); + } + + +// ----------------------------------------------------------------------------- +// CTsAppUi::DisablePopUpL +// ----------------------------------------------------------------------------- +// +void CTsAppUi::DisablePopUpL() + { + TSLOG_CONTEXT( CTsAppUi::DisablePopUpL, TSLOG_LOCAL ); + TSLOG_IN(); + if(iIsPopUpShown) + { + iIsPopUpShown = EFalse; + iEikonEnv->RootWin().SetOrdinalPosition(-1, ECoeWinPriorityNeverAtFront); + SetOrientationL(EAppUiOrientationAutomatic); + SetFullScreenApp(EFalse); + } + TSLOG_OUT(); + } + // End of file diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/src/tsappview.cpp --- a/taskswitcher/taskswitcherui/taskswitcherapp/src/tsappview.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/src/tsappview.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -29,9 +29,7 @@ #include #include #include -#include -#include - +#include #include "tsappview.h" #include "tsappui.h" #include "tsapplogging.h" @@ -39,14 +37,17 @@ #include "tseventcontroler.h" #include "tsuid.hrh" + + // ----------------------------------------------------------------------------- // CTsAppView::NewL // ----------------------------------------------------------------------------- // CTsAppView* CTsAppView::NewL( const TRect& aRect, - CTsDeviceState& aDeviceState ) + CTsDeviceState& aDeviceState, + RWindowGroup& aWg) { - CTsAppView* self = CTsAppView::NewLC( aRect, aDeviceState ); + CTsAppView* self = CTsAppView::NewLC( aRect, aDeviceState, aWg ); CleanupStack::Pop( self ); return self; } @@ -56,11 +57,12 @@ // ----------------------------------------------------------------------------- // CTsAppView* CTsAppView::NewLC( const TRect& aRect, - CTsDeviceState& aDeviceState ) + CTsDeviceState& aDeviceState, + RWindowGroup& aWg) { CTsAppView* self = new (ELeave) CTsAppView( aDeviceState ); CleanupStack::PushL( self ); - self->ConstructL( aRect ); + self->ConstructL( aRect, aWg ); return self; } @@ -100,14 +102,6 @@ // CTsAppView::~CTsAppView() { - GfxTransEffect::SetTransitionObserver( 0 ); - if ( GfxTransEffect::IsRegistered( this ) ) - { - MakeVisible( EFalse ); - CAknTransitionUtils::MakeVisibleSubComponents( this, - CAknTransitionUtils::EForceInvisible ); - GfxTransEffect::Deregister( this ); - } delete iBgContext; delete iFastSwapArea; delete iAppsHeading; @@ -119,13 +113,13 @@ // CTsAppView::ConstructL // ----------------------------------------------------------------------------- // -void CTsAppView::ConstructL( const TRect& aRect ) +void CTsAppView::ConstructL( const TRect& aRect, RWindowGroup& aWg ) { TSLOG_CONTEXT( CTsAppView::ConstructL, TSLOG_LOCAL ); TSLOG_IN(); // Create a window for this application view - CreateWindowL(); + CreateWindowL(aWg); // Store rect TInt variety = Layout_Meta_Data::IsLandscapeOrientation() ? 1 : 0; @@ -174,9 +168,8 @@ } DrawableWindow()->EnableBackup(EWindowBackupFullScreen); - Window().SetOrdinalPosition( 0, ECoeWinPriorityNormal ); SetComponentsToInheritVisibility(ETrue); - MakeVisible(ETrue); + MakeVisible(EFalse); // Ready to be drawn ActivateL(); @@ -221,14 +214,6 @@ TSLOG4( TSLOG_INFO, "inner rect for popup = %d %d %d %d", iBgContextInnerRect.iTl.iX, iBgContextInnerRect.iTl.iY, iBgContextInnerRect.iBr.iX, iBgContextInnerRect.iBr.iY ); - -#ifdef TASKSWITCHER_USE_CUSTOM_LAYOUT - if ( iFastSwapArea ) - { - iBgContextOuterRect = iFastSwapArea->Rect(); - iBgContextInnerRect = iFastSwapArea->Rect(); - } -#endif TSLOG_OUT(); } @@ -321,6 +306,7 @@ { TSLOG_CONTEXT( CTsAppView::SizeChanged, TSLOG_LOCAL ); TSLOG_IN(); + iViewRect = Rect(); UpdatePopupRects(); iBgContext->SetFrameRects(iBgContextOuterRect, iBgContextInnerRect); if ( iFastSwapArea && iAppsHeading ) @@ -455,19 +441,10 @@ // void CTsAppView::HandleSwitchToBackgroundEvent() { - // Stop animation and unfade - GfxTransEffect::Abort(); iPopupFader.FadeBehindPopup( this, NULL, EFalse ); - GfxTransEffect::Begin( this, 5); - // Forward event to interested controls iFastSwapArea->HandleSwitchToBackgroundEvent(); - // Hide - MakeVisible( EFalse ); - //GfxTransEffect::NotifyExternalState( ENotifyGlobalAbort ); - CAknTransitionUtils::MakeVisibleSubComponents( this, - CAknTransitionUtils::EForceInvisible ); } // ----------------------------------------------------------------------------- @@ -476,6 +453,9 @@ // void CTsAppView::HandleSwitchToForegroundEvent() { + TSLOG_CONTEXT( CTsAppView::HandleSwitchToForegroundEvent, TSLOG_LOCAL ); + TSLOG_IN(); + Window().Invalidate(Rect()); // Fade behind the pop-up @@ -495,7 +475,7 @@ if ( appui->EffectsEnabled() ) { InvalidateWindows( this ); - appui->StartTransion(AknTransEffect::EApplicationStart); + appui->StartTransion(CTsAppUi::EForegroundTransition); } else { @@ -505,6 +485,8 @@ } DrawDeferred(); + + TSLOG_OUT(); } // ----------------------------------------------------------------------------- @@ -551,7 +533,7 @@ // Called when screen orientation, touch awareness, or the skin has been changed. // ----------------------------------------------------------------------------- // -void CTsAppView::HandleDeviceStateChanged( TChangeType /*aChangeType*/ ) +void CTsAppView::HandleDeviceStateChanged( TChangeType aChangeType ) { TSLOG_CONTEXT( HandleDeviceStateChanged, TSLOG_LOCAL ); TSLOG_IN(); @@ -559,11 +541,20 @@ // Just set all the sizes, even when there is a skin change, because this will // guarantee proper redraw also with the ganes controls. - iViewRect = Rect(); - TSLOG4( TSLOG_INFO, "setting rect %d %d %d %d", - iViewRect.iTl.iX, iViewRect.iTl.iY, - iViewRect.iBr.iX, iViewRect.iBr.iY ); - SetRect( iViewRect ); + if(aChangeType == EOrientation) + { + SetRect( static_cast(iEikonEnv->AppUi())->ApplicationRect() ); + } + else + { + iViewRect = Rect(); + TSLOG4( TSLOG_INFO, "setting rect %d %d %d %d", + iViewRect.iTl.iX, iViewRect.iTl.iY, + iViewRect.iBr.iX, iViewRect.iBr.iY ); + SetRect( iViewRect ); + } + + InvalidateWindows(this); TSLOG_OUT(); } @@ -606,15 +597,10 @@ // void CTsAppView::HandlePointerEventL( const TPointerEvent &aPointerEvent ) { - MTouchFeedback* feedback = MTouchFeedback::Instance(); - if(0 != feedback && - (TPointerEvent::EButton1Down == aPointerEvent.iType || - TPointerEvent::EButton1Up == aPointerEvent.iType)) + if( TPointerEvent::EButton1Down == aPointerEvent.iType ) { - feedback->InstantFeedback(this, - ETouchFeedbackBasic, - ETouchFeedbackVibra, - aPointerEvent); + LaunchFeedback(ETouchFeedbackBasic, TTouchFeedbackType( + ETouchFeedbackVibra | ETouchFeedbackAudio), aPointerEvent); } iFastSwapArea->HandlePointerEventL(aPointerEvent); } @@ -657,6 +643,18 @@ iFastSwapArea->HandleAppKey(aType); } + +// ----------------------------------------------------------------------------- +// CTsAppView::OrderBackgrRedraw +// ----------------------------------------------------------------------------- +// +void CTsAppView::OrderFullWindowRedraw() + { + InvalidateWindows(this); + DrawNow(); + } + + // ----------------------------------------------------------------------------- // CTsAppView::MoveOffset // ----------------------------------------------------------------------------- @@ -702,12 +700,26 @@ } // ----------------------------------------------------------------------------- -// CTsAppView::Drag() +// CTsAppView::DragL() // ----------------------------------------------------------------------------- // -void CTsAppView::Drag(const MAknTouchGestureFwDragEvent& aEvent) +void CTsAppView::DragL(const MAknTouchGestureFwDragEvent& aEvent) { - iFastSwapArea->Drag(aEvent); + if( aEvent.State() == EAknTouchGestureFwStop ) + { + LaunchFeedback(ETouchFeedbackBasic, TTouchFeedbackType( + ETouchFeedbackVibra | ETouchFeedbackAudio), TPointerEvent()); + } + if( iFastSwapArea->Rect().Contains(aEvent.StartPosition()) || + iAppsHeading->Rect().Contains(aEvent.StartPosition()) ) + { + iFastSwapArea->DragL(aEvent); + } + else + { + //move task switcher to background + iEikonEnv->EikAppUi()->HandleCommandL(EAknSoftkeyExit); + } } // ----------------------------------------------------------------------------- @@ -728,4 +740,24 @@ return iFastSwapArea->ViewPos(); } +// ----------------------------------------------------------------------------- +// CTsAppView::LaunchFeedback +// ----------------------------------------------------------------------------- +// +void CTsAppView::LaunchFeedback( TTouchLogicalFeedback aLogicalType, + TTouchFeedbackType aFeedbackType, + const TPointerEvent& aPointerEvent) + { + MTouchFeedback* feedback = MTouchFeedback::Instance(); + if(0 != feedback) + { + feedback->InstantFeedback(this, aLogicalType, + aFeedbackType, + aPointerEvent); + } + } + + + + // End of file diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/src/tseventcontroler.cpp --- a/taskswitcher/taskswitcherui/taskswitcherapp/src/tseventcontroler.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/src/tseventcontroler.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -130,7 +130,7 @@ void CTsEventControler::HandleDragEventL( MAknTouchGestureFwDragEvent& aEvent) { - iObserver.Drag(aEvent); + iObserver.DragL(aEvent); iPhysicsHelper->HandleDragEvent(aEvent); } diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/src/tsfastswaparea.cpp --- a/taskswitcher/taskswitcherui/taskswitcherapp/src/tsfastswaparea.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/src/tsfastswaparea.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -24,7 +24,7 @@ #include #include #include -#include +#include #include #include #include @@ -38,6 +38,7 @@ #include "tsappui.h" #include "tsdatachangeobserver.h" #include "tseventcontroler.h" +#include "tsappview.h" /** command ids for the fsw popup */ enum TPopupCommands @@ -49,10 +50,6 @@ /** Number of closable applications, to show "close all" option. */ const TInt KTsMaxClosableApps = 2; -/** Interval until which no change in the fsw content is rendered - after starting the closing of an application. */ -const TInt KRefreshDelayAfterClose = 2; // seconds - /** Uid of Active Idle application. Used when movind Ai to specified position.*/ const TUid KAiUid = TUid::Uid( 0x102750F0 ); @@ -69,9 +66,12 @@ const TInt KLayoutItemCount = 4; const TInt KRedrawTime = 250000; // 0.25 sec +const TInt KRedrawTimeForLayoutSwitch = 700000; // 0.7 sec const TInt KHighlighActivationTime = 100000; // 100 ms const TInt KUpdateGridTime = 1000000; // 1 s +const TInt KMaxGranularity = 4; + // ----------------------------------------------------------------------------- // CTsFastSwapArea::NewL // ----------------------------------------------------------------------------- @@ -185,6 +185,7 @@ iGrid = new( ELeave ) CTsFastSwapGrid; iGrid->ConstructL( this ); + iGrid->DisableSingleClick(ETrue);//enables highlight on pointer iDeviceState.AddObserverL(*iGrid, MTsDeviceStateObserver::ESkin); AknListBoxLayouts::SetupStandardGrid( *iGrid ); @@ -201,7 +202,6 @@ TInt variety = Layout_Meta_Data::IsLandscapeOrientation() ? 1 : 0; iGrid->SetRect(gridAppPane.Rect()); - iGrid->SetVisibleViewRect(gridAppPane.Rect()); TAknLayoutScalableParameterLimits gridParams = AknLayoutScalable_Apps::cell_tport_appsw_pane_ParamLimits( variety ); TPoint empty( ELayoutEmpty, ELayoutEmpty ); @@ -353,7 +353,15 @@ iGrid->SetCurrentDataIndex(selIdx); UpdateGrid(ETrue, EFalse); DrawDeferred(); + + // Order full redraw after switch + if(iRedrawTimer) + { + iRedrawTimer->Cancel(); + iRedrawTimer->After(KRedrawTimeForLayoutSwitch); + } } + TSLOG_OUT(); } @@ -389,7 +397,7 @@ // Therefore ts must be moved to background. CTsAppUi* appui = static_cast( iEikonEnv->AppUi() ); - appui->MoveAppToBackground( AknTransEffect::EApplicationStartRect ); + appui->MoveAppToBackground( CTsAppUi::EActivationTransition ); } } @@ -405,6 +413,11 @@ if ( aIndex >= 0 && aIndex < iArray.Count() && CanClose( aIndex ) ) { + TInt selIdx = SelectedIndex(); + if ( selIdx > aIndex && selIdx > 0 ) + { + selIdx--; + } TInt wgId = iArray[aIndex]->WgId(); iFSClient->CloseApp( wgId ); // The fsw content will change sooner or later @@ -419,7 +432,7 @@ NotifyChange(); if ( !aSuppressRendering ) { - RenderContentL(); + RenderContentL( ETrue ); } // Update item selection on the screen if last item was deleted TInt newItemCount = GridItemCount(); @@ -428,7 +441,11 @@ newItemCount--; iGrid->SetCurrentDataIndex(newItemCount); } - iTimeOfLastClose.HomeTime(); + else + { + DrawDeferred(); + iGrid->SetCurrentDataIndex(selIdx); + } } TSLOG_OUT(); @@ -455,7 +472,7 @@ { RenderContentL(); RestoreSelectedIndex(); - iGrid->DrawNow(); + UpdateGrid(); } } @@ -518,18 +535,6 @@ TSLOG_CONTEXT( HandleFswContentChangedL, TSLOG_LOCAL ); TSLOG_IN(); - // If there was an app close operation started during the last - // few seconds then stop, to prevent flickering. - TTime now; - now.HomeTime(); - TTimeIntervalSeconds iv; - if ( now.SecondsFrom( iTimeOfLastClose, iv ) == KErrNone - && iv.Int() <= KRefreshDelayAfterClose ) - { - TSLOG1_OUT( "difference since last close is only %d sec, stop", iv.Int() ); - return; - } - // get current content from fastswap server iFSClient->GetContentL( iArray ); SwapApplicationOrder( iArray ); @@ -556,16 +561,16 @@ // CTsFastSwapArea::RenderContentL // -------------------------------------------------------------------------- // -void CTsFastSwapArea::RenderContentL() +void CTsFastSwapArea::RenderContentL( TBool aSuppressAnimation ) { TSLOG_CONTEXT( RenderContentL, TSLOG_LOCAL ); TSLOG_IN(); _LIT(KSeparator, "\t"); - CArrayPtr* iconArray = new ( ELeave ) CAknIconArray( iArray.Count() ); + CArrayPtr* iconArray = new ( ELeave ) CAknIconArray( KMaxGranularity ); CleanupStack::PushL( iconArray ); - CDesCArrayFlat* textArray = new ( ELeave ) CDesCArrayFlat( iArray.Count() ); + CDesCArrayFlat* textArray = new ( ELeave ) CDesCArrayFlat( KMaxGranularity ); CleanupStack::PushL( textArray ); RArray closeItemArray; CleanupClosePushL(closeItemArray); @@ -577,15 +582,18 @@ GetFastSwapAreaRects(rects); TAknLayoutRect gridItem = rects[1]; CleanupStack::PopAndDestroy(&rects); - if ( AknLayoutUtils::LayoutMirrored() ) + if ( iArray.Count() ) { - iGrid->SetLayoutL( EFalse, EFalse, ETrue, iArray.Count(), 1, gridItem.Rect().Size(), iGridItemGap ); + if ( AknLayoutUtils::LayoutMirrored() ) + { + iGrid->SetLayoutL( EFalse, EFalse, ETrue, iArray.Count(), 1, gridItem.Rect().Size(), iGridItemGap ); + } + else + { + iGrid->SetLayoutL( EFalse, ETrue, ETrue, iArray.Count(), 1, gridItem.Rect().Size(), iGridItemGap ); + } } - else - { - iGrid->SetLayoutL( EFalse, ETrue, ETrue, iArray.Count(), 1, gridItem.Rect().Size(), iGridItemGap ); - } - + for ( TInt i = 0, ie = iArray.Count(); i != ie; ++i ) { const TDesC& appName( iArray[i]->AppName() ); @@ -649,8 +657,11 @@ CleanupStack::Pop(textArray); CleanupStack::Pop(iconArray); - iGrid->ScrollBarFrame()->SetScrollBarVisibilityL( + if( iGrid->ScrollBarFrame() ) + { + iGrid->ScrollBarFrame()->SetScrollBarVisibilityL( CEikScrollBarFrame::EOff, CEikScrollBarFrame::EOff); + } // refresh the items in the grid if(iPreviousNoOfItems < iArray.Count()) @@ -663,7 +674,7 @@ } iPreviousNoOfItems = iArray.Count(); iEvtHandler.ReInitPhysicsL( GridWorldSize(), ViewSize(), ETrue ); - UpdateGrid( ETrue ); + UpdateGrid( ETrue, !aSuppressAnimation ); TSLOG_OUT(); } @@ -752,7 +763,7 @@ } RestoreSelectedIndex(); - UpdateGrid(ETrue, EFalse); + UpdateGrid(EFalse, EFalse); iRedrawTimer->Cancel(); iRedrawTimer->After(KRedrawTime); @@ -784,7 +795,6 @@ // store the currently selected index if there is one SaveSelectedIndex(); } - iGrid->DrawDeferred(); } // ----------------------------------------------------------------------------- @@ -865,7 +875,7 @@ { if (aType == EEventKey) { - ShowHighlight(); + iGrid->ShowHighlight(); iConsumeEvent = ETrue; } retVal = EKeyWasConsumed; @@ -937,8 +947,6 @@ } iSavedSelectedIndex = highlightItem - 1;//count from 0 iGrid->SetCurrentDataIndex( iSavedSelectedIndex ); - TBool forceRedraw(ETrue); - UpdateGrid(forceRedraw); } } @@ -949,6 +957,7 @@ // void CTsFastSwapArea::ProcessCommandL( TInt aCommandId ) { + static_cast(iEikonEnv->AppUi())->DisablePopUpL(); switch ( aCommandId ) { case EFswCmdClose: @@ -1017,7 +1026,7 @@ } else if(aSource == iRedrawTimer) { - DrawNow(); + static_cast(&iParent)->OrderFullWindowRedraw(); } else if( aSource == iUpdateGridTimer ) { @@ -1063,6 +1072,7 @@ if(showPopUp) { + static_cast(iEikonEnv->AppUi())->RequestPopUpL(); // give feedback LaunchPopupFeedback(); // save index for later use & show popup @@ -1164,6 +1174,7 @@ { case EEventEnterKeyPressed: case EEventItemClicked: + case EEventItemSingleClicked: { SwitchToApp(SelectedIndex()); } @@ -1225,15 +1236,6 @@ UpdateGrid(forceRedraw, animate); } -// -------------------------------------------------------------------------- -// CTsFastSwapArea::ShowHiglight -// -------------------------------------------------------------------------- -// -void CTsFastSwapArea::ShowHighlight() - { - iGrid->ShowHighlight(); - UpdateGrid(ETrue, EFalse); - } // -------------------------------------------------------------------------- // CTsFastSwapArea::CenterItem @@ -1279,6 +1281,7 @@ { if ( aAnimate ) { + iIgnorePhysicsMove = EFalse; iEvtHandler.Animate( targetPoint ); } else @@ -1307,7 +1310,7 @@ } else { - ShowHighlight(); + iGrid->ShowHighlight(); } } else if( aType == KAppKeyTypeLong ) @@ -1327,6 +1330,18 @@ TSLOG2_IN("New position x: %d, y:%d", aPoint.iX, aPoint.iY); TSLOG_OUT(); + //ignore case when drag occurs outside owned area + if( iIgnorePhysicsMove ) + { + return; + } + //postpone center item request in case of being moved + if(iUpdateGridTimer->IsActive()) + { + iUpdateGridTimer->Cancel(); + iUpdateGridTimer->After(KUpdateGridTime); + } + TInt currentXPos = aPoint.iX; currentXPos -= Rect().Width() / 2; TRect gridViewRect = Rect(); @@ -1339,7 +1354,7 @@ gridViewRect.iTl.iX += ( Rect().Width() - GridItemCount() * iGridItemWidth ) / 2; } iGrid->SetRect( gridViewRect ); - DrawNow(); + DrawDeferred(); } // -------------------------------------------------------------------------- @@ -1390,16 +1405,28 @@ } // -------------------------------------------------------------------------- -// CTsFastSwapArea::Drag +// CTsFastSwapArea::DragL // -------------------------------------------------------------------------- // -void CTsFastSwapArea::Drag( - const MAknTouchGestureFwDragEvent& /*aEvent*/) +void CTsFastSwapArea::DragL( + const MAknTouchGestureFwDragEvent& aEvent) { + if( aEvent.State() == EAknTouchGestureFwStop) + { + CenterItem( KUpdateGridTime ); + } + if( !Rect().Contains(aEvent.CurrentPosition()) ) + { + iIgnorePhysicsMove = ETrue; + return; + } + else + { + iIgnorePhysicsMove = EFalse; + } + iGrid->SetTactileFeedbackSupport(ETrue); iGrid->HideHighlight(); - CenterItem( KUpdateGridTime ); - DrawNow(); } // ----------------------------------------------------------------------------- diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/src/tsfastswapgrid.cpp --- a/taskswitcher/taskswitcherui/taskswitcherapp/src/tsfastswapgrid.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/src/tsfastswapgrid.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -30,6 +30,7 @@ */ const TInt KCloseIconRedrawTime = 300000; // 0.3 second +const TInt KFeedbackTime = 0; // ----------------------------------------------------------------------------- // CTsFastSwapGrid::CTsFastSwapGrid @@ -53,6 +54,7 @@ iCloseItems.Close(); delete iBgContext; delete iCloseIconRedrawTimer; + delete iFeedbackTimer; iFullyVisibleItems.Close(); iPartialVisibleItems.Close(); } @@ -73,9 +75,10 @@ TRect(), ETrue ); iBgContext->SetCenter( KAknsIIDQsnFrPopupCenter ); - iVisibleViewRect = TRect( 0, 0, 0, 0 ); iCloseIconRedrawTimer = new (ELeave) CTsFastSwapTimer( *this ); iCloseIconRedrawTimer->ConstructL(); + iFeedbackTimer = new (ELeave) CTsFastSwapTimer( *this ); + iFeedbackTimer->ConstructL(); } // ----------------------------------------------------------------------------- @@ -205,7 +208,8 @@ // void CTsFastSwapGrid::HandleResourceChange( TInt aType ) { - if ( aType != KEikDynamicLayoutVariantSwitch ) + if ( aType != KEikDynamicLayoutVariantSwitch && + Model()->ItemTextArray()->MdcaCount() ) { CAknGrid::HandleResourceChange( aType ); } @@ -245,6 +249,7 @@ AknLayoutScalable_Apps::tport_appsw_pane( variety ) ); const TInt leftOffset = fastSwapAreaPane.Rect().iTl.iX; const TInt rightOffset = availableRect.Width() - fastSwapAreaPane.Rect().iBr.iX; + SetVisibleViewRect(fastSwapAreaPane.Rect()); CFormattedCellGridData* data = CFormattedCellGridData::NewL(); CleanupStack::PushL( data ); @@ -266,8 +271,17 @@ { if ( aSource == iCloseIconRedrawTimer ) { - iFastSwapGridObserver->HandleCloseEventL( iCloseIconHitIdx ); + TInt itemToClose = iCloseIconHitIdx; ResetCloseHit(); + iFastSwapGridObserver->HandleCloseEventL( itemToClose ); + } + else if ( aSource == iFeedbackTimer ) + { + MTouchFeedback* feedback = MTouchFeedback::Instance(); + if (feedback) + { + feedback->InstantFeedback(ETouchFeedbackSensitive); + } } } @@ -500,11 +514,8 @@ return; } - MTouchFeedback* feedback = MTouchFeedback::Instance(); - if (feedback) - { - feedback->InstantFeedback(ETouchFeedbackSensitive); - } + iFeedbackTimer->Cancel(); + iFeedbackTimer->After(KFeedbackTime); } // ----------------------------------------------------------------------------- @@ -665,7 +676,7 @@ // ----------------------------------------------------------------------------- -// CTsTeleportGridItemDrawer::SetRedrawBackground +// CTsGridItemDrawer::SetRedrawBackground // ----------------------------------------------------------------------------- // void CTsGridItemDrawer::SetRedrawBackground( TBool aEnable ) @@ -770,11 +781,7 @@ { TBool retVal( EFalse ); TRect viewRect = iGrid->VisibleViewRect(); - if ( // left edge of item rectangle on screen - ( aItemRect.iTl.iX >= viewRect.iTl.iX && aItemRect.iTl.iX <= viewRect.iBr.iX ) || - // right edge of item rectangle on screen - ( aItemRect.iBr.iX >= viewRect.iTl.iX && aItemRect.iBr.iX <= viewRect.iBr.iX ) - ) + if ( viewRect.Intersects( aItemRect ) ) { retVal = ETrue; } diff -r c743ef5928ba -r f966699dea19 taskswitcher/taskswitcherui/taskswitcherapp/src/tsphysicsengine.cpp --- a/taskswitcher/taskswitcherui/taskswitcherapp/src/tsphysicsengine.cpp Tue Feb 02 00:04:13 2010 +0200 +++ b/taskswitcher/taskswitcherui/taskswitcherapp/src/tsphysicsengine.cpp Fri Feb 19 22:42:37 2010 +0200 @@ -102,6 +102,7 @@ { TPoint deltaPoint(aEvent.PreviousPosition() - aEvent.CurrentPosition()); iPhysics->RegisterPanningPosition(deltaPoint); + iStartTime.HomeTime(); } else //AknTouchGestureFw::EAknTouchGestureFwStop {