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