201027
authorhgs
Fri, 09 Jul 2010 15:04:41 +0300
changeset 41 f65a18712d2e
parent 28 e26add186222
child 42 607cc97c6047
201027
videotelephony.pro
videotelephony_plat/video_telephony_media_configuration_api/group/bld.inf
vtprotocolplugins/VideoSource/src/cmultiframeprovider.cpp
vtuis/lcvtapp/conf/CI_s60videotelephony.confml
vtuis/lcvtapp/conf/s60videotelephony.confml
vtuis/lcvtapp/conf/s60videotelephony_10281872.crml
vtuis/lcvtapp/inc/VideoTelephonyInternalCRKeys.h
vtuis/lcvtapp/lcvtapp.pro
vtuis/lcvtindicatorcontroller/bwins/lcvtindicatorcontrolleru.def
vtuis/lcvtindicatorcontroller/eabi/lcvtindicatorcontrolleru.def
vtuis/lcvtindicatorcontroller/inc/lcvtindicatorcontroller.h
vtuis/lcvtindicatorcontroller/inc/lcvtindicatorcontrollerimpl.h
vtuis/lcvtindicatorcontroller/lcvtindicatorcontroller.pri
vtuis/lcvtindicatorcontroller/lcvtindicatorcontroller.pro
vtuis/lcvtindicatorcontroller/rom/lcvtindctr.iby
vtuis/lcvtindicatorcontroller/src/lcvtindicatorcontroller.cpp
vtuis/lcvtindicatorcontroller/src/lcvtindicatorcontrollerimpl.cpp
vtuis/lcvtindicatorplugin/inc/lcvtindicatorplugin.h
vtuis/lcvtindicatorplugin/lcvtindicatorplugin.pro
vtuis/lcvtindicatorplugin/rom/lcvtindicatorplugin.iby
vtuis/lcvtindicatorplugin/src/lcvtindicatorplugin.cpp
vtuis/lcvtindicatorplugin/tsrc/qtestutils/inc/testresultxmlparser.h
vtuis/lcvtindicatorplugin/tsrc/qtestutils/src/testresultxmlparser.cpp
vtuis/lcvtindicatorplugin/tsrc/ut_lcvtindicatorplugin/inc/ut_lcvtindicatorplugin.h
vtuis/lcvtindicatorplugin/tsrc/ut_lcvtindicatorplugin/src/main.cpp
vtuis/lcvtindicatorplugin/tsrc/ut_lcvtindicatorplugin/src/ut_lcvtindicatorplugin.cpp
vtuis/lcvtindicatorplugin/tsrc/ut_lcvtindicatorplugin/stubs/symbianstubs.cpp
vtuis/lcvtindicatorplugin/tsrc/ut_lcvtindicatorplugin/stubs/symbianstubs_helper.h
vtuis/lcvtplugin/inc/base/clcvtsession.h
vtuis/lcvtplugin/src/base/clcvtsession.cpp
--- a/videotelephony.pro	Tue Jul 06 14:18:02 2010 +0300
+++ b/videotelephony.pro	Fri Jul 09 15:04:41 2010 +0300
@@ -18,7 +18,7 @@
 CONFIG += ordered
 
 symbian: {  
-        
+    //:BLD_INF_RULES.prj_exports += "$${LITERAL_HASH}include <platform_paths.hrh>"    
     :BLD_INF_RULES.prj_mmpfiles += $$LITERAL_HASH"include \"packetvideoengine/group/bld.inf\""
     :BLD_INF_RULES.prj_mmpfiles += $$LITERAL_HASH"include \"vtprotocols/group/bld.inf\""   
     :BLD_INF_RULES.prj_mmpfiles += $$LITERAL_HASH"include \"vtprotocolplugins/group/bld.inf\""
@@ -27,4 +27,6 @@
     :BLD_INF_RULES.prj_mmpfiles += $$LITERAL_HASH"include \"videotelephony_plat/group/bld.inf\""
 }
 
+//SUBDIRS += vtuis/lcvtindicatorplugin
+//SUBDIRS += vtuis/lcvtindicatorcontroller
 SUBDIRS += vtuis/lcvtapp
--- a/videotelephony_plat/video_telephony_media_configuration_api/group/bld.inf	Tue Jul 06 14:18:02 2010 +0300
+++ b/videotelephony_plat/video_telephony_media_configuration_api/group/bld.inf	Fri Jul 09 15:04:41 2010 +0300
@@ -2,9 +2,9 @@
 * Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies).
 * All rights reserved.
 * This component and the accompanying materials are made available
-* under the terms of the License "Symbian Foundation License v1.0"
+* under the terms of "Eclipse Public License v1.0"
 * which accompanies this distribution, and is available
-* at the URL "http://www.symbianfoundation.org/legal/sfl-v10.html".
+* at the URL "http://www.eclipse.org/legal/epl-v10.html".
 *
 * Initial Contributors:
 * Nokia Corporation - initial contribution.
--- a/vtprotocolplugins/VideoSource/src/cmultiframeprovider.cpp	Tue Jul 06 14:18:02 2010 +0300
+++ b/vtprotocolplugins/VideoSource/src/cmultiframeprovider.cpp	Fri Jul 09 15:04:41 2010 +0300
@@ -630,15 +630,15 @@
     {
     __IF_DEBUG(Print(_L("VideoSource[%d]: CMultiframeProvider::AddBitmapToFreeQueue() >>"), RThread().Id().operator TUint()));
     if ( iOldBM )
-    	  {
-    	  __IF_DEBUG(Print(_L("VideoSource[%d]: CMultiframeProvider::AddBitmapToFreeQueue() OLD BM"), RThread().Id().operator TUint()));
-    	  iOldBM = EFalse;
+        {
+        __IF_DEBUG(Print(_L("VideoSource[%d]: CMultiframeProvider::AddBitmapToFreeQueue() OLD BM"), RThread().Id().operator TUint()));
+        iOldBM = EFalse;
         User::LeaveIfError( iFreeQueue.Append( iOldBitmap ) );
-    	  }
+        }
     else
-    	  {
-   	 	  User::LeaveIfError( iFreeQueue.Append( iScaled ) );
-  		  }
+        {
+        User::LeaveIfError( iFreeQueue.Append( iScaled ) );
+        }
     iLoopAo->SetFreeBitmaps( 1 );
     __IF_DEBUG(Print(_L("VideoSource[%d]: CMultiframeProvider::AddBitmapToFreeQueue() <<"), RThread().Id().operator TUint()));
     }
Binary file vtuis/lcvtapp/conf/CI_s60videotelephony.confml has changed
Binary file vtuis/lcvtapp/conf/s60videotelephony.confml has changed
Binary file vtuis/lcvtapp/conf/s60videotelephony_10281872.crml has changed
--- a/vtuis/lcvtapp/inc/VideoTelephonyInternalCRKeys.h	Tue Jul 06 14:18:02 2010 +0300
+++ b/vtuis/lcvtapp/inc/VideoTelephonyInternalCRKeys.h	Fri Jul 09 15:04:41 2010 +0300
@@ -112,7 +112,7 @@
 * Defines number of toolbar buttons. Three buttons is minimum
 * and seven is maximum.
 */
-const TUint32 KVTToolbarCommands  = 0x0000000B;
+//const TUint32 KVTToolbarCommands  = 0x0000000B;
 
 #endif      // VIDEOTELEPHONYINTERNALCRKEYS_H
 
--- a/vtuis/lcvtapp/lcvtapp.pro	Tue Jul 06 14:18:02 2010 +0300
+++ b/vtuis/lcvtapp/lcvtapp.pro	Fri Jul 09 15:04:41 2010 +0300
@@ -31,6 +31,7 @@
 		:BLD_INF_RULES.prj_exports += "./rom/videotelui.iby CORE_APP_LAYER_IBY_EXPORT_PATH(videotelui.iby)"
 		:BLD_INF_RULES.prj_exports += "./rom/videoteluiResources.iby LANGUAGE_APP_LAYER_IBY_EXPORT_PATH(videoteluiResources.iby)"		
 		:BLD_INF_RULES.prj_exports += "./conf/s60videotelephony.confml APP_LAYER_CONFML(s60videotelephony.confml)"
+		:BLD_INF_RULES.prj_exports += "./conf/CI_s60videotelephony.confml APP_LAYER_CONFML(CI_s60videotelephony.confml)"
 		:BLD_INF_RULES.prj_exports += "./conf/s60videotelephony_102072D0.crml APP_LAYER_CRML(s60videotelephony_102072D0.crml)"
 		:BLD_INF_RULES.prj_exports += "./conf/s60videotelephony_10281872.crml APP_LAYER_CRML(s60videotelephony_10281872.crml)"
 		:BLD_INF_RULES.prj_exports += "./inc/VideoTelephonyVariant.hrh  |../../inc/videotelephonyvariant.hrh"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorcontroller/bwins/lcvtindicatorcontrolleru.def	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,6 @@
+EXPORTS
+	?disableActiveCallIndicator@LcVtIndicatorController@@QAEXXZ @ 1 NONAME ; void LcVtIndicatorController::disableActiveCallIndicator(void)
+	?enableActiveCallIndicator@LcVtIndicatorController@@QAEXXZ @ 2 NONAME ; void LcVtIndicatorController::enableActiveCallIndicator(void)
+	??1LcVtIndicatorController@@UAE@XZ @ 3 NONAME ; LcVtIndicatorController::~LcVtIndicatorController(void)
+	??0LcVtIndicatorController@@QAE@XZ @ 4 NONAME ; LcVtIndicatorController::LcVtIndicatorController(void)
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorcontroller/eabi/lcvtindicatorcontrolleru.def	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,9 @@
+EXPORTS
+	_ZN23LcVtIndicatorController25enableActiveCallIndicatorEv @ 1 NONAME
+	_ZN23LcVtIndicatorController26disableActiveCallIndicatorEv @ 2 NONAME
+	_ZN23LcVtIndicatorControllerC1Ev @ 3 NONAME
+	_ZN23LcVtIndicatorControllerC2Ev @ 4 NONAME
+	_ZN23LcVtIndicatorControllerD0Ev @ 5 NONAME
+	_ZN23LcVtIndicatorControllerD1Ev @ 6 NONAME
+	_ZN23LcVtIndicatorControllerD2Ev @ 7 NONAME
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorcontroller/inc/lcvtindicatorcontroller.h	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,39 @@
+/*!
+* 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:  Handles phone indicators.
+*/
+
+#ifndef LCVTINDICATORCONTROLLER_H_
+#define LCVTINDICATORCONTROLLER_H_
+
+// FORWARD DECLARATION
+
+class LcVtIndicatorControllerImpl;
+
+class LcVtIndicatorController
+    {
+public:
+    IMPORT_C explicit LcVtIndicatorController();
+    IMPORT_C virtual ~LcVtIndicatorController();
+
+    IMPORT_C void enableActiveCallIndicator();
+    IMPORT_C void disableActiveCallIndicator();
+    
+private:
+    LcVtIndicatorControllerImpl* mIndicatorimpl;
+    
+    friend class UT_LcVtIndicatorController;
+    };
+
+#endif /* LCVTINDICATORCONTROLLER_H_ */
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorcontroller/inc/lcvtindicatorcontrollerimpl.h	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,39 @@
+/*!
+* 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:  Handles phone indicators.
+*/
+
+#ifndef LCVTINDICATORCONTROLLERIMPL_H_
+#define LCVTINDICATORCONTROLLERIMPL_H_
+
+// FORWARD DECLARATION
+class HbIndicator;
+
+class LcVtIndicatorControllerImpl
+    {
+public:
+    explicit LcVtIndicatorControllerImpl();
+    virtual ~LcVtIndicatorControllerImpl();
+    
+    void enableActiveCallIndicator();
+    void disableActiveCallIndicator();
+    
+private:
+    HbIndicator* mIndicator;
+    friend class UT_LcVtIndicatorController;
+    };
+
+
+
+#endif /* LCVTINDICATORCONTROLLERIMPL_H_ */
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorcontroller/lcvtindicatorcontroller.pri	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,21 @@
+#
+# 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: 
+#
+
+HEADERS += ./inc/lcvtindicatorcontroller.h
+HEADERS += ./inc/lcvtindicatorcontrollerimpl.h
+
+SOURCES += ./src/lcvtindicatorcontroller.cpp
+SOURCES += ./src/lcvtindicatorcontrollerimpl.cpp
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorcontroller/lcvtindicatorcontroller.pro	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,46 @@
+# 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:
+
+TEMPLATE = lib
+TARGET = lcvtindicatorcontroller
+CONFIG += hb dll svg
+    
+QT += core
+    
+INCLUDEPATH += ./inc
+INCLUDEPATH += ../../inc
+INCLUDEPATH += $$APP_LAYER_SYSTEMINCLUDE
+
+DEFINES += LCVTINDICATORCONTROLLER_LIB
+
+libFiles.sources = lcvtindicatorcontroller.dll
+libFiles.path = "!:/sys/bin"
+DEPLOYMENT += libFiles
+
+symbian: {
+    TARGET.UID2 = 0x1000008d
+    TARGET.UID3 = 0x200315EC
+
+    TARGET.CAPABILITY = CAP_GENERAL_DLL
+    TARGET.EPOCALLOWDLLDATA = 1
+    LIBS += -lflogger -lxqplugins -lxqservice -lxqserviceutil
+    defFiles = "$${LITERAL_HASH}ifdef WINS" \
+        "DEFFILE bwins/lcvtindicatorcontroller.def" \
+        "$${LITERAL_HASH}else" \
+        "DEFFILE eabi/lcvtindicatorcontroller.def" \
+        "$${LITERAL_HASH}endif"
+    MMP_RULES += defFiles
+    :BLD_INF_RULES.prj_exports += "$${LITERAL_HASH}include <platform_paths.hrh>"           
+    :BLD_INF_RULES.prj_exports += "./inc/lcvtindicatorcontroller.h /epoc32/include/lcvtindicatorcontroller.h"
+    :BLD_INF_RULES.prj_exports += "rom/lcvtindctr.iby CORE_APP_LAYER_IBY_EXPORT_PATH(lcvtindctr.iby)"
+}
+# Input
+include(lcvtindicatorcontroller.pri)
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorcontroller/rom/lcvtindctr.iby	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,32 @@
+/*
+* 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:  IBY file
+ *
+*/
+
+ 
+#ifndef __LCVTINDCTR_IBY__
+#define __LCVTINDCTR_IBY__
+
+
+//#ifdef __CS_VIDEO_TELEPHONY
+
+file=ABI_DIR\UREL\lcvtindicatorcontroller.dll SHARED_LIB_DIR\lcvtindicatorcontroller.dll
+
+// Enabler for eclipsing ROM binaries
+//data=ZSYSTEM\install\lcvtplugin_stub.sis           system\install\lcvtplugin_stub.sis
+
+#endif
+
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorcontroller/src/lcvtindicatorcontroller.cpp	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,47 @@
+/*!
+* 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:  Handles phone indicators.
+*
+*/
+
+#include <qglobal.h>
+
+#include "lcvtindicatorcontroller.h"
+#include "lcvtindicatorcontrollerimpl.h"
+
+    
+EXPORT_C LcVtIndicatorController::LcVtIndicatorController()
+{
+    mIndicatorimpl = new LcVtIndicatorControllerImpl();
+}
+
+EXPORT_C LcVtIndicatorController::~LcVtIndicatorController()
+{
+    delete mIndicatorimpl;
+}
+
+
+EXPORT_C void LcVtIndicatorController::enableActiveCallIndicator()
+{
+    mIndicatorimpl->enableActiveCallIndicator();
+}
+
+EXPORT_C void LcVtIndicatorController::disableActiveCallIndicator()
+{
+    mIndicatorimpl->disableActiveCallIndicator();
+ 
+}
+
+// End of file
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorcontroller/src/lcvtindicatorcontrollerimpl.cpp	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,76 @@
+/*!
+* 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:  Handles phone indicators.
+*
+*/
+
+#include <QList>
+#include <QPair>
+#include <qglobal.h>
+#include <hbindicator.h>
+#include <hbindicatorinterface.h>
+#ifdef Q_OS_SYMBIAN
+#include <hbicon.h>
+#endif
+#include "lcvtindicatorcontrollerimpl.h"
+#include <QDebug>
+
+const static QString lcVtIndicator = "com.nokia.hb.indicator.lcvtindicatorplugin/1.0";
+
+
+LcVtIndicatorControllerImpl::LcVtIndicatorControllerImpl()
+{
+    qDebug() << "LcVtIndicatorControllerImpl::LcVtIndicatorControllerImpl()";
+    mIndicator = new HbIndicator();
+}
+
+LcVtIndicatorControllerImpl::~LcVtIndicatorControllerImpl()
+{   
+    qDebug() << "LcVtIndicatorControllerImpl::~LcVtIndicatorControllerImpl()";
+    delete mIndicator;
+}
+
+void LcVtIndicatorControllerImpl::enableActiveCallIndicator()
+{
+    qDebug() << "LcVtIndicatorControllerImpl::enableActiveCallIndicator()";
+    QString indicatorType(lcVtIndicator);
+    QVariantMap parameters;
+    
+    //indicator text
+    parameters.insert(
+            QVariant(HbIndicatorInterface::PrimaryTextRole).toString(),
+            hbTrId("txt_vt_dblist_ongoing_video_call"));
+    
+    //status bar icon
+    parameters.insert(
+            QVariant(HbIndicatorInterface::MonoDecorationNameRole).toString(),
+            QString("qtg_mono_call"));
+    
+    //indicator icon
+    parameters.insert(QVariant(HbIndicatorInterface::DecorationNameRole).toString(),
+            QString("qtg_mono_call"));
+    
+    mIndicator->activate(indicatorType, parameters);
+    qDebug() << "LcVtIndicatorControllerImpl::enableActiveCallIndicator(), exit";
+}
+
+void LcVtIndicatorControllerImpl::disableActiveCallIndicator()
+{
+    qDebug() << "LcVtIndicatorControllerImpl::disableActiveCallIndicator()";
+    QString indicatorType(lcVtIndicator);
+    mIndicator->deactivate(indicatorType);
+}
+
+// End of file
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorplugin/inc/lcvtindicatorplugin.h	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,62 @@
+/*
+ * 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 LCVTINDICATORPLUGIN_H
+#define LCVTINDICATORPLUGIN_H
+
+#include <hbindicatorplugininterface.h>
+#include <hbindicatorinterface.h>
+
+class LcVtIndicatorPlugin : public HbIndicatorInterface, public HbIndicatorPluginInterface
+{
+Q_OBJECT
+Q_INTERFACES(HbIndicatorPluginInterface)
+public:
+
+    LcVtIndicatorPlugin();
+    ~LcVtIndicatorPlugin();
+
+public: //from HbIndicatorPluginInterface    
+    QStringList indicatorTypes() const;
+    bool accessAllowed(const QString &indicatorType,
+                       const QVariantMap &securityInfo) const;
+    HbIndicatorInterface* createIndicator(const QString &indicatorType);
+    int error() const;
+    
+public: //from HbIndicatorInterface
+    bool handleInteraction(InteractionType type);
+    QVariant indicatorData(int role) const;
+
+
+protected: //from HbIndicatorInterface
+    bool handleClientRequest(RequestType type, const QVariant &parameter);
+    
+    
+private:
+    
+    bool bringVtToForeground();
+    
+private:
+    Q_DISABLE_COPY(LcVtIndicatorPlugin)
+    int mError;
+    QStringList mIndicatorTypes;
+    QVariant mParameter;
+    
+    friend class UT_LcVtIndicatorPlugin;
+};
+
+#endif // LCVTINDICATORPLUGIN_H
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorplugin/lcvtindicatorplugin.pro	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,41 @@
+#
+# 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:
+#
+
+TEMPLATE = lib
+TARGET = lcvtindicatorplugin
+CONFIG += plugin hb
+
+# directories
+INCLUDEPATH += $$APP_LAYER_SYSTEMINCLUDE
+INCLUDEPATH += ./inc
+
+# Input
+HEADERS += inc/lcvtindicatorplugin.h
+SOURCES += src/lcvtindicatorplugin.cpp
+
+symbian: {
+    TARGET.EPOCALLOWDLLDATA = 1
+    TARGET.UID3 = 0x200315EB
+    TARGET.CAPABILITY = CAP_GENERAL_DLL
+    LIBS += -lxqservice
+
+    :BLD_INF_RULES.prj_exports += "$${LITERAL_HASH}include <platform_paths.hrh>"
+    :BLD_INF_RULES.prj_exports += "rom/lcvtindicatorplugin.iby CORE_APP_LAYER_IBY_EXPORT_PATH(lcvtindicatorplugin.iby)"
+    
+    pluginstub.sources = lcvtindicatorplugin.dll
+    pluginstub.path = /resource/plugins/indicators
+    DEPLOYMENT += pluginstub
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorplugin/rom/lcvtindicatorplugin.iby	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,25 @@
+/*
+* 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 __LCVTINDICATORPLUGIN_IBY__
+#define __LCVTINDICATORPLUGIN_IBY__
+ 
+#include <data_caging_paths_for_iby.hrh>
+
+file=ABI_DIR\UREL\lcvtindicatorplugin.dll               SHARED_LIB_DIR\lcvtindicatorplugin.dll 
+data=\epoc32\data\z\resource\plugins\indicators\lcvtindicatorplugin.qtplugin   \resource\plugins\indicators\lcvtindicatorplugin.qtplugin
+#endif
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorplugin/src/lcvtindicatorplugin.cpp	Fri Jul 09 15:04:41 2010 +0300
@@ -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:  
+ *
+ */
+
+#include <QtPlugin>
+#include <QVariant>
+#include <QDebug>
+#include <eikenv.h>
+#include <apgtask.h>
+
+#include "lcvtindicatorplugin.h"
+
+const static QString IndicatorType = "com.nokia.hb.indicator.lcvtindicatorplugin/1.0";
+
+Q_EXPORT_PLUGIN(LcVtIndicatorPlugin)
+
+
+// -----------------------------------------------------------------------------
+//
+// -----------------------------------------------------------------------------
+//
+LcVtIndicatorPlugin::LcVtIndicatorPlugin(): 
+    HbIndicatorInterface(IndicatorType, NotificationCategory, InteractionActivated),
+    mError(0)
+{
+    qDebug() << "LcVtIndicatorPlugin::LcVtIndicatorPlugin()";
+    mIndicatorTypes << IndicatorType;
+}
+
+// -----------------------------------------------------------------------------
+//
+// -----------------------------------------------------------------------------
+//
+LcVtIndicatorPlugin::~LcVtIndicatorPlugin()
+{
+}
+
+// -----------------------------------------------------------------------------
+//
+// -----------------------------------------------------------------------------
+//
+QStringList LcVtIndicatorPlugin::indicatorTypes() const
+{
+    qDebug() << "LcVtIndicatorPlugin::indicatorTypes()";
+    return mIndicatorTypes;
+}
+
+// -----------------------------------------------------------------------------
+//
+// -----------------------------------------------------------------------------
+//
+bool LcVtIndicatorPlugin::accessAllowed(const QString &indicatorType,
+        const QVariantMap &securityInfo) const
+{
+    Q_UNUSED(indicatorType);
+    Q_UNUSED(securityInfo);
+    qDebug() << "LcVtIndicatorPlugin::accessAllowed()";
+    return true;
+}
+
+// -----------------------------------------------------------------------------
+//
+// -----------------------------------------------------------------------------
+//
+HbIndicatorInterface* LcVtIndicatorPlugin::createIndicator(
+        const QString &indicatorType)
+{
+    Q_UNUSED(indicatorType);
+    return this;
+}
+
+// -----------------------------------------------------------------------------
+//
+// -----------------------------------------------------------------------------
+//
+int LcVtIndicatorPlugin::error() const
+{
+    return mError;
+}
+
+
+// -----------------------------------------------------------------------------
+//
+// -----------------------------------------------------------------------------
+//
+bool LcVtIndicatorPlugin::handleInteraction(InteractionType type)
+{
+    qDebug() << "LcVtIndicatorPlugin::handleInteraction()";
+    bool handled = false;
+    if (type == InteractionActivated) {
+        handled = bringVtToForeground();        
+        if (!handled) {
+            qDebug() << "couldn't bring VT to FG, deactivating indicator!";
+            emit deactivate(); 
+        }
+    }
+    qDebug() << "LcVtIndicatorPlugin::handleInteraction(), exit";
+    return handled;
+}
+
+// -----------------------------------------------------------------------------
+//
+// -----------------------------------------------------------------------------
+//
+QVariant LcVtIndicatorPlugin::indicatorData(int role) const
+{
+    qDebug() << "LcVtIndicatorInterface::indicatorData()";
+    QVariantMap map = mParameter.value<QVariantMap>();
+    
+    if (role == PrimaryTextRole) {
+        return map.value( (QVariant(PrimaryTextRole)).toString()).toString();
+    } else if (role == MonoDecorationNameRole) { //status bar icon
+        return  map.value((QVariant(MonoDecorationNameRole)).toString()).toString();
+    } else if (role == DecorationNameRole) {
+        return map.value( (QVariant(DecorationNameRole)).toString()).toString();
+    }
+    return QVariant();
+}
+
+// -----------------------------------------------------------------------------
+//
+// -----------------------------------------------------------------------------
+//
+bool LcVtIndicatorPlugin::handleClientRequest(RequestType type, const QVariant &parameter)
+{
+    qDebug() << "LcVtIndicatorPlugin::handleClientRequest()";
+    bool handled(false);
+    switch (type) {
+        case RequestActivate:
+            if (mParameter != parameter) {
+                mParameter = parameter;
+                emit dataChanged();
+            }
+            handled =  true;
+            break;
+        default:
+            mParameter.clear();
+    }
+    qDebug() << "LcVtIndicatorPlugin::handleClientRequest(), exit";
+
+    return handled;
+}
+
+// -----------------------------------------------------------------------------
+//
+// -----------------------------------------------------------------------------
+//
+bool LcVtIndicatorPlugin::bringVtToForeground()
+{
+    bool ret = false;
+    RWsSession& wsSession = CEikonEnv::Static()->WsSession();
+    TApaTaskList taskList( wsSession );
+    const TUid KUidVtApp = { 0x101F8681 }; 
+    TApaTask task = taskList.FindApp(KUidVtApp);
+    if (task.Exists()) {
+        qDebug() << "-> SwitchBackToVTCall";
+        task.BringToForeground();
+        ret = true;
+    }
+    return ret;
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorplugin/tsrc/qtestutils/inc/testresultxmlparser.h	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,68 @@
+/*
+* 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 TESTRESULTXMLPARSER_H
+#define TESTRESULTXMLPARSER_H
+
+#include <QXmlDefaultHandler>
+
+
+class TestResultXmlParser : public QXmlDefaultHandler
+{
+public: // Constructors and destructor
+    TestResultXmlParser();
+    ~TestResultXmlParser();    
+    
+public: // From QXmlContentHandler 
+    bool startElement(
+        const QString& namespaceURI,
+        const QString& localName,
+        const QString& qName,
+        const QXmlAttributes& atts);
+    
+    bool endElement(
+        const QString& namespaceURI,
+        const QString& localName,
+        const QString& qName);
+    
+    bool characters(const QString& ch);
+       
+public: // New functions
+    
+    int parse(const QString& fileName);
+    
+    int parseAndPrintResults(
+        const QString& fileName,
+        bool printDetails=false);
+    
+    int testCount();
+    
+    QStringList errors();
+    
+private: // Data
+    int mTestCount;
+    QStringList* mErrors;
+    bool mParsingIncidentElement;
+    bool mParsingDescriptionElement;
+    bool mCurrentTestFailed;
+    QString mCurrentTestName;
+    QString mCurrentTestFile;
+    int mCurrentTestFailureLine;
+};
+
+
+#endif // TESTRESULTXMLPARSER_H
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorplugin/tsrc/qtestutils/src/testresultxmlparser.cpp	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,178 @@
+/*
+* 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 "testresultxmlparser.h" 
+#include <stdio.h>
+
+const char testFunctionElement[] = "TestFunction";
+const char incidentElement[] = "Incident";
+const char descriptionElement[] = "Description";
+const char nameAttr[] = "name";
+const char typeAttr[] = "type";
+const char fileAttr[] = "file";
+const char lineAttr[] = "line";
+const char attrValueFail[] = "fail";
+
+
+// -----------------------------------------------------------------------------
+// TestResultXmlParser::TestResultXmlParser
+// -----------------------------------------------------------------------------
+//
+TestResultXmlParser::TestResultXmlParser() 
+: mTestCount(0), 
+  mParsingIncidentElement(false),
+  mParsingDescriptionElement(false),
+  mCurrentTestFailed(false),
+  mCurrentTestFailureLine(0)
+{
+    mErrors = new QStringList;
+}
+
+// -----------------------------------------------------------------------------
+// TestResultXmlParser::TestResultXmlParser
+// -----------------------------------------------------------------------------
+//
+TestResultXmlParser::~TestResultXmlParser()
+{
+    delete mErrors;   
+}
+
+// -----------------------------------------------------------------------------
+// TestResultXmlParser::startElement
+// -----------------------------------------------------------------------------
+//
+bool TestResultXmlParser::startElement(
+    const QString& /*namespaceURI*/, 
+    const QString& /*localName*/, 
+    const QString& qName, 
+    const QXmlAttributes& atts)
+{
+    if (qName == testFunctionElement) {
+        mTestCount++;
+        mCurrentTestName = atts.value(nameAttr);
+        return true;
+    }
+    if (qName == incidentElement) {
+        mParsingIncidentElement = true;
+        if (atts.value(typeAttr) == attrValueFail) {
+            mCurrentTestFailed = true;
+            mCurrentTestFile = atts.value(fileAttr);
+            mCurrentTestFailureLine = atts.value(lineAttr).toInt();
+        }
+        return true;
+    }
+    mParsingDescriptionElement = (qName == descriptionElement);
+    return true;
+}
+
+// -----------------------------------------------------------------------------
+// TestResultXmlParser::endElement
+// -----------------------------------------------------------------------------
+//
+bool TestResultXmlParser::endElement(
+    const QString& /*namespaceURI*/,
+    const QString& /*localName*/,
+    const QString& qName)
+{
+    if (qName == incidentElement) {
+        mParsingIncidentElement = false;
+        mCurrentTestFailed = false;
+        return true;
+    }
+    if (qName == descriptionElement) {
+        mParsingDescriptionElement = false;
+    }    
+    return true;
+}
+
+// -----------------------------------------------------------------------------
+// TestResultXmlParser::characters
+// -----------------------------------------------------------------------------
+//
+bool TestResultXmlParser::characters(const QString& ch)
+{
+    if (mParsingIncidentElement && 
+        mParsingDescriptionElement &&
+        mCurrentTestFailed) {
+        QString testResult = mCurrentTestName + " failed:\n";
+        testResult += "File: ";
+        testResult += mCurrentTestFile;
+        testResult += "\n";
+        testResult += "Line: ";
+        testResult += QString::number(mCurrentTestFailureLine);
+        testResult += "\n";
+        testResult += "Reason: ";
+        testResult += ch;
+        testResult += "\n";
+        mErrors->append(testResult);
+    }
+    return true;
+}
+
+// -----------------------------------------------------------------------------
+// TestResultXmlParser::parse
+// -----------------------------------------------------------------------------
+//
+int TestResultXmlParser::parse(const QString& fileName)
+{
+    QFile file(fileName);
+    QXmlInputSource inputSource(&file);
+    QXmlSimpleReader reader;
+    reader.setContentHandler(this);
+    return reader.parse(inputSource);
+}
+
+// -----------------------------------------------------------------------------
+// TestResultXmlParser::parseAndPrintResults
+// -----------------------------------------------------------------------------
+//
+int TestResultXmlParser::parseAndPrintResults(
+    const QString& fileName,
+    bool printDetails)
+{
+    printf("Parsing: %s\n", fileName.toUtf8().data());
+    int error = parse(fileName);
+    printf("%d tests executed. Failed total: %d\n", mTestCount, mErrors->count());
+    if (printDetails) {
+        printf("\n");
+        foreach(QString error, *mErrors) {
+            printf(error.toUtf8().data());
+            printf("\n");
+        }
+    }
+    return error;
+}
+
+// -----------------------------------------------------------------------------
+// TestResultXmlParser::testCount
+// -----------------------------------------------------------------------------
+//
+int TestResultXmlParser::testCount()
+{
+    return mTestCount;
+}
+
+// -----------------------------------------------------------------------------
+// TestResultXmlParser::errors
+// -----------------------------------------------------------------------------
+//
+QStringList TestResultXmlParser::errors()
+{
+    return *mErrors;
+}
+
+// End of File.
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorplugin/tsrc/ut_lcvtindicatorplugin/inc/ut_lcvtindicatorplugin.h	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,65 @@
+/*
+* 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 UT_LCVTINDICATORPLUGIN_H
+#define UT_LCVTINDICATORPLUGIN_H
+
+#include <QObject>
+#include <QList>
+
+class LcVtIndicatorPlugin;
+
+class UT_LcVtIndicatorPlugin : public QObject               
+{
+     Q_OBJECT
+    
+private slots:
+
+/*
+ * In addition, there are four private slots that are not treated as testfunctions. 
+ * They will be executed by the testing framework and can be used to initialize and clean up 
+ * either the entire test or the current test function.
+ * 
+ * initTestCase() will be called before the first testfunction is executed.
+ * cleanupTestCase() will be called after the last testfunction was executed.
+ * init() will be called before each testfunction is executed.
+ * cleanup() will be called after every testfunction.
+*/
+    void initTestCase();
+    void cleanupTestCase();
+    void init();
+    void cleanup();
+
+private slots: //test methods
+     
+    void testLcVtIndicatorPlugin();
+    void testIndicatorTypes();
+    void testAccessAllowed();
+    void testCreateIndicator();
+    void testError();
+    void testHandleInteraction();
+    void testIndicatorData();
+    void testHandleClientRequest();
+    void testBringVtToForeground();
+    
+private:
+ 
+    LcVtIndicatorPlugin* mLcVtIndicatorPlugin; 
+
+};
+
+
+#endif //UT_LCVTINDICATORPLUGIN_H
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorplugin/tsrc/ut_lcvtindicatorplugin/src/main.cpp	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,53 @@
+/*
+* 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 <QtTest/QtTest>
+
+#include "ut_lcvtindicatorplugin.h"
+#include "testresultxmlparser.h"
+
+int main(int argc, char *argv[]) 
+{
+    bool promptOnExit(true);
+    for (int i=0; i<argc; i++) {
+        if (QString(argv[i]) == "-noprompt")
+            promptOnExit = false;
+    }
+    printf("Running tests...\n");
+    
+    QApplication app(argc, argv);
+    TestResultXmlParser parser;
+
+    UT_LcVtIndicatorPlugin ut_lcvtindicatorplugin;
+    QString resultFileName = "c:/ut_logs_ut_lcvtindicatorplugin.xml";
+    QStringList args_ut_lcvtindicatorplugin( "ut_ut_lcvtindicatorplugin");
+    args_ut_lcvtindicatorplugin << "-xml" << "-o" << resultFileName;
+    QTest::qExec(&ut_lcvtindicatorplugin, args_ut_lcvtindicatorplugin);
+    parser.parseAndPrintResults(resultFileName,true); 
+
+
+    if (promptOnExit) {
+        printf("Press any key...\n");
+        getchar(); 
+    }
+    return 0;   
+}
+
+
+
+ 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorplugin/tsrc/ut_lcvtindicatorplugin/src/ut_lcvtindicatorplugin.cpp	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,173 @@
+/*
+* 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 "ut_lcvtindicatorplugin.h"
+#include "lcvtindicatorplugin.h"
+#include "symbianstubs_helper.h"
+
+#include <QtTest/QtTest>
+
+const static QString lcVtIndicator = "com.nokia.hb.indicator.lcvtindicatorplugin/1.0";
+
+
+void UT_LcVtIndicatorPlugin::initTestCase()
+{
+
+}
+
+void UT_LcVtIndicatorPlugin::cleanupTestCase()
+{
+}
+
+void UT_LcVtIndicatorPlugin::init()
+{
+    mLcVtIndicatorPlugin = new LcVtIndicatorPlugin();
+}
+
+void UT_LcVtIndicatorPlugin::cleanup()
+{
+    delete mLcVtIndicatorPlugin;
+    mLcVtIndicatorPlugin = 0;
+}
+
+void UT_LcVtIndicatorPlugin::testLcVtIndicatorPlugin()
+{
+    QVERIFY( mLcVtIndicatorPlugin );
+}
+
+void UT_LcVtIndicatorPlugin::testIndicatorTypes()
+{
+	QCOMPARE(mLcVtIndicatorPlugin->indicatorTypes()[0], lcVtIndicator);
+}
+
+void  UT_LcVtIndicatorPlugin::testAccessAllowed()
+{
+	QVERIFY( mLcVtIndicatorPlugin->accessAllowed(QString(), QVariantMap()) );
+}
+
+void UT_LcVtIndicatorPlugin::testCreateIndicator()
+{
+	mLcVtIndicatorPlugin->createIndicator(lcVtIndicator);
+}
+
+void UT_LcVtIndicatorPlugin::testError()
+{
+    QVERIFY( !mLcVtIndicatorPlugin->error() );
+}
+
+
+void UT_LcVtIndicatorPlugin::testHandleInteraction()
+{
+    QSignalSpy spy(mLcVtIndicatorPlugin, SIGNAL(deactivate()));
+
+    //No interation requered
+    QVERIFY( !mLcVtIndicatorPlugin->handleInteraction(
+                 HbIndicatorInterface::NoInteraction) );
+    QCOMPARE( spy.count(), 0 );
+    
+    //Indicator activated, no VT running => deactivating
+    SymbianStubHelper::setVtTaskExists(false);
+    QVERIFY( !mLcVtIndicatorPlugin->handleInteraction(
+                     HbIndicatorInterface::InteractionActivated) );
+    QCOMPARE( spy.count(), 1 );
+    
+    //Indicator activated, VT running => bringing to FG
+    SymbianStubHelper::setVtTaskExists(true);
+    spy.clear();
+    QVERIFY( mLcVtIndicatorPlugin->bringVtToForeground() );    
+    QCOMPARE( spy.count(), 0 );   
+}
+
+void UT_LcVtIndicatorPlugin::testIndicatorData()
+{
+    //No params defined
+    QVERIFY( mLcVtIndicatorPlugin->indicatorData(
+                  HbIndicatorInterface::DecorationNameRole) == QVariant(QString()) );
+    QVERIFY( mLcVtIndicatorPlugin->indicatorData(
+                  HbIndicatorInterface::MonoDecorationNameRole) == QVariant(QString()) );
+    QVERIFY( mLcVtIndicatorPlugin->indicatorData(
+                  HbIndicatorInterface::PrimaryTextRole) == QVariant(QString()) );
+    QVERIFY( mLcVtIndicatorPlugin->indicatorData(
+                  HbIndicatorInterface::SecondaryTextRole) == QVariant() );
+    //Non-existing param role
+    QVERIFY( mLcVtIndicatorPlugin->indicatorData(999) == QVariant() );
+    
+    //Parameters defined
+    QVariantMap parameters;
+    parameters.insert(
+                QVariant(HbIndicatorInterface::DecorationNameRole).toString(),
+                QVariant("decoration") );
+    parameters.insert(
+                QVariant(HbIndicatorInterface::MonoDecorationNameRole).toString(),
+                QVariant("mono_decoration") );
+    parameters.insert(
+                QVariant(HbIndicatorInterface::PrimaryTextRole ).toString(),
+                QVariant("primary_text") );
+    parameters.insert(
+                QVariant(HbIndicatorInterface::SecondaryTextRole ).toString(),
+                QVariant("secondary_text") );
+    
+    mLcVtIndicatorPlugin->mParameter = parameters;
+    
+    QVERIFY( mLcVtIndicatorPlugin->indicatorData(
+                                  HbIndicatorInterface::DecorationNameRole)
+              == QVariant("decoration") );
+    QVERIFY( mLcVtIndicatorPlugin->indicatorData(
+                                  HbIndicatorInterface::MonoDecorationNameRole)
+              == QVariant("mono_decoration") );
+    QVERIFY( mLcVtIndicatorPlugin->indicatorData(
+                                  HbIndicatorInterface::PrimaryTextRole) 
+              == QVariant("primary_text") );
+    QVERIFY( mLcVtIndicatorPlugin->indicatorData(
+                                  HbIndicatorInterface::SecondaryTextRole)
+              == QVariant() );
+}
+
+void UT_LcVtIndicatorPlugin::testHandleClientRequest()
+{
+    QVariantMap parameters;
+    parameters.insert("key", QVariant("value"));
+    mLcVtIndicatorPlugin->mParameter = parameters;
+    QSignalSpy spy(mLcVtIndicatorPlugin, SIGNAL(dataChanged()));
+    
+    // Deactivate, params cleareds
+    QVERIFY( !mLcVtIndicatorPlugin->mParameter.isNull() );
+    QVERIFY( !mLcVtIndicatorPlugin->handleClientRequest(
+                HbIndicatorInterface::RequestDeactivate, QVariant()) );
+    QCOMPARE( spy.count(), 0 );
+    QVERIFY( mLcVtIndicatorPlugin->mParameter.isNull() );
+    
+    // Activate request, parameters changed
+    parameters.insert("key", QVariant("value"));
+    QVERIFY( mLcVtIndicatorPlugin->handleClientRequest(
+                    HbIndicatorInterface::RequestActivate, QVariant(parameters)) );
+    QCOMPARE( spy.count(), 1 );
+
+    // Activate request, parameters not changed
+    spy.clear();
+    QVERIFY( mLcVtIndicatorPlugin->handleClientRequest(
+                    HbIndicatorInterface::RequestActivate, QVariant(parameters)) );
+    QCOMPARE( spy.count(), 0 );
+}
+
+void UT_LcVtIndicatorPlugin::testBringVtToForeground()
+{
+    SymbianStubHelper::setVtTaskExists(false);
+    QVERIFY( !mLcVtIndicatorPlugin->bringVtToForeground() );
+    
+    SymbianStubHelper::setVtTaskExists(true);
+    QVERIFY( mLcVtIndicatorPlugin->bringVtToForeground() );    
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorplugin/tsrc/ut_lcvtindicatorplugin/stubs/symbianstubs.cpp	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,55 @@
+/*
+* Copyright (c) 2008-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:  HbMenu2 implementation.
+*
+*/
+
+
+#include "symbianstubs_helper.h"
+#include <apgtask.h>
+#include <w32std.h>
+#include <qglobal.h>
+
+bool testVtTaskExists = false;
+
+void SymbianStubHelper::reset()
+{
+    testVtTaskExists = false;
+}
+
+void SymbianStubHelper::setVtTaskExists(bool exists)
+{
+    testVtTaskExists = exists;
+}
+
+
+///////////////////////////////////////////////
+
+TApaTask TApaTaskList::FindApp(TUid aAppUid)
+{
+    Q_UNUSED(aAppUid)
+    RWsSession session;
+    return TApaTask(session);
+}
+
+
+TBool TApaTask::Exists() const
+{
+    return testVtTaskExists;
+}
+
+void TApaTask::BringToForeground()
+{
+    
+}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/vtuis/lcvtindicatorplugin/tsrc/ut_lcvtindicatorplugin/stubs/symbianstubs_helper.h	Fri Jul 09 15:04:41 2010 +0300
@@ -0,0 +1,33 @@
+/*
+* 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 SYMBIANSTUB_HELPER_H
+#define SYMBIANSTUB_HELPER_H
+
+
+/**
+* Helper class to control stub behavior
+*
+*/ 
+class SymbianStubHelper 
+{
+    public:
+        static void reset();
+        static void setVtTaskExists(bool exists);
+};
+
+#endif //SYMBIANSTUB_HELPER_H
--- a/vtuis/lcvtplugin/inc/base/clcvtsession.h	Tue Jul 06 14:18:02 2010 +0300
+++ b/vtuis/lcvtplugin/inc/base/clcvtsession.h	Fri Jul 09 15:04:41 2010 +0300
@@ -34,7 +34,7 @@
 #include    <lcsessionobserver.h>
 #include    <lcuiprovider.h>
 #include    <lcengine.h>
-
+//#include    <lcvtindicatorcontroller.h>
 #include    <cvtlogger.h>
 #include    <mvtengeventobserver.h>
 #include    <mvtengcommandobserver.h>
@@ -556,7 +556,7 @@
 
     HBufC* iRemoteDisplayName;
     HBufC* iRemoteDetails;
-    
+    //LcVtIndicatorController* iIndicatorCtr;
     };
     
 
--- a/vtuis/lcvtplugin/src/base/clcvtsession.cpp	Tue Jul 06 14:18:02 2010 +0300
+++ b/vtuis/lcvtplugin/src/base/clcvtsession.cpp	Fri Jul 09 15:04:41 2010 +0300
@@ -266,6 +266,8 @@
             TCallBack( &DelayedHandleLayoutChanged, this ),
             CActive::EPriorityStandard );   
 #endif    
+
+    //iIndicatorCtr = new  ( ELeave ) LcVtIndicatorController();
     __VTPRINTEXIT( "CLcVtSession.ConstructL" )
     
     }
@@ -301,6 +303,10 @@
     
     delete iRemoteDisplayName;
     delete iRemoteDetails;
+//    if (iIndicatorCtr) {
+//        iIndicatorCtr->disableActiveCallIndicator();
+//        delete iIndicatorCtr;
+//    }    
     __VTPRINTEXIT( "CLcVtSession.~CLcVtSession" )
     FeatureManager::UnInitializeLib();  
     }
@@ -443,9 +449,7 @@
 void CLcVtSession::TerminateLcSessionL()
     {
     __VTPRINTENTER( "CLcVtSession.TerminateLcSessionL" )    
-    
     HandleCommandL( EPluginCmdEndActiveCall );
-    
     __VTPRINTEXIT( "CLcVtSession.TerminateLcSessionL" )
     }
 
@@ -942,6 +946,13 @@
         iLocalVideoWindow->SetOrdinalPosition( 1 , priority );
         iRwSession.Flush();
         }
+//    if ( aIsForeground ) {
+//            iIndicatorCtr->disableActiveCallIndicator();
+//        }
+//    else  {
+//            iIndicatorCtr->enableActiveCallIndicator();
+//        }
+
     __VTPRINTEXIT( "CLcVtSession.SetForegroundStatus" )
     
     return KErrNone;