Revision: 201017
authorDremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Fri, 14 May 2010 15:58:48 +0300
changeset 33 8110bf1194d1
parent 29 26b6f0522fd8
child 35 4a49a8c90306
child 37 6e7b00453237
Revision: 201017 Kit: 201019
appinstall_plat/group/bld.inf
appinstall_plat/sifui_api/inc/sifuiprivate.h
appinstall_plat/sifui_api/src/sifuiprivate.cpp
appinstaller/AppinstUi/Daemon/Src/DialogWrapper.cpp
appinstaller/AppinstUi/Daemon/Src/SilentLauncher.cpp
appinstaller/AppinstUi/group/bld.inf
appinstaller/AppinstUi/sifuidevicedialogplugin/src/sifuidialog.cpp
appinstaller/AppinstUi/sifuiinstallindicatorplugin/inc/sifuiinstallindicator.h
appinstaller/AppinstUi/sifuiinstallindicatorplugin/inc/sifuiinstallindicatorparams.h
appinstaller/AppinstUi/sifuiinstallindicatorplugin/sifuiinstallindicatorplugin.qcrml
appinstaller/AppinstUi/sifuiinstallindicatorplugin/src/sifuiinstallindicator.cpp
appinstaller/AppinstUi/sifuiinstallindicatorplugin/src/sifuiinstallindicatorplugin.cpp
appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/ctc_instrument_code.bat
appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/mt_sifuiinstallindicator.cpp
appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/mt_sifuiinstallindicator.h
appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/mt_sifuiinstallindicator.pro
appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/testindiapp/testindiapp.cpp
appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/testindiapp/testindiapp.h
appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/testindiapp/testindiapp.pro
appinstaller/AppinstUi/sisxsifplugin/group/sisxsifplugin.mmp
appinstaller/AppinstUi/sisxsifplugin/inc/sisxsifpluginactiveimpl.h
appinstaller/AppinstUi/sisxsifplugin/inc/sisxsifpluginuihandler.h
appinstaller/AppinstUi/sisxsifplugin/src/sisxsifpluginactiveimpl.cpp
appinstaller/AppinstUi/sisxsifplugin/src/sisxsifpluginuihandler.cpp
appinstaller/AppinstUi/sisxsifplugin/tsrc/testinstaller/activerunner_symbian.h
appinstaller/AppinstUi/sisxsifplugin/tsrc/testinstaller/testinstaller.cpp
appinstaller/AppinstUi/startuplistupdater/group/bld.inf
appinstaller/AppinstUi/startuplistupdater/group/startuplistupdater.mmp
appinstaller/AppinstUi/startuplistupdater/inc/cleanupresetanddestroy.h
appinstaller/AppinstUi/startuplistupdater/inc/startuplistupdater.h
appinstaller/AppinstUi/startuplistupdater/rom/startuplistupdater.iby
appinstaller/AppinstUi/startuplistupdater/src/main.cpp
appinstaller/AppinstUi/startuplistupdater/src/startuplistupdater.cpp
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/bwins/mt_startuplistupdateru.def
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/conf/mt_startuplistupdater.cfg
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/ctc_compile_tests.bat
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/ctc_instrument_code.bat
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/ctc_remove_instrumentation.bat
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/ctc_run_tests.bat
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data/mmc/teststartlist.sisx
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data/mmc/teststartlist_winscw.sisx
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/bld.inf
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/doall.bat
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist.cpp
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist.h
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist.mmp
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist.pkg
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist.rss
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist_winscw.pkg
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/eabi/mt_startuplistupdateru.def
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/group/bld.inf
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/group/mt_startuplistupdater.mmp
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/group/mt_startuplistupdater.pkg
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/group/mt_startuplistupdater_nrm.mmp
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/inc/cleanupresetanddestroy.h
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/inc/mt_startuplistupdater.h
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/init/TestFramework.ini
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/rom/mt_startuplistupdater.iby
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/src/mt_startuplistupdater.cpp
appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/src/mt_startuplistupdaterblocks.cpp
appinstaller/AppinstUi/startuplistupdater/tsrc/run_module_tests.bat
appinstaller/AppinstUi/startuplistupdater/tsrc/testslulauncher/main.cpp
appinstaller/AppinstUi/startuplistupdater/tsrc/testslulauncher/testslulauncher.cpp
appinstaller/AppinstUi/startuplistupdater/tsrc/testslulauncher/testslulauncher.h
appinstaller/AppinstUi/startuplistupdater/tsrc/testslulauncher/testslulauncher.pro
iaupdate/IAD/backgroundchecker/inc/iaupdatebgrefreshtimer.h
iaupdate/IAD/backgroundchecker/src/iaupdatebgrefreshtimer.cpp
iaupdate/IAD/backgroundchecker/src/iaupdatebgsoftnotification.cpp
iaupdate/IAD/bgcindicatorplugin/inc/bgcindicatorplugin.h
iaupdate/IAD/bgcindicatorplugin/rom/bgcindicatorplugin.iby
iaupdate/IAD/bgcindicatorplugin/src/bgcindicator.cpp
iaupdate/IAD/bgcindicatorplugin/src/bgcindicatorplugin.cpp
iaupdate/IAD/engine/bwins/iaupdateengineu.def
iaupdate/IAD/engine/controller/inc/iaupdatenodeimpl.h
iaupdate/IAD/engine/controller/src/iaupdateinstalloperation.cpp
iaupdate/IAD/engine/controller/src/iaupdatenodeimpl.cpp
iaupdate/IAD/engine/controller/src/iaupdateutils.cpp
iaupdate/IAD/engine/eabi/iaupdateengineu.def
iaupdate/IAD/engine/inc/iaupdatenode.h
iaupdate/IAD/engine/inc/iaupdateutils.h
iaupdate/IAD/ui/iaupdate.pro
iaupdate/IAD/ui/iaupdate_mainview.docml
iaupdate/IAD/ui/inc/iaupdateagreement.h
iaupdate/IAD/ui/inc/iaupdateapplication.h
iaupdate/IAD/ui/inc/iaupdateengine.h
iaupdate/IAD/ui/inc/iaupdatemainview.h
iaupdate/IAD/ui/inc/iaupdatemainwindow.h
iaupdate/IAD/ui/inc/iaupdateresultsdialog.h
iaupdate/IAD/ui/inc/iaupdateuicontroller.h
iaupdate/IAD/ui/src/iaupdateagreement.cpp
iaupdate/IAD/ui/src/iaupdateapplication.cpp
iaupdate/IAD/ui/src/iaupdateautomaticcheck.cpp
iaupdate/IAD/ui/src/iaupdateengine.cpp
iaupdate/IAD/ui/src/iaupdatemainview.cpp
iaupdate/IAD/ui/src/iaupdatemainwindow.cpp
iaupdate/IAD/ui/src/iaupdateresultsdialog.cpp
iaupdate/IAD/ui/src/iaupdateserviceprovider.cpp
iaupdate/IAD/ui/src/iaupdateuicontroller.cpp
iaupdate/rom/iaupdate.iby
installationservices/refswinstallationplugin/group/sifrefinstallerserver.mmp
installationservices/refswinstallationplugin/group/sifrefpkgrec.mmp
installationservices/refswinstallationplugin/group/sifrefplugin.mmp
installationservices/swcomponentregistry/bwins/scrdatabaseu.def
installationservices/swcomponentregistry/eabi/scrdatabaseu.def
installationservices/swcomponentregistry/group/bld.inf
installationservices/swcomponentregistry/inc/tscr.iby
installationservices/swcomponentregistry/inc_private/scrclient.inl
installationservices/swcomponentregistry/inc_private/scrdatabase.h
installationservices/swcomponentregistry/inc_private/scrrequestimpl.h
installationservices/swcomponentregistry/source/database/scrdatabase.cpp
installationservices/swcomponentregistry/source/server/scrrequestimpl.cpp
installationservices/swcomponentregistry/test/tscr/inc/tscrstep.h
installationservices/swcomponentregistry/test/tscr/scripts/data/scr_large.db
installationservices/swcomponentregistry/test/tscr/scripts/data/scr_medium.db
installationservices/swcomponentregistry/test/tscr/scripts/data/scr_small.db
installationservices/swcomponentregistry/test/tscr/scripts/tscr_app_performance_cases.script
installationservices/swcomponentregistry/test/tscr/scripts/tscr_appreginfo.ini
installationservices/swcomponentregistry/test/tscr/scripts/tscr_performance.ini
installationservices/swcomponentregistry/test/tscr/source/appreginfosteps.cpp
installationservices/swcomponentregistry/test/tscr/source/tscrserver.cpp
installationservices/swcomponentregistry/test/tscrapparc/inc/appreginfoapparcsteps.h
installationservices/swcomponentregistry/test/tscrapparc/inc/tscrapparcserver.h
installationservices/swcomponentregistry/test/tscrapparc/source/appreginfoapparcsteps.cpp
installationservices/swcomponentregistry/test/tscrapparc/source/tscrapparcserver.cpp
installationservices/swi/group/bld.inf
installationservices/swi/source/backuprestore/backupsession.cpp
installationservices/swi/source/sislauncher/client/sislauncherclient.cpp
installationservices/swi/source/sislauncher/server/sislauncherserver.cpp
installationservices/swi/source/sislauncher/server/sislaunchersession.cpp
installationservices/swi/source/sislauncher/server/sislaunchersession.h
installationservices/swi/source/sisregistry/server_legacy/sisregistrycache.cpp
installationservices/swi/source/swis/server/installationprocessor.cpp
installationservices/swi/source/swis/server/installmachine.cpp
installationservices/swi/source/swis/server/restorecontroller.cpp
installationservices/swi/source/swis/server/restoremachine.cpp
installationservices/swi/source/swis/server/restoreprocessor.cpp
installationservices/swi/source/swis/server/restoreprocessor.h
installationservices/swi/source/swis/server/statemachine.cpp
installationservices/swi/test/tbackuprestore/scripts/batchfiles/tbackuprestore_post.bat
installationservices/swi/test/tbackuprestore/scripts/batchfiles/tbackuprestore_pre.bat
installationservices/swi/test/tbackuprestore/scripts/ini
installationservices/swi/test/tbackuprestore/scripts/ini_armv5
installationservices/swi/test/tbackuprestore/scripts/tbackuprestore.script
installationservices/swi/test/tbackuprestore/scripts/tbackuprestore_armv5.script
installationservices/swi/test/testexes/packages/int_nr_option_04.pkg
installationservices/swi/test/testexes/packages/int_nr_option_05.pkg
installationservices/swi/test/testexes/packages/nonremovableupgrade.pkg
installationservices/swi/test/testexes/packages/sp_int_nr_option_04.pkg
installationservices/swi/test/testexes/packages/sp_int_nr_option_06.pkg
installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_01.pkg
installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_02.pkg
installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_03.pkg
installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_04.pkg
installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_05.pkg
installationservices/swi/test/testexes/packages_interpretsis_testcase/pu_int_nr_option_01.pkg
installationservices/swi/test/testexes/packages_interpretsis_testcase/sp_int_nr_option_01.pkg
installationservices/swi/test/testexes/packages_interpretsis_testcase/sp_int_nr_option_04.pkg
installationservices/swi/test/testexes/packages_interpretsis_testcase/sp_int_nr_option_06.pkg
installationservices/swi/test/testexes/tswiappregintegration/bld.inf
installationservices/swi/test/testexes/tswiappregintegration/case05/01-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case05/02-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case05/03-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case05/04-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case05/rsc-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case05/swiappregintegration_case05_loc.rss
installationservices/swi/test/testexes/tswiappregintegration/case05/swiappregintegration_case05_reg.rss
installationservices/swi/test/testexes/tswiappregintegration/case05/swiappregintegration_case05_su_reg.rss
installationservices/swi/test/testexes/tswiappregintegration/case06/01-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case06/02-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case06/03-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case06/04-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case06/rsc-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case06/swiappregintegration_case06_loc.rss
installationservices/swi/test/testexes/tswiappregintegration/case06/swiappregintegration_case06_reg.rss
installationservices/swi/test/testexes/tswiappregintegration/case07/01-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case07/02-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case07/03-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case07/04-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case07/rsc-strings.rls
installationservices/swi/test/testexes/tswiappregintegration/case07/swiappregintegration_case07_loc.rss
installationservices/swi/test/testexes/tswiappregintegration/case07/swiappregintegration_case07_reg.rss
installationservices/swi/test/testexes/tswiappregintegration/tswiappregintegration05.mmp
installationservices/swi/test/testexes/tswiappregintegration/tswiappregintegration06.mmp
installationservices/swi/test/testexes/tswiappregintegration/tswiappregintegration07.mmp
installationservices/swi/test/tuiscriptadaptors/scripts/tswiappregintegration.ini
installationservices/swi/test/tuiscriptadaptors/scripts/tswiappregintegration.script
installationservices/swiconfig/conf/appinstallconfig_2002cff6.crml
installationservices/swiconfig/swi/swiconfig.iby
installationservices/swiconfig/usif/scr/scr.db
installationservices/swiconfig/usif/scr/update_db_production.xml
installationservices/swiconfig/usif/siflauncher/siflauncher_reg.rss
installationservices/swinstallationfw/bwins/sifnotificationu.def
installationservices/swinstallationfw/eabi/sifnotificationu.def
installationservices/swinstallationfw/examples/refnativeplugin/group/refnativeplugin.mmp
installationservices/swinstallationfw/group/bld.inf
installationservices/swinstallationfw/group/siflauncher.mmp
installationservices/swinstallationfw/group/sifnotification.mmp
installationservices/swinstallationfw/group/sifserver.mmp
installationservices/swinstallationfw/group/siftransport.mmp
installationservices/swinstallationfw/inc/sif.iby
installationservices/swinstallationfw/inc/sifcommon.h
installationservices/swinstallationfw/inc/sifnotification.h
installationservices/swinstallationfw/inc/tsif.iby
installationservices/swinstallationfw/inc_private/sifnotification_internal.h
installationservices/swinstallationfw/source/sifnotification.cpp
installationservices/swinstallationfw/source/sifnotifierdata.cpp
installationservices/swinstallationfw/source/sifservertask.cpp
installationservices/swinstallationfw/source/siftransportserver.cpp
installationservices/swinstallationfw/test/group/cleansiflauncher.bat
installationservices/swinstallationfw/test/group/tsiflauncher.mmp
installationservices/swinstallationfw/test/plugins/nonnativeplugin/group/testnonnativeplugin.mmp
installationservices/swinstallationfw/test/plugins/nonnativeplugin/group/testnonnativeplugin2.mmp
installationservices/swinstallationfw/test/siflauncherconfig/siflauncher_reg.rss
installationservices/swinstallationfw/test/tusif/group/createleesisfiles.pl
installationservices/swinstallationfw/test/tusif/group/tsif.mmp
installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case05.pkg
installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case05_SU.pkg
installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_base.pkg
installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_pu.pkg
installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_sa.pkg
installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_sp1.pkg
installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_sp2.pkg
installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_sp3.pkg
installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case08_sa1.pkg
installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case08_sa2.pkg
installationservices/swinstallationfw/test/tusif/scripts/tnotifier.ini
installationservices/swinstallationfw/test/tusif/scripts/tnotifier.script
installationservices/swinstallationfw/test/tusif/source/tsifnotifierteststep.cpp
installationservices/swinstallationfw/test/tusif/source/tsifnotifierteststep.h
installationservices/swinstallationfw/test/tusif/source/tsifsuitedefs.h
installationservices/swinstallationfw/test/tusif/source/tsifsuiteserver.cpp
installationservices/switestfw/test/autotesting/hosts
installationservices/switestfw/test/autotesting/runusiftests.bat
installationservices/switestfw/test/autotesting/test_spec_apr_9.5.txt
ncdengine/engine/group/catalogsserver.mmp
package_definition.xml
secureswitools/swisistools/group/interpretsislib.mmp
secureswitools/swisistools/source/dbmanager/dblayer.cpp
secureswitools/swisistools/source/dbmanager/dbprocessor.cpp
secureswitools/swisistools/source/dbmanager/dbprocessor.h
secureswitools/swisistools/source/interpretsis/main.cpp
secureswitools/swisistools/source/interpretsislib/installer.cpp
secureswitools/swisistools/source/interpretsislib/installer.h
secureswitools/swisistools/source/interpretsislib/sisregistry.cpp
secureswitools/swisistools/source/rscparser/aplappinforeader.cpp
secureswitools/swisistools/source/rscparser/barscimpl.cpp
secureswitools/swisistools/source/rscparser/barscimpl.h
secureswitools/swisistools/source/rscparser/barsreadimpl.cpp
secureswitools/swisistools/source/rscparser/commontypes.cpp
secureswitools/swisistools/source/rscparser/commontypes.h
secureswitools/swisistools/source/rscparser/dictionarycompression.cpp
secureswitools/swisistools/source/rscparser/dictionarycompression.h
secureswitools/swisistools/source/rscparser/dirparse.cpp
secureswitools/swisistools/source/rscparser/uidtype.cpp
secureswitools/swisistools/source/rscparser/uidtype.h
secureswitools/swisistools/test/tinterpretsisinteg/data/regfiles/tstapp_reg.rss
secureswitools/swisistools/test/tinterpretsisinteg/int_nr_option-01_db.bat
secureswitools/swisistools/test/tinterpretsisinteg/scripts/ini.ini
secureswitools/swisistools/test/tscrtool/data/preprovision.dtd
secureswitools/swisistools/test/tscrtool/data/preprovision_appreginfo.xml
secureswitools/swisistools/test/tscrtool/data/preprovision_nocaptioniconinfo.xml
secureswitools/swisistools/test/tscrtool/data/preprovision_nullappfile.xml
secureswitools/swisistools/test/tscrtool/data/preprovision_nullappuid.xml
tsrc/group/bld.inf
--- a/appinstall_plat/group/bld.inf	Mon May 03 12:38:03 2010 +0300
+++ b/appinstall_plat/group/bld.inf	Fri May 14 15:58:48 2010 +0300
@@ -25,6 +25,5 @@
 #include "../sw_installer_ui_plugin_api/group/bld.inf"
 #include "../sw_installer_cr_keys/group/bld.inf"
 #include "../sw_installer_ps_keys/group/bld.inf"
-#include "../appmngr2runtimeapi/group/bld.inf"
 #include "../sifui_api/group/bld.inf"
 
--- a/appinstall_plat/sifui_api/inc/sifuiprivate.h	Mon May 03 12:38:03 2010 +0300
+++ b/appinstall_plat/sifui_api/inc/sifuiprivate.h	Fri May 14 15:58:48 2010 +0300
@@ -19,7 +19,7 @@
 #define C_SIFUIPRIVATE_H
 
 #include <e32base.h>                            // CActive
-#include <hb/hbcore/hbsymbiandevicedialog.h>    // MHbDeviceDialogObserver
+#include <hb/hbcore/hbdevicedialogsymbian.h>    // MHbDeviceDialogObserver
 #include <bamdesca.h>                           // MDesCArray
 
 class CHbDeviceDialog;
@@ -79,7 +79,7 @@
         void ResponseReceived( TInt aCompletionCode );
 
     private:    // data
-        CHbDeviceDialog* iDeviceDialog;
+        CHbDeviceDialogSymbian* iDeviceDialog;
         CHbSymbianVariantMap* iVariantMap;
         CActiveSchedulerWait* iWait;
         TBool iIsDisplayingDialog;
--- a/appinstall_plat/sifui_api/src/sifuiprivate.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstall_plat/sifui_api/src/sifuiprivate.cpp	Fri May 14 15:58:48 2010 +0300
@@ -17,7 +17,6 @@
 
 #include "sifuiprivate.h"                       // CSifUiPrivate
 #include "sifuidefs.h"                          // SIF UI device dialog parameters
-#include <hb/hbcore/hbsymbiandevicedialog.h>    // CHbDeviceDialog
 #include <hb/hbcore/hbsymbianvariant.h>         // CHbSymbianVariantMap
 #include <swi/msisuihandlers.h>                 // Swi::CAppInfo
 #include <apgicnfl.h>                           // CApaMaskedBitmap
@@ -404,7 +403,7 @@
         {
         if( !iDeviceDialog )
             {
-            iDeviceDialog = CHbDeviceDialog::NewL();
+            iDeviceDialog = CHbDeviceDialogSymbian::NewL();
             }
         iDeviceDialog->Show( KSifUiDeviceDialog, *iVariantMap, this );
         iIsDisplayingDialog = ETrue;
--- a/appinstaller/AppinstUi/Daemon/Src/DialogWrapper.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/Daemon/Src/DialogWrapper.cpp	Fri May 14 15:58:48 2010 +0300
@@ -233,7 +233,7 @@
     
 	if ( iIsProgressDialog )
 		{
-		iHbProgressDialog->Cancel();
+		iHbProgressDialog->Close();
 		delete iHbProgressDialog;
 		iHbProgressDialog = NULL;
 		iIsProgressDialog = EFalse;
--- a/appinstaller/AppinstUi/Daemon/Src/SilentLauncher.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/Daemon/Src/SilentLauncher.cpp	Fri May 14 15:58:48 2010 +0300
@@ -60,8 +60,9 @@
     iSifOptions->AddIntL( Usif::KSifInParam_GrantCapabilities, EFalse ); 
     // Defined for the install.
     iSifOptions->AddIntL( Usif::KSifInParam_InstallOptionalItems, ETrue );          
-    iSifOptions->AddIntL( Usif::KSifInParam_IgnoreOCSPWarnings, ETrue );   
-    iSifOptions->AddIntL( Usif::KSifInParam_DisplayPackageInfo, ETrue );     
+    iSifOptions->AddIntL( Usif::KSifInParam_IgnoreOCSPWarnings, ETrue ); 
+    // TODO: Is this removed from current USIF ?	  
+    //iSifOptions->AddIntL( Usif::KSifInParam_DisplayPackageInfo, ETrue );     
     iSifOptions->AddIntL( Usif::KSifInParam_AllowAppShutdown, ETrue );
     iSifOptions->AddIntL( Usif::KSifInParam_AllowDownload, ETrue );
     iSifOptions->AddIntL( Usif::KSifInParam_AllowOverwrite, ETrue );
--- a/appinstaller/AppinstUi/group/bld.inf	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/group/bld.inf	Fri May 14 15:58:48 2010 +0300
@@ -84,4 +84,6 @@
 // SISX SIF plugin
 #include "../sisxsifplugin/group/bld.inf"
 
+// Startup list updater
+#include "../startuplistupdater/group/bld.inf"
 
--- a/appinstaller/AppinstUi/sifuidevicedialogplugin/src/sifuidialog.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuidevicedialogplugin/src/sifuidialog.cpp	Fri May 14 15:58:48 2010 +0300
@@ -28,6 +28,8 @@
 #include <hbmessagebox.h>
 #include <qvaluespacesubscriber.h>
 
+QTM_USE_NAMESPACE
+
 const QString KTranslationsPath = "resource/qt/translations/";
 const QString KTranslationsFile = "sifuidevicedialogplugin";
 const QString KSwiErrorsFile = "c:\\temp\\swierrors.txt";
@@ -329,7 +331,7 @@
 void SifUiDialog::monitorIndicatorActivity()
 {
     if (!mSubscriber) {
-        mSubscriber = new QTM_PREPEND_NAMESPACE(QValueSpaceSubscriber(KSifUiIndicatorPath));
+        mSubscriber = new QValueSpaceSubscriber(KSifUiInstallIndicatorStatusPath);
         connect(mSubscriber, SIGNAL(contentsChanged()),
             this, SLOT(handleIndicatorActivityChanged()));
     }
@@ -382,31 +384,11 @@
 {
     if (!mIndicator) {
         mIndicator = new HbIndicator(this);
-
-        QVariantMap variantMap;
-        QVariant applicationNameVariant(mContent->applicationName());
-        variantMap.insert(KSifUiIndicatorApplicationName, applicationNameVariant);
-
+        QVariant applicationName(mContent->applicationName());
         if (!mContent->isDefaultIconUsed()) {
-            int iconHandle = 0;
-            int maskHandle = 0;
-            mContent->iconHandles(iconHandle, maskHandle);
-            QVariant iconHandleVariant(iconHandle);
-            variantMap.insert(KSifUiIndicatorAppIconHandle, iconHandleVariant);
-            QVariant maskHandleVariant(maskHandle);
-            variantMap.insert(KSifUiIndicatorAppIconMaskHandle, maskHandleVariant);
+            // TODO: send icon to indicator
         }
-
-        int finalValue = 0;
-        int progressValue = 0;
-        mContent->progressInfo(finalValue, progressValue);
-        QVariant finalValueVariant(finalValue);
-        variantMap.insert(KSifUiIndicatorProgressFinal, finalValueVariant);
-        QVariant progressValueVariant(progressValue);
-        variantMap.insert(KSifUiIndicatorProgressValue, progressValueVariant);
-
-        QVariant parameter(variantMap);
-        if (mIndicator->activate(KSifUiIndicatorPlugin, parameter)) {
+        if (mIndicator->activate(KSifUiInstallIndicatorType, applicationName)) {
             hide();
             monitorIndicatorActivity();
         }
@@ -419,7 +401,7 @@
 //
 void SifUiDialog::handleIndicatorActivityChanged()
 {
-    QVariant variant = mSubscriber->value(KSifUiIndicatorActive);
+    QVariant variant = mSubscriber->value();
     if (variant.isValid() && (variant.type() == QVariant::Int)) {
         bool valueOk = false;
         int intValue = variant.toInt(&valueOk);
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/inc/sifuiinstallindicator.h	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/inc/sifuiinstallindicator.h	Fri May 14 15:58:48 2010 +0300
@@ -51,7 +51,9 @@
 
 private:    // data
     QString mAppName;
+    int mProgress;
     QTM_PREPEND_NAMESPACE(QValueSpacePublisher) *mPublisher;
+    bool mIsActive;
 };
 
 #endif  // SIFUIINSTALLINDICATOR_H
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/inc/sifuiinstallindicatorparams.h	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/inc/sifuiinstallindicatorparams.h	Fri May 14 15:58:48 2010 +0300
@@ -19,18 +19,12 @@
 #define SIFUIINSTALLINDICATORPARAMS_H
 
 // Install indicator plugin type string
-const QString KSifUiIndicatorPlugin = "com.nokia.sifui.indi/1.0";
-
-// Variant map keys for install indicator
-const QString KSifUiIndicatorApplicationName = "app";       // string
-const QString KSifUiIndicatorAppIconHandle = "icon";        // integer, bitmap handle
-const QString KSifUiIndicatorAppIconMaskHandle = "mask";    // integer, bitmap handle
-const QString KSifUiIndicatorProgressValue = "pval";        // integer
-const QString KSifUiIndicatorProgressFinal = "pfin";        // integer
+const QString KSifUiInstallIndicatorType = "com.nokia.sifui.indi/1.0";
 
 // Path and value name for QValueSpacePublisher/QValueSpaceSubscriber.
-const QString KSifUiIndicatorPath = "/sifui";
-const QString KSifUiIndicatorActive = "indicator_active";
+const QString KSifUiInstallIndicatorPath = "/SifUiInstallIndicator";
+const QString KSifUiInstallIndicatorStatus = "Status";
+const QString KSifUiInstallIndicatorStatusPath = "/SifUiInstallIndicator/Status";
 
 #endif // SIFUIINSTALLINDICATORPARAMS_H
 
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/sifuiinstallindicatorplugin.qcrml	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/sifuiinstallindicatorplugin.qcrml	Fri May 14 15:58:48 2010 +0300
@@ -1,4 +1,4 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<repository target="RProperty" uidValue="0x2002E690">
-<key ref="/sifui/indicator_active" int="0x00000001"/>
+<repository target="RProperty" uidValue="0x20022FC5">
+<key int="0x2002E690" ref="/SifUiInstallIndicator/Status"></key>
 </repository>
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/src/sifuiinstallindicator.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/src/sifuiinstallindicator.cpp	Fri May 14 15:58:48 2010 +0300
@@ -20,15 +20,19 @@
 #include <QVariant>
 #include <qvaluespacepublisher.h>
 
+const char KSifUiDefaultApplicationIcon[] = "qtg_large_application.svg";
+const QString KSifUiPathSeparator = "/";
+
 
 // ---------------------------------------------------------------------------
 // SifUiInstallIndicator::SifUiInstallIndicator()
 // ---------------------------------------------------------------------------
 //
 SifUiInstallIndicator::SifUiInstallIndicator(const QString &indicatorType) :
-    HbIndicatorInterface(indicatorType, HbIndicatorInterface::GroupPriorityHigh,
-            InteractionActivated), mAppName(), mPublisher(0)
+    HbIndicatorInterface(indicatorType, HbIndicatorInterface::ProgressCategory,
+            InteractionActivated), mAppName(), mPublisher(0), mIsActive(false)
 {
+    mPublisher = new QTM_PREPEND_NAMESPACE(QValueSpacePublisher(KSifUiInstallIndicatorPath));
 }
 
 // ---------------------------------------------------------------------------
@@ -37,6 +41,9 @@
 //
 SifUiInstallIndicator::~SifUiInstallIndicator()
 {
+    if (mPublisher && mIsActive) {
+        publishActivityStatus(false);
+    }
     delete mPublisher;
 }
 
@@ -50,6 +57,7 @@
 
     if (type == InteractionActivated) {
         emit deactivate();
+        publishActivityStatus(false);
         handled = true;
     }
 
@@ -65,19 +73,21 @@
     QVariant data;
 
     switch(role) {
-        case IconNameRole:
         case DecorationNameRole:
-            // TODO: use proper icon when available
-            data = QString("note_info.svg");
+            data = QString(KSifUiDefaultApplicationIcon);
             break;
         case PrimaryTextRole:
             //: Primary text for application installation progress displayed in
             //: universal indicator menu. Secondary text is the application name.
             // TODO: use localised UI string when available
-            data = tr("Installing...");
+            data = tr("Installing");
+            // TODO: text must indicate installation phase, need to support also
+            // tr("Downloading") and tr("Doing OCSP checks")
             break;
         case SecondaryTextRole:
-            data = mAppName;
+            if (!mAppName.isEmpty()) {
+                data = tr("%1 (%L2 %)").arg(mAppName).arg(mProgress);
+            }
         default:
             break;
     }
@@ -115,9 +125,12 @@
 //
 void SifUiInstallIndicator::processParameters(const QVariant &parameter)
 {
-    if (parameter.isValid() && (parameter.type() == QVariant::Map)) {
-        QVariantMap map = parameter.toMap();
-        mAppName = map.value(KSifUiIndicatorApplicationName).toString();
+    if (parameter.isValid() && (parameter.type() == QVariant::String)) {
+        mAppName = parameter.toString();
+        mProgress = 0;
+
+        // TODO: get icon if standard icon needs to be replaced
+        // TODO: start listening USIF installation progress
     }
 }
 
@@ -127,9 +140,13 @@
 //
 void SifUiInstallIndicator::publishActivityStatus(bool status)
 {
-    if (!mPublisher) {
-        mPublisher = new QTM_PREPEND_NAMESPACE(QValueSpacePublisher(KSifUiIndicatorPath));
+    if (status != mIsActive) {
+        if (mPublisher) {
+            int intStatus = status;
+            mPublisher->setValue(KSifUiInstallIndicatorStatus, QVariant(intStatus));
+            mPublisher->sync();
+        }
+        mIsActive = status;
     }
-    mPublisher->setValue(KSifUiIndicatorActive, QVariant(status));
 }
 
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/src/sifuiinstallindicatorplugin.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/src/sifuiinstallindicatorplugin.cpp	Fri May 14 15:58:48 2010 +0300
@@ -45,7 +45,7 @@
 QStringList SifUiInstallIndicatorPlugin::indicatorTypes() const
 {
     QStringList types;
-    types << KSifUiIndicatorPlugin;
+    types << KSifUiInstallIndicatorType;
     return types;
 }
 
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/ctc_instrument_code.bat	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/ctc_instrument_code.bat	Fri May 14 15:58:48 2010 +0300
@@ -25,8 +25,8 @@
 if exist MON.sym del MON.sym
 if exist MON.dat del MON.dat
 call qmake
-call bldmake bldfiles
-call abld reallyclean winscw udeb
-call ctcwrap -i f -C "EXCLUDE+moc_*.cpp" -C "EXCLUDE+*.UID.CPP" -C "SKIP_FUNCTION_NAME+qt_plugin_query_verification_data" -C "SKIP_FUNCTION_NAME+qt_plugin_instance" abld build winscw udeb
+call make distclean
+call qmake
+call ctcwrap -i f -2comp -C "EXCLUDE+moc_*.cpp" -C "EXCLUDE+*.UID.CPP" -C "SKIP_FUNCTION_NAME+SifUiInstallIndicatorPlugin::error()" -C "SKIP_FUNCTION_NAME+qt_plugin_query_verification_data" -C "SKIP_FUNCTION_NAME+qt_plugin_instance" make debug-winscw
 popd
 
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/mt_sifuiinstallindicator.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/mt_sifuiinstallindicator.cpp	Fri May 14 15:58:48 2010 +0300
@@ -18,8 +18,11 @@
 #include "mt_sifuiinstallindicator.h"
 #include "sifuiinstallindicatorparams.h"
 #include <hbindicator.h>
+#include <qvaluespacesubscriber.h>
 #include <QTest>
 
+QTM_USE_NAMESPACE
+
 
 // ---------------------------------------------------------------------------
 // TestSifUiInstallIndicator::activateWithoutParams()
@@ -27,13 +30,22 @@
 //
 void TestSifUiInstallIndicator::activateWithoutParams()
 {
+    QValueSpaceSubscriber *subscriber = 0;
+    subscriber = new QValueSpaceSubscriber(KSifUiInstallIndicatorStatusPath);
+    QSignalSpy indicatorStatusSpy(subscriber, SIGNAL(contentsChanged()));
+
     HbIndicator *indicator = new HbIndicator();
     QVERIFY(indicator != 0);
     QVERIFY(indicator->error() == 0);
-    QVERIFY(indicator->activate(KSifUiIndicatorPlugin));
+
+    QVERIFY(indicator->activate(KSifUiInstallIndicatorType));
     QTest::qWait(3000);
-    QVERIFY(indicator->deactivate(KSifUiIndicatorPlugin));
+    QCOMPARE(indicatorStatusSpy.count(), 1);
+    QVERIFY(indicator->deactivate(KSifUiInstallIndicatorType));
     delete indicator;
+
+    QCOMPARE(indicatorStatusSpy.count(), 2);
+    delete subscriber;
 }
 
 // ---------------------------------------------------------------------------
@@ -46,13 +58,19 @@
     QVERIFY(indicator != 0);
     QVERIFY(indicator->error() == 0);
 
-    QVariantMap map;
-    map.insert(KSifUiIndicatorApplicationName, QString("Application name"));
-    QVariant params(map);
-    QVERIFY(indicator->activate(KSifUiIndicatorPlugin, params));
+    QValueSpaceSubscriber *subscriber = 0;
+    subscriber = new QValueSpaceSubscriber(KSifUiInstallIndicatorStatusPath);
+    QSignalSpy indicatorStatusSpy(subscriber, SIGNAL(contentsChanged()));
+
+    QVariant params(QString("Test application"));
+    QVERIFY(indicator->activate(KSifUiInstallIndicatorType, params));
     QTest::qWait(3000);
-    QVERIFY(indicator->deactivate(KSifUiIndicatorPlugin));
+    QCOMPARE(indicatorStatusSpy.count(), 1);
+    QVERIFY(indicator->deactivate(KSifUiInstallIndicatorType));
     delete indicator;
+
+    QCOMPARE(indicatorStatusSpy.count(), 2);
+    delete subscriber;
 }
 
 // ---------------------------------------------------------------------------
@@ -61,15 +79,23 @@
 //
 void TestSifUiInstallIndicator::activateWithInvalidParam()
 {
+    QValueSpaceSubscriber *subscriber = 0;
+    subscriber = new QValueSpaceSubscriber(KSifUiInstallIndicatorStatusPath);
+    QSignalSpy indicatorStatusSpy(subscriber, SIGNAL(contentsChanged()));
+
     HbIndicator *indicator = new HbIndicator();
     QVERIFY(indicator != 0);
     QVERIFY(indicator->error() == 0);
 
     QVariant params(QByteArray("test"));
-    QVERIFY(indicator->activate(KSifUiIndicatorPlugin, params));
+    QVERIFY(indicator->activate(KSifUiInstallIndicatorType, params));
     QTest::qWait(3000);
-    QVERIFY(indicator->deactivate(KSifUiIndicatorPlugin));
+    QCOMPARE(indicatorStatusSpy.count(), 1);
+    QVERIFY(indicator->deactivate(KSifUiInstallIndicatorType));
     delete indicator;
+
+    QCOMPARE(indicatorStatusSpy.count(), 2);
+    delete subscriber;
 }
 
 // ---------------------------------------------------------------------------
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/mt_sifuiinstallindicator.h	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/mt_sifuiinstallindicator.h	Fri May 14 15:58:48 2010 +0300
@@ -19,19 +19,17 @@
 #ifndef MT_SIFUIINSTALLINDICATOR_H
 #define MT_SIFUIINSTALLINDICATOR_H
 
-
 #include <QtTest/QtTest>
 
 class TestSifUiInstallIndicator: public QObject
 {
     Q_OBJECT
 
-private slots:
+private slots:  // test functions
     void activateWithoutParams();
     void activateWithAppName();
     void activateWithInvalidParam();
 };
 
-
 #endif  // MT_SIFUIINSTALLINDICATOR_H
 
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/mt_sifuiinstallindicator.pro	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/mt_sifuiinstallindicator/mt_sifuiinstallindicator.pro	Fri May 14 15:58:48 2010 +0300
@@ -19,6 +19,7 @@
 CONFIG += qtestlib hb
 DEPENDPATH += .
 INCLUDEPATH += . ../../inc
+LIBS += -lQtPublishSubscribe
 
 HEADERS += mt_sifuiinstallindicator.h
 SOURCES += mt_sifuiinstallindicator.cpp
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/testindiapp/testindiapp.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/testindiapp/testindiapp.cpp	Fri May 14 15:58:48 2010 +0300
@@ -20,30 +20,39 @@
 #include <hbview.h>
 #include <QGraphicsLinearLayout>
 #include <hbtextitem.h>
-#include <hbcheckbox.h>
 #include <hbpushbutton.h>
 #include <hbindicator.h>
+#include <hbmessagebox.h>
+#include <qvaluespacesubscriber.h>
+#include "../../inc/sifuiinstallindicatorparams.h"
 
-const QString KInstallIndicator = "com.nokia.sifui.indi/1.0";
 
 TestInstallIndicator::TestInstallIndicator(int& argc, char* argv[]) : HbApplication(argc, argv),
-    mMainWindow(0), mMainView(0), mIndicator(0)
+    mMainWindow(0), mMainView(0), mIndicator(0), mSubscriber(0)
 {
     mMainWindow = new HbMainWindow();
     mMainView = new HbView();
     mMainView->setTitle(tr("TestInstIndi"));
 
+    mIndicator = new HbIndicator;
+
+    mSubscriber = new QTM_PREPEND_NAMESPACE(QValueSpaceSubscriber(KSifUiInstallIndicatorStatusPath));
+    connect(mSubscriber, SIGNAL(contentsChanged()), this, SLOT(handleIndicatorActivity()));
+
     QGraphicsLinearLayout *layout = new QGraphicsLinearLayout(Qt::Vertical);
 
     HbTextItem *infoText = new HbTextItem;
-    infoText->setText("Enable/disable SW install progress indicator in status indicator area and/or in universal indicator popup.");
+    infoText->setText("Activate/deactivate SW install indicator in universal indicator popup.");
     infoText->setTextWrapping(Hb::TextWordWrap);
     layout->addItem(infoText);
 
-    HbCheckBox *enableCheckBox = new HbCheckBox;
-    enableCheckBox->setText("Activate install indicator");
-    connect(enableCheckBox, SIGNAL(stateChanged(int)), this, SLOT(activateStateChanged(int)));
-    layout->addItem(enableCheckBox);
+    HbPushButton *activateButton = new HbPushButton("Activate install indicator");
+    connect(activateButton, SIGNAL(clicked()), this, SLOT(activatePressed()));
+    layout->addItem(activateButton);
+
+    HbPushButton *deactivateButton = new HbPushButton("Deactivate install indicator");
+    connect(deactivateButton, SIGNAL(clicked()), this, SLOT(deactivatePressed()));
+    layout->addItem(deactivateButton);
 
     HbPushButton *closeButton = new HbPushButton("Close");
     connect(closeButton, SIGNAL(clicked()), qApp, SLOT(quit()));
@@ -56,22 +65,55 @@
 
 TestInstallIndicator::~TestInstallIndicator()
 {
+    delete mSubscriber;
     delete mIndicator;
     delete mMainView;
     delete mMainWindow;
 }
 
-void TestInstallIndicator::activateStateChanged(int state)
+bool TestInstallIndicator::isIndicatorActive()
 {
-    if (!mIndicator) {
-        mIndicator = new HbIndicator;
+    bool isActive = false;
+    if (mSubscriber) {
+        QVariant variant = mSubscriber->value();
+        bool valueOk = false;
+        int intValue = variant.toInt(&valueOk);
+        if (valueOk && intValue) {
+            isActive = true;
+        }
     }
+    return isActive;
+}
 
-    Qt::CheckState s = static_cast<Qt::CheckState>(state);
-    if (s == Qt::Checked) {
-        mIndicator->activate(KInstallIndicator);
+void TestInstallIndicator::handleIndicatorActivity()
+{
+    if (isIndicatorActive()) {
+        HbMessageBox::information("Indicator activated");
     } else {
-        mIndicator->deactivate(KInstallIndicator);
+        HbMessageBox::information("Indicator deactivated");
     }
 }
 
+void TestInstallIndicator::activatePressed()
+{
+    if (mIndicator) {
+        if (isIndicatorActive()) {
+            HbMessageBox::information("Already active");
+        } else {
+            QVariant parameter(QString("Application"));
+            mIndicator->activate(KSifUiInstallIndicatorType, parameter);
+        }
+    }
+}
+
+void TestInstallIndicator::deactivatePressed()
+{
+    if (mIndicator) {
+        if (isIndicatorActive()) {
+            mIndicator->deactivate(KSifUiInstallIndicatorType);
+        } else {
+            HbMessageBox::information("Already deactive");
+        }
+    }
+}
+
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/testindiapp/testindiapp.h	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/testindiapp/testindiapp.h	Fri May 14 15:58:48 2010 +0300
@@ -19,11 +19,16 @@
 #define TESTINDICAPPLICATION_H
 
 #include <hbapplication.h>
+#include <qmobilityglobal.h>            // QTM namespace macros
 
 class HbMainWindow;
 class HbView;
 class HbIndicator;
 
+QTM_BEGIN_NAMESPACE
+class QValueSpaceSubscriber;
+QTM_END_NAMESPACE
+
 
 class TestInstallIndicator : public HbApplication
 {
@@ -32,14 +37,18 @@
 public:     // constructor and destructor
     TestInstallIndicator(int& argc, char* argv[]);
     ~TestInstallIndicator();
+    bool isIndicatorActive();
 
 private slots:  // new functions
-    void activateStateChanged(int state);
+    void handleIndicatorActivity();
+    void activatePressed();
+    void deactivatePressed();
 
 private:    // data
     HbMainWindow *mMainWindow;
     HbView       *mMainView;
     HbIndicator  *mIndicator;
+    QTM_PREPEND_NAMESPACE(QValueSpaceSubscriber) *mSubscriber;
 };
 
 #endif  // TESTINDICAPPLICATION_H
--- a/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/testindiapp/testindiapp.pro	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sifuiinstallindicatorplugin/tsrc/testindiapp/testindiapp.pro	Fri May 14 15:58:48 2010 +0300
@@ -19,6 +19,7 @@
 CONFIG += hb
 DEPENDPATH += .
 INCLUDEPATH += .
+LIBS += -lQtPublishSubscribe
 
 HEADERS += testindiapp.h
 SOURCES += testindimain.cpp testindiapp.cpp
--- a/appinstaller/AppinstUi/sisxsifplugin/group/sisxsifplugin.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sisxsifplugin/group/sisxsifplugin.mmp	Fri May 14 15:58:48 2010 +0300
@@ -53,4 +53,6 @@
 LIBRARY         efsrv.lib               // RFs
 LIBRARY         PlatformEnv.lib         // TDriveInfo
 LIBRARY         featmgr.lib             // FeatureManager
+LIBRARY         pkixcertbase.lib        // CPKIXValidationResultBase
+LIBRARY         x509.lib                // TValidationStatus
 
--- a/appinstaller/AppinstUi/sisxsifplugin/inc/sisxsifpluginactiveimpl.h	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sisxsifplugin/inc/sisxsifpluginactiveimpl.h	Fri May 14 15:58:48 2010 +0300
@@ -80,18 +80,20 @@
         void CommonRequestPreamble( const COpaqueNamedParams& aInputParams,
                 COpaqueNamedParams& aOutputParams, TRequestStatus& aStatus );
         void CompleteClientRequest( TInt aResult );
-        void DoInstallL( const TDesC& aFileName );
         void DoUninstallL( TComponentId aComponentId );
         void DoActivateL( TComponentId aComponentId );
         void DoDeactivateL( TComponentId aComponentId );
+        void DoHandleErrorL( TInt aError );
         TInt ConvertToSifErrorCode( TInt aSwiErrorCode );
+        void SetInstallFileL( const TDesC& aFileName );
+        void SetInstallFile( RFile& aFileHandle );
         TComponentId GetLastInstalledComponentIdL();
-        TBool RequiresUserCapabilityL();
-        void ProcessSilentInstallL();
-        void ProcessSilentUninstallL();
-        void SetSilentInstallFileL( const TDesC& aFileName );
-        void SetSilentInstallFile( RFile& aFileHandle );
-        static TInt GrantCapabilitiesHelpCallback( TAny* aPtr );
+        TBool RequiresUserCapabilityL( const CComponentInfo::CNode& aRootNode );
+        void StartInstallingL();
+        void StartSilentInstallingL();
+        void StartSilentUninstallingL();
+        void FinalizeInstallationL();
+        void UpdateStartupListL();
 
     private:    // data
         RFs iFs;
@@ -106,8 +108,6 @@
         HBufC* iFileName;
         RFile* iFileHandle;             // not owned
         TBool iUseSilentMode;
-        TBool iIsPackageCheckedForSilentInstall;
-
         enum TOperationType
             {
             ENone,
@@ -116,8 +116,14 @@
             EUninstall,
             EActivate,
             EDeactivate
-            };
-        TOperationType iOperation;
+            } iOperation;
+        enum TPhase
+            {
+            ENotActive,
+            EPreprocessing,
+            ERunningOperation,
+            EPostprocessing
+            } iPhase;
         };
 
 }   // namespace Usif
--- a/appinstaller/AppinstUi/sisxsifplugin/inc/sisxsifpluginuihandler.h	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sisxsifplugin/inc/sisxsifpluginuihandler.h	Fri May 14 15:58:48 2010 +0300
@@ -89,13 +89,18 @@
         TBool DisplayUninstallL( const Swi::CAppInfo& aAppInfo );
 
     public:     // new functions
+        void DisplayPreparingInstallL( const TDesC& aFileName );
         void DisplayCompleteL();
         void DisplayFailedL( TInt aErrorCode );
+        void SetDriveSelectionRequired( TBool aIsRequired );
+        void SetMaxInstalledSize( TInt aSize );
 
     private:    // new functions
         CSisxSifPluginUiHandler( RFs& aFs );
         void ConstructL();
-        void MemorySelectionL();
+        void AddMemorySelectionL();
+        void AddCertificatesL( RPointerArray<Swi::CCertificateInfo>& aCertificates,
+                RPointerArray<CPKIXValidationResultBase>& aPkixResults );
 
     private:    // data
         RFs& iFs;
@@ -103,6 +108,8 @@
         CSifUi* iSifUi;
         CApaMaskedBitmap* iLogo;
         TBool iQuestionIncompatibleDisplayed;
+        TInt iMaxInstalledSize;
+        TBool iDriveSelectionRequired;
         RArray<TInt> iSelectableDrives;
         };
 
--- a/appinstaller/AppinstUi/sisxsifplugin/src/sisxsifpluginactiveimpl.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sisxsifplugin/src/sisxsifpluginactiveimpl.cpp	Fri May 14 15:58:48 2010 +0300
@@ -29,21 +29,26 @@
 #include "sisregistrywritablesession.h" // RSisRegistryWritableSession
 #include <e32property.h>                // RProperty
 #include <sacls.h>                      // KUidSwiLatestInstallation
+#include <featmgr.h>                    // FeatureManager
 
 // TODO: replace with proper logging
 #ifdef _DEBUG
 #define FLOG(x)         RDebug::Print(x);
 #define FLOG_1(x,y)     RDebug::Print(x, y);
 #define FLOG_2(x,y,z)   RDebug::Print(x, y, z);
+#define FLOG_3(x,y,z,v) RDebug::Print(x, y, z, v);
 #else
 #define FLOG(x)
 #define FLOG_1(x,y)
 #define FLOG_2(x,y,z)
+#define FLOG_3(x,y,z,v)
 #endif
 
 using namespace Usif;
 
 _LIT( KCompUid, "CompUid" );
+_LIT( KStartupListUpdaterExecutable, "z:\\sys\\bin\\startuplistupdater.exe" );
+_LIT( KStartupListUpdaterName, "StartupListUpdater" );
 
 const TInt KSystemWideErrorsBoundary = -100;
 
@@ -78,6 +83,7 @@
     delete iInstallPrefs;
     delete iComponentInfo;
     delete iFileName;
+    FeatureManager::UnInitializeLib();
     iFs.Close();
 	}
 
@@ -109,48 +115,57 @@
 void CSisxSifPluginActiveImpl::RunL()
     {
     TInt result = iStatus.Int();
-    FLOG_2( _L("CSisxSifPluginActiveImpl::RunL(), op %d, result %d"), iOperation, result );
+    FLOG_3( _L("CSisxSifPluginActiveImpl::RunL(), operation %d, phase %d, result %d"),
+            iOperation, iPhase, result );
+    User::LeaveIfError( result );
 
-    if( result == KErrNone && iOperation == EInstall &&
-            iUseSilentMode && !iIsPackageCheckedForSilentInstall )
+    switch( iOperation )
         {
-        ProcessSilentInstallL();    // makes the real silent install request
-        iIsPackageCheckedForSilentInstall = ETrue;
-        }
-    else
-        {
-        if( iOutputParams )
-            {
-            iOutputParams->AddIntL( KSifOutParam_ExtendedErrCode, result );
-
-            if( iOperation == EInstall && result == KErrNone )
+        case EInstall:
+            switch( iPhase )
                 {
-                TComponentId resultComponentId = 0;
-                TRAPD( getLastIdErr, resultComponentId = GetLastInstalledComponentIdL() );
-                if( getLastIdErr == KErrNone )
-                    {
-                    iOutputParams->AddIntL( KSifOutParam_ComponentId, resultComponentId );
-                    }
-                }
-            }
+                case EPreprocessing:
+                    if( iUseSilentMode )
+                        {
+                        StartSilentInstallingL();
+                        }
+                    else
+                        {
+                        StartInstallingL();
+                        }
+                    iPhase = ERunningOperation;
+                    SetActive();
+                    break;
+
+                case ERunningOperation:
+                    FinalizeInstallationL();
+                    CompleteClientRequest( KErrNone );
+                    iPhase = ENotActive;
+                    break;
 
-        TInt errorCode = ConvertToSifErrorCode( result );
-        if( !iUseSilentMode )
-            {
-            if( errorCode == KErrNone )
-                {
-                iUiHandler->DisplayCompleteL();
+                default:
+                    Panic( ESisxSifInternalError );
+                    break;
                 }
-            else
-                {
-                if( errorCode != KErrCancel )
-                    {
-                    iUiHandler->DisplayFailedL( errorCode );
-                    }
-                }
-            }
-        User::RequestComplete( iClientStatus, errorCode );
-        iClientStatus = NULL;
+            break;
+
+        case EUninstall:
+            __ASSERT_DEBUG( iPhase == ERunningOperation, Panic( ESisxSifInternalError ) );
+            UpdateStartupListL();
+            CompleteClientRequest( KErrNone );
+            iPhase = ENotActive;
+            break;
+
+        case EActivate:
+        case EDeactivate:
+            __ASSERT_DEBUG( iPhase == ERunningOperation, Panic( ESisxSifInternalError ) );
+            CompleteClientRequest( KErrNone );
+            iPhase = ENotActive;
+            break;
+
+        default:
+            Panic( ESisxSifInternalError );
+            break;
         }
     }
 
@@ -160,11 +175,10 @@
 //
 TInt CSisxSifPluginActiveImpl::RunError( TInt aError )
     {
-    if( iClientStatus )
-        {
-        User::RequestComplete( iClientStatus, aError );
-        iClientStatus = NULL;
-        }
+    FLOG_1( _L("CSisxSifPluginActiveImpl::RunError(), aError %d"), aError );
+    TRAP_IGNORE( DoHandleErrorL( aError ) );
+    CompleteClientRequest( aError );
+    iPhase = ENotActive;
     return KErrNone;
     }
 
@@ -178,20 +192,30 @@
         CComponentInfo& aComponentInfo,
         TRequestStatus& aStatus )
 	{
-    iOperation = EGetComponentInfo;
-    aStatus = KRequestPending;
-    iClientStatus = &aStatus;
+    FLOG_1( _L("CSisxSifPluginActiveImpl::GetComponentInfo: %S"), &aFileName );
+    if( !IsActive() )
+        {
+        iOperation = EGetComponentInfo;
+        aStatus = KRequestPending;
+        iClientStatus = &aStatus;
+        iPhase = ERunningOperation;
 
-    TRAPD( err, iAsyncLauncher->GetComponentInfoL( UiHandlerL(), aFileName,
-            *iInstallPrefs, aComponentInfo, iStatus ) );
-    FLOG_1( _L("CSisxSifPluginActiveImpl::GetComponentInfo, err = %d"), err );
-    if( err != KErrNone )
+        TRAPD( err, iAsyncLauncher->GetComponentInfoL( UiHandlerL(), aFileName,
+                *iInstallPrefs, aComponentInfo, iStatus ) );
+        if( err )
+            {
+            FLOG_1( _L("CSisxSifPluginActiveImpl::GetComponentInfo ERROR %d"), err );
+            CompleteClientRequest( err );
+            return;
+            }
+
+        SetActive();
+        }
+    else
         {
-        CompleteClientRequest( err );
-        return;
+        FLOG( _L("CSisxSifPluginActiveImpl::GetComponentInfo KErrInUse") );
+        CompleteClientRequest( KErrInUse );
         }
-
-    SetActive();
 	}
 
 // ---------------------------------------------------------------------------
@@ -204,20 +228,30 @@
         CComponentInfo& aComponentInfo,
         TRequestStatus& aStatus )
 	{
-    iOperation = EGetComponentInfo;
-    aStatus = KRequestPending;
-    iClientStatus = &aStatus;
+    FLOG( _L("CSisxSifPluginActiveImpl::GetComponentInfo(RFile)") );
+    if( !IsActive() )
+        {
+        iOperation = EGetComponentInfo;
+        aStatus = KRequestPending;
+        iClientStatus = &aStatus;
+        iPhase = ERunningOperation;
 
-    TRAPD( err, iAsyncLauncher->GetComponentInfoL( UiHandlerL(), aFileHandle,
-            *iInstallPrefs, aComponentInfo, iStatus ) );
-    FLOG_1( _L("CSisxSifPluginActiveImpl::GetComponentInfo, err = %d"), err );
+        TRAPD( err, iAsyncLauncher->GetComponentInfoL( UiHandlerL(), aFileHandle,
+                *iInstallPrefs, aComponentInfo, iStatus ) );
+        if( err )
+            {
+            FLOG_1( _L("CSisxSifPluginActiveImpl::GetComponentInfo ERROR %d"), err );
+            CompleteClientRequest( err );
+            return;
+            }
 
-    if( err != KErrNone )
+        SetActive();
+        }
+    else
         {
-        CompleteClientRequest( err );
-        return;
+        FLOG( _L("CSisxSifPluginActiveImpl::GetComponentInfo KErrInUse") );
+        CompleteClientRequest( KErrInUse );
         }
-    SetActive();
 	}
 
 // ---------------------------------------------------------------------------
@@ -231,27 +265,45 @@
         COpaqueNamedParams& aOutputParams,
         TRequestStatus& aStatus )
 	{
-    iOperation = EInstall;
-    CommonRequestPreamble( aInputParams, aOutputParams, aStatus );
-
-    if( iUseSilentMode && !aSecurityContext.HasCapability( ECapabilityTrustedUI ) )
+    FLOG_1( _L("CSisxSifPluginActiveImpl::Install: %S"), &aFileName );
+    if( !IsActive() )
         {
-        FLOG( _L("CSisxSifPluginActiveImpl: missing ECapabilityTrustedUI ERROR") );
-        CompleteClientRequest( KErrPermissionDenied );
-        return;
-        }
+        CommonRequestPreamble( aInputParams, aOutputParams, aStatus );
+        FLOG_1( _L("CSisxSifPluginActiveImpl::Install, iUseSilentMode=%d"), iUseSilentMode );
 
-    FLOG_2( _L("CSisxSifPluginActiveImpl::Install: %S, iUseSilentMode=%d"),
-            &aFileName, iUseSilentMode );
-    TRAPD( err, DoInstallL( aFileName ) );
-    FLOG_1( _L("CSisxSifPluginActiveImpl::Install, err=%d"), err );
+        if( iUseSilentMode )
+            {
+            if( !aSecurityContext.HasCapability( ECapabilityTrustedUI ) )
+                {
+                FLOG( _L("CSisxSifPluginActiveImpl::Install, missing ECapabilityTrustedUI") );
+                CompleteClientRequest( KErrPermissionDenied );
+                return;
+                }
+            }
+        else
+            {
+            iUiHandler->DisplayPreparingInstallL( aFileName );
+            }
+        SetInstallFileL( aFileName );
 
-    if( err != KErrNone )
+        TRAPD( err, iAsyncLauncher->GetComponentInfoL( UiHandlerL( iUseSilentMode ),
+                aFileName, *iInstallPrefs, *iComponentInfo, iStatus ) );
+        if( err )
+            {
+            FLOG_1( _L("CSisxSifPluginActiveImpl::Install, GetComponentInfoL ERROR %d"), err );
+            CompleteClientRequest( err );
+            return;
+            }
+
+        iOperation = EInstall;
+        iPhase = EPreprocessing;
+        SetActive();
+        }
+    else
         {
-        CompleteClientRequest( err );
-        return;
+        FLOG( _L("CSisxSifPluginActiveImpl::GetComponentInfo, KErrInUse") );
+        CompleteClientRequest( KErrInUse );
         }
-    SetActive();
 	}
 
 // ---------------------------------------------------------------------------
@@ -265,43 +317,47 @@
         COpaqueNamedParams& aOutputParams,
         TRequestStatus& aStatus )
 	{
-    iOperation = EInstall;
-    CommonRequestPreamble( aInputParams, aOutputParams, aStatus );
-
-    if( iUseSilentMode && !aSecurityContext.HasCapability( ECapabilityTrustedUI ) )
+    TFileName fileName;
+    aFileHandle.Name( fileName );
+    FLOG_1( _L("CSisxSifPluginActiveImpl::Install(RFile): %S"), &fileName );
+    if( !IsActive() )
         {
-        FLOG( _L("CSisxSifPluginActiveImpl: missing ECapabilityTrustedUI ERROR") );
-        CompleteClientRequest( KErrPermissionDenied );
-        return;
-        }
+        CommonRequestPreamble( aInputParams, aOutputParams, aStatus );
+        FLOG_1( _L("CSisxSifPluginActiveImpl::Install, iUseSilentMode=%d"), iUseSilentMode );
 
-    FLOG_1( _L("CSisxSifPluginActiveImpl::Install, iUseSilentMode=%d"), iUseSilentMode );
-    TInt err = KErrNone;
-    if( iUseSilentMode )
-        {
-        // Silent install does a few addtional checks on the package to see if is
-        // signed and had the required capabilities. So we need to the get the
-        // package component information without installing it. Real silent install
-        // operation is started in RunL() after this GetComponentInfoL() completes.
-        SetSilentInstallFile( aFileHandle );
-        TRAP( err, iAsyncLauncher->GetComponentInfoL( UiHandlerL( iUseSilentMode ),
+        if( iUseSilentMode )
+            {
+            if( !aSecurityContext.HasCapability( ECapabilityTrustedUI ) )
+                {
+                FLOG( _L("CSisxSifPluginActiveImpl::Install, missing ECapabilityTrustedUI") );
+                CompleteClientRequest( KErrPermissionDenied );
+                return;
+                }
+            }
+        else
+            {
+            iUiHandler->DisplayPreparingInstallL( fileName );
+            }
+        SetInstallFile( aFileHandle );
+
+        TRAPD( err, iAsyncLauncher->GetComponentInfoL( UiHandlerL( iUseSilentMode ),
                 aFileHandle, *iInstallPrefs, *iComponentInfo, iStatus ) );
-        FLOG_1( _L("CSisxSifPluginActiveImpl::GetComponentInfoL, err=%d"), err );
+        if( err )
+            {
+            FLOG_1( _L("CSisxSifPluginActiveImpl::Install, GetComponentInfoL ERROR %d"), err );
+            CompleteClientRequest( err );
+            return;
+            }
+
+        iOperation = EInstall;
+        iPhase = EPreprocessing;
+        SetActive();
         }
     else
         {
-        // Proceed with the normal installation.
-        TRAP( err, iAsyncLauncher->InstallL( UiHandlerL(), aFileHandle,
-                *iInstallPrefs, iStatus ) );
-        FLOG_1( _L("CSisxSifPluginActiveImpl::Install, err=%d"), err );
+        FLOG( _L("CSisxSifPluginActiveImpl::Install KErrInUse") );
+        CompleteClientRequest( KErrInUse );
         }
-
-    if( err != KErrNone )
-        {
-        CompleteClientRequest( err );
-        return;
-        }
-    SetActive();
 	}
 
 // ---------------------------------------------------------------------------
@@ -315,28 +371,37 @@
         COpaqueNamedParams& aOutputParams,
         TRequestStatus& aStatus )
 	{
-    iOperation = EUninstall;
-    CommonRequestPreamble( aInputParams, aOutputParams, aStatus );
+    FLOG_1( _L("CSisxSifPluginActiveImpl::Uninstall, aComponentId %d"), aComponentId );
+    if( !IsActive() )
+        {
+        CommonRequestPreamble( aInputParams, aOutputParams, aStatus );
 
-    // Uninstall is always silent. TrustedUI capability is always required.
-    if( !aSecurityContext.HasCapability( ECapabilityTrustedUI ) )
-        {
-        FLOG( _L( "CSisxSifPluginActiveImpl: missing ECapabilityTrustedUI ERROR") );
-        CompleteClientRequest( KErrPermissionDenied );
-        return;
+        // Uninstall is always silent. TrustedUI capability is required.
+        if( !aSecurityContext.HasCapability( ECapabilityTrustedUI ) )
+            {
+            FLOG( _L( "CSisxSifPluginActiveImpl::Uninstall, missing ECapabilityTrustedUI") );
+            CompleteClientRequest( KErrPermissionDenied );
+            return;
+            }
+        iUseSilentMode = ETrue;     // no complete/error notes launched in RunL
+
+        TRAPD( err, DoUninstallL( aComponentId ) );
+        if( err )
+            {
+            FLOG_1( _L("CSisxSifPluginActiveImpl::Uninstall, DoUninstallL ERROR %d"), err );
+            CompleteClientRequest( err );
+            return;
+            }
+
+        iOperation = EUninstall;
+        iPhase = ERunningOperation;
+        SetActive();
         }
-    iUseSilentMode = ETrue;     // no complete/error notes launched in RunL
-
-    FLOG( _L("CSisxSifPluginActiveImpl::Uninstall") );
-    TRAPD( err, DoUninstallL( aComponentId ) );
-    FLOG_1( _L("CSisxSifPluginActiveImpl::Uninstall, err=%d"), err );
-
-    if( err != KErrNone )
+    else
         {
-        CompleteClientRequest( err );
-        return;
+        FLOG( _L("CSisxSifPluginActiveImpl::Uninstall KErrInUse") );
+        CompleteClientRequest( KErrInUse );
         }
-    SetActive();
 	}
 
 // ---------------------------------------------------------------------------
@@ -348,22 +413,33 @@
         const TSecurityContext& /*aSecurityContext*/,
         TRequestStatus& aStatus )
 	{
-    iOperation = EActivate;
-    aStatus = KRequestPending;
-    iClientStatus = &aStatus;
-
-    TRAPD( err, DoActivateL( aComponentId ) );
-    FLOG_2( _L("CSisxSifPluginActiveImpl::Activate, component %d, err=%d"), aComponentId, err );
-    if( err != KErrNone )
+    FLOG_1( _L("CSisxSifPluginActiveImpl::Activate, aComponentId %d"), aComponentId );
+    if( !IsActive() )
         {
-        CompleteClientRequest( err );
-        return;
-        }
+        aStatus = KRequestPending;
+        iClientStatus = &aStatus;
+
+        TRAPD( err, DoActivateL( aComponentId ) );
+        if( err )
+            {
+            FLOG_1( _L("CSisxSifPluginActiveImpl::Activate, DoActivateL ERROR %d"), err );
+            CompleteClientRequest( err );
+            return;
+            }
 
-    iStatus = KRequestPending;
-    TRequestStatus* status = &iStatus;
-    User::RequestComplete( status, KErrNone );
-    SetActive();
+        iStatus = KRequestPending;
+        TRequestStatus* status = &iStatus;
+        User::RequestComplete( status, KErrNone );
+
+        iOperation = EActivate;
+        iPhase = ERunningOperation;
+        SetActive();
+        }
+    else
+        {
+        FLOG( _L("CSisxSifPluginActiveImpl::Activate KErrInUse") );
+        CompleteClientRequest( KErrInUse );
+        }
 	}
 
 // ---------------------------------------------------------------------------
@@ -375,22 +451,33 @@
         const TSecurityContext& /*aSecurityContext*/,
         TRequestStatus& aStatus )
 	{
-    iOperation = EDeactivate;
-    aStatus = KRequestPending;
-    iClientStatus = &aStatus;
-
-    TRAPD( err, DoDeactivateL( aComponentId ) );
-    FLOG_2( _L("CSisxSifPluginActiveImpl::Deactivate, component %d, err=%d"), aComponentId, err );
-    if( err != KErrNone )
+    FLOG_1( _L("CSisxSifPluginActiveImpl::Deactivate, aComponentId %d"), aComponentId );
+    if( !IsActive() )
         {
-        CompleteClientRequest( err );
-        return;
-        }
+        aStatus = KRequestPending;
+        iClientStatus = &aStatus;
+
+        TRAPD( err, DoDeactivateL( aComponentId ) );
+        if( err )
+            {
+            FLOG_1( _L("CSisxSifPluginActiveImpl::Deactivate, DoDeactivateL ERROR %d"), err );
+            CompleteClientRequest( err );
+            return;
+            }
 
-    iStatus = KRequestPending;
-    TRequestStatus* status = &iStatus;
-    User::RequestComplete( status, KErrNone );
-    SetActive();
+        iStatus = KRequestPending;
+        TRequestStatus* status = &iStatus;
+        User::RequestComplete( status, KErrNone );
+
+        iOperation = EDeactivate;
+        iPhase = ERunningOperation;
+        SetActive();
+        }
+    else
+        {
+        FLOG( _L("CSisxSifPluginActiveImpl::Deactivate KErrInUse") );
+        CompleteClientRequest( KErrInUse );
+        }
 	}
 
 // ---------------------------------------------------------------------------
@@ -409,6 +496,7 @@
 void CSisxSifPluginActiveImpl::ConstructL()
     {
     User::LeaveIfError( iFs.Connect() );
+    FeatureManager::InitializeLibL();
 
     iAsyncLauncher = Swi::CAsyncLauncher::NewL();
     iInstallPrefs = Swi::CInstallPrefs::NewL();
@@ -468,7 +556,6 @@
     TInt silentInstall = 0;
     TRAPD( err, aInputParams.GetIntByNameL( KSifInParam_InstallSilently, silentInstall ) );
     iUseSilentMode = ( err == KErrNone && silentInstall != 0 );
-    iIsPackageCheckedForSilentInstall = EFalse;
 
     iInputParams = &aInputParams;
     iOutputParams = &aOutputParams;
@@ -490,30 +577,6 @@
     }
 
 // ---------------------------------------------------------------------------
-// CSisxSifPluginActiveImpl::DoInstallL()
-// ---------------------------------------------------------------------------
-//
-void CSisxSifPluginActiveImpl::DoInstallL( const TDesC& aFileName )
-    {
-    if( iUseSilentMode )
-        {
-        // Silent install does a few addtional checks on the package to see if is
-        // signed and had the required capabilities. So we need to the get the
-        // package component information without installing it. Real silent install
-        // operation is started in RunL() after this GetComponentInfoL() completes.
-        SetSilentInstallFileL( aFileName );
-        iIsPackageCheckedForSilentInstall = EFalse;
-        iAsyncLauncher->GetComponentInfoL( UiHandlerL( iUseSilentMode ), aFileName,
-                *iInstallPrefs, *iComponentInfo, iStatus );
-        }
-    else
-        {
-        // Proceed with the normal installation.
-        iAsyncLauncher->InstallL( UiHandlerL(), aFileName, *iInstallPrefs, iStatus );
-        }
-    }
-
-// ---------------------------------------------------------------------------
 // CSisxSifPluginActiveImpl::DoUninstallL()
 // ---------------------------------------------------------------------------
 //
@@ -548,8 +611,9 @@
     {
     Swi::RSisRegistryWritableSession sisRegSession;
     User::LeaveIfError( sisRegSession.Connect() );
+    CleanupClosePushL( sisRegSession );
     sisRegSession.ActivateComponentL( aComponentId );
-    sisRegSession.Close();
+    CleanupStack::PopAndDestroy( &sisRegSession );
     }
 
 // ---------------------------------------------------------------------------
@@ -560,8 +624,26 @@
     {
     Swi::RSisRegistryWritableSession sisRegSession;
     User::LeaveIfError( sisRegSession.Connect() );
+    CleanupClosePushL( sisRegSession );
     sisRegSession.DeactivateComponentL( aComponentId );
-    sisRegSession.Close();
+    CleanupStack::PopAndDestroy( &sisRegSession );
+    }
+
+// ---------------------------------------------------------------------------
+// CSisxSifPluginActiveImpl::DoHandleErrorL()
+// ---------------------------------------------------------------------------
+//
+void CSisxSifPluginActiveImpl::DoHandleErrorL( TInt aError )
+    {
+    if( iOutputParams )
+        {
+        iOutputParams->AddIntL( KSifOutParam_ExtendedErrCode, aError );
+        }
+    TInt errorCode = ConvertToSifErrorCode( aError );
+    if( !iUseSilentMode && ( errorCode != KErrCancel ) )
+        {
+        iUiHandler->DisplayFailedL( errorCode );
+        }
     }
 
 // ---------------------------------------------------------------------------
@@ -669,6 +751,35 @@
     }
 
 // ---------------------------------------------------------------------------
+// CSisxSifPluginActiveImpl::SetInstallFileL()
+// ---------------------------------------------------------------------------
+//
+void CSisxSifPluginActiveImpl::SetInstallFileL( const TDesC& aFileName )
+    {
+    if( iFileName )
+        {
+        delete iFileName;
+        iFileName = NULL;
+        }
+    iFileName = aFileName.AllocL();
+    iFileHandle = NULL;
+    }
+
+// ---------------------------------------------------------------------------
+// CSisxSifPluginActiveImpl::SetInstallFile()
+// ---------------------------------------------------------------------------
+//
+void CSisxSifPluginActiveImpl::SetInstallFile( RFile& aFileHandle )
+    {
+    if( iFileName )
+        {
+        delete iFileName;
+        iFileName = NULL;
+        }
+    iFileHandle = &aFileHandle;
+    }
+
+// ---------------------------------------------------------------------------
 // CSisxSifPluginActiveImpl::GetLastInstalledComponentIdL()
 // ---------------------------------------------------------------------------
 //
@@ -695,17 +806,18 @@
 // CSisxSifPluginActiveImpl::RequiresUserCapabilityL()
 // ---------------------------------------------------------------------------
 //
-TBool CSisxSifPluginActiveImpl::RequiresUserCapabilityL()
+TBool CSisxSifPluginActiveImpl::RequiresUserCapabilityL(
+        const CComponentInfo::CNode& aRootNode )
     {
     // Silent install is not allowed when the package requires additional capabilities
-    // than what it is signed for (Package may request for some capability that is not
+    // than what it is signed for (package may request for some capability that is not
     // granted by the certificate used to sign it).
-    const TCapabilitySet& componentUserCaps( iComponentInfo->RootNodeL().UserGrantableCaps() );
+    const TCapabilitySet& componentUserCaps( aRootNode.UserGrantableCaps() );
     for( TInt cap = 0; cap < ECapability_Limit; cap++ )
         {
         if( componentUserCaps.HasCapability( TCapability( cap ) ) )
             {
-            FLOG_1( _L("Package requires additional capability - %d"), cap );
+            FLOG_1( _L("CSisxSifPluginActiveImpl::RequiresUserCapabilityL - %d"), cap );
             return ETrue;
             }
         }
@@ -713,80 +825,116 @@
     }
 
 // ---------------------------------------------------------------------------
-// CSisxSifPluginActiveImpl::ProcessSilentInstallL()
+// CSisxSifPluginActiveImpl::StartInstallingL()
 // ---------------------------------------------------------------------------
 //
-void CSisxSifPluginActiveImpl::ProcessSilentInstallL()
+void CSisxSifPluginActiveImpl::StartInstallingL()
     {
-    TBool isAuthenticated = ( iComponentInfo->RootNodeL().Authenticity() == EAuthenticated );
-    TBool requiresUserCapability = RequiresUserCapabilityL();
-    if( !isAuthenticated || requiresUserCapability )
+    Swi::MUiHandler& uiHandler = UiHandlerL( iUseSilentMode );
+
+    if( !iUseSilentMode && iUiHandler )
+        {
+        const CComponentInfo::CNode& rootNode( iComponentInfo->RootNodeL() );
+        TBool driveSelection = rootNode.DriveSeletionRequired();
+        iUiHandler->SetDriveSelectionRequired( driveSelection );
+        TInt maxInstalledSize = rootNode.MaxInstalledSize();
+        iUiHandler->SetMaxInstalledSize( maxInstalledSize );
+        }
+
+    if( iFileHandle )
+        {
+        iAsyncLauncher->InstallL( uiHandler, *iFileHandle, *iInstallPrefs, iStatus );
+        }
+    else if( iFileName )
+        {
+        iAsyncLauncher->InstallL( uiHandler, *iFileName, *iInstallPrefs, iStatus );
+        }
+    else
         {
-        if( !isAuthenticated )
-            {
-            FLOG( _L("Silent Install is not allowed on unsigned or self-signed packages") );
-            }
-        if( requiresUserCapability )
-            {
-            FLOG( _L("Silent Install is not allowed when user capabilities are required") );
-            }
+        Panic( ESisxSifInternalError );
+        }
+    }
+
+// ---------------------------------------------------------------------------
+// CSisxSifPluginActiveImpl::StartSilentInstallingL()
+// ---------------------------------------------------------------------------
+//
+void CSisxSifPluginActiveImpl::StartSilentInstallingL()
+    {
+    const CComponentInfo::CNode& rootNode( iComponentInfo->RootNodeL() );
+    TBool hasExecutable = rootNode.HasExecutable();
+    TBool isAuthenticated = ( rootNode.Authenticity() == EAuthenticated );
+    TBool requiresUserCapability = RequiresUserCapabilityL( rootNode );
+    if( hasExecutable && !isAuthenticated )
+        {
+        FLOG( _L("Silent install is not allowed on unsigned packages containing executables") );
+        CompleteClientRequest( KErrPermissionDenied );
+        }
+    else if( requiresUserCapability )
+        {
+        FLOG( _L("Silent install is not allowed when user capabilities are required") );
         CompleteClientRequest( KErrPermissionDenied );
         }
     else
         {
-        TInt err = KErrNone;
-        if( iFileHandle )
-            {
-            TRAP( err, iAsyncLauncher->InstallL( UiHandlerL( iUseSilentMode ), *iFileHandle,
-                    *iInstallPrefs, iStatus ) );
-            }
-        else if( iFileName )
-            {
-            TRAP( err, iAsyncLauncher->InstallL( UiHandlerL( iUseSilentMode ), *iFileName,
-                    *iInstallPrefs, iStatus ) );
-            }
-        else
-            {
-            Panic( ESisxSifInternalError );
-            }
+        StartInstallingL();
+        }
+    }
 
-        if( !err )
-            {
-            SetActive();
-            }
-        else
-            {
-            CompleteClientRequest( err );
-            }
+// ---------------------------------------------------------------------------
+// CSisxSifPluginActiveImpl::FinalizeInstallationL()
+// ---------------------------------------------------------------------------
+//
+void CSisxSifPluginActiveImpl::FinalizeInstallationL()
+    {
+    UpdateStartupListL();
+
+    if( iOutputParams )
+        {
+        TComponentId componentId = GetLastInstalledComponentIdL();
+        iOutputParams->AddIntL( KSifOutParam_ComponentId, componentId );
+        }
+    if( !iUseSilentMode )
+        {
+        iUiHandler->DisplayCompleteL();
         }
     }
 
 // ---------------------------------------------------------------------------
-// CSisxSifPluginActiveImpl::SetSilentInstallFileL()
+// CSisxSifPluginActiveImpl::UpdateStartupListL()
 // ---------------------------------------------------------------------------
 //
-void CSisxSifPluginActiveImpl::SetSilentInstallFileL( const TDesC& aFileName )
+void CSisxSifPluginActiveImpl::UpdateStartupListL()
     {
-    if( iFileName )
+    if( FeatureManager::FeatureSupported( KFeatureIdExtendedStartup ) )
         {
-        delete iFileName;
-        iFileName = NULL;
+        TFullName name( KStartupListUpdaterName );
+        name.Append( '*' );
+        TFindProcess findProcess( name );
+        if( findProcess.Next( name ) == KErrNone )
+            {
+            // already running, no need to do anything
+            return;
+            }
+
+        RProcess process;
+        CleanupClosePushL( process );
+
+        TInt result = process.Create( KStartupListUpdaterExecutable, KNullDesC );
+        if( result == KErrNone )
+            {
+            TRequestStatus rendezvousStatus;
+            process.Rendezvous( rendezvousStatus );
+
+            // start process and wait until it is started
+            process.Resume();
+            User::WaitForRequest( rendezvousStatus );
+
+            // ignore possible errors
+            result = rendezvousStatus.Int();
+            }
+
+        CleanupStack::PopAndDestroy( &process );
         }
-    iFileName = aFileName.AllocL();
-    iFileHandle = NULL;
     }
 
-// ---------------------------------------------------------------------------
-// CSisxSifPluginActiveImpl::SetSilentInstallFile()
-// ---------------------------------------------------------------------------
-//
-void CSisxSifPluginActiveImpl::SetSilentInstallFile( RFile& aFileHandle )
-    {
-    if( iFileName )
-        {
-        delete iFileName;
-        iFileName = NULL;
-        }
-    iFileHandle = &aFileHandle;
-    }
-
--- a/appinstaller/AppinstUi/sisxsifplugin/src/sisxsifpluginuihandler.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sisxsifplugin/src/sisxsifpluginuihandler.cpp	Fri May 14 15:58:48 2010 +0300
@@ -24,11 +24,11 @@
 #include <driveinfo.h>                  // DriveInfo
 #include <featmgr.h>                    // FeatureManager
 //#include <csxhelp/am.hlp.hrh>           // Help IDs
-#include <hb/hbcore/hbsymbiandevicedialog.h> // CHbDeviceDialog
-#include <hb/hbcore/hbsymbianvariant.h> // CHbSymbianVariantMap
 
 using namespace Usif;
 
+const TInt KFreeSpaceTreshold = 128*1024;   // bytes
+
 // TODO: replace with proper tracing support
 #ifdef _DEBUG
 #define FLOG(x)         RDebug::Print(x);
@@ -148,17 +148,14 @@
 //
 TBool CSisxSifPluginUiHandler::DisplayInstallL( const Swi::CAppInfo& /*aAppInfo*/,
         const CApaMaskedBitmap* /*aLogo*/,
-        const RPointerArray<Swi::CCertificateInfo>& /*aCertificates*/ )
+        const RPointerArray<Swi::CCertificateInfo>& aCertificates )
     {
     FLOG( _L("CSisxSifPluginUiHandler::DisplayInstallL") );
 
-    // TODO: show preparing note -- unless it can be displayed already earlier.
-    // Preparing note should not have any buttons yet, but it might display some
-    // application details already.
-
-    // TODO: SISX SIF plugin needs to set memory selection when needed
-    MemorySelectionL();
-
+    if( iSifUi )
+        {
+        iSifUi->SetCertificateInfoL( aCertificates );
+        }
     return ETrue;
     }
 
@@ -191,11 +188,34 @@
 // ---------------------------------------------------------------------------
 //
 TInt CSisxSifPluginUiHandler::DisplayDriveL( const Swi::CAppInfo& /*aAppInfo*/,
-        TInt64 /*aSize*/, const RArray<TChar>& /*aDriveLetters*/,
+        TInt64 /*aSize*/, const RArray<TChar>& aDriveLetters,
         const RArray<TInt64>& /*aDriveSpaces*/ )
     {
     FLOG( _L("CSisxSifPluginUiHandler::DisplayDriveL") );
 
+    TInt err = KErrNone;
+    TInt driveNumber = EDriveC;
+    if( iSifUi )
+        {
+        err = iSifUi->SelectedDrive( driveNumber );
+        if( err )
+            {
+            FLOG_1( _L("CSisxSifPluginUiHandler::DisplayDriveL; SelectedDrive err=%d"), err );
+            }
+        }
+
+    TChar driveLetter = 'C';
+    err = RFs::DriveToChar( driveNumber, driveLetter );
+    if( err )
+        {
+        FLOG_1( _L("CSisxSifPluginUiHandler::DisplayDriveL; DriveToChar err=%d"), err );
+        }
+
+    TInt index = aDriveLetters.Find( driveLetter );
+    if( index >= 0 && index < aDriveLetters.Count() )
+        {
+        return index;
+        }
     return 0;
     }
 
@@ -232,13 +252,10 @@
     {
     FLOG_2( _L("CSisxSifPluginUiHandler::HandleInstallEventL: aEvent %d, aValue %d"), aEvent, aValue );
 
-    // TODO: application size?
-    TInt appSize = 0;
-
     switch( aEvent )
         {
         case Swi::EEventSetProgressBarFinalValue:
-            iSifUi->ShowProgressL( aAppInfo, appSize, aValue );
+            iSifUi->ShowProgressL( aAppInfo, iMaxInstalledSize, aValue );
             break;
 
         case Swi::EEventUpdateProgressBar:
@@ -285,20 +302,23 @@
 //
 TBool CSisxSifPluginUiHandler::DisplaySecurityWarningL( const Swi::CAppInfo& aAppInfo,
         Swi::TSignatureValidationResult aSigValidationResult,
-        RPointerArray<CPKIXValidationResultBase>& /*aPkixResults*/,
-        RPointerArray<Swi::CCertificateInfo>& /*aCertificates*/,
+        RPointerArray<CPKIXValidationResultBase>& aPkixResults,
+        RPointerArray<Swi::CCertificateInfo>& aCertificates,
         TBool aInstallAnyway )
     {
     FLOG( _L("CSisxSifPluginUiHandler::DisplaySecurityWarningL") );
     TBool result = EFalse;
 
-    // TODO: add application size
-    TInt appSize = 0;
+    if( iDriveSelectionRequired )
+        {
+        AddMemorySelectionL();
+        }
+    AddCertificatesL( aCertificates, aPkixResults );
 
     switch( aSigValidationResult )
         {
         case Swi::EValidationSucceeded:
-            result = iSifUi->ShowConfirmationL( aAppInfo, appSize, iLogo );
+            result = iSifUi->ShowConfirmationL( aAppInfo, iMaxInstalledSize, iLogo );
             break;
 
         case Swi::ESignatureSelfSigned:
@@ -311,7 +331,7 @@
         case Swi::EMandatorySignatureMissing:
             if( aInstallAnyway )
                 {
-                result = iSifUi->ShowConfirmationL( aAppInfo, appSize, iLogo );
+                result = iSifUi->ShowConfirmationL( aAppInfo, iMaxInstalledSize, iLogo );
                 }
             break;
 
@@ -371,6 +391,15 @@
     }
 
 // ---------------------------------------------------------------------------
+// CSisxSifPluginUiHandler::DisplayPreparingInstallL()
+// ---------------------------------------------------------------------------
+//
+void CSisxSifPluginUiHandler::DisplayPreparingInstallL( const TDesC& /*aFileName*/ )
+    {
+    // TODO: should this be displayed?
+    }
+
+// ---------------------------------------------------------------------------
 // CSisxSifPluginUiHandler::DisplayCompleteL()
 // ---------------------------------------------------------------------------
 //
@@ -383,7 +412,7 @@
     }
 
 // ---------------------------------------------------------------------------
-// CSisxSifPluginUiHandler::DisplayFailedL
+// CSisxSifPluginUiHandler::DisplayFailedL()
 // ---------------------------------------------------------------------------
 //
 void CSisxSifPluginUiHandler::DisplayFailedL( TInt aErrorCode )
@@ -396,6 +425,24 @@
     }
 
 // ---------------------------------------------------------------------------
+// CSisxSifPluginUiHandler::SetDriveSelectionRequired()
+// ---------------------------------------------------------------------------
+//
+void CSisxSifPluginUiHandler::SetDriveSelectionRequired( TBool aIsRequired )
+    {
+    iDriveSelectionRequired = aIsRequired;
+    }
+
+// ---------------------------------------------------------------------------
+// CSisxSifPluginUiHandler::SetMaxInstalledSize()
+// ---------------------------------------------------------------------------
+//
+void CSisxSifPluginUiHandler::SetMaxInstalledSize( TInt aSize )
+    {
+    iMaxInstalledSize = aSize;
+    }
+
+// ---------------------------------------------------------------------------
 // CSisxSifPluginUiHandler::CSisxSifPluginUiHandler()
 // ---------------------------------------------------------------------------
 //
@@ -414,11 +461,13 @@
     }
 
 // ---------------------------------------------------------------------------
-// CSisxSifPluginUiHandler::MemorySelectionL()
+// CSisxSifPluginUiHandler::AddMemorySelectionL()
 // ---------------------------------------------------------------------------
 //
-void CSisxSifPluginUiHandler::MemorySelectionL()
+void CSisxSifPluginUiHandler::AddMemorySelectionL()
     {
+    TInt64 adjustedSize = iMaxInstalledSize + KFreeSpaceTreshold;
+
     TDriveList driveList;
     TInt driveCount = 0;
     TInt err = DriveInfo::GetUserVisibleDrives( iFs, driveList, driveCount );
@@ -434,10 +483,41 @@
             err = DriveInfo::GetDriveStatus( iFs, driveNumber, driveStatus );
             if( !err && !( driveStatus & DriveInfo::EDriveRemote ) )
                 {
-                iSelectableDrives.Append( driveNumber );
+                TVolumeInfo volumeInfo;
+                err = iFs.Volume( volumeInfo, driveNumber );
+                if( !err && volumeInfo.iFree > adjustedSize )
+                    {
+                    iSelectableDrives.Append( driveNumber );
+                    }
                 }
             }
         }
     iSifUi->SetMemorySelectionL( iSelectableDrives );
     }
 
+// ---------------------------------------------------------------------------
+// CSisxSifPluginUiHandler::AddCertificatesL()
+// ---------------------------------------------------------------------------
+//
+void CSisxSifPluginUiHandler::AddCertificatesL(
+        RPointerArray<Swi::CCertificateInfo>& aCertificates,
+        RPointerArray<CPKIXValidationResultBase>& aPkixResults )
+    {
+    ASSERT( aCertificates.Count() == aPkixResults.Count() );
+
+    RPointerArray<Swi::CCertificateInfo> certificates;
+    CleanupClosePushL( certificates );  // does not own array items
+
+    for( TInt index = 0; index < aCertificates.Count(); ++index )
+        {
+        TValidationStatus status = aPkixResults[ index ]->Error();
+        if( status.iReason == EValidatedOK )
+            {
+            Swi::CCertificateInfo* cert = aCertificates[ index ];
+            certificates.AppendL( cert );   // not owned
+            }
+        }
+    iSifUi->SetCertificateInfoL( certificates );
+    CleanupStack::PopAndDestroy( &certificates );
+    }
+
--- a/appinstaller/AppinstUi/sisxsifplugin/tsrc/testinstaller/activerunner_symbian.h	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sisxsifplugin/tsrc/testinstaller/activerunner_symbian.h	Fri May 14 15:58:48 2010 +0300
@@ -20,7 +20,6 @@
 
 #include <e32base.h>            // CActive
 #include <usif/sif/sif.h>       // Usif::RSoftwareInstall
-#include <usif/sif/sif.h>       // Usif::RSoftwareInstall
 #include <SWInstApi.h>          // RSWInstLauncher
 
 class ActiveRunner;
--- a/appinstaller/AppinstUi/sisxsifplugin/tsrc/testinstaller/testinstaller.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/appinstaller/AppinstUi/sisxsifplugin/tsrc/testinstaller/testinstaller.cpp	Fri May 14 15:58:48 2010 +0300
@@ -271,6 +271,7 @@
     CleanupClosePushL(registry);
 
     RArray<TComponentId> componentIdList;
+    CleanupClosePushL( componentIdList );
     registry.GetComponentIdsL(componentIdList);
     for (int i = 0; i < componentIdList.Count(); ++i) {
         TComponentId compId = componentIdList[i];
@@ -303,7 +304,7 @@
         CleanupStack::PopAndDestroy(compEntry);
     }
 
-    CleanupStack::PopAndDestroy(&registry);
+    CleanupStack::PopAndDestroy(2, &registry);  // componentIdList, registry
 }
 
 bool TestInstaller::isFileSelected()
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/group/bld.inf	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,33 @@
+/*
+* 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:  Build information file for startup list updater.
+*               Applications that needs to be started at boot time install
+*               resource file containing STARTUP_ITEM_INFO resource into
+*               the import directory of the startup list updater. Startup
+*               list updater registers these applications to system, to be
+*               started at boot time. Uninstalled applications are removed
+*               from the startup list too.
+*/
+
+#include <platform_paths.hrh>
+
+PRJ_PLATFORMS
+DEFAULT
+
+PRJ_EXPORTS
+../rom/startuplistupdater.iby   CORE_MW_LAYER_IBY_EXPORT_PATH( startuplistupdater.iby )
+
+PRJ_MMPFILES
+startuplistupdater.mmp
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/group/startuplistupdater.mmp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,48 @@
+/*
+* 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:  Project file for startup list updater.
+*               Applications that needs to be started at boot time install
+*               resource file containing STARTUP_ITEM_INFO resource into
+*               the import directory of the startup list updater. Startup
+*               list updater registers these applications to system, to be
+*               started at boot time. Uninstalled applications are removed
+*               from the startup list too.
+*/
+
+#include <platform_paths.hrh>
+#include <data_caging_paths.hrh>
+
+TARGET          startuplistupdater.exe
+TARGETTYPE      exe
+UID             0x100039CE 0xE5F88F39   // TODO: Change UID3 to 0x101F875A after SWInstSvrUI has been removed
+CAPABILITY      CAP_SERVER AllFiles
+VENDORID        VID_DEFAULT
+
+SOURCEPATH      ../src
+SOURCE          main.cpp
+SOURCE          startuplistupdater.cpp
+
+MW_LAYER_SYSTEMINCLUDE
+USERINCLUDE     ../inc
+
+LIBRARY         euser.lib
+LIBRARY         efsrv.lib				// RFs, RFile
+LIBRARY         dscstore.lib			// RDscStore, CDscItem
+LIBRARY         sisregistryclient.lib	// Swi::RSisRegistrySession, Swi::RSisRegistryEntry
+LIBRARY         featmgr.lib				// FeatureManager
+LIBRARY         bafl.lib				// RResourceFile
+LIBRARY         platformenv.lib         // DriveInfo
+
+SMPSAFE
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/inc/cleanupresetanddestroy.h	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,55 @@
+/*
+* Copyright (c) 2008-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:   Defines CleanupResetAndDestroyPushL
+*
+*/
+
+
+#ifndef CLEANUPRESETANDDESTROY_H
+#define CLEANUPRESETANDDESTROY_H
+
+template <class T>
+class CleanupResetAndDestroy
+    {
+public:
+    inline static void PushL( T& aRef );
+private:
+    static void ResetAndDestroy( TAny *aPtr );
+    };
+
+template <class T>
+inline void CleanupResetAndDestroyPushL( T& aRef );
+
+template <class T>
+inline void CleanupResetAndDestroy<T>::PushL( T& aRef )
+    {
+    CleanupStack::PushL( TCleanupItem( &ResetAndDestroy, &aRef ) );
+    }
+
+template <class T>
+void CleanupResetAndDestroy<T>::ResetAndDestroy( TAny *aPtr )
+    {
+    if( aPtr )
+        {
+        static_cast<T*>( aPtr )->ResetAndDestroy();
+        }
+    }
+
+template <class T>
+inline void CleanupResetAndDestroyPushL( T& aRef )
+    {
+    CleanupResetAndDestroy<T>::PushL( aRef );
+    }
+
+#endif // CLEANUPRESETANDDESTROY_H
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/inc/startuplistupdater.h	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,69 @@
+/*
+* 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:  Header file for startup list updater.
+*
+*/
+
+#ifndef STARTUPLISTUPDATER_H
+#define STARTUPLISTUPDATER_H
+
+#include <e32base.h>                    // CBase
+#include <f32file.h>                    // RFs
+#include <dscstore.h>                   // RDscStore
+
+namespace Swi
+    {
+    class RSisRegistryEntry;
+    }
+
+class CStartupListUpdater : public CBase
+    {
+public:     // constructor and destructor
+    static CStartupListUpdater* NewL();
+    ~CStartupListUpdater();
+
+public:     // new functions
+    void UpdateStartupListL();
+
+private:    // new functions
+    CStartupListUpdater();
+    void ConstructL();
+    const TDesC& PrivateImportPathL();
+    void ProcessImportsAndUninstallsL();
+    void OpenDscStoreLC( RDscStore& aDscStore );
+    void ImportNewResourceFilesL( RDscStore& aDscStore );
+    void DeregisterUninstalledAppsL( RDscStore& aDscStore );
+    void GetDataToBeImportedL( RPointerArray<HBufC>& aExecutableArray,
+            RPointerArray<HBufC>& aResourceFileArray );
+    void ImportExecutablesL( RDscStore& aDscStore, RPointerArray<HBufC>& aExecutableArray );
+    void RemoveImportedResourceFiles( RPointerArray<HBufC>& aResourceFileArray );
+    void AppendExecutablesFromResourceFileL( const TDesC& aResourceFile,
+            RPointerArray<HBufC>& aExecutableArray );
+    void GetInstalledAppsL( RPointerArray<HBufC>& aInstalledExecutableArray );
+    void GetStartupListAppsL( RDscStore& aDscStore,
+            RPointerArray<HBufC>& aStartedExecutableArray );
+    void StartedButNotInstalledAppsL( RPointerArray<HBufC>& aStartedExecutableArray,
+            RPointerArray<HBufC>& aInstalledExecutableArray,
+            RPointerArray<HBufC>& aStartedButNotInstalledExecutableArray );
+    void RemoveFromStartupListL( RDscStore& aDscStore, RPointerArray<HBufC>& aExecutableArray );
+    void GetExecutablesFromEntryL( Swi::RSisRegistryEntry& aEntry,
+            RPointerArray<HBufC>& aExecutableArray );
+
+private:    // new data
+    RFs iFs;
+    HBufC* iPrivateImportPath;
+    };
+
+#endif  // STARTUPLISTUPDATER_H
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/rom/startuplistupdater.iby	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,23 @@
+/*
+* 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: ROM image files for startup list updater.
+*
+*/
+
+#ifndef STARTUPLISTUPDATER_IBY
+#define STARTUPLISTUPDATER_IBY
+
+file=ABI_DIR\BUILD_DIR\startuplistupdater.exe   sys\bin\startuplistupdater.exe
+
+#endif  // STARTUPLISTUPDATER_IBY
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/src/main.cpp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,75 @@
+/*
+* 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:  Main source file for startup list updater.
+*
+*/
+
+#include "startuplistupdater.h"
+
+_LIT( KStartupListUpdaterThread, "StartupListUpdater" );
+
+
+// ---------------------------------------------------------------------------
+// StartupListUpdaterL()
+// ---------------------------------------------------------------------------
+//
+void StartupListUpdaterL()
+    {
+    User::LeaveIfError( User::RenameThread( KStartupListUpdaterThread ) );
+    RProcess::Rendezvous( KErrNone );
+
+    CStartupListUpdater* updater = CStartupListUpdater::NewL();
+    CleanupStack::PushL( updater );
+    updater->UpdateStartupListL();
+    CleanupStack::PopAndDestroy( updater );
+}
+
+
+// ---------------------------------------------------------------------------
+// E32Main()
+// ---------------------------------------------------------------------------
+//
+GLDEF_C TInt E32Main()
+    {
+    TInt returnCode = KErrNone;
+    __UHEAP_MARK;
+
+    CTrapCleanup* cleanup = CTrapCleanup::New();
+    if( cleanup )
+        {
+        CActiveScheduler* scheduler = new CActiveScheduler();
+        if( scheduler )
+            {
+            CActiveScheduler::Install( scheduler );
+
+            TRAP( returnCode, StartupListUpdaterL() );
+
+            delete scheduler;
+            delete cleanup;
+            }
+        else
+            {
+            delete cleanup;
+            return KErrNoMemory;
+            }
+        }
+    else
+        {
+        return KErrNoMemory;
+        }
+
+    __UHEAP_MARKEND;
+    return returnCode;
+    }
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/src/startuplistupdater.cpp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,455 @@
+/*
+* 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:  Startup list updater implementation.
+*
+*/
+
+#include "startuplistupdater.h"         // CStartupListUpdater
+#include "cleanupresetanddestroy.h"     // CleanupResetAndDestroyPushL
+#include <featmgr.h>                    // FeatureManager
+#include <driveinfo.h>                  // DriveInfo
+#include <barsc.h>                      // RResourceFile
+#include <barsread.h>                   // TResourceReader
+#include <StartupItem.hrh>              // EStartupItemExPolicyNone
+#include <dscitem.h>                    // CDscItem
+#include <swi/sisregistrysession.h>     // Swi::RSisRegistrySession
+#include <swi/sisregistrypackage.h>     // Swi::CSisRegistryPackage
+#include <swi/sisregistryentry.h>       // Swi::RSisRegistryEntry
+
+_LIT( KImport, "import\\" );
+_LIT( KDriveAndPathFormat, "%c:%S" );
+_LIT( KResourceFileSpec, "c:*.rsc" );
+_LIT( KExecutableExtension, ".exe" );
+_LIT( KAsterisk, "*" );
+
+const TInt KDriveSpecLength = 2;
+const TInt KFirstStartupItemInfo = 1;
+
+
+// ======== LOCAL FUNCTIONS ========
+
+// ---------------------------------------------------------------------------
+// FileNamesEqual()
+// ---------------------------------------------------------------------------
+//
+TBool FileNamesEqual( const HBufC& aFile1, const HBufC& aFile2 )
+    {
+    return ( aFile1.CompareF( aFile2 ) == 0 );
+    }
+
+
+// ======== MEMBER FUNCTIONS ========
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::NewL()
+// ---------------------------------------------------------------------------
+//
+CStartupListUpdater* CStartupListUpdater::NewL()
+    {
+    CStartupListUpdater* self = new( ELeave ) CStartupListUpdater;
+    CleanupStack::PushL( self );
+    self->ConstructL();
+    CleanupStack::Pop( self );
+    return self;
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::~CStartupListUpdater()
+// ---------------------------------------------------------------------------
+//
+CStartupListUpdater::~CStartupListUpdater()
+    {
+    delete iPrivateImportPath;
+    iFs.Close();
+
+    FeatureManager::UnInitializeLib();
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::UpdateStartupListL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::UpdateStartupListL()
+    {
+    if ( FeatureManager::FeatureSupported( KFeatureIdExtendedStartup ) )
+        {
+        ProcessImportsAndUninstallsL();
+        }
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::CStartupListUpdater()
+// ---------------------------------------------------------------------------
+//
+CStartupListUpdater::CStartupListUpdater()
+    {
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::ConstructL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::ConstructL()
+    {
+    FeatureManager::InitializeLibL();
+    User::LeaveIfError( iFs.Connect() );
+
+    TInt err = iFs.MkDirAll( PrivateImportPathL() );
+    if( err != KErrNone && err != KErrAlreadyExists )
+        {
+        User::Leave( err );
+        }
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::PrivateImportPathL()
+// ---------------------------------------------------------------------------
+//
+const TDesC& CStartupListUpdater::PrivateImportPathL()
+    {
+    if( !iPrivateImportPath )
+        {
+        TFileName privateImportPath;
+        User::LeaveIfError( iFs.PrivatePath( privateImportPath ) );
+        privateImportPath.Append( KImport );
+
+        TInt driveNumber;
+        TInt err = DriveInfo::GetDefaultDrive( DriveInfo::EDefaultSystem, driveNumber );
+        User::LeaveIfError( err );
+        TChar driveLetter;
+        User::LeaveIfError( RFs::DriveToChar( driveNumber, driveLetter ) );
+
+        iPrivateImportPath = HBufC::NewL( KDriveSpecLength + privateImportPath.Length() );
+        TPtr ptr( iPrivateImportPath->Des() );
+        ptr.Format( KDriveAndPathFormat, static_cast< TUint >( driveLetter ), &privateImportPath );
+        }
+    return *iPrivateImportPath;
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::ProcessImportsAndUninstallsL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::ProcessImportsAndUninstallsL()
+    {
+    RDscStore dscStore;
+    OpenDscStoreLC( dscStore );
+
+    ImportNewResourceFilesL( dscStore );
+    DeregisterUninstalledAppsL( dscStore );
+
+    CleanupStack::PopAndDestroy( &dscStore );
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::OpenDscStoreLC()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::OpenDscStoreLC( RDscStore& aDscStore )
+    {
+    if( !aDscStore.IsOpened() )
+        {
+        aDscStore.OpenL();
+        CleanupClosePushL( aDscStore );
+        if( !aDscStore.DscExistsL() )
+            {
+            aDscStore.CreateDscL();
+            }
+        }
+    else
+        {
+        User::Leave( KErrAlreadyExists );
+        }
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::ImportNewResourceFilesL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::ImportNewResourceFilesL( RDscStore& aDscStore )
+    {
+    RPointerArray<HBufC> executableArray;
+    CleanupResetAndDestroyPushL( executableArray );
+    RPointerArray<HBufC> resourceFileArray;
+    CleanupResetAndDestroyPushL( resourceFileArray );
+
+    GetDataToBeImportedL( executableArray, resourceFileArray );
+    ImportExecutablesL( aDscStore, executableArray );
+    RemoveImportedResourceFiles( resourceFileArray );
+
+    CleanupStack::PopAndDestroy( 2, &executableArray );
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::DeregisterUninstalledAppsL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::DeregisterUninstalledAppsL( RDscStore& aDscStore )
+    {
+    RPointerArray<HBufC> startedAtBootArray;
+    CleanupResetAndDestroyPushL( startedAtBootArray );
+    RPointerArray<HBufC> installedArray;
+    CleanupResetAndDestroyPushL( installedArray );
+    RPointerArray<HBufC> startedNotInstalled;
+    CleanupResetAndDestroyPushL( startedNotInstalled );
+
+    GetStartupListAppsL( aDscStore, startedAtBootArray );
+    GetInstalledAppsL( installedArray );
+    StartedButNotInstalledAppsL( startedAtBootArray, installedArray, startedNotInstalled );
+    RemoveFromStartupListL( aDscStore, startedNotInstalled );
+
+    CleanupStack::PopAndDestroy( 3, &startedAtBootArray );
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::GetDataToBeImportedL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::GetDataToBeImportedL(
+        RPointerArray<HBufC>& aExecutableArray,
+        RPointerArray<HBufC>& aResourceFileArray )
+    {
+    TParse resourceFiles;
+    User::LeaveIfError( resourceFiles.Set( KResourceFileSpec, &PrivateImportPathL(), NULL ) );
+    const TPtrC importDir( resourceFiles.FullName() );
+
+    CDir* dir;
+    User::LeaveIfError( iFs.GetDir( importDir, KEntryAttMaskSupported, ESortNone, dir ) );
+    CleanupStack::PushL( dir );
+    for( TInt index = 0; index < dir->Count(); ++index )
+        {
+        TFileName resourceFile;
+        TInt lastSeparator = importDir.LocateReverse( '\\' );
+        if( lastSeparator > 0 )
+            {
+            resourceFile.Copy( importDir.Mid( 0, lastSeparator + 1 ) );
+            resourceFile.Append( ( *dir )[ index ].iName );
+            aResourceFileArray.AppendL( resourceFile.AllocL() );
+
+            AppendExecutablesFromResourceFileL( resourceFile, aExecutableArray );
+            }
+        }
+    CleanupStack::PopAndDestroy( dir );
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::ImportExecutablesL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::ImportExecutablesL( RDscStore& aDscStore,
+        RPointerArray<HBufC>& aExecutableArray )
+    {
+    for( TInt index = 0; index < aExecutableArray.Count(); ++index )
+        {
+        const TDesC& executableName = *( aExecutableArray[ index ] );
+        CDscItem* item = CDscItem::NewLC( executableName, KNullDesC );
+        if( !aDscStore.ItemExistsL( *item ) )
+            {
+            aDscStore.AddItemL( *item );
+            }
+        CleanupStack::PopAndDestroy( item );
+        }
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::RemoveImportedResourceFiles()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::RemoveImportedResourceFiles(
+        RPointerArray<HBufC>& aResourceFileArray )
+    {
+    for( TInt index = 0; index < aResourceFileArray.Count(); ++index )
+        {
+        const TDesC& fileName = *( aResourceFileArray[ index ] );
+        TInt err = iFs.Delete( fileName );
+        if( err )
+            {
+#ifdef _DEBUG
+            RDebug::Print( _L("CStartupListUpdater: cannot delete %S, error %d"),
+                    &fileName, err );
+#endif
+            }
+        }
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::AppendExecutablesFromResourceFileL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::AppendExecutablesFromResourceFileL(
+        const TDesC& aResourceFile,
+        RPointerArray<HBufC>& aExecutableArray )
+    {
+    RResourceFile resource;
+    CleanupClosePushL( resource );
+    resource.OpenL( iFs, aResourceFile );
+
+    for( TInt id = KFirstStartupItemInfo; resource.OwnsResourceId( id ); ++id )
+        {
+        HBufC8* buffer = resource.AllocReadLC( id );
+
+        TResourceReader reader;
+        reader.SetBuffer( buffer );
+
+        // Read STARTUP_ITEM_INFO
+        TInt versionInfo = reader.ReadUint8();
+        TFileName executableName;
+        executableName.Copy( reader.ReadTPtrC() );
+        TInt recoveryPolicy = reader.ReadUint16();
+
+        CleanupStack::PopAndDestroy( buffer );
+
+        if( recoveryPolicy == EStartupItemExPolicyNone )
+            {
+            // PKG files use '!' for drive letters that user can decide at installation time
+            if( executableName.Length() > 0 && executableName[ 0 ] == '!' )
+                {
+                executableName.Replace( 0, 1, KAsterisk );
+
+                TFindFile fileFinder( iFs );
+                CDir* executableDir;
+                TInt err = fileFinder.FindWildByDir( executableName, KNullDesC, executableDir );
+                if( !err )
+                    {
+                    CleanupStack::PushL( executableDir );
+                    executableName.Replace( 0, 1, fileFinder.File() );
+                    CleanupStack::PopAndDestroy( executableDir );
+                    }
+                }
+
+            TEntry entry;
+            if( iFs.Entry( executableName, entry ) == KErrNone )    // needs AllFiles capability
+                {
+                aExecutableArray.AppendL( executableName.AllocL() );
+                }
+            }
+        }
+
+    CleanupStack::PopAndDestroy( &resource );
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::GetInstalledAppsL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::GetInstalledAppsL(
+        RPointerArray<HBufC>& aInstalledExecutableArray )
+    {
+    Swi::RSisRegistrySession sisRegistrySession;
+    User::LeaveIfError( sisRegistrySession.Connect() );
+    CleanupClosePushL( sisRegistrySession );
+
+    RPointerArray<Swi::CSisRegistryPackage> removablePackages;
+    CleanupResetAndDestroyPushL( removablePackages );
+    sisRegistrySession.RemovablePackagesL( removablePackages );
+
+    for( TInt index = 0; index < removablePackages.Count(); ++index )
+        {
+        Swi::RSisRegistryEntry entry;
+        CleanupClosePushL( entry );
+        entry.OpenL( sisRegistrySession, *( removablePackages[ index ] ) );
+        if( entry.IsPresentL() && entry.RemovableL() )
+            {
+            GetExecutablesFromEntryL( entry, aInstalledExecutableArray );
+            }
+        CleanupStack::PopAndDestroy( &entry );
+        }
+
+    CleanupStack::PopAndDestroy( 2, &sisRegistrySession );
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::GetStartupListAppsL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::GetStartupListAppsL( RDscStore& aDscStore,
+        RPointerArray<HBufC>& aStartedExecutableArray )
+    {
+    aDscStore.EnumOpenLC();
+
+    while( CDscItem* item = aDscStore.EnumReadNextL() )
+        {
+        CleanupStack::PushL( item );
+        aStartedExecutableArray.AppendL( item->FileName().AllocL() );
+        CleanupStack::PopAndDestroy( item );
+        }
+
+    CleanupStack::PopAndDestroy();  // runs EnumClose
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::StartedButNotInstalledAppsL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::StartedButNotInstalledAppsL(
+        RPointerArray<HBufC>& aStartedExecutableArray,                  // in
+        RPointerArray<HBufC>& aInstalledExecutableArray,                // in
+        RPointerArray<HBufC>& aStartedButNotInstalledExecutableArray )  // out
+    {
+    aStartedButNotInstalledExecutableArray.ResetAndDestroy();
+
+    TIdentityRelation<HBufC> identityRelation( FileNamesEqual );
+    for( TInt index = 0; index < aStartedExecutableArray.Count(); ++index )
+        {
+        const HBufC* startedAppName = aStartedExecutableArray[ index ];
+        if( aInstalledExecutableArray.Find( startedAppName, identityRelation ) == KErrNotFound )
+            {
+            aStartedButNotInstalledExecutableArray.AppendL( startedAppName->AllocL() );
+            }
+        }
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::RemoveFromStartupListL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::RemoveFromStartupListL( RDscStore& aDscStore,
+        RPointerArray<HBufC>& aExecutableArray )
+    {
+    for( TInt index = 0; index < aExecutableArray.Count(); ++index )
+        {
+        const TDesC& executableName = *( aExecutableArray[ index ] );
+        CDscItem* item = CDscItem::NewLC( executableName, KNullDesC );
+        if( aDscStore.ItemExistsL( *item ) )
+            {
+            aDscStore.DeleteItemL( *item );
+            }
+        CleanupStack::PopAndDestroy( item );
+        }
+    }
+
+// ---------------------------------------------------------------------------
+// CStartupListUpdater::GetExecutablesFromEntryL()
+// ---------------------------------------------------------------------------
+//
+void CStartupListUpdater::GetExecutablesFromEntryL( Swi::RSisRegistryEntry& aEntry,
+        RPointerArray<HBufC>& aExecutableArray )
+    {
+    RPointerArray<HBufC> filesList;
+    CleanupResetAndDestroyPushL( filesList );
+    aEntry.FilesL( filesList );
+
+    for( TInt index = 0; index < filesList.Count(); ++index )
+        {
+        TParse parse;
+        TInt err = parse.SetNoWild( KNullDesC, filesList[ index ], NULL );
+        if( !err && ( parse.Ext().CompareF( KExecutableExtension ) == 0 ) )
+            {
+            aExecutableArray.AppendL( parse.FullName().AllocL() );
+            }
+        }
+
+    CleanupStack::PopAndDestroy( &filesList );
+    }
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/bwins/mt_startuplistupdateru.def	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,3 @@
+EXPORTS
+	?LibEntryL@@YAPAVCScriptBase@@AAVCTestModuleIf@@@Z @ 1 NONAME ; class CScriptBase * __cdecl LibEntryL(class CTestModuleIf &)
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/conf/mt_startuplistupdater.cfg	Fri May 14 15:58:48 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:  Startup list updater test module.
+//
+
+
+[Test]
+title Install startable exe
+create mt_startuplistupdater test
+test NotInStartList c:\sys\bin\teststartlist.exe
+//test Install e:\testing\data\teststartlist.sisx
+test Install c:\data\installs\teststartlist.sisx
+pause 1000
+test InStartList c:\sys\bin\teststartlist.exe
+delete test
+[Endtest]
+
+[Test]
+title Remove startable exe
+create mt_startuplistupdater test
+test InStartList c:\sys\bin\teststartlist.exe
+test Remove 0xEBE1C11B
+pause 1000
+test NotInStartList c:\sys\bin\teststartlist.exe
+delete test
+[Endtest]
+
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/ctc_compile_tests.bat	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,28 @@
+@echo off
+rem
+rem Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+rem All rights reserved.
+rem This component and the accompanying materials are made available
+rem under the terms of "Eclipse Public License v1.0"
+rem which accompanies this distribution, and is available
+rem at the URL "http://www.eclipse.org/legal/epl-v10.html".
+rem
+rem Initial Contributors:
+rem Nokia Corporation - initial contribution.
+rem
+rem Contributors:
+rem
+rem Description:  Module tests for startup list updater.
+rem
+
+echo ----------------------------------------------------------------------
+echo.
+echo Compiling module tests
+echo.
+echo ----------------------------------------------------------------------
+echo.
+pushd group
+call sbs -c armv5_urel
+call sbs -c winscw_udeb
+popd
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/ctc_instrument_code.bat	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,32 @@
+@echo off
+rem
+rem Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+rem All rights reserved.
+rem This component and the accompanying materials are made available
+rem under the terms of "Eclipse Public License v1.0"
+rem which accompanies this distribution, and is available
+rem at the URL "http://www.eclipse.org/legal/epl-v10.html".
+rem
+rem Initial Contributors:
+rem Nokia Corporation - initial contribution.
+rem
+rem Contributors:
+rem
+rem Description:  Module tests for startup list updater.
+rem
+
+echo ----------------------------------------------------------------------
+echo.
+echo Instrumenting code (armv5 urel and winscw udeb, function coverage)
+echo.
+echo ----------------------------------------------------------------------
+echo.
+pushd ..\..\group
+if exist MON.sym del MON.sym
+if exist MON.dat del MON.dat
+if exist profile.txt del profile.txt
+call sbs reallyclean
+call ctcwrap -i f -2comp -C "EXCLUDE+*.UID.CPP" sbs -c armv5_urel
+call ctcwrap -i f -2comp -C "EXCLUDE+*.UID.CPP" sbs -c winscw_udeb
+popd
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/ctc_remove_instrumentation.bat	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,29 @@
+@echo off
+rem
+rem Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+rem All rights reserved.
+rem This component and the accompanying materials are made available
+rem under the terms of "Eclipse Public License v1.0"
+rem which accompanies this distribution, and is available
+rem at the URL "http://www.eclipse.org/legal/epl-v10.html".
+rem
+rem Initial Contributors:
+rem Nokia Corporation - initial contribution.
+rem
+rem Contributors:
+rem
+rem Description:  Module tests for startup list updater.
+rem
+
+echo ----------------------------------------------------------------------
+echo.
+echo Removing instrumentation
+echo.
+echo ----------------------------------------------------------------------
+echo.
+pushd ..\..\group
+call sbs reallyclean
+call sbs -c armv5_urel
+call sbs -c winscw_udeb
+popd
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/ctc_run_tests.bat	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,37 @@
+@echo off
+rem
+rem Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+rem All rights reserved.
+rem This component and the accompanying materials are made available
+rem under the terms of "Eclipse Public License v1.0"
+rem which accompanies this distribution, and is available
+rem at the URL "http://www.eclipse.org/legal/epl-v10.html".
+rem
+rem Initial Contributors:
+rem Nokia Corporation - initial contribution.
+rem
+rem Contributors:
+rem
+rem Description:  Module tests for startup list updater.
+rem
+
+echo ----------------------------------------------------------------------
+echo.
+echo Running module tests
+echo.
+echo ----------------------------------------------------------------------
+echo.
+pushd ..\..\group
+call \epoc32\release\winscw\udeb\ATSInterface.exe –testmodule testscripter –config c:\testframework\mt_startuplistupdater.cfg
+
+echo.
+echo.
+echo ----------------------------------------------------------------------
+echo.
+echo Processing test results
+echo.
+echo ----------------------------------------------------------------------
+echo.
+call ctcpost MON.sym MON.dat -p profile.txt
+call ctc2html -i profile.txt
+popd
Binary file appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data/mmc/teststartlist.sisx has changed
Binary file appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data/mmc/teststartlist_winscw.sisx has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/bld.inf	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,23 @@
+/*
+* 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:  Test exe for startup list updater test module.
+*
+*/
+
+
+PRJ_PLATFORMS
+DEFAULT
+
+PRJ_MMPFILES
+teststartlist.mmp
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/doall.bat	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,43 @@
+@echo off
+rem
+rem Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+rem All rights reserved.
+rem This component and the accompanying materials are made available
+rem under the terms of "Eclipse Public License v1.0"
+rem which accompanies this distribution, and is available
+rem at the URL "http://www.eclipse.org/legal/epl-v10.html".
+rem
+rem Initial Contributors:
+rem Nokia Corporation - initial contribution.
+rem
+rem Contributors:
+rem
+rem Description:  Creates test exe for startup list updater test module.
+rem
+
+set CERTPATH=%1
+if not x%CERTPATH%x == xx goto doit
+echo Usage
+echo doall.bat [path to RD certificates]
+goto end
+
+:doit
+echo on
+call sbs
+call makesis teststartlist.pkg
+call makesis teststartlist_winscw.pkg
+call signsis teststartlist.sis teststartlist.sisx %CERTPATH%\rd.cer %CERTPATH%\rd-key.pem
+call signsis teststartlist_winscw.sis teststartlist_winscw.sisx %CERTPATH%\rd.cer %CERTPATH%\rd-key.pem
+if not exist ..\..\data mkdir ..\..\data
+if not exist ..\..\data\mmc mkdir ..\..\data\mmc
+if exist ..\..\data\mmc\teststartlist.sisx del /F/Q ..\..\data\mmc\teststartlist.sisx
+move teststartlist.sisx ..\..\data\mmc\.
+if exist ..\..\data\mmc\teststartlist_winscw.sisx del /F/Q ..\..\data\mmc\teststartlist_winscw.sisx
+move teststartlist_winscw.sisx ..\..\data\mmc\.
+del teststartlist.sis
+del teststartlist_winscw.sis
+call sbs reallyclean
+dir ..\..\data\mmc
+
+:end
+set CERTPATH=
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist.cpp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,26 @@
+/*
+* 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:  Test exe for startup list updater test module.
+*
+*/
+
+
+#include "teststartlist.h"
+
+
+GLDEF_C TInt E32Main()
+    {
+    return KErrNone;
+    }
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist.h	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,27 @@
+/*
+* 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:  Test exe for startup list updater test module.
+*
+*/
+
+
+#ifndef TESTSTARTLIST_H
+#define TESTSTARTLIST_H
+
+#include <e32base.h>
+
+GLDEF_C TInt E32Main();
+
+#endif  // TESTSTARTLIST_H
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist.mmp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,38 @@
+/*
+* 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:  Test exe for startup list updater test module.
+*
+*/
+
+#include <platform_paths.hrh>
+
+TARGET          teststartlist.exe
+TARGETTYPE      exe
+UID             0 0xEBE1C11B    // random UID
+
+START RESOURCE  teststartlist.rss
+TARGET          ebe1c11b.rsc
+TARGETPATH      /private/101f875a/import
+END
+
+USERINCLUDE     .
+APP_LAYER_SYSTEMINCLUDE
+
+SOURCEPATH      .
+SOURCE          teststartlist.cpp
+
+LIBRARY         euser.lib
+
+SMPSAFE
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,35 @@
+;
+; 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:  Test exe for startup list updater test module.
+;
+
+
+#{"TestStartList"},(0xEBE1C11B),1,0,0
+
+; S60 platform dependencies
+[0x101F7961],0,0,0,{"Series60ProductID"}
+[0x1028315F],0,0,0,{"Series60ProductID"}
+[0x10283160],0,0,0,{"Series60ProductID"}
+[0x20022E6D],0,0,0,{"Series60ProductID"}
+
+; Localised Vendor name
+%{"Nokia"}
+
+; Unique Vendor name
+:"Nokia"
+
+; Files
+"\epoc32\release\armv5\urel\teststartlist.exe" - "c:\sys\bin\teststartlist.exe"
+"\epoc32\data\z\private\101f875a\import\ebe1c11b.rsc" - "c:\private\101f875a\import\ebe1c11b.rsc"
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist.rss	Fri May 14 15:58:48 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:  Test exe for startup list updater test module.
+*
+*/
+
+#include <startupitem.rh>
+
+RESOURCE STARTUP_ITEM_INFO teststartlist
+    {
+    executable_name = "c:\\sys\\bin\\teststartlist.exe";
+    recovery = EStartupItemExPolicyNone;
+    }
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/data_src/teststartlist/teststartlist_winscw.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,36 @@
+;
+; 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:  Test exe for startup list updater test module.
+;
+
+
+#{"TestStartList"},(0xEBE1C11B),1,0,0
+
+; S60 platform dependencies
+[0x101F7961],0,0,0,{"Series60ProductID"}
+[0x1028315F],0,0,0,{"Series60ProductID"}
+[0x10283160],0,0,0,{"Series60ProductID"}
+[0x20022E6D],0,0,0,{"Series60ProductID"}
+
+; Localised Vendor name
+%{"Nokia"}
+
+; Unique Vendor name
+:"Nokia"
+
+; Files
+"\epoc32\release\winscw\udeb\teststartlist.exe" - "c:\sys\bin\teststartlist.exe"
+; "\epoc32\data\z\private\101f875a\import\ebe1c11b.rsc" - "c:\private\101f875a\import\ebe1c11b.rsc"
+"\epoc32\data\z\private\101f875a\import\ebe1c11b.rsc" - "c:\private\E5F88F39\import\ebe1c11b.rsc"
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/eabi/mt_startuplistupdateru.def	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,5 @@
+EXPORTS
+	_Z9LibEntryLR13CTestModuleIf @ 1 NONAME
+	_ZTI23CTestStartupListUpdater @ 2 NONAME
+	_ZTV23CTestStartupListUpdater @ 3 NONAME
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/group/bld.inf	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,33 @@
+/*
+* 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:  Startup list updater test module.
+*
+*/
+
+PRJ_PLATFORMS
+DEFAULT
+
+PRJ_EXPORTS
+../init/TestFramework.ini   /epoc32/winscw/c/testframework/TestFramework.ini
+../init/TestFramework.ini   /epoc32/data/z/system/data/TestFramework.ini
+../conf/mt_startuplistupdater.cfg   /epoc32/winscw/c/testframework/mt_startuplistupdater.cfg
+../conf/mt_startuplistupdater.cfg   /epoc32/data/z/testframework/mt_startuplistupdater.cfg
+../rom/mt_startuplistupdater.iby    CORE_MW_LAYER_IBY_EXPORT_PATH( mt_startuplistupdater.iby )
+
+PRJ_TESTMMPFILES
+mt_startuplistupdater.mmp
+
+PRJ_MMPFILES
+mt_startuplistupdater_nrm.mmp
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/group/mt_startuplistupdater.mmp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,44 @@
+/*
+* 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:  Startup list updater test module.
+*
+*/
+
+#include <platform_paths.hrh>
+
+TARGET          mt_startuplistupdater.dll
+TARGETTYPE      dll
+UID             0x1000008D 0x101FB3E3
+
+CAPABILITY      ALL -TCB
+VENDORID        VID_DEFAULT
+
+USERINCLUDE     ../inc
+MW_LAYER_SYSTEMINCLUDE
+
+SOURCEPATH      ../src
+SOURCE          mt_startuplistupdater.cpp
+SOURCE          mt_startuplistupdaterblocks.cpp
+
+LIBRARY         euser.lib
+LIBRARY         stiftestinterface.lib
+LIBRARY         stiftestengine.lib
+LIBRARY         sif.lib
+LIBRARY         scrclient.lib
+LIBRARY         dscstore.lib
+
+LANG            SC
+
+SMPSAFE
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/group/mt_startuplistupdater.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,34 @@
+;
+; 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:  Startup list updater test module.
+;
+
+; Languages
+&EN
+
+; Provide value for uid
+#{"STIF"},(0x00000000),1,1,0,TYPE=SA
+
+; Series60 product id for S60 3.0
+[0x101F7961], 0, 0, 0, {"Series60ProductID"}
+
+; Localised Vendor name
+%{"Nokia"}
+
+; Unique Vendor name
+:"Nokia"
+
+; Install files
+"\epoc32\release\armv5\udeb\mt_startuplistupdater.dll" - "!:\sys\bin\mt_startuplistupdater.dll"
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/group/mt_startuplistupdater_nrm.mmp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,19 @@
+/*
+* 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:  Startup list updater test module.
+*
+*/
+
+#include "mt_startuplistupdater.mmp"
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/inc/cleanupresetanddestroy.h	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,55 @@
+/*
+* Copyright (c) 2008-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:   Defines CleanupResetAndDestroyPushL
+*
+*/
+
+
+#ifndef CLEANUPRESETANDDESTROY_H
+#define CLEANUPRESETANDDESTROY_H
+
+template <class T>
+class CleanupResetAndDestroy
+    {
+public:
+    inline static void PushL( T& aRef );
+private:
+    static void ResetAndDestroy( TAny *aPtr );
+    };
+
+template <class T>
+inline void CleanupResetAndDestroyPushL( T& aRef );
+
+template <class T>
+inline void CleanupResetAndDestroy<T>::PushL( T& aRef )
+    {
+    CleanupStack::PushL( TCleanupItem( &ResetAndDestroy, &aRef ) );
+    }
+
+template <class T>
+void CleanupResetAndDestroy<T>::ResetAndDestroy( TAny *aPtr )
+    {
+    if( aPtr )
+        {
+        static_cast<T*>( aPtr )->ResetAndDestroy();
+        }
+    }
+
+template <class T>
+inline void CleanupResetAndDestroyPushL( T& aRef )
+    {
+    CleanupResetAndDestroy<T>::PushL( aRef );
+    }
+
+#endif // CLEANUPRESETANDDESTROY_H
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/inc/mt_startuplistupdater.h	Fri May 14 15:58:48 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:  Startup list updater test module.
+*
+*/
+
+#ifndef MT_STARTUPLISTUPDATER_H
+#define MT_STARTUPLISTUPDATER_H
+
+#include <StifLogger.h>
+#include <TestScripterInternal.h>
+#include <StifTestModule.h>
+#include <TestclassAssert.h>
+
+#define TEST_CLASS_VERSION_MAJOR 1
+#define TEST_CLASS_VERSION_MINOR 0
+#define TEST_CLASS_VERSION_BUILD 0
+
+_LIT( KTestStartupListUpdaterLogPath, "\\logs\\testframework\\mt_startuplistupdater\\" );
+_LIT( KTestStartupListUpdaterLogFile, "mt_startuplistupdater.txt" );
+_LIT( KTestStartupListUpdaterLogFileWithTitle, "mt_startuplistupdater_[%S].txt" );
+
+
+class CTestStartupListUpdater : public CScriptBase
+    {
+    public:     // constructors and destructor
+        static CTestStartupListUpdater* NewL( CTestModuleIf& aTestModuleIf );
+        ~CTestStartupListUpdater();
+
+    private:    // new functions
+        CTestStartupListUpdater( CTestModuleIf& aTestModuleIf );
+        void ConstructL();
+        void SendTestClassVersion();
+        void Delete();
+        void Print( const TInt aPriority, TRefByValue<const TDesC> aFmt, ... );
+
+    public:     // from CScriptBase
+        TInt RunMethodL( CStifItemParser& aItem );
+
+    private:    // test methods
+        TInt InstallL( CStifItemParser& aItem );
+        TInt RemoveL( CStifItemParser& aItem );
+        TInt CheckStartListContainsL( CStifItemParser& aItem );
+        TInt CheckStartListDoesNotContainL( CStifItemParser& aItem );
+
+    private:    // new functions
+        void GetStartupListL( RPointerArray<HBufC>& aStartupList );
+    };
+
+#endif      // MT_STARTUPLISTUPDATER_H
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/init/TestFramework.ini	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,37 @@
+#
+# 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:  Startup list updater test module.
+#
+#
+
+[Engine_Defaults]
+TestReportMode= FullReport
+CreateTestReport= YES
+TestReportFilePath= C:\LOGS\TestFramework\
+TestReportFileName= TestReport
+TestReportFormat= TXT
+TestReportOutput= FILE
+TestReportFileCreationMode= OVERWRITE
+DeviceResetDllName= StifResetForNokia.dll
+DisableMeasurement= stifmeasurementdisablenone
+Timeout= 0
+UITestingSupport= YES
+SeparateProcesses= NO
+[End_Defaults]
+
+[New_Module]
+ModuleName= testscripter
+TestCaseFile= c:\testframework\mt_startuplistupdater.cfg
+[End_Module]
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/rom/mt_startuplistupdater.iby	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,23 @@
+/*
+* 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:  Startup list updater test module.
+*
+*/
+
+#ifndef MT_STARTUPLISTUPDATERTEST_IBY
+#define MT_STARTUPLISTUPDATERTEST_IBY
+
+data=\epoc32\release\armv5\urel\mt_startuplistupdater.dll   \sys\bin\mt_startuplistupdater.dll
+
+#endif  // MT_STARTUPLISTUPDATERTEST_IBY
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/src/mt_startuplistupdater.cpp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,118 @@
+/*
+* 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:  Startup list updater test module.
+*
+*/
+
+#include "mt_startuplistupdater.h"          // CTestStartupListUpdater
+#include <SettingServerClient.h>            // RSettingServer
+
+
+// ======== MEMBER FUNCTIONS ========
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::CTestStartupListUpdater
+// ---------------------------------------------------------------------------
+//
+CTestStartupListUpdater::CTestStartupListUpdater( CTestModuleIf& aTestModuleIf ) :
+        CScriptBase( aTestModuleIf )
+    {
+    }
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::ConstructL
+// ---------------------------------------------------------------------------
+//
+void CTestStartupListUpdater::ConstructL()
+    {
+    // Read settings to check if test case name is to be appended to file name.
+    RSettingServer settingsServer;
+    User::LeaveIfError( settingsServer.Connect() );
+    CleanupClosePushL( settingsServer );
+
+    TLoggerSettings loggerSettings;
+    User::LeaveIfError( settingsServer.GetLoggerSettings( loggerSettings ) );
+
+    CleanupStack::PopAndDestroy( &settingsServer );
+
+    TFileName logFileName;
+    if( loggerSettings.iAddTestCaseTitle )
+        {
+        TName title;
+        TestModuleIf().GetTestCaseTitleL( title );
+        logFileName.Format( KTestStartupListUpdaterLogFileWithTitle, &title );
+        }
+    else
+        {
+        logFileName.Copy( KTestStartupListUpdaterLogFile );
+        }
+
+    iLog = CStifLogger::NewL( KTestStartupListUpdaterLogPath, logFileName,
+        CStifLogger::ETxt, CStifLogger::EFile, EFalse );
+    SendTestClassVersion();
+    }
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::NewL
+// ---------------------------------------------------------------------------
+//
+CTestStartupListUpdater* CTestStartupListUpdater::NewL( CTestModuleIf& aTestModuleIf )
+    {
+    CTestStartupListUpdater* self = new( ELeave ) CTestStartupListUpdater( aTestModuleIf );
+    CleanupStack::PushL( self );
+    self->ConstructL();
+    CleanupStack::Pop();
+    return self;
+    }
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::~CTestStartupListUpdater()
+// ---------------------------------------------------------------------------
+//
+CTestStartupListUpdater::~CTestStartupListUpdater()
+    {
+    Delete();
+    delete iLog;
+    }
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::SendTestClassVersion
+// ---------------------------------------------------------------------------
+//
+void CTestStartupListUpdater::SendTestClassVersion()
+    {
+    TVersion moduleVersion;
+    moduleVersion.iMajor = TEST_CLASS_VERSION_MAJOR;
+    moduleVersion.iMinor = TEST_CLASS_VERSION_MINOR;
+    moduleVersion.iBuild = TEST_CLASS_VERSION_BUILD;
+
+    TFileName moduleName;
+    moduleName = _L("mt_startuplistupdater.dll");
+
+    TBool newVersionOfMethod = ETrue;
+    TestModuleIf().SendTestModuleVersion( moduleVersion, moduleName, newVersionOfMethod );
+    }
+
+
+// ======== GLOBAL FUNCTIONS ========
+
+// ---------------------------------------------------------------------------
+// LibEntryL()
+// ---------------------------------------------------------------------------
+//
+EXPORT_C CScriptBase* LibEntryL( CTestModuleIf& aTestModuleIf )
+    {
+    return reinterpret_cast< CScriptBase* >( CTestStartupListUpdater::NewL( aTestModuleIf ) );
+    }
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/mt_startuplistupdater/src/mt_startuplistupdaterblocks.cpp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,325 @@
+/*
+* 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:  Startup list updater test module.
+*
+*/
+
+#include "mt_startuplistupdater.h"      // CTestStartupListUpdater
+#include "cleanupresetanddestroy.h"     // CleanupResetAndDestroyPushL
+#include <StifParser.h>                 // CStifItemParser
+#include <usif/sif/sif.h>               // Usif::RSoftwareInstall
+#include <usif/scr/scr.h>               // Usif::RSoftwareComponentRegistry
+#include <dscstore.h>                   // RDscStore
+#include <dscitem.h>                    // CDscItem
+
+const TInt KMaxLineLength = 256;
+
+_LIT( KTestTag, "SLU" );
+_LIT( KTestStartFormat, "%S: start" );
+_LIT( KTestParamFormatArg, "%S: %S => %d");
+_LIT( KTestDoneFormat, "%S: done" );
+
+using namespace Usif;
+
+
+// ======== LOCAL FUNCTIONS ========
+
+// ---------------------------------------------------------------------------
+// FileNamesEqual()
+// ---------------------------------------------------------------------------
+//
+TBool FileNamesEqual( const HBufC& aFile1, const HBufC& aFile2 )
+    {
+    return ( aFile1.CompareF( aFile2 ) == 0 );
+    }
+
+
+// ======== MEMBER FUNCTIONS ========
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::Delete
+// ---------------------------------------------------------------------------
+//
+void CTestStartupListUpdater::Delete()
+    {
+    }
+
+// -----------------------------------------------------------------------------
+// CTestStartupListUpdater::Print()
+// -----------------------------------------------------------------------------
+//
+void CTestStartupListUpdater::Print( const TInt aPriority,
+        TRefByValue<const TDesC> aFmt, ... )
+    {
+    VA_LIST list;
+    VA_START( list, aFmt );
+    TBuf<KMaxLineLength> buf;
+    buf.FormatList( aFmt, list );
+    iLog->Log( buf );
+    TestModuleIf().Printf( aPriority, KTestTag, buf );
+    }
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::RunMethodL
+// ---------------------------------------------------------------------------
+//
+TInt CTestStartupListUpdater::RunMethodL( CStifItemParser& aItem )
+    {
+    static TStifFunctionInfo const KFunctions[] =
+        {
+        ENTRY( "Install", CTestStartupListUpdater::InstallL ),
+        ENTRY( "Remove", CTestStartupListUpdater::RemoveL ),
+        ENTRY( "InStartList", CTestStartupListUpdater::CheckStartListContainsL ),
+        ENTRY( "NotInStartList", CTestStartupListUpdater::CheckStartListDoesNotContainL )
+        };
+
+    const TInt count = sizeof( KFunctions ) / sizeof( TStifFunctionInfo );
+    return RunInternalL( KFunctions, count, aItem );
+    }
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::InstallL
+// ---------------------------------------------------------------------------
+//
+TInt CTestStartupListUpdater::InstallL( CStifItemParser& aItem )
+    {
+    _LIT( KTestName, "Install" );
+    Print( 0, KTestStartFormat, &KTestName );
+    TInt testResult = KErrNone;
+
+    RSoftwareInstall installer;
+    User::LeaveIfError( installer.Connect() );
+    CleanupClosePushL( installer );
+
+    TPtrC param;
+    while ( aItem.GetNextString ( param ) == KErrNone )
+        {
+        COpaqueNamedParams* args = COpaqueNamedParams::NewLC();
+        COpaqueNamedParams* results = COpaqueNamedParams::NewLC();
+        args->AddIntL( KSifInParam_InstallSilently, 1 );
+
+        TRequestStatus status;
+        installer.Install( param, *args, *results, status );
+        User::WaitForRequest( status );
+        testResult = status.Int();
+
+        CleanupStack::PopAndDestroy( 2, args );
+
+        Print( 1, KTestParamFormatArg, &KTestName, &param, testResult );
+        }
+
+    CleanupStack::PopAndDestroy( &installer );
+
+    Print( 0, KTestDoneFormat, &KTestName );
+    return testResult;
+    }
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::RemoveL()
+// ---------------------------------------------------------------------------
+//
+TInt CTestStartupListUpdater::RemoveL( CStifItemParser& aItem )
+    {
+    _LIT( KTestName, "Remove" );
+    Print( 0, KTestStartFormat, &KTestName );
+    TInt testResult = KErrNone;
+
+    RSoftwareComponentRegistry registry;
+    User::LeaveIfError( registry.Connect() );
+    CleanupClosePushL( registry );
+
+    // Get installed application TComponentIds and TUids
+    RArray<TUid> uidList;
+    CleanupClosePushL( uidList );
+    RArray<TComponentId> componentIdList;
+    CleanupClosePushL( componentIdList );
+
+    registry.GetComponentIdsL( componentIdList );
+    for( TInt i = 0; i < componentIdList.Count(); ++i ) {
+        TComponentId compId = componentIdList[ i ];
+        CComponentEntry *compEntry = CComponentEntry::NewLC();
+        if( registry.GetComponentL( compId, *compEntry ) ) {
+            if( compEntry->IsRemovable() && compEntry->SoftwareType() == KSoftwareTypeNative )
+                {
+                _LIT(KCompUid, "CompUid");
+                CPropertyEntry *property = registry.GetComponentPropertyL( compId, KCompUid );
+                CleanupStack::PushL( property );
+                CIntPropertyEntry* intProperty = dynamic_cast<CIntPropertyEntry*>( property );
+                uidList.AppendL( TUid::Uid( intProperty->IntValue() ) );
+                CleanupStack::PopAndDestroy( property );
+            } else {
+                uidList.AppendL( KNullUid );
+            }
+
+        }
+        CleanupStack::PopAndDestroy( compEntry );
+    }
+    if( uidList.Count() != componentIdList.Count() )
+        {
+        _LIT( KFailedToGetIds, "Failed to get IDs" );
+        Print( 0, KTestStartFormat, &KFailedToGetIds );
+        testResult = KErrGeneral;
+        }
+
+    // Uninstall TUid apps listed in parameters
+    TPtrC param;
+    while( aItem.GetNextString ( param ) == KErrNone && testResult == KErrNone )
+        {
+        const TUint KMaxLimit = 0xFFFFFFFF;
+        TLex lex( param );
+        TUint32 intVal = 0;
+
+        _LIT( KHexPrefix, "0x" );
+        if( param.Left( KHexPrefix().Length() ) == KHexPrefix )
+            {
+            lex.Inc( KHexPrefix().Length() );
+            testResult = lex.BoundedVal( intVal, EHex, KMaxLimit );
+            }
+        else
+            {
+            testResult = lex.BoundedVal( intVal, EDecimal, KMaxLimit );
+            }
+
+        if( testResult == KErrNone )
+            {
+            TUid uid( TUid::Uid( intVal ) );
+            if( uid != KNullUid )
+                {
+                TInt index = uidList.Find( uid );
+                if( index >= 0 && index < componentIdList.Count() )
+                    {
+                    TComponentId componentId = componentIdList[ index ];
+
+                    RSoftwareInstall installer;
+                    User::LeaveIfError( installer.Connect() );
+                    CleanupClosePushL( installer );
+
+                    TRequestStatus status;
+                    installer.Uninstall( componentId, status );
+                    User::WaitForRequest( status );
+                    testResult = status.Int();
+
+                    CleanupStack::PopAndDestroy( &installer );
+                    }
+                else
+                    {
+                    testResult = KErrNotFound;
+                    }
+                }
+            else
+                {
+                testResult = KErrUnknown;
+                }
+            }
+        Print( 1, KTestParamFormatArg, &KTestName, &param, testResult );
+        }
+
+    CleanupStack::PopAndDestroy( 3, &registry );    // componentIdList, uidList, registry
+    Print( 0, KTestDoneFormat, &KTestName );
+    return testResult;
+    }
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::CheckStartListContainsL()
+// ---------------------------------------------------------------------------
+//
+TInt CTestStartupListUpdater::CheckStartListContainsL( CStifItemParser& aItem )
+    {
+    _LIT( KTestName, "InStartList" );
+    Print( 0, KTestStartFormat, &KTestName );
+    TInt testResult = KErrNone;
+
+    RPointerArray<HBufC> startupList;
+    CleanupResetAndDestroyPushL( startupList );
+    GetStartupListL( startupList );
+
+    TIdentityRelation<HBufC> compareFileNames( FileNamesEqual );
+
+    TPtrC param;
+    while( aItem.GetNextString ( param ) == KErrNone )
+        {
+        HBufC* buf = param.AllocLC();
+        if( startupList.Find( buf, compareFileNames ) == KErrNotFound )
+            {
+            testResult = KErrNotFound;
+            }
+        CleanupStack::PopAndDestroy( buf );
+        Print( 1, KTestParamFormatArg, &KTestName, &param, testResult );
+        }
+
+    CleanupStack::PopAndDestroy( &startupList );
+
+    Print( 0, KTestDoneFormat, &KTestName );
+    return testResult;
+    }
+
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::CheckStartListDoesNotContainL()
+// ---------------------------------------------------------------------------
+//
+TInt CTestStartupListUpdater::CheckStartListDoesNotContainL( CStifItemParser& aItem )
+    {
+    _LIT( KTestName, "NotInStartList" );
+    Print( 0, KTestStartFormat, &KTestName );
+    TInt testResult = KErrNone;
+
+    RPointerArray<HBufC> startupList;
+    CleanupResetAndDestroyPushL( startupList );
+    GetStartupListL( startupList );
+
+    TIdentityRelation<HBufC> compareFileNames( FileNamesEqual );
+
+    TPtrC param;
+    while( aItem.GetNextString ( param ) == KErrNone )
+        {
+        HBufC* buf = param.AllocLC();
+        if( startupList.Find( buf, compareFileNames ) >= 0 )
+            {
+            testResult = KErrAlreadyExists;
+            }
+        CleanupStack::PopAndDestroy( buf );
+        Print( 1, KTestParamFormatArg, &KTestName, &param, testResult );
+        }
+
+    CleanupStack::PopAndDestroy( &startupList );
+
+    Print( 0, KTestDoneFormat, &KTestName );
+    return testResult;
+    }
+
+// ---------------------------------------------------------------------------
+// CTestStartupListUpdater::GetStartupListL()
+// ---------------------------------------------------------------------------
+//
+void CTestStartupListUpdater::GetStartupListL( RPointerArray<HBufC>& aStartupList )
+    {
+    RDscStore dscStore;
+    dscStore.OpenL();
+    CleanupClosePushL( dscStore );
+    if( !dscStore.DscExistsL() )
+        {
+        dscStore.CreateDscL();
+        }
+    dscStore.EnumOpenLC();
+
+    while( CDscItem* item = dscStore.EnumReadNextL() )
+        {
+        CleanupStack::PushL( item );
+        aStartupList.AppendL( item->FileName().AllocL() );
+        CleanupStack::PopAndDestroy( item );
+        }
+
+    CleanupStack::PopAndDestroy( 2, &dscStore );    // EnumClose, dscStore
+    }
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/run_module_tests.bat	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,23 @@
+@echo off
+rem
+rem Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies).
+rem All rights reserved.
+rem This component and the accompanying materials are made available
+rem under the terms of "Eclipse Public License v1.0"
+rem which accompanies this distribution, and is available
+rem at the URL "http://www.eclipse.org/legal/epl-v10.html".
+rem
+rem Initial Contributors:
+rem Nokia Corporation - initial contribution.
+rem
+rem Contributors:
+rem
+rem Description:  Module tests for startup list updater.
+rem
+
+pushd mt_startuplistupdater
+call ctc_instrument_code.bat
+call ctc_compile_tests.bat
+call ctc_run_tests.bat
+call ctc_remove_instrumentation.bat
+popd
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/testslulauncher/main.cpp	Fri May 14 15:58:48 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:  Test startup list update launcher application
+*
+*/
+
+#include "testslulauncher.h"
+
+int main(int argc, char *argv[]) {
+    TestStartupListUpdateLauncher testApp(argc, argv);
+    testApp.setApplicationName("TestSLULauncher");
+    return testApp.exec();
+}
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/testslulauncher/testslulauncher.cpp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,134 @@
+/*
+* 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:  Test startup list update launcher application
+*
+*/
+
+#include "testslulauncher.h"
+#include <hbmainwindow.h>
+#include <hbview.h>
+#include <hbpushbutton.h>
+#include <hblabel.h>
+#include <hbmessagebox.h>
+#include <QGraphicsLinearLayout>
+#ifdef Q_OS_SYMBIAN
+#include <e32std.h>
+#endif  // Q_OS_SYMBIAN
+
+
+// ======== LOCAL FUNCTIONS ========
+
+#ifdef Q_OS_SYMBIAN
+_LIT( KStartupListUpdater, "z:\\sys\\bin\\startuplistupdater.exe" );
+
+// ---------------------------------------------------------------------------
+// DoLaunchStartupListUpdater()
+// ---------------------------------------------------------------------------
+//
+TInt DoLaunchStartupListUpdater()
+{
+    RProcess process;
+    TInt result = process.Create( KStartupListUpdater, KNullDesC );
+
+    if (result == KErrNone) {
+        TRequestStatus rendezvousStatus;
+        process.Rendezvous(rendezvousStatus);
+
+        // start process and wait until it is started
+        process.Resume();
+        User::WaitForRequest(rendezvousStatus);
+
+        if (rendezvousStatus.Int() == KErrNone) {
+            TRequestStatus logonStatus;
+            process.Logon(logonStatus);
+
+            // waits until process is finished
+            User::WaitForRequest(logonStatus);
+
+            result = logonStatus.Int();
+        } else {
+            result = rendezvousStatus.Int();
+        }
+
+        process.Close();
+    }
+
+    return result;
+}
+#endif  // Q_OS_SYMBIAN
+
+
+// ======== MEMBER FUNCTIONS ========
+
+// ---------------------------------------------------------------------------
+// TestStartupListUpdateLauncher::TestStartupListUpdateLauncher
+// ---------------------------------------------------------------------------
+//
+TestStartupListUpdateLauncher::TestStartupListUpdateLauncher(int& argc, char* argv[])
+        : HbApplication(argc, argv), mMainWindow(0), mMainView(0)
+{
+    mMainWindow = new HbMainWindow();
+    mMainView = new HbView();
+    mMainView->setTitle(tr("Test SLU Launcher"));
+
+    QGraphicsLinearLayout *layout = new QGraphicsLinearLayout(Qt::Vertical);
+
+    HbPushButton *updateStartupList = new HbPushButton(tr("Update Startup List"));
+    layout->addItem(updateStartupList);
+    connect(updateStartupList, SIGNAL(clicked()), this, SLOT(updateStartupList()));
+
+    HbPushButton *exitApp = new HbPushButton(tr("Exit"));
+    layout->addItem(exitApp);
+    connect(exitApp, SIGNAL(clicked()), this, SLOT(closeApp()));
+
+    mMainView->setLayout(layout);
+    mMainWindow->addView(mMainView);
+    mMainWindow->show();
+}
+
+// ---------------------------------------------------------------------------
+// TestStartupListUpdateLauncher::~TestStartupListUpdateLauncher
+// ---------------------------------------------------------------------------
+//
+TestStartupListUpdateLauncher::~TestStartupListUpdateLauncher()
+{
+    delete mMainView;
+    delete mMainWindow;
+}
+
+// ---------------------------------------------------------------------------
+// TestStartupListUpdateLauncher::updateStartupList()
+// ---------------------------------------------------------------------------
+//
+void TestStartupListUpdateLauncher::updateStartupList()
+{
+#ifdef Q_OS_SYMBIAN
+    int err = DoLaunchStartupListUpdater();
+    if( !err ) {
+        HbMessageBox::information(tr("Ok"));
+    } else {
+        HbMessageBox::information(tr("Error %L1").arg(err));
+    }
+#endif  // Q_OS_SYMBIAN
+}
+
+// ---------------------------------------------------------------------------
+// TestStartupListUpdateLauncher::closeApp()
+// ---------------------------------------------------------------------------
+//
+void TestStartupListUpdateLauncher::closeApp()
+{
+    qApp->exit();
+}
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/testslulauncher/testslulauncher.h	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,46 @@
+/*
+* 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:  Test startup list update launcher application
+*
+*/
+
+#ifndef TESTSLULAUNCHER_H
+#define TESTSLULAUNCHER_H
+
+#include <hbapplication.h>
+
+class HbMainWindow;
+class HbView;
+
+
+class TestStartupListUpdateLauncher : public HbApplication
+{
+    Q_OBJECT
+
+public:     // constructor and destructor
+    TestStartupListUpdateLauncher(int& argc, char* argv[]);
+    ~TestStartupListUpdateLauncher();
+
+private slots:
+    void updateStartupList();
+    void closeApp();
+
+private:    // functions
+
+private:    // data
+    HbMainWindow *mMainWindow;
+    HbView       *mMainView;
+};
+
+#endif  // TESTSLULAUNCHER_H
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/appinstaller/AppinstUi/startuplistupdater/tsrc/testslulauncher/testslulauncher.pro	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,35 @@
+#
+# 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:  Test startup list update launcher application
+#
+#
+
+
+TEMPLATE = app
+TARGET = testslulauncher
+DEPENDPATH += .
+INCLUDEPATH += .
+CONFIG += Hb
+
+HEADERS +=  testslulauncher.h
+SOURCES +=  testslulauncher.cpp main.cpp
+
+symbian {
+    TARGET.CAPABILITY = ALL -TCB
+    TARGET.UID2 = 0x100039ce
+    TARGET.UID3 = 0xed835a87      // random UID
+    TARGET.VID = VID_DEFAULT
+}
+
+
--- a/iaupdate/IAD/backgroundchecker/inc/iaupdatebgrefreshtimer.h	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/backgroundchecker/inc/iaupdatebgrefreshtimer.h	Fri May 14 15:58:48 2010 +0300
@@ -174,7 +174,7 @@
         
         void StartUpdatesCheckingL();    
         
-        HBufC8* LoadFileLC(const TDesC& aFile);
+        // HBufC8* LoadFileLC(const TDesC& aFile);
         
         TInt GetPrivatePathL( TFileName& aPath );
         
--- a/iaupdate/IAD/backgroundchecker/src/iaupdatebgrefreshtimer.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/backgroundchecker/src/iaupdatebgrefreshtimer.cpp	Fri May 14 15:58:48 2010 +0300
@@ -25,12 +25,16 @@
 #include <apgwgnam.h>
 #include <apgcli.h>
 #include <apacmdln.h>
-#include <data_caging_path_literals.hrh>
+// #include <avkon.hrh>
+//#include <StringLoader.h> 
+//#include <iaupdate.rsg>
+//#include <data_caging_path_literals.hrh>
 #include <bautils.h>
 #include <apgtask.h>
 #include <sysversioninfo.h>  //sysversioninfo
 #include <featurecontrol.h>
 
+#include <hb/hbcore/hbtextresolversymbian.h>
 #include "iaupdateprivatecrkeys.h"
 #include "iaupdate.hrh"
 
@@ -47,6 +51,8 @@
 _LIT(KImageFile, "qgn_note_swupdate_notification.svg");
 _LIT8( KFirstTimeCase, "0" );
 
+
+
 //CONSTANTS
 const TUint KIADUpdateLauncherUid( 0x2001FE2F );
 
@@ -1788,23 +1794,88 @@
 // ----------------------------------------------------------
 void CIAUpdateBGTimer::LaunchNotificationL( const int aNrOfUpdates )
     {
-    
-    _LIT( KIcon, "C:\\qgn_note_swupdate_notification.svg" );
+   
     _LIT( KFirstTimeText, "Check for updates ?" );
     _LIT( KNormalText, "Updates available" );
     _LIT( KSecondText, "Tap to view" );
+
+    // loc:
+    /*
+    _LIT( KIcon, "z:\\resource\\iaupdate\\qgn_note_swupdate_notification.svg" );
+    _LIT(KLocFile, "Text_Map_Swupdate_");
+    _LIT(KLocFilePath, "z:\\resource\\iaupdate\\");
+    
+    _LIT(KTitleFirstTime, "txt_software_update_list_software_update");
+    _LIT(KTitleOneUpdate, "txt_software_dpophead_update_available");
+    _LIT(KTitleSeveralUpdates, "txt_software_dpophead_updates_available");
+    
+    
+    _LIT(KSecondFirstTime, "txt_software_update_list_software_update");
+    _LIT(KSecondOneUpdate, "txt_software_dpopinfo_val_1_new");
+    _LIT(KSecondSeveralUpdates, "txt_software_dpopinfo_ln_new");
+   */
     
     FLOG("[bgchecker] LaunchNotificationL ");
         
     iMode = ModeL();
     
-    //text for 1st line
-     if ( iMode == ENormalMode )
-         {
-         
-         }
+    // loc: initialize localisation text loader
+    /*
+    TBool res = HbTextResolverSymbian::Init(KLocFile, KLocFilePath);
+    if ( res != KErrNone )
+        {
+        // nothing to do
+        }
+    */
+    
+    
+    // loc: Resolve title text
+    /*
+    HBufC*  titleText;
+    if ( aNrOfUpdates == 0 )
+        {
+        // First time case
+        titleText = HbTextResolverSymbian::LoadL( KTitleFirstTime );
+        }
+    else if ( aNrOfUpdates == 1 )
+        {
+        // one update available
+        titleText = HbTextResolverSymbian::LoadL( KTitleOneUpdate );
+        }
+    else
+        {
+        // several updates available
+        titleText = HbTextResolverSymbian::LoadL( KTitleSeveralUpdates );
+        }
+    
+    // Resolve second text
+    HBufC*  secondText;
+    if ( aNrOfUpdates == 0 )
+        {
+        // First time case
+        secondText = HbTextResolverSymbian::LoadL( KSecondFirstTime );
+        }
+    else if ( aNrOfUpdates == 1 )
+        {
+        // one update available
+        secondText = HbTextResolverSymbian::LoadL( KSecondOneUpdate, aNrOfUpdates );
+        }
+    else
+        {
+        // several updates available
+        // loc: text.append(hbTrId("txt_software_dblist_updates_available"));
+        secondText = HbTextResolverSymbian::LoadL( KSecondSeveralUpdates, aNrOfUpdates );
+        }
+     */
+    
+    // loc: Load title and second line
+    // HBufC* titleText = HbTextResolverSymbian::LoadL(KTextTitle);
+    // CleanupStack::PushL( titleText );
+    // HBufC* secondText3 = HbTextResolverSymbian::LoadL(KTextSecond);
+    // CleanupStack::PushL( titleText );
     
     //TBuf<256> iconPath;
+    
     TBuf<128> titleText;
     TBuf<128> secondText;
     
@@ -1835,10 +1906,18 @@
             //CleanupStack::PopAndDestroy( image );
             }
         }
+    
+    // loc: set image path
+    // iSoftNotification->SetImagePathL( KIcon );
   
     // Set texts
+    // loc: iSoftNotification->SetTextL( titleText->Des(), secondText->Des() );
     iSoftNotification->SetTextL( titleText, secondText );
     
+    // loc: delete text buffers
+    // CleanupStack::PopAndDestroy( titleText );
+    // CleanupStack::PopAndDestroy( titleText );
+    
     // Set number of updates
     iSoftNotification->SetNrOfUpdates( aNrOfUpdates );
    
@@ -1851,7 +1930,7 @@
 // ----------------------------------------------------------
 // CIAUpdateBGTimer::LaunchSoftNotificationL()
 // ----------------------------------------------------------
-/*
+/* HLa
 void CIAUpdateBGTimer::LaunchSoftNotificationL( const TInt& aResourceId, const TInt& SK1, const TInt& SK2 )
     {     
     iInternalFile->ReadControllerDataL(); 
@@ -1893,6 +1972,7 @@
     }
 */
 
+
 // ----------------------------------------------------------
 // CIAUpdateBGTimer::GetPrivatePathL()
 // ----------------------------------------------------------
@@ -1920,6 +2000,7 @@
     return err;
     }
 
+/*
 // ----------------------------------------------------------
 // CIAUpdateBGTimer::LoadFileLC()
 // ----------------------------------------------------------
@@ -1941,7 +2022,7 @@
     CleanupDeletePushL(imagebuf);
     return imagebuf;
      } 
-
+*/
  
  // ----------------------------------------------------------
  // CIAUpdateBGTimer::SetPrivateDriveL()
@@ -2030,6 +2111,7 @@
      return driveNum;
      }
 
+ 
 // ----------------------------------------------------------
 // CIAUpdateBGTimer::ReadResourceLC()
 // ----------------------------------------------------------
--- a/iaupdate/IAD/backgroundchecker/src/iaupdatebgsoftnotification.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/backgroundchecker/src/iaupdatebgsoftnotification.cpp	Fri May 14 15:58:48 2010 +0300
@@ -117,10 +117,13 @@
 //
 void CIAUpdateBGSoftNotification::ShowNotificationL()
     {
+    
+    /*
     _LIT( KIcon, "C:\\qgn_note_swupdate_notification.svg" );
     _LIT( KFirstTimeText, "Check for updates ?" );
     _LIT( KNormalText, "Check for updates ?" );
     _LIT( KTextRow2, "Tap to view" );
+    */
     
     FLOG("[bgchecker] ShowNotificationL");
     
@@ -283,10 +286,10 @@
         }
     
     // set wrapping, timeout and touch 
-    iNotificationDialog->SetTitleTextWrappingL(
+    iNotificationDialog->SetTitleTextWrapping(
             CHbDeviceNotificationDialogSymbian::TextWordWrap);
-    iNotificationDialog->SetTimeoutL(4000); //default 3000
-    iNotificationDialog->EnableTouchActivationL(ETrue); // default FALSE
+    iNotificationDialog->SetTimeout(4000); //default 3000
+    iNotificationDialog->EnableTouchActivation(ETrue); // default FALSE
   
     }  
 // ----------------------------------------------------------
--- a/iaupdate/IAD/bgcindicatorplugin/inc/bgcindicatorplugin.h	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/bgcindicatorplugin/inc/bgcindicatorplugin.h	Fri May 14 15:58:48 2010 +0300
@@ -54,7 +54,7 @@
      * @see HbIndicatorPluginInterface
      */
     bool accessAllowed(const QString &indicatorType,
-                               const HbSecurityInfo *securityInfo) const;   
+            const QVariantMap &securityInfo) const;
     /**
      * @see HbIndicatorPluginInterface
      */
--- a/iaupdate/IAD/bgcindicatorplugin/rom/bgcindicatorplugin.iby	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/bgcindicatorplugin/rom/bgcindicatorplugin.iby	Fri May 14 15:58:48 2010 +0300
@@ -20,4 +20,5 @@
 REM DLL
 file=ABI_DIR\UREL\bgcindicatorplugin.dll               SHARED_LIB_DIR\bgcindicatorplugin.dll UNPAGED
 data=\epoc32\data\z\resource\plugins\indicators\bgcindicatorplugin.qtplugin   \resource\plugins\indicators\bgcindicatorplugin.qtplugin
+data=\epoc32\s60\icons\qgn_note_swupdate_notification.svg   \resource\iaupdate\qgn_note_swupdate_notification.svg
 #endif
\ No newline at end of file
--- a/iaupdate/IAD/bgcindicatorplugin/src/bgcindicator.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/bgcindicatorplugin/src/bgcindicator.cpp	Fri May 14 15:58:48 2010 +0300
@@ -20,7 +20,10 @@
 #include <apacmdln.h>
 #include <xqservicerequest.h>
 
-// #include "debugtraces.h"
+#include <hb/hbcore/hbtranslator.h>
+
+#include <hbicon.h>
+
 #include "bgcindicator.h" 
 
 //----------------------------------------------------------------------
@@ -32,8 +35,8 @@
 // ----------------------------------------------------------------------------
 BgcIndicator::BgcIndicator(const QString &indicatorType) :
 HbIndicatorInterface(indicatorType,
-        HbIndicatorInterface::GroupPriorityHigh,
-        InteractionActivated),
+        HbIndicatorInterface::NotificationCategory,
+        InteractionActivated), 
         mNrOfUpdates(0)
     {
     }
@@ -56,7 +59,11 @@
     
     if (type == InteractionActivated) 
         {
-        StartIaupdateL();
+        TRAPD( err, StartIaupdateL() );
+        if ( err != KErrNone )
+            {
+            // nothing to do 
+            }
         handled = true;   
         
         emit deactivate(); 
@@ -70,27 +77,63 @@
 // ----------------------------------------------------------------------------
 QVariant BgcIndicator::indicatorData(int role) const
 {
-    
+    // use iaupdate's translate file
+    // loc: HbTranslator trans("z:\\resource\\iaupdate\\","Text_Map_Swupdate_");
+        
 switch(role)
     {
-    case TextRole: 
+    case PrimaryTextRole: 
         {
         QString text("");
-        if ( mNrOfUpdates > 0 )
+        if ( mNrOfUpdates == 0 )
+            {
+            // First time case
+            // loc: text.append(hbTrId("txt_software_update_list_software_update"));
+            text.append(QString("Check for updates?"));
+            }
+        else if ( mNrOfUpdates == 1 )
+            {
+            // one update available
+            // loc: text.append(hbTrId("txt_software_dblist_update_available"));
+            text.append(QString("Update available"));
+            }
+        else
+            {
+            // several updates available
+            // loc: text.append(hbTrId("txt_software_dblist_updates_available"));
             text.append(QString("Updates available"));
-        else
-            text.append(QString("Check for updates?"));
+            }
         return text;        
         }
     case SecondaryTextRole:
         {
-        QString text("Tap to view");
+        QString text("");
+        if ( mNrOfUpdates == 0 )
+            {
+            // First time case
+            // loc: QString text(hbTrId("txt_software_update_list_software_update"));
+            text.append(QString("Tap to view"));
+            }
+        else if ( mNrOfUpdates == 1 )
+            {
+            // one update available
+            // loc: QString text(hbTrId("txt_software_dblist_val_1_new"));
+            text.append(QString("%1 new").arg(mNrOfUpdates));
+            }
+        else
+            {
+            // several updates available
+            // loc: QString text(hbTrId("txt_software_dblist_val_ln_new"));
+            text.append(QString("%1 new").arg(mNrOfUpdates));
+            }
         return text; 
         }
-    case IconNameRole:
+    case DecorationNameRole:
+    case MonoDecorationNameRole:
         {
         // QString iconName("z:/resource/messaging/message.svg");
-        QString iconName("c:/qgn_note_swupdate_notification.svg");
+        // HbIcon iconName1 ("c:/qgn_note_swupdate_notification.svg");
+        QString iconName("z:/resource/iaupdate/qgn_note_swupdate_notification.svg");
         return iconName;
         }
     default: 
@@ -110,6 +153,7 @@
         case RequestActivate:
             {
             mNrOfUpdates = parameter.toInt();
+            emit dataChanged();
             handled =  true;
             }
             break;
@@ -126,7 +170,7 @@
     }
 
 // ----------------------------------------------------------
-// CIAUpdateBGTimer::StartIaupdateL()
+// BgcIndicator::StartIaupdateL()
 // ----------------------------------------------------------
 void BgcIndicator::StartIaupdateL() const
     {
@@ -135,16 +179,13 @@
     _LIT(KIAUpdateLauncherExe, "iaupdatelauncher.exe" );
     _LIT8( KRefreshFromNetworkDenied, "1" );
     
-    //FLOG("[bgchecker] StartIaupdateL() begin");
     RWsSession ws;   
     User::LeaveIfError( ws.Connect() == KErrNone );
     TApaTaskList tasklist(ws);   
     TApaTask task = tasklist.FindApp( TUid::Uid( KIADUpdateLauncherUid ) );
     if ( task.Exists() )
         {
-        //FLOG("[bgchecker] StartIaupdateL() IAD launcher process found");
         task.BringToForeground();
-        //FLOG("[bgchecker] StartIaupdateL() after task.BringToForeground()");
         ws.Close();
         }
     else 
@@ -165,6 +206,5 @@
         process.Resume();
         CleanupStack::PopAndDestroy( &process );    
         }
-    //FLOG("[bgchecker] StartIaupdateL() end");
     }
 
--- a/iaupdate/IAD/bgcindicatorplugin/src/bgcindicatorplugin.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/bgcindicatorplugin/src/bgcindicatorplugin.cpp	Fri May 14 15:58:48 2010 +0300
@@ -58,7 +58,7 @@
 // @see bgcindicatorplugin.h
 // ----------------------------------------------------------------------------
 bool BgcIndicatorPlugin::accessAllowed(const QString &indicatorType,
-    const HbSecurityInfo *securityInfo) const
+        const QVariantMap &securityInfo) const
 {
     Q_UNUSED(indicatorType)
     Q_UNUSED(securityInfo)
--- a/iaupdate/IAD/engine/bwins/iaupdateengineu.def	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/engine/bwins/iaupdateengineu.def	Fri May 14 15:58:48 2010 +0300
@@ -1,91 +1,90 @@
 EXPORTS
-	??0CIAUpdateXmlParser@@IAE@PAVCIAUpdateXmlSubParser@@@Z @ 1 NONAME ; CIAUpdateXmlParser::CIAUpdateXmlParser(class CIAUpdateXmlSubParser *)
-	??0CIAUpdateXmlSubParser@@IAE@XZ @ 2 NONAME ; CIAUpdateXmlSubParser::CIAUpdateXmlSubParser(void)
-	??1CIAUpdateControllerFile@@UAE@XZ @ 3 NONAME ; CIAUpdateControllerFile::~CIAUpdateControllerFile(void)
-	??1CIAUpdatePendingNodesFile@@UAE@XZ @ 4 NONAME ; CIAUpdatePendingNodesFile::~CIAUpdatePendingNodesFile(void)
-	??1CIAUpdateRestartInfo@@UAE@XZ @ 5 NONAME ; CIAUpdateRestartInfo::~CIAUpdateRestartInfo(void)
-	??1CIAUpdateXmlParser@@UAE@XZ @ 6 NONAME ; CIAUpdateXmlParser::~CIAUpdateXmlParser(void)
-	??1CIAUpdateXmlSubParser@@UAE@XZ @ 7 NONAME ; CIAUpdateXmlSubParser::~CIAUpdateXmlSubParser(void)
-	?AcceptData@CIAUpdateXmlSubParser@@IBEHXZ @ 8 NONAME ; int CIAUpdateXmlSubParser::AcceptData(void) const
-	?AppPackageUidL@IAUpdateUtils@@YA?AVTUid@@ABV2@@Z @ 9 NONAME ; class TUid IAUpdateUtils::AppPackageUidL(class TUid const &)
-	?AppPackageUidL@IAUpdateUtils@@YA?AVTUid@@ABV2@AAVTIAUpdateVersion@@@Z @ 10 NONAME ; class TUid IAUpdateUtils::AppPackageUidL(class TUid const &, class TIAUpdateVersion &)
-	?ConstructL@CIAUpdateXmlParser@@MAEXXZ @ 11 NONAME ; void CIAUpdateXmlParser::ConstructL(void)
-	?ConstructL@CIAUpdateXmlSubParser@@MAEXABVTDesC8@@@Z @ 12 NONAME ; void CIAUpdateXmlSubParser::ConstructL(class TDesC8 const &)
-	?CreateControllerL@IAUpdateFactory@@YAPAVMIAUpdateController@@ABVTUid@@AAVMIAUpdateControllerObserver@@@Z @ 13 NONAME ; class MIAUpdateController * IAUpdateFactory::CreateControllerL(class TUid const &, class MIAUpdateControllerObserver &)
-	?CurrentSubParser@CIAUpdateXmlSubParser@@IBEPAV1@XZ @ 14 NONAME ; class CIAUpdateXmlSubParser * CIAUpdateXmlSubParser::CurrentSubParser(void) const
-	?DeleteFiles@CIAUpdateRestartInfo@@QAEXXZ @ 15 NONAME ; void CIAUpdateRestartInfo::DeleteFiles(void)
-	?DesHexToIntL@IAUpdateUtils@@YAHABVTDesC16@@@Z @ 16 NONAME ; int IAUpdateUtils::DesHexToIntL(class TDesC16 const &)
-	?DesToVersionL@IAUpdateUtils@@YAXABVTDesC16@@AAC1AAF@Z @ 17 NONAME ; void IAUpdateUtils::DesToVersionL(class TDesC16 const &, signed char &, signed char &, short &)
-	?ElementTagInfoEquals@CIAUpdateXmlSubParser@@IBEHABVRTagInfo@Xml@@@Z @ 18 NONAME ; int CIAUpdateXmlSubParser::ElementTagInfoEquals(class Xml::RTagInfo const &) const
-	?FilePath@CIAUpdatePendingNodesFile@@QBEABVTDesC16@@XZ @ 19 NONAME ; class TDesC16 const & CIAUpdatePendingNodesFile::FilePath(void) const
-	?GetExtendedInterface@CIAUpdateXmlSubParser@@UAEPAXJ@Z @ 20 NONAME ; void * CIAUpdateXmlSubParser::GetExtendedInterface(long)
-	?Index@CIAUpdatePendingNodesFile@@QBEHXZ @ 21 NONAME ; int CIAUpdatePendingNodesFile::Index(void) const
-	?IsAppInstalledL@IAUpdateUtils@@YAHABVTUid@@@Z @ 22 NONAME ; int IAUpdateUtils::IsAppInstalledL(class TUid const &)
-	?IsAppInstalledL@IAUpdateUtils@@YAHABVTUid@@AAVTIAUpdateVersion@@@Z @ 23 NONAME ; int IAUpdateUtils::IsAppInstalledL(class TUid const &, class TIAUpdateVersion &)
-	?IsElementEnded@CIAUpdateXmlSubParser@@IBEHXZ @ 24 NONAME ; int CIAUpdateXmlSubParser::IsElementEnded(void) const
-	?IsElementStarted@CIAUpdateXmlSubParser@@IBEHXZ @ 25 NONAME ; int CIAUpdateXmlSubParser::IsElementStarted(void) const
-	?IsInstalledL@IAUpdateUtils@@YAHABVTUid@@ABVTDesC16@@@Z @ 26 NONAME ; int IAUpdateUtils::IsInstalledL(class TUid const &, class TDesC16 const &)
-	?Language@CIAUpdateControllerFile@@QBE?AW4TLanguage@@XZ @ 27 NONAME ; enum TLanguage CIAUpdateControllerFile::Language(void) const
-	?LocalName@CIAUpdateXmlSubParser@@IBEABVTDesC8@@XZ @ 28 NONAME ; class TDesC8 const & CIAUpdateXmlSubParser::LocalName(void) const
-	?NewL@CIAUpdateControllerFile@@SAPAV1@ABVTDesC16@@@Z @ 29 NONAME ; class CIAUpdateControllerFile * CIAUpdateControllerFile::NewL(class TDesC16 const &)
-	?NewL@CIAUpdateNetworkRegistration@@SAPAV1@AAVMIAUpdateNetworkRegistrationObserver@@@Z @ 30 NONAME ; class CIAUpdateNetworkRegistration * CIAUpdateNetworkRegistration::NewL(class MIAUpdateNetworkRegistrationObserver &)
-	?NewL@CIAUpdatePendingNodesFile@@SAPAV1@XZ @ 31 NONAME ; class CIAUpdatePendingNodesFile * CIAUpdatePendingNodesFile::NewL(void)
-	?NewL@CIAUpdateRestartInfo@@SAPAV1@XZ @ 32 NONAME ; class CIAUpdateRestartInfo * CIAUpdateRestartInfo::NewL(void)
-	?NewL@CIAUpdateXmlParser@@SAPAV1@PAVCIAUpdateXmlSubParser@@@Z @ 33 NONAME ; class CIAUpdateXmlParser * CIAUpdateXmlParser::NewL(class CIAUpdateXmlSubParser *)
-	?NewLC@CIAUpdateControllerFile@@SAPAV1@ABVTDesC16@@@Z @ 34 NONAME ; class CIAUpdateControllerFile * CIAUpdateControllerFile::NewLC(class TDesC16 const &)
-	?NewLC@CIAUpdatePendingNodesFile@@SAPAV1@XZ @ 35 NONAME ; class CIAUpdatePendingNodesFile * CIAUpdatePendingNodesFile::NewLC(void)
-	?NewLC@CIAUpdateRestartInfo@@SAPAV1@XZ @ 36 NONAME ; class CIAUpdateRestartInfo * CIAUpdateRestartInfo::NewLC(void)
-	?NewLC@CIAUpdateXmlParser@@SAPAV1@PAVCIAUpdateXmlSubParser@@@Z @ 37 NONAME ; class CIAUpdateXmlParser * CIAUpdateXmlParser::NewLC(class CIAUpdateXmlSubParser *)
-	?OnContentL@CIAUpdateXmlSubParser@@UAEXABVTDesC8@@H@Z @ 38 NONAME ; void CIAUpdateXmlSubParser::OnContentL(class TDesC8 const &, int)
-	?OnEndDocumentL@CIAUpdateXmlSubParser@@UAEXH@Z @ 39 NONAME ; void CIAUpdateXmlSubParser::OnEndDocumentL(int)
-	?OnEndElementL@CIAUpdateXmlSubParser@@UAEXABVRTagInfo@Xml@@H@Z @ 40 NONAME ; void CIAUpdateXmlSubParser::OnEndElementL(class Xml::RTagInfo const &, int)
-	?OnEndPrefixMappingL@CIAUpdateXmlSubParser@@UAEXABVRString@@H@Z @ 41 NONAME ; void CIAUpdateXmlSubParser::OnEndPrefixMappingL(class RString const &, int)
-	?OnError@CIAUpdateXmlSubParser@@UAEXH@Z @ 42 NONAME ; void CIAUpdateXmlSubParser::OnError(int)
-	?OnIgnorableWhiteSpaceL@CIAUpdateXmlSubParser@@UAEXABVTDesC8@@H@Z @ 43 NONAME ; void CIAUpdateXmlSubParser::OnIgnorableWhiteSpaceL(class TDesC8 const &, int)
-	?OnProcessingInstructionL@CIAUpdateXmlSubParser@@UAEXABVTDesC8@@0H@Z @ 44 NONAME ; void CIAUpdateXmlSubParser::OnProcessingInstructionL(class TDesC8 const &, class TDesC8 const &, int)
-	?OnSkippedEntityL@CIAUpdateXmlSubParser@@UAEXABVRString@@H@Z @ 45 NONAME ; void CIAUpdateXmlSubParser::OnSkippedEntityL(class RString const &, int)
-	?OnStartDocumentL@CIAUpdateXmlSubParser@@UAEXABVRDocumentParameters@Xml@@H@Z @ 46 NONAME ; void CIAUpdateXmlSubParser::OnStartDocumentL(class Xml::RDocumentParameters const &, int)
-	?OnStartElementL@CIAUpdateXmlSubParser@@UAEXABVRTagInfo@Xml@@ABV?$RArray@VRAttribute@Xml@@@@H@Z @ 47 NONAME ; void CIAUpdateXmlSubParser::OnStartElementL(class Xml::RTagInfo const &, class RArray<class Xml::RAttribute> const &, int)
-	?OnStartPrefixMappingL@CIAUpdateXmlSubParser@@UAEXABVRString@@0H@Z @ 48 NONAME ; void CIAUpdateXmlSubParser::OnStartPrefixMappingL(class RString const &, class RString const &, int)
-	?ParseFileL@CIAUpdateXmlParser@@QAEXABVTDesC16@@@Z @ 49 NONAME ; void CIAUpdateXmlParser::ParseFileL(class TDesC16 const &)
-	?ParseL@CIAUpdateXmlParser@@QAEXABVTDesC16@@@Z @ 50 NONAME ; void CIAUpdateXmlParser::ParseL(class TDesC16 const &)
-	?ParseL@CIAUpdateXmlParser@@QAEXABVTDesC8@@@Z @ 51 NONAME ; void CIAUpdateXmlParser::ParseL(class TDesC8 const &)
-	?ParsePrivateFileL@CIAUpdateXmlParser@@QAEXABVTDesC16@@@Z @ 52 NONAME ; void CIAUpdateXmlParser::ParsePrivateFileL(class TDesC16 const &)
-	?PendingNodes@CIAUpdatePendingNodesFile@@QAEAAV?$RPointerArray@VCIAUpdaterIdentifier@@@@XZ @ 53 NONAME ; class RPointerArray<class CIAUpdaterIdentifier> & CIAUpdatePendingNodesFile::PendingNodes(void)
-	?PendingNodesFile@CIAUpdateRestartInfo@@QAEAAVCIAUpdatePendingNodesFile@@XZ @ 54 NONAME ; class CIAUpdatePendingNodesFile & CIAUpdateRestartInfo::PendingNodesFile(void)
-	?ReadControllerDataL@CIAUpdateControllerFile@@QAEHXZ @ 55 NONAME ; int CIAUpdateControllerFile::ReadControllerDataL(void)
-	?ReadDataL@CIAUpdatePendingNodesFile@@QAEHXZ @ 56 NONAME ; int CIAUpdatePendingNodesFile::ReadDataL(void)
-	?RefreshTime@CIAUpdateControllerFile@@QBEABVTTime@@XZ @ 57 NONAME ; class TTime const & CIAUpdateControllerFile::RefreshTime(void) const
-	?RemoveFile@CIAUpdatePendingNodesFile@@QAEHXZ @ 58 NONAME ; int CIAUpdatePendingNodesFile::RemoveFile(void)
-	?Reset@CIAUpdatePendingNodesFile@@QAEXXZ @ 59 NONAME ; void CIAUpdatePendingNodesFile::Reset(void)
-	?ResultsFile@CIAUpdateRestartInfo@@QAEAAVCIAUpdaterResultsFile@@XZ @ 60 NONAME ; class CIAUpdaterResultsFile & CIAUpdateRestartInfo::ResultsFile(void)
-	?SetCurrentData@CIAUpdateControllerFile@@QAEXXZ @ 61 NONAME ; void CIAUpdateControllerFile::SetCurrentData(void)
-	?SetCurrentLanguage@CIAUpdateControllerFile@@QAEXXZ @ 62 NONAME ; void CIAUpdateControllerFile::SetCurrentLanguage(void)
-	?SetCurrentRefreshTime@CIAUpdateControllerFile@@QAEXXZ @ 63 NONAME ; void CIAUpdateControllerFile::SetCurrentRefreshTime(void)
-	?SetFilePathL@CIAUpdatePendingNodesFile@@QAEXABVTDesC16@@@Z @ 64 NONAME ; void CIAUpdatePendingNodesFile::SetFilePathL(class TDesC16 const &)
-	?SetIndex@CIAUpdatePendingNodesFile@@QAEXH@Z @ 65 NONAME ; void CIAUpdatePendingNodesFile::SetIndex(int)
-	?SetLanguage@CIAUpdateControllerFile@@QAEXW4TLanguage@@@Z @ 66 NONAME ; void CIAUpdateControllerFile::SetLanguage(enum TLanguage)
-	?SetRefreshTime@CIAUpdateControllerFile@@QAEXABVTTime@@@Z @ 67 NONAME ; void CIAUpdateControllerFile::SetRefreshTime(class TTime const &)
-	?SetRefreshTime@CIAUpdateControllerFile@@QAEX_J@Z @ 68 NONAME ; void CIAUpdateControllerFile::SetRefreshTime(long long)
-	?SilentInstallOptionsL@IAUpdateUtils@@YA?AVTInstallOptions@SwiUI@@ABVTUid@@H@Z @ 69 NONAME ; class SwiUI::TInstallOptions IAUpdateUtils::SilentInstallOptionsL(class TUid const &, int)
-	?SpaceAvailableInInternalDrivesL@IAUpdateUtils@@YAHAAV?$RPointerArray@VMIAUpdateNode@@@@@Z @ 70 NONAME ; int IAUpdateUtils::SpaceAvailableInInternalDrivesL(class RPointerArray<class MIAUpdateNode> &)
-	?StartMonitoringL@CIAUpdateNetworkRegistration@@QAEXXZ @ 71 NONAME ; void CIAUpdateNetworkRegistration::StartMonitoringL(void)
-	?SubParser@CIAUpdateXmlParser@@IAEAAVCIAUpdateXmlSubParser@@XZ @ 72 NONAME ; class CIAUpdateXmlSubParser & CIAUpdateXmlParser::SubParser(void)
-	?SubParsers@CIAUpdateXmlSubParser@@IAEAAV?$RPointerArray@VCIAUpdateXmlSubParser@@@@XZ @ 73 NONAME ; class RPointerArray<class CIAUpdateXmlSubParser> & CIAUpdateXmlSubParser::SubParsers(void)
-	?UnknownElementCounter@CIAUpdateXmlSubParser@@IBEHXZ @ 74 NONAME ; int CIAUpdateXmlSubParser::UnknownElementCounter(void) const
-	?WriteControllerDataL@CIAUpdateControllerFile@@QAEXXZ @ 75 NONAME ; void CIAUpdateControllerFile::WriteControllerDataL(void)
-	?WriteDataL@CIAUpdatePendingNodesFile@@QAEXXZ @ 76 NONAME ; void CIAUpdatePendingNodesFile::WriteDataL(void)
-	??0TIAUpdateVersion@@QAE@ABVTVersion@@@Z @ 77 NONAME ; TIAUpdateVersion::TIAUpdateVersion(class TVersion const &)
-	??0TIAUpdateVersion@@QAE@XZ @ 78 NONAME ; TIAUpdateVersion::TIAUpdateVersion(void)
-	??4TIAUpdateVersion@@QAEABV0@ABVTVersion@@@Z @ 79 NONAME ; class TIAUpdateVersion const & TIAUpdateVersion::operator=(class TVersion const &)
-	??8TIAUpdateVersion@@QBEHABV0@@Z @ 80 NONAME ; int TIAUpdateVersion::operator==(class TIAUpdateVersion const &) const
-	??9TIAUpdateVersion@@QBEHABV0@@Z @ 81 NONAME ; int TIAUpdateVersion::operator!=(class TIAUpdateVersion const &) const
-	??MTIAUpdateVersion@@QBEHABV0@@Z @ 82 NONAME ; int TIAUpdateVersion::operator<(class TIAUpdateVersion const &) const
-	??NTIAUpdateVersion@@QBEHABV0@@Z @ 83 NONAME ; int TIAUpdateVersion::operator<=(class TIAUpdateVersion const &) const
-	??OTIAUpdateVersion@@QBEHABV0@@Z @ 84 NONAME ; int TIAUpdateVersion::operator>(class TIAUpdateVersion const &) const
-	??PTIAUpdateVersion@@QBEHABV0@@Z @ 85 NONAME ; int TIAUpdateVersion::operator>=(class TIAUpdateVersion const &) const
-	?InternalizeL@TIAUpdateVersion@@QAEXABVTDesC16@@@Z @ 86 NONAME ; void TIAUpdateVersion::InternalizeL(class TDesC16 const &)
-	?SetToFloor@TIAUpdateVersion@@QAEXXZ @ 87 NONAME ; void TIAUpdateVersion::SetToFloor(void)
-	?SetToRoof@TIAUpdateVersion@@QAEXXZ @ 88 NONAME ; void TIAUpdateVersion::SetToRoof(void)
-	?IsWidgetInstalledL@IAUpdateUtils@@YAHABVTDesC16@@AAVTIAUpdateVersion@@@Z @ 89 NONAME ; int IAUpdateUtils::IsWidgetInstalledL(class TDesC16 const &, class TIAUpdateVersion &)
+	?SetFilePathL@CIAUpdatePendingNodesFile@@QAEXABVTDesC16@@@Z @ 1 NONAME ; void CIAUpdatePendingNodesFile::SetFilePathL(class TDesC16 const &)
+	?OnProcessingInstructionL@CIAUpdateXmlSubParser@@UAEXABVTDesC8@@0H@Z @ 2 NONAME ; void CIAUpdateXmlSubParser::OnProcessingInstructionL(class TDesC8 const &, class TDesC8 const &, int)
+	?SetCurrentData@CIAUpdateControllerFile@@QAEXXZ @ 3 NONAME ; void CIAUpdateControllerFile::SetCurrentData(void)
+	?ElementTagInfoEquals@CIAUpdateXmlSubParser@@IBEHABVRTagInfo@Xml@@@Z @ 4 NONAME ; int CIAUpdateXmlSubParser::ElementTagInfoEquals(class Xml::RTagInfo const &) const
+	??PTIAUpdateVersion@@QBEHABV0@@Z @ 5 NONAME ; int TIAUpdateVersion::operator>=(class TIAUpdateVersion const &) const
+	??OTIAUpdateVersion@@QBEHABV0@@Z @ 6 NONAME ; int TIAUpdateVersion::operator>(class TIAUpdateVersion const &) const
+	?NewL@CIAUpdateXmlParser@@SAPAV1@PAVCIAUpdateXmlSubParser@@@Z @ 7 NONAME ; class CIAUpdateXmlParser * CIAUpdateXmlParser::NewL(class CIAUpdateXmlSubParser *)
+	??NTIAUpdateVersion@@QBEHABV0@@Z @ 8 NONAME ; int TIAUpdateVersion::operator<=(class TIAUpdateVersion const &) const
+	?IsElementEnded@CIAUpdateXmlSubParser@@IBEHXZ @ 9 NONAME ; int CIAUpdateXmlSubParser::IsElementEnded(void) const
+	??MTIAUpdateVersion@@QBEHABV0@@Z @ 10 NONAME ; int TIAUpdateVersion::operator<(class TIAUpdateVersion const &) const
+	?ParseFileL@CIAUpdateXmlParser@@QAEXABVTDesC16@@@Z @ 11 NONAME ; void CIAUpdateXmlParser::ParseFileL(class TDesC16 const &)
+	?ParsePrivateFileL@CIAUpdateXmlParser@@QAEXABVTDesC16@@@Z @ 12 NONAME ; void CIAUpdateXmlParser::ParsePrivateFileL(class TDesC16 const &)
+	?OnEndPrefixMappingL@CIAUpdateXmlSubParser@@UAEXABVRString@@H@Z @ 13 NONAME ; void CIAUpdateXmlSubParser::OnEndPrefixMappingL(class RString const &, int)
+	?SubParsers@CIAUpdateXmlSubParser@@IAEAAV?$RPointerArray@VCIAUpdateXmlSubParser@@@@XZ @ 14 NONAME ; class RPointerArray<class CIAUpdateXmlSubParser> & CIAUpdateXmlSubParser::SubParsers(void)
+	?OnSkippedEntityL@CIAUpdateXmlSubParser@@UAEXABVRString@@H@Z @ 15 NONAME ; void CIAUpdateXmlSubParser::OnSkippedEntityL(class RString const &, int)
+	?FilePath@CIAUpdatePendingNodesFile@@QBEABVTDesC16@@XZ @ 16 NONAME ; class TDesC16 const & CIAUpdatePendingNodesFile::FilePath(void) const
+	?SetCurrentLanguage@CIAUpdateControllerFile@@QAEXXZ @ 17 NONAME ; void CIAUpdateControllerFile::SetCurrentLanguage(void)
+	??1CIAUpdatePendingNodesFile@@UAE@XZ @ 18 NONAME ; CIAUpdatePendingNodesFile::~CIAUpdatePendingNodesFile(void)
+	?ConstructL@CIAUpdateXmlParser@@MAEXXZ @ 19 NONAME ; void CIAUpdateXmlParser::ConstructL(void)
+	??1CIAUpdateXmlSubParser@@UAE@XZ @ 20 NONAME ; CIAUpdateXmlSubParser::~CIAUpdateXmlSubParser(void)
+	??4TIAUpdateVersion@@QAEABV0@ABVTVersion@@@Z @ 21 NONAME ; class TIAUpdateVersion const & TIAUpdateVersion::operator=(class TVersion const &)
+	?WriteControllerDataL@CIAUpdateControllerFile@@QAEXXZ @ 22 NONAME ; void CIAUpdateControllerFile::WriteControllerDataL(void)
+	?SetToRoof@TIAUpdateVersion@@QAEXXZ @ 23 NONAME ; void TIAUpdateVersion::SetToRoof(void)
+	?OnStartElementL@CIAUpdateXmlSubParser@@UAEXABVRTagInfo@Xml@@ABV?$RArray@VRAttribute@Xml@@@@H@Z @ 24 NONAME ; void CIAUpdateXmlSubParser::OnStartElementL(class Xml::RTagInfo const &, class RArray<class Xml::RAttribute> const &, int)
+	??0TIAUpdateVersion@@QAE@XZ @ 25 NONAME ; TIAUpdateVersion::TIAUpdateVersion(void)
+	?GetExtendedInterface@CIAUpdateXmlSubParser@@UAEPAXJ@Z @ 26 NONAME ; void * CIAUpdateXmlSubParser::GetExtendedInterface(long)
+	?OnError@CIAUpdateXmlSubParser@@UAEXH@Z @ 27 NONAME ; void CIAUpdateXmlSubParser::OnError(int)
+	?SetCurrentRefreshTime@CIAUpdateControllerFile@@QAEXXZ @ 28 NONAME ; void CIAUpdateControllerFile::SetCurrentRefreshTime(void)
+	?RemoveFile@CIAUpdatePendingNodesFile@@QAEHXZ @ 29 NONAME ; int CIAUpdatePendingNodesFile::RemoveFile(void)
+	?ParseL@CIAUpdateXmlParser@@QAEXABVTDesC16@@@Z @ 30 NONAME ; void CIAUpdateXmlParser::ParseL(class TDesC16 const &)
+	?CreateControllerL@IAUpdateFactory@@YAPAVMIAUpdateController@@ABVTUid@@AAVMIAUpdateControllerObserver@@@Z @ 31 NONAME ; class MIAUpdateController * IAUpdateFactory::CreateControllerL(class TUid const &, class MIAUpdateControllerObserver &)
+	?OnStartPrefixMappingL@CIAUpdateXmlSubParser@@UAEXABVRString@@0H@Z @ 32 NONAME ; void CIAUpdateXmlSubParser::OnStartPrefixMappingL(class RString const &, class RString const &, int)
+	?NewLC@CIAUpdateXmlParser@@SAPAV1@PAVCIAUpdateXmlSubParser@@@Z @ 33 NONAME ; class CIAUpdateXmlParser * CIAUpdateXmlParser::NewLC(class CIAUpdateXmlSubParser *)
+	?OnStartDocumentL@CIAUpdateXmlSubParser@@UAEXABVRDocumentParameters@Xml@@H@Z @ 34 NONAME ; void CIAUpdateXmlSubParser::OnStartDocumentL(class Xml::RDocumentParameters const &, int)
+	?SetToFloor@TIAUpdateVersion@@QAEXXZ @ 35 NONAME ; void TIAUpdateVersion::SetToFloor(void)
+	?AcceptData@CIAUpdateXmlSubParser@@IBEHXZ @ 36 NONAME ; int CIAUpdateXmlSubParser::AcceptData(void) const
+	?OnIgnorableWhiteSpaceL@CIAUpdateXmlSubParser@@UAEXABVTDesC8@@H@Z @ 37 NONAME ; void CIAUpdateXmlSubParser::OnIgnorableWhiteSpaceL(class TDesC8 const &, int)
+	??9TIAUpdateVersion@@QBEHABV0@@Z @ 38 NONAME ; int TIAUpdateVersion::operator!=(class TIAUpdateVersion const &) const
+	??8TIAUpdateVersion@@QBEHABV0@@Z @ 39 NONAME ; int TIAUpdateVersion::operator==(class TIAUpdateVersion const &) const
+	?NewL@CIAUpdateControllerFile@@SAPAV1@ABVTDesC16@@@Z @ 40 NONAME ; class CIAUpdateControllerFile * CIAUpdateControllerFile::NewL(class TDesC16 const &)
+	?IsInstalledL@IAUpdateUtils@@YAHABVTUid@@ABVTDesC16@@@Z @ 41 NONAME ; int IAUpdateUtils::IsInstalledL(class TUid const &, class TDesC16 const &)
+	?AppPackageUidL@IAUpdateUtils@@YA?AVTUid@@ABV2@AAVTIAUpdateVersion@@@Z @ 42 NONAME ; class TUid IAUpdateUtils::AppPackageUidL(class TUid const &, class TIAUpdateVersion &)
+	?WriteDataL@CIAUpdatePendingNodesFile@@QAEXXZ @ 43 NONAME ; void CIAUpdatePendingNodesFile::WriteDataL(void)
+	?ConstructL@CIAUpdateXmlSubParser@@MAEXABVTDesC8@@@Z @ 44 NONAME ; void CIAUpdateXmlSubParser::ConstructL(class TDesC8 const &)
+	?DeleteFiles@CIAUpdateRestartInfo@@QAEXXZ @ 45 NONAME ; void CIAUpdateRestartInfo::DeleteFiles(void)
+	?SpaceAvailableInInternalDrivesL@IAUpdateUtils@@YAHAAV?$RPointerArray@VMIAUpdateNode@@@@@Z @ 46 NONAME ; int IAUpdateUtils::SpaceAvailableInInternalDrivesL(class RPointerArray<class MIAUpdateNode> &)
+	?IsAppInstalledL@IAUpdateUtils@@YAHABVTUid@@@Z @ 47 NONAME ; int IAUpdateUtils::IsAppInstalledL(class TUid const &)
+	?ReadControllerDataL@CIAUpdateControllerFile@@QAEHXZ @ 48 NONAME ; int CIAUpdateControllerFile::ReadControllerDataL(void)
+	??0TIAUpdateVersion@@QAE@ABVTVersion@@@Z @ 49 NONAME ; TIAUpdateVersion::TIAUpdateVersion(class TVersion const &)
+	?OnEndElementL@CIAUpdateXmlSubParser@@UAEXABVRTagInfo@Xml@@H@Z @ 50 NONAME ; void CIAUpdateXmlSubParser::OnEndElementL(class Xml::RTagInfo const &, int)
+	?AppPackageUidL@IAUpdateUtils@@YA?AVTUid@@ABV2@@Z @ 51 NONAME ; class TUid IAUpdateUtils::AppPackageUidL(class TUid const &)
+	?StartMonitoringL@CIAUpdateNetworkRegistration@@QAEXXZ @ 52 NONAME ; void CIAUpdateNetworkRegistration::StartMonitoringL(void)
+	?UnknownElementCounter@CIAUpdateXmlSubParser@@IBEHXZ @ 53 NONAME ; int CIAUpdateXmlSubParser::UnknownElementCounter(void) const
+	?SetLanguage@CIAUpdateControllerFile@@QAEXW4TLanguage@@@Z @ 54 NONAME ; void CIAUpdateControllerFile::SetLanguage(enum TLanguage)
+	?DesHexToIntL@IAUpdateUtils@@YAHABVTDesC16@@@Z @ 55 NONAME ; int IAUpdateUtils::DesHexToIntL(class TDesC16 const &)
+	??1CIAUpdateXmlParser@@UAE@XZ @ 56 NONAME ; CIAUpdateXmlParser::~CIAUpdateXmlParser(void)
+	?SetRefreshTime@CIAUpdateControllerFile@@QAEX_J@Z @ 57 NONAME ; void CIAUpdateControllerFile::SetRefreshTime(long long)
+	??0CIAUpdateXmlSubParser@@IAE@XZ @ 58 NONAME ; CIAUpdateXmlSubParser::CIAUpdateXmlSubParser(void)
+	?ReadDataL@CIAUpdatePendingNodesFile@@QAEHXZ @ 59 NONAME ; int CIAUpdatePendingNodesFile::ReadDataL(void)
+	?NewLC@CIAUpdateRestartInfo@@SAPAV1@XZ @ 60 NONAME ; class CIAUpdateRestartInfo * CIAUpdateRestartInfo::NewLC(void)
+	??1CIAUpdateRestartInfo@@UAE@XZ @ 61 NONAME ; CIAUpdateRestartInfo::~CIAUpdateRestartInfo(void)
+	?NewLC@CIAUpdateControllerFile@@SAPAV1@ABVTDesC16@@@Z @ 62 NONAME ; class CIAUpdateControllerFile * CIAUpdateControllerFile::NewLC(class TDesC16 const &)
+	?InternalizeL@TIAUpdateVersion@@QAEXABVTDesC16@@@Z @ 63 NONAME ; void TIAUpdateVersion::InternalizeL(class TDesC16 const &)
+	?SetRefreshTime@CIAUpdateControllerFile@@QAEXABVTTime@@@Z @ 64 NONAME ; void CIAUpdateControllerFile::SetRefreshTime(class TTime const &)
+	?RefreshTime@CIAUpdateControllerFile@@QBEABVTTime@@XZ @ 65 NONAME ; class TTime const & CIAUpdateControllerFile::RefreshTime(void) const
+	?Language@CIAUpdateControllerFile@@QBE?AW4TLanguage@@XZ @ 66 NONAME ; enum TLanguage CIAUpdateControllerFile::Language(void) const
+	?NewLC@CIAUpdatePendingNodesFile@@SAPAV1@XZ @ 67 NONAME ; class CIAUpdatePendingNodesFile * CIAUpdatePendingNodesFile::NewLC(void)
+	?Index@CIAUpdatePendingNodesFile@@QBEHXZ @ 68 NONAME ; int CIAUpdatePendingNodesFile::Index(void) const
+	?IsWidgetInstalledL@IAUpdateUtils@@YAHABVTDesC16@@AAVTIAUpdateVersion@@@Z @ 69 NONAME ; int IAUpdateUtils::IsWidgetInstalledL(class TDesC16 const &, class TIAUpdateVersion &)
+	?PendingNodesFile@CIAUpdateRestartInfo@@QAEAAVCIAUpdatePendingNodesFile@@XZ @ 70 NONAME ; class CIAUpdatePendingNodesFile & CIAUpdateRestartInfo::PendingNodesFile(void)
+	?CurrentSubParser@CIAUpdateXmlSubParser@@IBEPAV1@XZ @ 71 NONAME ; class CIAUpdateXmlSubParser * CIAUpdateXmlSubParser::CurrentSubParser(void) const
+	?SetIndex@CIAUpdatePendingNodesFile@@QAEXH@Z @ 72 NONAME ; void CIAUpdatePendingNodesFile::SetIndex(int)
+	?PendingNodes@CIAUpdatePendingNodesFile@@QAEAAV?$RPointerArray@VCIAUpdaterIdentifier@@@@XZ @ 73 NONAME ; class RPointerArray<class CIAUpdaterIdentifier> & CIAUpdatePendingNodesFile::PendingNodes(void)
+	?SubParser@CIAUpdateXmlParser@@IAEAAVCIAUpdateXmlSubParser@@XZ @ 74 NONAME ; class CIAUpdateXmlSubParser & CIAUpdateXmlParser::SubParser(void)
+	?IsElementStarted@CIAUpdateXmlSubParser@@IBEHXZ @ 75 NONAME ; int CIAUpdateXmlSubParser::IsElementStarted(void) const
+	?IsAppInstalledL@IAUpdateUtils@@YAHABVTUid@@AAVTIAUpdateVersion@@@Z @ 76 NONAME ; int IAUpdateUtils::IsAppInstalledL(class TUid const &, class TIAUpdateVersion &)
+	?LocalName@CIAUpdateXmlSubParser@@IBEABVTDesC8@@XZ @ 77 NONAME ; class TDesC8 const & CIAUpdateXmlSubParser::LocalName(void) const
+	?DesToVersionL@IAUpdateUtils@@YAXABVTDesC16@@AAC1AAF@Z @ 78 NONAME ; void IAUpdateUtils::DesToVersionL(class TDesC16 const &, signed char &, signed char &, short &)
+	?OnContentL@CIAUpdateXmlSubParser@@UAEXABVTDesC8@@H@Z @ 79 NONAME ; void CIAUpdateXmlSubParser::OnContentL(class TDesC8 const &, int)
+	?ParseL@CIAUpdateXmlParser@@QAEXABVTDesC8@@@Z @ 80 NONAME ; void CIAUpdateXmlParser::ParseL(class TDesC8 const &)
+	?Reset@CIAUpdatePendingNodesFile@@QAEXXZ @ 81 NONAME ; void CIAUpdatePendingNodesFile::Reset(void)
+	??1CIAUpdateControllerFile@@UAE@XZ @ 82 NONAME ; CIAUpdateControllerFile::~CIAUpdateControllerFile(void)
+	?NewL@CIAUpdateRestartInfo@@SAPAV1@XZ @ 83 NONAME ; class CIAUpdateRestartInfo * CIAUpdateRestartInfo::NewL(void)
+	?OnEndDocumentL@CIAUpdateXmlSubParser@@UAEXH@Z @ 84 NONAME ; void CIAUpdateXmlSubParser::OnEndDocumentL(int)
+	?ResultsFile@CIAUpdateRestartInfo@@QAEAAVCIAUpdaterResultsFile@@XZ @ 85 NONAME ; class CIAUpdaterResultsFile & CIAUpdateRestartInfo::ResultsFile(void)
+	??0CIAUpdateXmlParser@@IAE@PAVCIAUpdateXmlSubParser@@@Z @ 86 NONAME ; CIAUpdateXmlParser::CIAUpdateXmlParser(class CIAUpdateXmlSubParser *)
+	?NewL@CIAUpdateNetworkRegistration@@SAPAV1@AAVMIAUpdateNetworkRegistrationObserver@@@Z @ 87 NONAME ; class CIAUpdateNetworkRegistration * CIAUpdateNetworkRegistration::NewL(class MIAUpdateNetworkRegistrationObserver &)
+	?NewL@CIAUpdatePendingNodesFile@@SAPAV1@XZ @ 88 NONAME ; class CIAUpdatePendingNodesFile * CIAUpdatePendingNodesFile::NewL(void)
 
--- a/iaupdate/IAD/engine/controller/inc/iaupdatenodeimpl.h	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/engine/controller/inc/iaupdatenodeimpl.h	Fri May 14 15:58:48 2010 +0300
@@ -137,8 +137,22 @@
      * @see MIAUpdateNode::Depth
      */
     virtual TInt Depth() const;
+    
+    /**
+     * Informs UI that downloading is ongoing
+     **/
+    virtual TBool Downloading() const;
 
     /**
+     * Informs UI that installing is ongoing
+     **/
+    virtual TBool Installing() const;
+    
+    virtual void SetDownloading( TBool aDownloading );
+
+    virtual void SetInstalling( TBool aInstalling );
+        
+    /**
      * @see MIAUpdateNode:::NodeType
      */
     virtual TNodeType NodeType() const;
@@ -323,6 +337,8 @@
     TDependencyCheckStatus              iDependencyCheckStatus;
     TInt                                iLeafDistance;
     TInt                                iDepth;
+    TBool                               iDownloading;
+    TBool                               iInstalling;
 
     // These arrays do not own the nodes.
     RPointerArray< CIAUpdateNode >      iDependants;
--- a/iaupdate/IAD/engine/controller/src/iaupdateinstalloperation.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/engine/controller/src/iaupdateinstalloperation.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2007-2008 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2007-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"
@@ -206,8 +206,8 @@
         // Install interface was available.
         // So, start installing with silent install operation.
         SwiUI::TInstallOptions options(
-            IAUpdateUtils::SilentInstallOptionsL( 
-                Node().Uid(), Node().OwnContentSizeL() ) );
+            IAUpdateUtils::SilentInstallOptionsL( Node() ) );
+        
         operation = install->SilentInstallL( *this, options );
 
         if( !operation )
--- a/iaupdate/IAD/engine/controller/src/iaupdatenodeimpl.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/engine/controller/src/iaupdatenodeimpl.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2007-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"
@@ -365,6 +365,45 @@
     return iDepth;
     }
 
+// ---------------------------------------------------------------------------
+// CIAUpdateNode::Downloading()
+// 
+// ---------------------------------------------------------------------------
+//
+TBool CIAUpdateNode::Downloading() const
+    {
+    return iDownloading;
+    }
+
+// ---------------------------------------------------------------------------
+// CIAUpdateNode::Installing()
+// 
+// ---------------------------------------------------------------------------
+//
+TBool CIAUpdateNode::Installing() const
+    {
+    return iInstalling;
+    }
+ 
+// ---------------------------------------------------------------------------
+// CIAUpdateNode::SetDownloading()
+// 
+// ---------------------------------------------------------------------------
+//
+void CIAUpdateNode::SetDownloading( TBool aDownloading )
+    {
+    iDownloading = aDownloading;
+    }
+
+// ---------------------------------------------------------------------------
+// CIAUpdateNode::SetInstalling()
+// 
+// ---------------------------------------------------------------------------
+//
+void CIAUpdateNode::SetInstalling( TBool aInstalling )
+    {
+    iInstalling = aInstalling;
+    }
 
 // ---------------------------------------------------------------------------
 // CIAUpdateNode::NodeType
--- a/iaupdate/IAD/engine/controller/src/iaupdateutils.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/engine/controller/src/iaupdateutils.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2009 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,7 +22,9 @@
 #include "iaupdateversion.h"
 #include "iaupdatenode.h"
 #include "iaupdatebasenode.h"
+#include "iaupdatebasenodeimpl.h"
 #include "iaupdatefwversionfilehandler.h"
+#include "iaupdateprotocolconsts.h"
 #include "iaupdatedebug.h"
 
 #include <swi/sisregistrysession.h>
@@ -40,10 +42,11 @@
 #include <WidgetRegistryClient.h>
 
 //Constants
-const TInt KSpaceMarginal( 100 * 1024 );
-const TInt KSizeMultiplier( 1 );
 const TText KVersionSeparator( '.' );
 
+_LIT( KExe, ".exe" );
+_LIT( KDll, ".dll" );
+
 
 // -----------------------------------------------------------------------------
 // IAUpdateUtils::DesHexToIntL
@@ -355,28 +358,29 @@
     RFs fs;
     User::LeaveIfError( fs.Connect() );
     CleanupClosePushL( fs );  
+    
+    for ( i = 0; i < aNodes.Count(); ++i )
+        {
+        MIAUpdateNode* node( aNodes[ i ] );
+        MIAUpdateBaseNode& baseNode( node->Base() );
+        if ( baseNode.ContentSizeL() > sizeOfBiggest )
+            {
+            sizeOfBiggest = baseNode.ContentSizeL();
+            }
+        }
+    
     TInt64 freeOnC = FreeDiskSpace( fs, EDriveC );
     TInt64 freeOnE = FreeDiskSpace( fs, EDriveE );
-
-    if ( freeOnC >= freeOnE )
-        {
-        for ( i = 0; i < aNodes.Count(); ++i )
-            {
-            MIAUpdateNode* node( aNodes[ i ] );
-            MIAUpdateBaseNode& baseNode( node->Base() );
-            if ( baseNode.ContentSizeL() > sizeOfBiggest )
-                {
-                sizeOfBiggest = baseNode.ContentSizeL();
-                }
-            }
-        }
-  
 	TDriveUnit driveUnit( EDriveC );
+	if ( freeOnE > freeOnC )
+	    {
+	    driveUnit = EDriveE;
+	    }
 	if ( SysUtil::DiskSpaceBelowCriticalLevelL( &fs, sizeOfBiggest, driveUnit ) ) 
 	    { // no space even for package caching
 		enoughSpaceFound = EFalse;
 	    }
-	else
+/*	else
 	    {
         TInt sizeNeededInDrive = sizeOfBiggest + KSpaceMarginal; //size of the biggest package is included in C drive
         for ( i = 0; i < aNodes.Count() && enoughSpaceFound; ++i )
@@ -384,7 +388,7 @@
             TDriveUnit installedDrive;
             MIAUpdateNode* node( aNodes[ i ] );
             MIAUpdateBaseNode& baseNode( node->Base() );
-            if ( !IAUpdateUtils::InstalledDriveL( baseNode.Uid(), installedDrive ) )
+            if ( !IAUpdateUtils::InstalledDriveL( fs, baseNode.Uid(), installedDrive ) )
                 { //let's assume that already installed package does not need extra space
         	    sizeNeededInDrive += ( baseNode.ContentSizeL() * KSizeMultiplier );       
                 if ( SysUtil::DiskSpaceBelowCriticalLevelL( &fs, sizeNeededInDrive, driveUnit ) )
@@ -416,7 +420,7 @@
                     }
         	    }
             }
-        }
+        }*/
     CleanupStack::PopAndDestroy( &fs );
     return enoughSpaceFound;
     }
@@ -463,9 +467,10 @@
 // 
 // ---------------------------------------------------------------------------
 //
-EXPORT_C SwiUI::TInstallOptions IAUpdateUtils::SilentInstallOptionsL( 
-    const TUid& aUid, TInt aSize )
+SwiUI::TInstallOptions IAUpdateUtils::SilentInstallOptionsL(
+    const CIAUpdateBaseNode& aNode )
     {
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::SilentInstallOptionsL() begin");
     SwiUI::TInstallOptions options;
 
     // Upgrades are allowed        
@@ -500,8 +505,20 @@
     options.iDownload = SwiUI::EPolicyAllowed;
     
     // Where to save.
-    TDriveUnit driveUnit = IAUpdateUtils::DriveToInstallL( aUid, aSize );
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::SilentInstallOptionsL() before DriveToInstallL");
+    TDriveUnit driveUnit;
+    if ( aNode.Mime().Compare( IAUpdateProtocolConsts::KMimeWidget ) == 0 )
+        {
+        driveUnit = IAUpdateUtils::DriveToInstallWidgetL( aNode.Identifier() );
+        }
+    else
+        {
+        driveUnit = IAUpdateUtils::DriveToInstallL( aNode.Uid(), aNode.OwnContentSizeL() );
+        }
+     IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::SilentInstallOptionsL() after DriveToInstallL");
+    
     TDriveName driveName = driveUnit.Name();
+    IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::SilentInstallOptionsL() driveName: %S", &driveName );
     options.iDrive = driveName[0];
     
     // Choose the phone language.
@@ -512,7 +529,7 @@
     
     // Does not affect SISX. This is for Java.
     options.iUpgradeData = SwiUI::EPolicyAllowed;
-
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::SilentInstallOptionsL() end");
     return options;
     }
 
@@ -522,9 +539,10 @@
 // 
 // -----------------------------------------------------------------------------
 // 
-TBool IAUpdateUtils::InstalledDriveL( 
-    const TUid& aUid, TDriveUnit& aLocationDrive )
+TBool IAUpdateUtils::InstalledDriveL(
+    RFs& aFs, const TUid& aUid, TDriveUnit& aLocationDrive )
     {
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::InstalledDriveL() begin");
     TBool installed = EFalse;
 	Swi::RSisRegistrySession registrySession;
 	User::LeaveIfError( registrySession.Connect() );
@@ -541,23 +559,75 @@
         if ( ( !entry.IsInRomL() ) && ( entry.IsPresentL() ) )
             { //only interested in a drive available for installation just now
             installed = ETrue;
-    	    TUint drivesMask = entry.InstalledDrivesL();
+            }
+        
+        if ( !entry.IsInRomL() )
+            {
+            IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::InstalledDriveL() entry not in ROM"); 
+     	    TUint drivesMask = entry.InstalledDrivesL();
             if( drivesMask )
                 {
+                IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::InstalledDriveL() drivesMask exists"); 
                 // Select the highest drive as location drive. That's the case when 
                 // all installation is not in same drive
+                TInt driveCount = 0;
                 TInt drive = EDriveA;
                 while( drivesMask >>= 1 )
                     {
+                    driveCount++; 
                     drive++;
                     }
-                aLocationDrive = drive;
+                IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::InstalledDriveL() driveCount: %d", driveCount );
+                if ( driveCount > 1 )
+                    {
+                    // installation is in multiple drives
+                    // the drive where are binaries (EXEs and DLLs) is chosen
+                    RArray<TInt> drivesWithBinaries; 
+                    CleanupClosePushL( drivesWithBinaries );
+                    DrivesWithBinariesL( entry, drivesWithBinaries ); 
+                    if ( drivesWithBinaries.Count() == 0 )
+                        {
+                        //let's assume the highest drive 
+                        aLocationDrive = drive;
+                        }
+                    else if ( drivesWithBinaries.Count() == 1 )
+                        {
+                        // there are binaries only in one drive, this one is chosen
+                        aLocationDrive = drivesWithBinaries[0];
+                        }
+                    else
+                        {
+                        // there are binaries in multiple drives, C drive is chosen
+                        aLocationDrive = EDriveC;
+                        }
+                    CleanupStack::PopAndDestroy( &drivesWithBinaries );
+                    }
+                else
+                    {
+                    aLocationDrive = drive;
+                    }
                 }
             else
                 {
                 // No installed files, select C: as location drive
                 aLocationDrive = EDriveC;
                 }
+            IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::InstalledDriveL() location drive: %d", aLocationDrive.operator int() );
+            // if the drive chosen is physically removable and it's not available, then install to C drive
+            TUint driveStatus = 0;
+            User::LeaveIfError( DriveInfo::GetDriveStatus( aFs, aLocationDrive, driveStatus ) );
+            if  ( driveStatus & DriveInfo::EDriveRemovable )
+                {
+                IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::InstalledDriveL() removable"); 
+                }
+            if  ( driveStatus & DriveInfo::EDrivePresent )
+                {
+                IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::InstalledDriveL() present"); 
+                }
+            if ( ( driveStatus & DriveInfo::EDriveRemovable ) && ( !(driveStatus & DriveInfo::EDrivePresent) ) )
+                {
+                aLocationDrive = EDriveC;
+                }
             }
         CleanupStack::PopAndDestroy( &entry );
         }
@@ -567,9 +637,46 @@
         }
     
     CleanupStack::PopAndDestroy( &registrySession ); 
+    IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::InstalledDriveL() installed: %d", installed );
+    IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::InstalledDriveL() target drive: %d", aLocationDrive.operator int() );
 	return installed;
     }
 
+// -----------------------------------------------------------------------------
+// IAUpdateUtils::InstalledDriveWidgetL
+// 
+// -----------------------------------------------------------------------------
+// 
+void IAUpdateUtils::InstalledDriveWidgetL( RFs& aFs, 
+                                           RWidgetRegistryClientSession& aWidgetRegistry, 
+                                           const TUid& aUid, 
+                                           TDriveUnit& aLocationDrive )
+    {
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::InstalledDriveWidgetL() begin");
+    TFileName widgetPath;
+    aWidgetRegistry.GetWidgetPath( aUid, widgetPath );
+    aLocationDrive = widgetPath.Mid( 0, 2 );
+    IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::InstalledDriveWidgetL() Drive in registry: %S", &aLocationDrive.Name() );
+    if ( aLocationDrive == EDriveZ )
+        {
+        // if the installation is in ROM, then install to C drive
+        aLocationDrive = EDriveC;
+        IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::InstalledDriveWidgetL() Exists in ROM, install to C:");
+        }
+    else
+        {
+        TUint driveStatus = 0;
+        User::LeaveIfError( DriveInfo::GetDriveStatus( aFs, aLocationDrive, driveStatus ) );
+        // if the installation drive physically removable and it's not available, then install to C drive
+        if ( ( driveStatus & DriveInfo::EDriveRemovable ) && ( !(driveStatus & DriveInfo::EDrivePresent) ) )
+            {
+            aLocationDrive = EDriveC;
+            IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::InstalledDriveWidgetL() Physically removable drive not present, install to C:");
+            }
+        }
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::InstalledDriveWidgetL() begin");
+    }
+
 
 // -----------------------------------------------------------------------------
 // IAUpdateUtils::NextInternalDriveL
@@ -615,9 +722,9 @@
 // 
 // -----------------------------------------------------------------------------
 //   
-TDriveUnit IAUpdateUtils::DriveToInstallL( const TUid& /*aUid*/, TInt /*aSize*/ )
+TDriveUnit IAUpdateUtils::DriveToInstallL( const TUid& aUid, TInt /*aSize*/ )
     {
-    
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::DriveToInstallL() begin");
 	/*TDriveUnit preferredDriveUnit;
 	TDriveUnit targetDriveUnit( EDriveC );
 	//preferred drive is same as a drive of previous installation
@@ -635,12 +742,65 @@
 			targetDriveUnit = preferredDriveUnit;
 		    }
 	    }*/
-	    
-	// installation drive is alvays "C"
+	
+    RFs fs;
+    User::LeaveIfError( fs.Connect() );
+    CleanupClosePushL( fs );  
     TDriveUnit targetDriveUnit( EDriveC );
+    InstalledDriveL( fs, aUid, targetDriveUnit );
+    CleanupStack::PopAndDestroy( &fs );
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::DriveToInstallL() end");
     return targetDriveUnit;
     }
 
+// -----------------------------------------------------------------------------
+// IAUpdateUtils::DriveToInstallWidgetL
+// 
+// -----------------------------------------------------------------------------
+//   
+TDriveUnit IAUpdateUtils::DriveToInstallWidgetL( const TDesC& aIdentifier )
+    {
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::DriveToInstallWidgetL() begin");
+    IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::DriveToInstallWidgetL() identifier: %S", &aIdentifier );
+    TDriveUnit targetDriveUnit( EDriveC );
+    RWidgetRegistryClientSession widgetRegistry;
+
+    User::LeaveIfError( widgetRegistry.Connect() );
+        
+    CleanupClosePushL( widgetRegistry );
+        
+    RPointerArray<CWidgetInfo> widgetInfoArr;
+    CleanupResetAndDestroyPushL( widgetInfoArr );
+    TInt err = widgetRegistry.InstalledWidgetsL(widgetInfoArr); 
+    
+    TBool foundInRegistry( EFalse );
+    for( TInt i( widgetInfoArr.Count() - 1 ); !foundInRegistry && i >= 0; --i ) 
+        {
+        CWidgetInfo* widgetInfo( widgetInfoArr[i] );  
+            
+        CWidgetPropertyValue* BundleId = widgetRegistry.GetWidgetPropertyValueL(widgetInfo->iUid, EBundleIdentifier );
+        CleanupStack::PushL( BundleId );
+            
+        if( aIdentifier.Compare( *(BundleId->iValue.s) )== 0 )
+            {
+            IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::DriveToInstallWidgetL() Found in registry");
+            foundInRegistry = ETrue;
+            RFs fs;
+            User::LeaveIfError( fs.Connect() );
+            CleanupClosePushL( fs );
+            InstalledDriveWidgetL( fs, widgetRegistry, widgetInfo->iUid, targetDriveUnit );
+            CleanupStack::PopAndDestroy( &fs );
+            }
+        CleanupStack::PopAndDestroy( BundleId );
+        }
+        
+    CleanupStack::PopAndDestroy( &widgetInfoArr );
+    CleanupStack::PopAndDestroy( &widgetRegistry);
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::DriveToInstallWidgetL() end");
+    return targetDriveUnit;
+    }
+
+
 
 // -----------------------------------------------------------------------------
 // IAUpdateUtils::BiggestInternalDriveL
@@ -826,6 +986,50 @@
     IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::FreeDiskSpace() end");
     return freeSpace;
     }  
-    
 
-
+// ---------------------------------------------------------------------------
+// IAUpdateUtils::DrivesWithBinariesL
+// ---------------------------------------------------------------------------
+//
+void IAUpdateUtils::DrivesWithBinariesL( Swi::RSisRegistryEntry& aEntry, RArray<TInt>& aDrives )
+    {
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::DrivesWithBinariesL() begin");
+    RPointerArray<HBufC> files; 
+    aEntry.FilesL( files );
+    IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::DrivesWithBinariesL() file count: %d", files.Count() );
+    for( TInt i = 0; i < files.Count(); i++)
+        {
+        TFileName fullName = *files[i]; 
+        IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::DrivesWithBinariesL() fullname: %S", &fullName);
+        TParse parse;
+        parse.Set( fullName, NULL, NULL);    
+        IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::DrivesWithBinariesL() extension: %S", &parse.Ext());
+        if ( parse.Ext().CompareF( KExe() ) == 0  || parse.Ext().CompareF( KDll() ) == 0 )
+            {
+            IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::DrivesWithBinariesL() EXE or DLL found");
+            TDriveUnit driveUnit( parse.Drive() );
+            TInt driveInt = driveUnit;
+            IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::DrivesWithBinariesL() driveInt: %d", driveInt );
+            TBool driveExistInList = EFalse;
+            for( TInt j = 0; !driveExistInList && j < aDrives.Count(); j++)
+                {
+                if ( driveInt == aDrives[j])
+                    {
+                    driveExistInList = ETrue;
+                    }
+                }
+            if ( !driveExistInList )
+                {
+                TInt ret = aDrives.Append(driveInt);
+                if ( ret != KErrNone )
+                    {
+                    files.ResetAndDestroy(); 
+                    User::Leave( ret );
+                    }
+                IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateUtils::DrivesWithBinariesL() drive added to list: %d", driveInt );
+                }
+            }
+        }
+    files.ResetAndDestroy(); 
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateUtils::DrivesWithBinariesL() end");
+    }
--- a/iaupdate/IAD/engine/eabi/iaupdateengineu.def	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/engine/eabi/iaupdateengineu.def	Fri May 14 15:58:48 2010 +0300
@@ -6,7 +6,7 @@
 	_ZN13IAUpdateUtils14AppPackageUidLERK4TUidR16TIAUpdateVersion @ 5 NONAME
 	_ZN13IAUpdateUtils15IsAppInstalledLERK4TUid @ 6 NONAME
 	_ZN13IAUpdateUtils15IsAppInstalledLERK4TUidR16TIAUpdateVersion @ 7 NONAME
-	_ZN13IAUpdateUtils21SilentInstallOptionsLERK4TUidi @ 8 NONAME
+	_ZN13IAUpdateUtils18IsWidgetInstalledLERK7TDesC16R16TIAUpdateVersion @ 8 NONAME
 	_ZN13IAUpdateUtils31SpaceAvailableInInternalDrivesLER13RPointerArrayI13MIAUpdateNodeE @ 9 NONAME
 	_ZN15IAUpdateFactory17CreateControllerLERK4TUidR27MIAUpdateControllerObserver @ 10 NONAME
 	_ZN16TIAUpdateVersion10SetToFloorEv @ 11 NONAME
@@ -101,121 +101,120 @@
 	_ZNK23CIAUpdateControllerFile8LanguageEv @ 100 NONAME
 	_ZNK25CIAUpdatePendingNodesFile5IndexEv @ 101 NONAME
 	_ZNK25CIAUpdatePendingNodesFile8FilePathEv @ 102 NONAME
-	_ZTI13CIAUpdateNode @ 103 NONAME ; #<TI>#
-	_ZTI14CIAUpdateTimer @ 104 NONAME ; #<TI>#
-	_ZTI15CIAUpdateFwNode @ 105 NONAME ; #<TI>#
-	_ZTI15CIAUpdateLoader @ 106 NONAME ; #<TI>#
-	_ZTI16CIAUpdateHistory @ 107 NONAME ; #<TI>#
-	_ZTI17CIAUpdateBaseNode @ 108 NONAME ; #<TI>#
-	_ZTI18CIAUpdateXmlParser @ 109 NONAME ; #<TI>#
-	_ZTI19CIAUpdateController @ 110 NONAME ; #<TI>#
-	_ZTI19CIAUpdateRendezvous @ 111 NONAME ; #<TI>#
-	_ZTI20CIAUpdateHistoryItem @ 112 NONAME ; #<TI>#
-	_ZTI20CIAUpdateNodeDetails @ 113 NONAME ; #<TI>#
-	_ZTI20CIAUpdateRestartInfo @ 114 NONAME ; #<TI>#
-	_ZTI20CIAUpdateSpecialNode @ 115 NONAME ; #<TI>#
-	_ZTI21CIAUpdateCacheCleaner @ 116 NONAME ; #<TI>#
-	_ZTI21CIAUpdateXmlSubParser @ 117 NONAME ; #<TI>#
-	_ZTI22CIAUpdateNodeContainer @ 118 NONAME ; #<TI>#
-	_ZTI23CIAUpdateControllerFile @ 119 NONAME ; #<TI>#
-	_ZTI23CIAUpdateNodeDependency @ 120 NONAME ; #<TI>#
-	_ZTI24CIAUpdateEngineXmlParser @ 121 NONAME ; #<TI>#
-	_ZTI24CIAUpdateSelfUpdaterCtrl @ 122 NONAME ; #<TI>#
-	_ZTI24CIAUpdateServicePackNode @ 123 NONAME ; #<TI>#
-	_ZTI25CIAUpdateContentOperation @ 124 NONAME ; #<TI>#
-	_ZTI25CIAUpdateEngineConfigData @ 125 NONAME ; #<TI>#
-	_ZTI25CIAUpdateInstallOperation @ 126 NONAME ; #<TI>#
-	_ZTI25CIAUpdateNodeUidXmlParser @ 127 NONAME ; #<TI>#
-	_ZTI25CIAUpdatePendingNodesFile @ 128 NONAME ; #<TI>#
-	_ZTI26CIAUpdateDownloadOperation @ 129 NONAME ; #<TI>#
-	_ZTI26CIAUpdateInterDepXmlParser @ 130 NONAME ; #<TI>#
-	_ZTI26CIAUpdatePurchaseOperation @ 131 NONAME ; #<TI>#
-	_ZTI27CIAUpdateEngineXmlSubParser @ 132 NONAME ; #<TI>#
-	_ZTI27CIAUpdatePlatformDependency @ 133 NONAME ; #<TI>#
-	_ZTI28CIAUpdateDependencyXmlParser @ 134 NONAME ; #<TI>#
-	_ZTI28CIAUpdateFwPurchaseOperation @ 135 NONAME ; #<TI>#
-	_ZTI28CIAUpdateNetworkRegistration @ 136 NONAME ; #<TI>#
-	_ZTI29CIAUpdateNodeVersionXmlParser @ 137 NONAME ; #<TI>#
-	_ZTI30CIAUpdateNodeEmbeddedXmlParser @ 138 NONAME ; #<TI>#
-	_ZTI30CIAUpdateVersionBuildXmlParser @ 139 NONAME ; #<TI>#
-	_ZTI30CIAUpdateVersionMajorXmlParser @ 140 NONAME ; #<TI>#
-	_ZTI30CIAUpdateVersionMinorXmlParser @ 141 NONAME ; #<TI>#
-	_ZTI31CIAUpdateDependencyXmlSubParser @ 142 NONAME ; #<TI>#
-	_ZTI31CIAUpdateNormalContentOperation @ 143 NONAME ; #<TI>#
-	_ZTI31CIAUpdateSelfUpdaterInitializer @ 144 NONAME ; #<TI>#
-	_ZTI32CIAUpdateContentOperationManager @ 145 NONAME ; #<TI>#
-	_ZTI32CIAUpdateNodeDependencyXmlParser @ 146 NONAME ; #<TI>#
-	_ZTI32CIAUpdateSelfUpdateInitOperation @ 147 NONAME ; #<TI>#
-	_ZTI33CIAUpdateNodeVersionRoofXmlParser @ 148 NONAME ; #<TI>#
-	_ZTI33CIAUpdatePlatformVersionXmlParser @ 149 NONAME ; #<TI>#
-	_ZTI34CIAUpdateNodeVersionFloorXmlParser @ 150 NONAME ; #<TI>#
-	_ZTI36CIAUpdatePlatformDependencyXmlParser @ 151 NONAME ; #<TI>#
-	_ZTI37CIAUpdatePlatformDescriptionXmlParser @ 152 NONAME ; #<TI>#
-	_ZTI37CIAUpdatePlatformVersionRoofXmlParser @ 153 NONAME ; #<TI>#
-	_ZTI38CIAUpdatePlatformVersionFloorXmlParser @ 154 NONAME ; #<TI>#
-	_ZTV13CIAUpdateNode @ 155 NONAME ; #<VT>#
-	_ZTV14CIAUpdateTimer @ 156 NONAME ; #<VT>#
-	_ZTV15CIAUpdateFwNode @ 157 NONAME ; #<VT>#
-	_ZTV15CIAUpdateLoader @ 158 NONAME ; #<VT>#
-	_ZTV16CIAUpdateHistory @ 159 NONAME ; #<VT>#
-	_ZTV17CIAUpdateBaseNode @ 160 NONAME ; #<VT>#
-	_ZTV18CIAUpdateXmlParser @ 161 NONAME ; #<VT>#
-	_ZTV19CIAUpdateController @ 162 NONAME ; #<VT>#
-	_ZTV19CIAUpdateRendezvous @ 163 NONAME ; #<VT>#
-	_ZTV20CIAUpdateHistoryItem @ 164 NONAME ; #<VT>#
-	_ZTV20CIAUpdateNodeDetails @ 165 NONAME ; #<VT>#
-	_ZTV20CIAUpdateRestartInfo @ 166 NONAME ; #<VT>#
-	_ZTV20CIAUpdateSpecialNode @ 167 NONAME ; #<VT>#
-	_ZTV21CIAUpdateCacheCleaner @ 168 NONAME ; #<VT>#
-	_ZTV21CIAUpdateXmlSubParser @ 169 NONAME ; #<VT>#
-	_ZTV22CIAUpdateNodeContainer @ 170 NONAME ; #<VT>#
-	_ZTV23CIAUpdateControllerFile @ 171 NONAME ; #<VT>#
-	_ZTV23CIAUpdateNodeDependency @ 172 NONAME ; #<VT>#
-	_ZTV24CIAUpdateEngineXmlParser @ 173 NONAME ; #<VT>#
-	_ZTV24CIAUpdateSelfUpdaterCtrl @ 174 NONAME ; #<VT>#
-	_ZTV24CIAUpdateServicePackNode @ 175 NONAME ; #<VT>#
-	_ZTV25CIAUpdateContentOperation @ 176 NONAME ; #<VT>#
-	_ZTV25CIAUpdateEngineConfigData @ 177 NONAME ; #<VT>#
-	_ZTV25CIAUpdateInstallOperation @ 178 NONAME ; #<VT>#
-	_ZTV25CIAUpdateNodeUidXmlParser @ 179 NONAME ; #<VT>#
-	_ZTV25CIAUpdatePendingNodesFile @ 180 NONAME ; #<VT>#
-	_ZTV26CIAUpdateDownloadOperation @ 181 NONAME ; #<VT>#
-	_ZTV26CIAUpdateInterDepXmlParser @ 182 NONAME ; #<VT>#
-	_ZTV26CIAUpdatePurchaseOperation @ 183 NONAME ; #<VT>#
-	_ZTV27CIAUpdateEngineXmlSubParser @ 184 NONAME ; #<VT>#
-	_ZTV27CIAUpdatePlatformDependency @ 185 NONAME ; #<VT>#
-	_ZTV28CIAUpdateDependencyXmlParser @ 186 NONAME ; #<VT>#
-	_ZTV28CIAUpdateFwPurchaseOperation @ 187 NONAME ; #<VT>#
-	_ZTV28CIAUpdateNetworkRegistration @ 188 NONAME ; #<VT>#
-	_ZTV29CIAUpdateNodeVersionXmlParser @ 189 NONAME ; #<VT>#
-	_ZTV30CIAUpdateNodeEmbeddedXmlParser @ 190 NONAME ; #<VT>#
-	_ZTV30CIAUpdateVersionBuildXmlParser @ 191 NONAME ; #<VT>#
-	_ZTV30CIAUpdateVersionMajorXmlParser @ 192 NONAME ; #<VT>#
-	_ZTV30CIAUpdateVersionMinorXmlParser @ 193 NONAME ; #<VT>#
-	_ZTV31CIAUpdateDependencyXmlSubParser @ 194 NONAME ; #<VT>#
-	_ZTV31CIAUpdateNormalContentOperation @ 195 NONAME ; #<VT>#
-	_ZTV31CIAUpdateSelfUpdaterInitializer @ 196 NONAME ; #<VT>#
-	_ZTV32CIAUpdateContentOperationManager @ 197 NONAME ; #<VT>#
-	_ZTV32CIAUpdateNodeDependencyXmlParser @ 198 NONAME ; #<VT>#
-	_ZTV32CIAUpdateSelfUpdateInitOperation @ 199 NONAME ; #<VT>#
-	_ZTV33CIAUpdateNodeVersionRoofXmlParser @ 200 NONAME ; #<VT>#
-	_ZTV33CIAUpdatePlatformVersionXmlParser @ 201 NONAME ; #<VT>#
-	_ZTV34CIAUpdateNodeVersionFloorXmlParser @ 202 NONAME ; #<VT>#
-	_ZTV36CIAUpdatePlatformDependencyXmlParser @ 203 NONAME ; #<VT>#
-	_ZTV37CIAUpdatePlatformDescriptionXmlParser @ 204 NONAME ; #<VT>#
-	_ZTV37CIAUpdatePlatformVersionRoofXmlParser @ 205 NONAME ; #<VT>#
-	_ZTV38CIAUpdatePlatformVersionFloorXmlParser @ 206 NONAME ; #<VT>#
-	_ZThn4_N21CIAUpdateXmlSubParser10OnContentLERK6TDesC8i @ 207 NONAME ; #<thunk>#
-	_ZThn4_N21CIAUpdateXmlSubParser13OnEndElementLERKN3Xml8RTagInfoEi @ 208 NONAME ; #<thunk>#
-	_ZThn4_N21CIAUpdateXmlSubParser14OnEndDocumentLEi @ 209 NONAME ; #<thunk>#
-	_ZThn4_N21CIAUpdateXmlSubParser15OnStartElementLERKN3Xml8RTagInfoERK6RArrayINS0_10RAttributeEEi @ 210 NONAME ; #<thunk>#
-	_ZThn4_N21CIAUpdateXmlSubParser16OnSkippedEntityLERK7RStringi @ 211 NONAME ; #<thunk>#
-	_ZThn4_N21CIAUpdateXmlSubParser16OnStartDocumentLERKN3Xml19RDocumentParametersEi @ 212 NONAME ; #<thunk>#
-	_ZThn4_N21CIAUpdateXmlSubParser19OnEndPrefixMappingLERK7RStringi @ 213 NONAME ; #<thunk>#
-	_ZThn4_N21CIAUpdateXmlSubParser20GetExtendedInterfaceEl @ 214 NONAME ; #<thunk>#
-	_ZThn4_N21CIAUpdateXmlSubParser21OnStartPrefixMappingLERK7RStringS2_i @ 215 NONAME ; #<thunk>#
-	_ZThn4_N21CIAUpdateXmlSubParser22OnIgnorableWhiteSpaceLERK6TDesC8i @ 216 NONAME ; #<thunk>#
-	_ZThn4_N21CIAUpdateXmlSubParser24OnProcessingInstructionLERK6TDesC8S2_i @ 217 NONAME ; #<thunk>#
-	_ZThn4_N21CIAUpdateXmlSubParser7OnErrorEi @ 218 NONAME ; #<thunk>#
-	_ZN13IAUpdateUtils18IsWidgetInstalledLERK7TDesC16R16TIAUpdateVersion @ 219 NONAME
+	_ZTI13CIAUpdateNode @ 103 NONAME
+	_ZTI14CIAUpdateTimer @ 104 NONAME
+	_ZTI15CIAUpdateFwNode @ 105 NONAME
+	_ZTI15CIAUpdateLoader @ 106 NONAME
+	_ZTI16CIAUpdateHistory @ 107 NONAME
+	_ZTI17CIAUpdateBaseNode @ 108 NONAME
+	_ZTI18CIAUpdateXmlParser @ 109 NONAME
+	_ZTI19CIAUpdateController @ 110 NONAME
+	_ZTI19CIAUpdateRendezvous @ 111 NONAME
+	_ZTI20CIAUpdateHistoryItem @ 112 NONAME
+	_ZTI20CIAUpdateNodeDetails @ 113 NONAME
+	_ZTI20CIAUpdateRestartInfo @ 114 NONAME
+	_ZTI20CIAUpdateSpecialNode @ 115 NONAME
+	_ZTI21CIAUpdateCacheCleaner @ 116 NONAME
+	_ZTI21CIAUpdateXmlSubParser @ 117 NONAME
+	_ZTI22CIAUpdateNodeContainer @ 118 NONAME
+	_ZTI23CIAUpdateControllerFile @ 119 NONAME
+	_ZTI23CIAUpdateNodeDependency @ 120 NONAME
+	_ZTI24CIAUpdateEngineXmlParser @ 121 NONAME
+	_ZTI24CIAUpdateSelfUpdaterCtrl @ 122 NONAME
+	_ZTI24CIAUpdateServicePackNode @ 123 NONAME
+	_ZTI25CIAUpdateContentOperation @ 124 NONAME
+	_ZTI25CIAUpdateEngineConfigData @ 125 NONAME
+	_ZTI25CIAUpdateInstallOperation @ 126 NONAME
+	_ZTI25CIAUpdateNodeUidXmlParser @ 127 NONAME
+	_ZTI25CIAUpdatePendingNodesFile @ 128 NONAME
+	_ZTI26CIAUpdateDownloadOperation @ 129 NONAME
+	_ZTI26CIAUpdateInterDepXmlParser @ 130 NONAME
+	_ZTI26CIAUpdatePurchaseOperation @ 131 NONAME
+	_ZTI27CIAUpdateEngineXmlSubParser @ 132 NONAME
+	_ZTI27CIAUpdatePlatformDependency @ 133 NONAME
+	_ZTI28CIAUpdateDependencyXmlParser @ 134 NONAME
+	_ZTI28CIAUpdateFwPurchaseOperation @ 135 NONAME
+	_ZTI28CIAUpdateNetworkRegistration @ 136 NONAME
+	_ZTI29CIAUpdateNodeVersionXmlParser @ 137 NONAME
+	_ZTI30CIAUpdateNodeEmbeddedXmlParser @ 138 NONAME
+	_ZTI30CIAUpdateVersionBuildXmlParser @ 139 NONAME
+	_ZTI30CIAUpdateVersionMajorXmlParser @ 140 NONAME
+	_ZTI30CIAUpdateVersionMinorXmlParser @ 141 NONAME
+	_ZTI31CIAUpdateDependencyXmlSubParser @ 142 NONAME
+	_ZTI31CIAUpdateNormalContentOperation @ 143 NONAME
+	_ZTI31CIAUpdateSelfUpdaterInitializer @ 144 NONAME
+	_ZTI32CIAUpdateContentOperationManager @ 145 NONAME
+	_ZTI32CIAUpdateNodeDependencyXmlParser @ 146 NONAME
+	_ZTI32CIAUpdateSelfUpdateInitOperation @ 147 NONAME
+	_ZTI33CIAUpdateNodeVersionRoofXmlParser @ 148 NONAME
+	_ZTI33CIAUpdatePlatformVersionXmlParser @ 149 NONAME
+	_ZTI34CIAUpdateNodeVersionFloorXmlParser @ 150 NONAME
+	_ZTI36CIAUpdatePlatformDependencyXmlParser @ 151 NONAME
+	_ZTI37CIAUpdatePlatformDescriptionXmlParser @ 152 NONAME
+	_ZTI37CIAUpdatePlatformVersionRoofXmlParser @ 153 NONAME
+	_ZTI38CIAUpdatePlatformVersionFloorXmlParser @ 154 NONAME
+	_ZTV13CIAUpdateNode @ 155 NONAME
+	_ZTV14CIAUpdateTimer @ 156 NONAME
+	_ZTV15CIAUpdateFwNode @ 157 NONAME
+	_ZTV15CIAUpdateLoader @ 158 NONAME
+	_ZTV16CIAUpdateHistory @ 159 NONAME
+	_ZTV17CIAUpdateBaseNode @ 160 NONAME
+	_ZTV18CIAUpdateXmlParser @ 161 NONAME
+	_ZTV19CIAUpdateController @ 162 NONAME
+	_ZTV19CIAUpdateRendezvous @ 163 NONAME
+	_ZTV20CIAUpdateHistoryItem @ 164 NONAME
+	_ZTV20CIAUpdateNodeDetails @ 165 NONAME
+	_ZTV20CIAUpdateRestartInfo @ 166 NONAME
+	_ZTV20CIAUpdateSpecialNode @ 167 NONAME
+	_ZTV21CIAUpdateCacheCleaner @ 168 NONAME
+	_ZTV21CIAUpdateXmlSubParser @ 169 NONAME
+	_ZTV22CIAUpdateNodeContainer @ 170 NONAME
+	_ZTV23CIAUpdateControllerFile @ 171 NONAME
+	_ZTV23CIAUpdateNodeDependency @ 172 NONAME
+	_ZTV24CIAUpdateEngineXmlParser @ 173 NONAME
+	_ZTV24CIAUpdateSelfUpdaterCtrl @ 174 NONAME
+	_ZTV24CIAUpdateServicePackNode @ 175 NONAME
+	_ZTV25CIAUpdateContentOperation @ 176 NONAME
+	_ZTV25CIAUpdateEngineConfigData @ 177 NONAME
+	_ZTV25CIAUpdateInstallOperation @ 178 NONAME
+	_ZTV25CIAUpdateNodeUidXmlParser @ 179 NONAME
+	_ZTV25CIAUpdatePendingNodesFile @ 180 NONAME
+	_ZTV26CIAUpdateDownloadOperation @ 181 NONAME
+	_ZTV26CIAUpdateInterDepXmlParser @ 182 NONAME
+	_ZTV26CIAUpdatePurchaseOperation @ 183 NONAME
+	_ZTV27CIAUpdateEngineXmlSubParser @ 184 NONAME
+	_ZTV27CIAUpdatePlatformDependency @ 185 NONAME
+	_ZTV28CIAUpdateDependencyXmlParser @ 186 NONAME
+	_ZTV28CIAUpdateFwPurchaseOperation @ 187 NONAME
+	_ZTV28CIAUpdateNetworkRegistration @ 188 NONAME
+	_ZTV29CIAUpdateNodeVersionXmlParser @ 189 NONAME
+	_ZTV30CIAUpdateNodeEmbeddedXmlParser @ 190 NONAME
+	_ZTV30CIAUpdateVersionBuildXmlParser @ 191 NONAME
+	_ZTV30CIAUpdateVersionMajorXmlParser @ 192 NONAME
+	_ZTV30CIAUpdateVersionMinorXmlParser @ 193 NONAME
+	_ZTV31CIAUpdateDependencyXmlSubParser @ 194 NONAME
+	_ZTV31CIAUpdateNormalContentOperation @ 195 NONAME
+	_ZTV31CIAUpdateSelfUpdaterInitializer @ 196 NONAME
+	_ZTV32CIAUpdateContentOperationManager @ 197 NONAME
+	_ZTV32CIAUpdateNodeDependencyXmlParser @ 198 NONAME
+	_ZTV32CIAUpdateSelfUpdateInitOperation @ 199 NONAME
+	_ZTV33CIAUpdateNodeVersionRoofXmlParser @ 200 NONAME
+	_ZTV33CIAUpdatePlatformVersionXmlParser @ 201 NONAME
+	_ZTV34CIAUpdateNodeVersionFloorXmlParser @ 202 NONAME
+	_ZTV36CIAUpdatePlatformDependencyXmlParser @ 203 NONAME
+	_ZTV37CIAUpdatePlatformDescriptionXmlParser @ 204 NONAME
+	_ZTV37CIAUpdatePlatformVersionRoofXmlParser @ 205 NONAME
+	_ZTV38CIAUpdatePlatformVersionFloorXmlParser @ 206 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser10OnContentLERK6TDesC8i @ 207 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser13OnEndElementLERKN3Xml8RTagInfoEi @ 208 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser14OnEndDocumentLEi @ 209 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser15OnStartElementLERKN3Xml8RTagInfoERK6RArrayINS0_10RAttributeEEi @ 210 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser16OnSkippedEntityLERK7RStringi @ 211 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser16OnStartDocumentLERKN3Xml19RDocumentParametersEi @ 212 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser19OnEndPrefixMappingLERK7RStringi @ 213 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser20GetExtendedInterfaceEl @ 214 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser21OnStartPrefixMappingLERK7RStringS2_i @ 215 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser22OnIgnorableWhiteSpaceLERK6TDesC8i @ 216 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser24OnProcessingInstructionLERK6TDesC8S2_i @ 217 NONAME
+	_ZThn4_N21CIAUpdateXmlSubParser7OnErrorEi @ 218 NONAME
 
--- a/iaupdate/IAD/engine/inc/iaupdatenode.h	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/engine/inc/iaupdatenode.h	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2007-2008 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2007-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"
@@ -169,6 +169,20 @@
      */
     virtual TInt Depth() const = 0;
 
+    /**
+     * Informs UI that downloading is ongoing
+     **/
+    virtual TBool Downloading() const = 0;
+
+    /**
+    * Informs UI that installing is ongoing
+    **/
+    virtual TBool Installing() const = 0;
+    
+    virtual void SetDownloading( TBool aDownloading ) = 0;
+
+    virtual void SetInstalling( TBool aInstalling ) = 0;
+    
 
 protected:
 
--- a/iaupdate/IAD/engine/inc/iaupdateutils.h	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/engine/inc/iaupdateutils.h	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2009 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"
@@ -25,9 +25,12 @@
 
 // For silent installation
 #include <SWInstDefs.h>
+#include <swi/sisregistryentry.h>
 
 class TIAUpdateVersion;
 class MIAUpdateNode;
+class CIAUpdateBaseNode;
+class RWidgetRegistryClientSession;
 
 namespace IAUpdateUtils
 {
@@ -120,11 +123,10 @@
  * Creates options for silent install.
  * Uses DriveToInstallL to etermine target drive to install.
  * 
- * @param aUid PUID of the application
- * @param aSize Estimated size of installation
+ * @param aNode
  */
-IMPORT_C SwiUI::TInstallOptions SilentInstallOptionsL( const TUid& aUid,
-                                                       TInt aSize );
+SwiUI::TInstallOptions SilentInstallOptionsL( const CIAUpdateBaseNode& aNode );
+                                                     
 
 
 
@@ -134,7 +136,12 @@
  * @param aLocationDrive Drive where a package is currently installed
  * @return ETrue if a package previously installed to an available drive
  **/
-TBool InstalledDriveL( const TUid& aUid, TDriveUnit& aLocationDrive );
+TBool InstalledDriveL( RFs& aFs, const TUid& aUid, TDriveUnit& aLocationDrive );
+
+void InstalledDriveWidgetL( RFs& aFs, 
+                            RWidgetRegistryClientSession& aWidgetRegistry, 
+                            const TUid& aUid, 
+                            TDriveUnit& aLocationDrive );
 
 TBool NextInternalDriveL( RFs& aFs, 
                           TDriveUnit aCurrentDrive, 
@@ -149,6 +156,8 @@
  **/
 TDriveUnit DriveToInstallL( const TUid& aUid, TInt aSize );
 
+TDriveUnit DriveToInstallWidgetL( const TDesC& aIdentifier );
+
 TDriveUnit BiggestInternalDriveL();
 
 TBool InternalDriveWithSpaceL( TInt aSize, 
@@ -161,6 +170,8 @@
 
 TInt64 FreeDiskSpace( RFs& aFs, TInt aDriveNumber );
 
+void DrivesWithBinariesL( Swi::RSisRegistryEntry& aEntry, RArray<TInt>& aDrives );
+
 }
 
 
--- a/iaupdate/IAD/ui/iaupdate.pro	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/iaupdate.pro	Fri May 14 15:58:48 2010 +0300
@@ -66,7 +66,8 @@
     iaupdateserviceprovider.cpp \
     iaupdatewaitdialog.cpp \
     iaupdatenodeid.cpp \
-    iaupdatetools.cpp
+    iaupdatetools.cpp \
+    iaupdateresultsdialog.cpp
     
 
 HEADERS = iaupdateapplication.h \
@@ -105,7 +106,8 @@
     iaupdateuitimer.h \
     iaupdateserviceprovider.h \
     iaupdatenodeid.h \
-    iaupdatetools.h
+    iaupdatetools.h \
+    iaupdateresultsdialog.h 
 
 
 LIBS += -lbafl
@@ -128,6 +130,7 @@
 LIBS += -lws32
 LIBS += -lapparc
 LIBS += -lapgrfx
+LIBS += -lstarterclient
 
 
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/iaupdate/IAD/ui/iaupdate_mainview.docml	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,33 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<hbdocument version="0.4">
+    <object name="action" type="HbAction">
+        <string name="text" value="Start update"/>
+    </object>
+    <object name="action_1" type="HbAction">
+        <string name="text" value="Settings"/>
+    </object>
+    <object name="action_2" type="HbAction">
+        <string name="text" value="Disclaimer"/>
+    </object>
+    <widget name="view" type="HbView">
+        <widget name="content" role="HbView:widget" type="HbWidget">
+            <widget name="listWidget" type="HbListWidget">
+                <sizehint height="16.41791091514448un" type="PREFERRED" width="38.80597125397785un"/>
+            </widget>
+            <zvalue value="0.0"/>
+            <layout type="grid">
+                <griditem column="0" itemname="listWidget" row="0"/>
+            </layout>
+        </widget>
+        <widget name="viewMenu" role="HbView:menu" type="HbMenu">
+            <ref object="action" role="HbMenu:addAction"/>
+            <ref object="action_1" role="HbMenu:addAction"/>
+            <ref object="action_2" role="HbMenu:addAction"/>
+        </widget>
+        <widget name="viewToolbar" role="HbView:toolBar" type="HbToolBar">
+            <ref object="action" role="HbToolBar:addAction"/>
+        </widget>
+        <string name="title" value="Software update"/>
+    </widget>
+    <metadata display="QHD portrait" unit="un"/>
+</hbdocument>
--- a/iaupdate/IAD/ui/inc/iaupdateagreement.h	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/inc/iaupdateagreement.h	Fri May 14 15:58:48 2010 +0300
@@ -74,6 +74,8 @@
     * @return True value if agreement accepted 
     */
     TBool AgreementAcceptedL();
+    
+    void SetAgreementAcceptedL();
 
 private:
 
--- a/iaupdate/IAD/ui/inc/iaupdateapplication.h	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/inc/iaupdateapplication.h	Fri May 14 15:58:48 2010 +0300
@@ -33,7 +33,7 @@
     virtual ~IAUpdateApplication();
     
 private:
-    QSharedPointer<IAUpdateEngine> mEngine;         // owned
+    IAUpdateEngine *mEngine;         // owned
     QSharedPointer<IAUpdateMainWindow> mMainWindow; // owned
     };
 
--- a/iaupdate/IAD/ui/inc/iaupdateengine.h	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/inc/iaupdateengine.h	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2009 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"
@@ -27,6 +27,7 @@
 
 class IAUpdateServiceProvider;
 class CIAUpdateUiController;
+class CIAUpdateFWUpdateHandler;
 class CIAUpdateParameters;
 class CIAUpdateGlobalLockHandler;
 class MIAUpdateNode;
@@ -42,7 +43,7 @@
 
 public:
     IAUpdateEngine(QObject *parent = 0);
-    virtual ~IAUpdateEngine();
+    ~IAUpdateEngine();
     
     void StartedByLauncherL( TBool aRefreshFromNetworkDenied );
      
@@ -54,7 +55,9 @@
       * @param aFilterParams These parameters are used when update items
       * are filtered for the UI list.
       */
-     void CheckUpdatesRequestL( int wgid, CIAUpdateParameters* aFilterParams );
+     void CheckUpdatesRequestL( int wgid, 
+                                CIAUpdateParameters* aFilterParams, 
+                                TBool aForcedRefresh );
 
      /**
       * When the show update operation is started through
@@ -76,7 +79,9 @@
       * @param aUid  Uid of the caller of the request
       */
      void ShowUpdateQueryRequestL( int wgid, TUint aUid );
-          
+     
+     
+     void StartUpdate( TBool aFirmwareUpdate );
      /**
       * Set this application visible/unvisible
       * @param aVisible If EFalse application is put background and is hidden in FSW 
@@ -91,7 +96,7 @@
       void SetClientWgId( TInt aWgId );
           
       /**
-      * Is client application in backround
+      * Is client application in background
       *
       * @param True value if client application is in background
       */
@@ -160,6 +165,17 @@
 private:  //new methods
 
     /**
+    * Show results dialog of update
+    */ 
+    void ShowResultsDialogL();
+        
+    /**
+    * Starts CIdle. Results dialog is shown in callback function. 
+    */ 
+    void ShowResultsDialogDeferredL();
+    
+    
+    /**
     * Informs an observer that its async request is completed 
     *
     * @param aError  Error code 
@@ -210,6 +226,16 @@
      void HideApplicationInFSWL( TBool aHide ) const;
      
      /**
+     * CIdle callback function, that shows status dialog
+     * To be used to guarantee that possible old status dialog is totally 
+     * removed by AVKON before showing new one  
+     *
+     * @param aPtr  Pointer to this instance
+     */ 
+     static TInt ShowResultsDialogCallbackL( TAny* aPtr );
+     
+     
+     /**
      * CIdle callback function, that shows update query dialog
      * To be used because a client to be informed immediately that its 
      * async request is issued. Waiting dialog cannot be shown before responding to a client  
@@ -217,6 +243,13 @@
      * @param aPtr  Pointer to this instance
      */
      static TInt UpdateQueryCallbackL( TAny* aPtr );
+     
+     /**
+     * CIdle callback function, that performs automatic update check and query
+     *
+     * @param aPtr  Pointer to this instance
+     */
+     static TInt AutomaticCheckCallbackL( TAny* aPtr );
          
      
     
@@ -226,15 +259,18 @@
     
 private:
     CIAUpdateUiController* iController;
+    CIAUpdateFWUpdateHandler* iFwUpdateHandler;
     CIAUpdateGlobalLockHandler* iGlobalLockHandler;
     CEikonEnv* iEikEnv; //not owned
     CIdle* iIdle;
+    CIdle* iIdleAutCheck;
     
     IAUpdateUiDefines::TIAUpdateUiRequestType iRequestType;
     TBool iUpdateNow;
     RArray<TUint32> iDestIdArray;
     TBool iRequestIssued;
     TBool iStartedFromApplication;
+    TBool iUiRefreshAllowed;
     TUint iUpdatequeryUid;
     TInt iWgId;
   
--- a/iaupdate/IAD/ui/inc/iaupdatemainview.h	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/inc/iaupdatemainview.h	Fri May 14 15:58:48 2010 +0300
@@ -28,7 +28,7 @@
 
 
 class HbListWidget;
-//class HbListView;
+class IAUpdateEngine;
 
 
 class IAUpdateMainView : public HbView
@@ -36,12 +36,12 @@
     Q_OBJECT 
     
 public:
-    IAUpdateMainView();
+    IAUpdateMainView(IAUpdateEngine *engine);
     virtual ~IAUpdateMainView();
         
-    void refresh( const RPointerArray<MIAUpdateNode>& nodes,
-                      const RPointerArray<MIAUpdateFwNode>& fwNodes,
-                      int error );
+    void refresh(const RPointerArray<MIAUpdateNode> &nodes,
+                 const RPointerArray<MIAUpdateFwNode> &fwNodes,
+                 int error);
 public slots:
     void handleStartUpdate();
  
@@ -53,10 +53,15 @@
     
 private:
     
-
+    void getSelectedNodes(RPointerArray<MIAUpdateAnyNode> &selectedNodes) const;
+    void markListItem(bool mark, int index);
+    bool getMandatoryNodes(RPointerArray<MIAUpdateAnyNode> &mandNodes) const;
+    void showUpdateCannotOmitDialog() const; 
+    bool showDependenciesFoundDialog(QString &text) const;
+    void updateSelectionsToList();
     
 private:
-    //HbListView *mListView;
+    IAUpdateEngine *mEngine;
     HbListWidget *mListView;
     RPointerArray<MIAUpdateAnyNode> mAllNodes;
 
--- a/iaupdate/IAD/ui/inc/iaupdatemainwindow.h	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/inc/iaupdatemainwindow.h	Fri May 14 15:58:48 2010 +0300
@@ -28,14 +28,14 @@
 class HbDocumentLoader;
 class MIAUpdateNode;
 class MIAUpdateFwNode;
-class IAUpdateServiceProvider;  //temp
+class IAUpdateEngine;  
 
 class IAUpdateMainWindow : public HbMainWindow
     {
     Q_OBJECT
     
 public:
-    IAUpdateMainWindow();
+    IAUpdateMainWindow(IAUpdateEngine *engine);
     virtual ~IAUpdateMainWindow();
 
 public slots:
@@ -46,7 +46,7 @@
     void toHistoryView();
 
 private:
-    void addMainView();
+    void addMainView(IAUpdateEngine *engine);
     void addHistoryView();
     
 private:
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/iaupdate/IAD/ui/inc/iaupdateresultsdialog.h	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,44 @@
+/*
+* 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:   Header file of IAUpdateResultsDialog
+*
+*/
+
+
+
+#ifndef IAUPDATERESULTSDIALOG_H
+#define IAUPDATERESULTSDIALOG_H
+
+
+//  INCLUDES
+#include <QObject>
+
+class TIAUpdateResultsInfo;
+
+class IAUpdateResultsDialog : public QObject
+{
+public:
+
+    IAUpdateResultsDialog(QObject *parent = 0);
+    ~IAUpdateResultsDialog();
+    
+    void showResults(const TIAUpdateResultsInfo &param);
+   
+private:
+
+    void constructText(const TIAUpdateResultsInfo &param, QString &buf);
+};
+#endif      // IAUPDATERESULTSDIALOG_H
+            
+// End of File
--- a/iaupdate/IAD/ui/inc/iaupdateuicontroller.h	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/inc/iaupdateuicontroller.h	Fri May 14 15:58:48 2010 +0300
@@ -234,7 +234,10 @@
     * Ownership is not transferred.
     */
     CIAUpdateParameters* ParamsReadAndRemoveFileL();
-        
+    
+    TBool ForcedRefresh() const;
+      
+    void SetForcedRefresh( TBool aForcedRefresh );
     /**
      * Is client role "testing"
      *
@@ -598,6 +601,8 @@
     TBool iRefreshFromNetworkDenied; 
     
     TBool iOffConfigurated;
+    
+    TBool iForcedRefresh;
         
     TBool iTestRole;
 
--- a/iaupdate/IAD/ui/src/iaupdateagreement.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/src/iaupdateagreement.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2008-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"
@@ -19,7 +19,7 @@
 
 //INCLUDES
 #include <hbaction.h>
-#include <hbmessagebox.h>
+#include <hbdialog.h>
 #include <hbtextitem.h>
 #include <centralrepository.h>
 
@@ -125,6 +125,22 @@
     }
 
 // ---------------------------------------------------------------------------
+// CIAUpdateAgreement::SetAgreementAcceptedL
+// 
+// ---------------------------------------------------------------------------
+//
+void CIAUpdateAgreement::SetAgreementAcceptedL()
+    {
+    CIAUpdateFirstTimeInfo* firstTimeInfo = CIAUpdateFirstTimeInfo::NewLC();
+    firstTimeInfo->SetAgreementAcceptedL();
+    CleanupStack::PopAndDestroy( firstTimeInfo );
+    }
+
+
+
+
+
+// ---------------------------------------------------------------------------
 // CIAUpdateAgreement::ShowAgreementL
 // 
 // ---------------------------------------------------------------------------
@@ -175,8 +191,9 @@
         agreementDialog.setSecondaryAction(secondaryAction);
         }
     agreementDialog.setTimeout(HbPopup::NoTimeout);
-    
-    return agreementDialog.exec(); 
+    agreementDialog.show();
+    //return agreementDialog.exec(); 
+    return primaryAction;
     }        
     
     /*HBufC* text_1 = StringLoader::LoadLC( R_IAUPDATE_AGREEMENT_DIALOG_TEXT_1 );
--- a/iaupdate/IAD/ui/src/iaupdateapplication.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/src/iaupdateapplication.cpp	Fri May 14 15:58:48 2010 +0300
@@ -23,7 +23,7 @@
 IAUpdateApplication::IAUpdateApplication(  int argc, char* argv[] ) :
     HbApplication( argc, argv ),
     mEngine (new IAUpdateEngine),
-    mMainWindow (new IAUpdateMainWindow())
+    mMainWindow (new IAUpdateMainWindow(mEngine))
     {
     
     // Connect view change signals to the view change slots
--- a/iaupdate/IAD/ui/src/iaupdateautomaticcheck.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/src/iaupdateautomaticcheck.cpp	Fri May 14 15:58:48 2010 +0300
@@ -25,10 +25,10 @@
 #include "iaupdate.hrh"
 #include "iaupdateprivatecrkeys.h"
 
-
-
-#include <avkon.hrh>
+//#include <avkon.hrh>
 #include <centralrepository.h> 
+#include <hbmessagebox.h>
+#include <hbaction.h>
 
 
 // ---------------------------------------------------------------------------
@@ -102,15 +102,20 @@
 	        }
 	    else
 	        {
-	        /*TInt ret = IAUpdateDialogUtil::ShowConfirmationQueryL( 
-	                                          R_IAUPDATE_TURN_ON_AUTOUPD_CHECKS, 
-	                                          R_AVKON_SOFTKEYS_YES_NO );*/ 
-	        TInt ret = EAknSoftkeyYes;
+	        HbMessageBox messageBox(HbMessageBox::MessageTypeQuestion); 
+	        messageBox.setText(QString("Turn on setting for Automatic update checks?"));
+	        HbAction yesAction("Yes");
+	        HbAction noAction("No");
+	        messageBox.setPrimaryAction(&yesAction);
+	        messageBox.setSecondaryAction(&noAction);
+	        messageBox.setTimeout(HbPopup::NoTimeout);
+	        messageBox.show();
+	        //HbAction *selectedAction = messageBox.exec();
 	        firstTimeInfo->SetAutomaticUpdatesAskedL();
-	        if ( ret == EAknSoftkeyYes )
-                {
-	            EnableAutoUpdateCheckL( ETrue );
-	            }
+	        //if ( selectedAction == messageBox.primaryAction() )
+	        //    {
+                //EnableAutoUpdateCheckL( ETrue ); // TEMP
+            //    }
 	        }
 	    }
 	CleanupStack::PopAndDestroy( firstTimeInfo ); 
--- a/iaupdate/IAD/ui/src/iaupdateengine.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/src/iaupdateengine.cpp	Fri May 14 15:58:48 2010 +0300
@@ -25,10 +25,12 @@
 #include <cmdestinationext.h>
 #include <rconnmon.h>
 #include <apgwgnam.h>
+#include <starterclient.h>
 
 #include "iaupdateengine.h"
 #include "iaupdateserviceprovider.h"
 #include "iaupdateuicontroller.h"
+#include "iaupdatefwupdatehandler.h"
 #include "iaupdategloballockhandler.h"
 #include "iaupdatenodefilter.h"
 #include "iaupdateresult.h"
@@ -36,24 +38,32 @@
 #include "iaupdateuiconfigdata.h"
 #include "iaupdatequeryhistory.h"
 #include "iaupdateparameters.h"
+#include "iaupdateagreement.h"
+#include "iaupdateautomaticcheck.h"
+#include "iaupdateresultsdialog.h"
 #include "iaupdatedebug.h"
 
+
 IAUpdateEngine::IAUpdateEngine(QObject *parent)
-    : QObject(parent),
+     : QObject(parent),
       iController(NULL),
+      iFwUpdateHandler(NULL),
       iGlobalLockHandler(NULL),
       iIdle(NULL),
+      iIdleAutCheck(NULL),
       iUpdateNow(EFalse),
       iRequestIssued(EFalse),
       iStartedFromApplication(EFalse),
+      iUiRefreshAllowed(ETrue),
       iUpdatequeryUid(0)
 {
     IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::IAUpdateEngine() begin");
     iEikEnv = CEikonEnv::Static();
+    mServiceProvider = NULL;
     mServiceProvider = new IAUpdateServiceProvider( *this );
     connect(mServiceProvider, SIGNAL(clientDisconnected()), this, SLOT(handleAllClientsClosed()));
     TRAP_IGNORE( iController = CIAUpdateUiController::NewL( *this ));
-    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::IAUpdateEngine() end")
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::IAUpdateEngine() end");
 }
 
 
@@ -61,9 +71,30 @@
 {
     IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::~IAUpdateEngine() begin");
     InformRequestObserver( KErrCancel );
-    delete iGlobalLockHandler;
-    delete iController;
-    delete mServiceProvider;    
+    if (iIdle)
+        {
+        delete iIdle;
+        }
+    if (iIdleAutCheck)
+        {
+        delete iIdleAutCheck;
+        }
+    if (iGlobalLockHandler)
+        {
+        delete iGlobalLockHandler;
+        }
+    if ( iController )
+        {
+        delete iController;
+        }
+    if ( iFwUpdateHandler )
+        {
+        delete iFwUpdateHandler;
+        }
+    if ( mServiceProvider )
+        {
+        delete mServiceProvider;
+        }
     IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::~IAUpdateEngine() end");
 }
 
@@ -89,7 +120,9 @@
 // 
 // -----------------------------------------------------------------------------
 //
-void IAUpdateEngine::CheckUpdatesRequestL( int wgid, CIAUpdateParameters* aFilterParams )
+void IAUpdateEngine::CheckUpdatesRequestL( int wgid, 
+                                           CIAUpdateParameters* aFilterParams,
+                                           TBool aForcedRefresh )
                                            
     {
     IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::CheckUpdatesRequestL() begin");
@@ -110,6 +143,7 @@
            
     iRequestType = IAUpdateUiDefines::ECheckUpdates; 
     iController->SetRequestType( iRequestType );
+    iController->SetForcedRefresh( aForcedRefresh );
     
     iController->CheckUpdatesDeferredL( aFilterParams, EFalse ); 
     
@@ -208,6 +242,52 @@
     }
 
 // -----------------------------------------------------------------------------
+// IAUpdateEngine::StartUpdate
+// 
+// -----------------------------------------------------------------------------
+//
+void IAUpdateEngine::StartUpdate( TBool aFirmwareUpdate )
+    {
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::StartUpdate() begin");
+    if ( aFirmwareUpdate )
+        {
+        if ( !iFwUpdateHandler )
+            {
+            TRAP_IGNORE( CIAUpdateFWUpdateHandler::NewL() );
+            }
+        if ( iFwUpdateHandler )
+            {
+            iFwUpdateHandler->FirmWareUpdatewithFOTA();
+            }
+        }
+    else
+        {
+        // by pushing object to cleanup stack it's destructor is called if leave happens
+        // so global lock issued by this instance can be released in destructor of CIAUpdateGlobalLockHandler
+        CIAUpdateGlobalLockHandler* globalLockHandler = CIAUpdateGlobalLockHandler::NewLC();
+        if ( !globalLockHandler->InUseByAnotherInstanceL() )
+            {
+            globalLockHandler->SetToInUseForAnotherInstancesL( ETrue );
+            // No need to be totally silent since the updating is started
+            // by user.
+            SetDefaultConnectionMethodL( EFalse );
+            iController->StartUpdateL();
+            CleanupStack::Pop( globalLockHandler ); 
+            delete iGlobalLockHandler;
+            iGlobalLockHandler = globalLockHandler;
+            //now possible deletion of iGlobalLockHandler in leave situation is handled
+            //in HandleLeaveErrorL() and HandleLeaveErrorWithoutLeave methods. 
+            }
+        else
+            {
+            CleanupStack::PopAndDestroy( globalLockHandler );   
+            }
+        }
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::StartUpdate() end");
+    }
+
+
+// -----------------------------------------------------------------------------
 // IAUpdateEngine::SetVisibleL
 // 
 // -----------------------------------------------------------------------------
@@ -273,21 +353,11 @@
     }
 
 
-
 // -----------------------------------------------------------------------------
-// IAUpdateEngine::refresh
+// IAUpdateEngine::handleAllClientsClosed()
 // 
 // -----------------------------------------------------------------------------
-//  
-/*void IAUpdateEngine::refresh(int error) 
-    {
-    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::refresh() begin");
-    IAUPDATE_TRACE_1("[IAUPDATE] Error code: %d", error );
-    //iMainView->RefreshL( iController->Nodes(), iController->FwNodes(), aError );                    
-    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::refresh() end");
-    }*/
-
-
+//
 void IAUpdateEngine::handleAllClientsClosed()
 {
     qApp->quit(); 
@@ -343,8 +413,11 @@
                     {
                     if ( iController->Filter()->FilterParams()->Refresh() )
                         {
-                        //from bgchecker, make it silent
-                        totalSilent = ETrue;
+                        if ( !iController->ForcedRefresh() )
+                            {
+                            //from bgchecker, make it silent
+                            totalSilent = ETrue;
+                            }
                         }
                     }
                 }
@@ -362,7 +435,7 @@
     
     IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::StartupCompleteL() end");    
     }
-    
+
  
 // -----------------------------------------------------------------------------
 // IAUpdateEngine::HandleLeaveErrorL
@@ -433,19 +506,31 @@
           //  {
           //  ActivateLocalViewL( TUid::Uid( EIAUpdateMainViewId ) );
           //  }
- 
+        CIAUpdateAgreement* agreement = CIAUpdateAgreement::NewLC();
+        TBool agreementAccepted = agreement->AgreementAcceptedL();
+        if ( iController->ForcedRefresh() )    
+            {
+            if ( !agreementAccepted )
+                {
+                agreement->SetAgreementAcceptedL();
+                }
+            }
+        CleanupStack::PopAndDestroy( agreement );
         // By calling CIdle possible waiting dialog can be closed before
         // automatic check where a new dialog may be launched
-        //delete iIdleAutCheck;
-        //iIdleAutCheck = NULL;
-        //iIdleAutCheck = CIdle::NewL( CActive::EPriorityIdle ); 
-        //iIdleAutCheck->Start( TCallBack( AutomaticCheckCallbackL, this ) );*/
+        delete iIdleAutCheck;
+        iIdleAutCheck = NULL;
+        iIdleAutCheck = CIdle::NewL( CActive::EPriorityIdle ); 
+        iIdleAutCheck->Start( TCallBack( AutomaticCheckCallbackL, this ) );
         } 
  
   
     IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::RefreshCompleteL() end");        
     }
 
+
+
+
 // -----------------------------------------------------------------------------
 // IAUpdateEngine::UpdateCompleteL
 // 
@@ -463,9 +548,9 @@
         InformRequestObserver( aError );
         }
     
-    //RefreshL( KErrNone ); 
-      
-    //ShowStatusDialogDeferredL();
+    emit refresh( iController->Nodes(), iController->FwNodes(), KErrNone );
+         
+    ShowResultsDialogDeferredL();
                 
     IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::UpdateCompleteL end");
     }
@@ -473,6 +558,84 @@
 
 
 // -----------------------------------------------------------------------------
+// IAUpdateEngine::ShowResultsDialogL
+// 
+// -----------------------------------------------------------------------------
+//   
+void IAUpdateEngine::ShowResultsDialogL()
+    {
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::ShowResultsDialogL() begin");
+                
+    iUiRefreshAllowed = ETrue;
+    IAUpdateResultsDialog resultsDialog;
+    resultsDialog.showResults(iController->ResultsInfo());
+    
+    //TODO: How to recognise when application is closing 
+    if ( iController->ResultsInfo().iRebootAfterInstall )
+        {
+        HbMessageBox messageBox(HbMessageBox::MessageTypeQuestion); 
+        messageBox.setText(QString("Phone restart needed. Restart now?"));
+        HbAction okAction("Ok");
+        HbAction cancelAction("Cancel");
+        messageBox.setPrimaryAction(&okAction);
+        messageBox.setSecondaryAction(&cancelAction);
+        messageBox.setTimeout(HbPopup::NoTimeout);
+        messageBox.show();
+        /*HbAction *selectedAction = messageBox.exec();
+        if (selectedAction == messageBox.primaryAction())
+            {
+            RStarterSession startersession;
+            if( startersession.Connect() == KErrNone )
+                {
+                startersession.Reset( RStarterSession::EUnknownReset );
+                startersession.Close();
+                return;
+                }
+            }*/
+        }
+    if ( iStartedFromApplication && 
+        iController->ResultsInfo().iCountCancelled == 0 &&
+        iController->ResultsInfo().iCountFailed == 0 )
+        {
+        qApp->quit();
+        }
+    
+    IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateEngine::ShowResultsDialogL() nodes count: %d", iController->Nodes().Count() );
+    IAUPDATE_TRACE_1("[IAUPDATE] IAUpdateEngine::ShowResultsDialogL() fw nodes: %d", iController->FwNodes().Count() );
+    //exit from result view if there are no update left
+    if ( iController->Nodes().Count() == 0 && iController->FwNodes().Count() == 0 )
+        {
+        qApp->quit();
+        }
+    
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::ShowResultsDialogL() end");
+    }
+
+// -----------------------------------------------------------------------------
+// IAUpdateEngin::ShowResultsDialogDeferredL
+// 
+// -----------------------------------------------------------------------------
+//       
+void IAUpdateEngine::ShowResultsDialogDeferredL()
+    {
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::ShowResultsDialogDeferredL() begin");
+    delete iIdle;
+    iIdle = NULL;
+    iIdle = CIdle::NewL( CActive::EPriorityIdle ); 
+    iIdle->Start( TCallBack( ShowResultsDialogCallbackL, this ) ); 
+    iUiRefreshAllowed = EFalse;
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::ShowResultsDialogDeferredL() end");
+    }
+ 
+
+
+
+
+
+
+
+
+// -----------------------------------------------------------------------------
 // IAUpdateEngine::InformRequestObserver
 // 
 // -----------------------------------------------------------------------------
@@ -910,9 +1073,10 @@
         messageBox.setSecondaryAction(&laterAction);
         messageBox.setTimeout(HbPopup::NoTimeout);
         messageBox.show();
-        HbAction *selectedAction = messageBox.exec();
+        iUpdateNow = ETrue;
+        //HbAction *selectedAction = messageBox.exec();
         
-        if (selectedAction == messageBox.primaryAction())
+        /*if (selectedAction == messageBox.primaryAction())
             {
             IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::ShowUpdateQueryL() Now");
             iUpdateNow = ETrue;
@@ -921,7 +1085,7 @@
             {
             IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::ShowUpdateQueryL() Later");
             updateQueryHistory->SetTimeL( iUpdatequeryUid );
-            }
+            }*/
         }
     CleanupStack::PopAndDestroy( updateQueryHistory );
     InformRequestObserver( KErrNone );  
@@ -951,6 +1115,22 @@
     }
 
 // ---------------------------------------------------------------------------
+// IAUpdateEngine::ShowResultsDialogCallbackL
+// ---------------------------------------------------------------------------
+//
+TInt IAUpdateEngine::ShowResultsDialogCallbackL( TAny* aPtr )
+    {
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::ShowResultsDialogCallbackL() begin");
+    IAUpdateEngine* engine = static_cast<IAUpdateEngine*>( aPtr );
+    //TRAPD( err, engine->ShowResultsDialogL() );
+    TRAP_IGNORE( engine->ShowResultsDialogL() );
+    //appUI->HandleLeaveErrorL( err );
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::ShowResultsDialogCallbackL() end");
+    return KErrNone;
+    }
+
+
+// ---------------------------------------------------------------------------
 // IAUpdateEngine::UpdateQueryCallbackL
 // ---------------------------------------------------------------------------
 //
@@ -968,7 +1148,38 @@
     return KErrNone;
     }    
 
+// ---------------------------------------------------------------------------
+// IAUpdateEngine::AutomaticCheckCallbackL
+// ---------------------------------------------------------------------------
+//    
+    
+TInt IAUpdateEngine::AutomaticCheckCallbackL( TAny* aPtr )    
+    {
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::AutomaticCheckCallbackL() begin");
+    IAUpdateEngine* engine= static_cast<IAUpdateEngine*>( aPtr ); 
+    
+    TInt err = KErrNone;
+    CIAUpdateAutomaticCheck* automaticCheck = NULL;
+    TRAP( err, automaticCheck = CIAUpdateAutomaticCheck::NewL() ); 
+    if ( err != KErrNone )
+        {
+        engine->HandleLeaveErrorL( err );
+        }
+    else
+        {
+        CleanupStack::PushL( automaticCheck );
+        TRAP( err, automaticCheck->AcceptAutomaticCheckL() );
+        if ( err != KErrNone )
+            {
+            engine->HandleLeaveErrorL( err );
+            }   
+        } 
+    
+    CleanupStack::PopAndDestroy( automaticCheck );
+    
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateEngine::AutomaticCheckCallbackL() end");
+    return KErrNone;
+    }
 
 
 
-
--- a/iaupdate/IAD/ui/src/iaupdatemainview.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/src/iaupdatemainview.cpp	Fri May 14 15:58:48 2010 +0300
@@ -26,9 +26,12 @@
 #include <hbmenu.h>
 #include <hbdocumentloader.h>
 #include <xqconversions.h>
+#include <hbmessagebox.h>
 
 #include "iaupdatemainview.h"
+#include "iaupdateengine.h"
 #include "iaupdateagreement.h"
+#include "iaupdatedeputils.h"
 
 #include "iaupdatedebug.h"
 
@@ -37,7 +40,8 @@
 const int KMaxShownInKiloBytes = 10 * KMegaByte;
 
 
-IAUpdateMainView::IAUpdateMainView()
+IAUpdateMainView::IAUpdateMainView(IAUpdateEngine *engine):
+mEngine( engine )        
 {
     HbDocumentLoader loader;
     bool ok = false;
@@ -99,8 +103,8 @@
 // Refreshes update list
 // -----------------------------------------------------------------------------
 //    
-void IAUpdateMainView::refresh( const RPointerArray<MIAUpdateNode>& nodes,
-                                const RPointerArray<MIAUpdateFwNode>& fwNodes,
+void IAUpdateMainView::refresh( const RPointerArray<MIAUpdateNode> &nodes,
+                                const RPointerArray<MIAUpdateFwNode> &fwNodes,
                                 int /*error*/ )
     {   
     IAUPDATE_TRACE("[IAUPDATE] IAUpdateMainView::refresh begin");
@@ -281,9 +285,9 @@
             item->setIcon(icon);
              mListView->addItem(item); 
  
-            if ( node-> Base().IsSelected() )
+            if ( node->Base().IsSelected() )
                 {
-                int count = mListView->indexCount();
+                int count = mListView->count();
                 QModelIndex modelIndex = mListView->model()->index(count-1,0);
                 selectionModel->select(modelIndex, QItemSelectionModel::Select);
                 }
@@ -335,7 +339,22 @@
 
 void IAUpdateMainView::handleStartUpdate()
 {
-     
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateMainView::handleStartUpdate() begin");
+    bool firmwareUpdate = false; 
+    RPointerArray<MIAUpdateAnyNode> selectedNodes;
+    getSelectedNodes(selectedNodes);
+    if (selectedNodes.Count() > 0)
+        {
+        if ( selectedNodes[0]->NodeType() == MIAUpdateAnyNode::ENodeTypeFw )
+            {
+            //the marking logic will make sure firmware won't be marked with normal sis updates
+            //at the same time.
+            firmwareUpdate = true;
+            }
+        }
+    selectedNodes.Close();
+    //mEngine->StartUpdate(firmwareUpdate);
+    IAUPDATE_TRACE("[IAUPDATE] IAUpdateMainView::handleStartUpdate() end");
 }
 
 
@@ -350,10 +369,335 @@
     CleanupStack::PopAndDestroy( agreement);
 }
 
-void IAUpdateMainView::handleSelectionChanged(QItemSelection)
+void IAUpdateMainView::handleSelectionChanged(QItemSelection itemSelection)
 {
+    QModelIndexList indexList = itemSelection.indexes(); 
+    bool changedItemFound = false; 
+    for (int i = 0; !changedItemFound && i < mAllNodes.Count(); ++i)
+    {
+        bool currentlySelected = false; 
+        for (int j = 0; !currentlySelected && j < indexList.count(); ++j)
+        {
+            //QModelIndex modelIndex = indexList.at(j);
+            //modelIndex.row();
+            if (i == indexList.at(j).row())
+            {
+                currentlySelected = true;
+            }
+        }
+        if (currentlySelected !=  mAllNodes[i]->Base().IsSelected())
+        {
+            changedItemFound = true;
+            markListItem(currentlySelected,i);
+            updateSelectionsToList();
+        }
+    }
 
 }
 
+void IAUpdateMainView::getSelectedNodes(RPointerArray<MIAUpdateAnyNode> &selectedNodes) const
+{
+    for (int i = 0; i < mAllNodes.Count(); ++i)
+    {
+        if (mAllNodes[i]->Base().IsSelected())
+        {
+            selectedNodes.Append(mAllNodes[i]);
+        }
+    }
+}
+
+void IAUpdateMainView::markListItem(bool mark, int index)
+{
+    if (mark)
+    {
+        //It's Mark Command
+        RPointerArray<MIAUpdateAnyNode> selectedNodes;
+        getSelectedNodes(selectedNodes); 
+        
+        //There are selected items already and type are different with the current one
+        if (selectedNodes.Count() > 0 && (mAllNodes[index]->NodeType() != selectedNodes[0]->NodeType()))
+        {       
+            // firmware item and normal sis items can't be selected at the same time
+            // unmark the selected nodes.
+            for (int i = 0; i < selectedNodes.Count(); i++)
+            {                
+                int index = mAllNodes.Find(selectedNodes[i]);
+                mAllNodes[index]->Base().SetSelected(false);
+            }
+        }
+        selectedNodes.Close();
+    }
+    
+    //there is no selected items or the type is the same with the current one
+    
+    if (mAllNodes[index]->NodeType() == MIAUpdateAnyNode::ENodeTypeFw )
+    {
+        mAllNodes[index]->Base().SetSelected(mark);       
+        return;
+    }
+    
+    if (mAllNodes[index]->NodeType() == MIAUpdateAnyNode::ENodeTypeNormal )
+    {
+        bool accepted = false;
+        
+        if(index > -1)
+        {
+            accepted = true;
+            
+            MIAUpdateNode* node = static_cast<MIAUpdateNode*>(mAllNodes[index]);
+            RPointerArray<MIAUpdateAnyNode> mands;
+            RPointerArray<MIAUpdateNode> deps;
+           
+            if (mark)
+            {
+                TRAPD(err,IAUpdateDepUtils::GetDependenciesL(*node, mAllNodes, deps));
+                if (err != KErrNone)
+                {
+                    deps.Close();
+                    return;
+                }
+                if (!getMandatoryNodes(mands))
+                {
+                    // error when creating mandatory node list
+                    mands.Close();
+                    return;
+                }
+            }
+            else
+            {
+                //mandatory item is not allowed to be unmarked
+                if (mAllNodes[index]->Base().Importance() == MIAUpdateBaseNode::EMandatory)
+                {
+                    //show dialog  
+                    showUpdateCannotOmitDialog();
+                    return;
+                }
+                
+                //CleanupClosePushL( deps );
+                TRAPD(err,IAUpdateDepUtils::GetDependantsL(*node, mAllNodes, deps));  
+                if (err != KErrNone)
+                {
+                    deps.Close();
+                    return;
+                }
+                // item is not allowed to be unmarked if its dependant is mandatory
+                bool mandatoryDependantFound = false;
+                for(int i = 0; i < deps.Count() && !mandatoryDependantFound; i++)
+                {
+                    if (deps[i]->Base().Importance() == MIAUpdateBaseNode::EMandatory)
+                    {
+                        mandatoryDependantFound = true;
+                    }
+                }
+                if (mandatoryDependantFound)
+                {
+                    showUpdateCannotOmitDialog();
+                    deps.Close();
+                    return;
+                }
+            }
+             
+            int depCount = deps.Count();
+           
+            if (depCount > 0)
+            {
+                QString text;
+                QString names;
+                MIAUpdateNode* depNode = NULL;
+                QString separator(",");
+                       
+                for(int i = 0; i < depCount; i++)  
+                {
+                    depNode = deps[i];
+                    if (i > 0)
+                    {
+                        names.append(separator);
+                        names.append(QString(" "));
+                    }
+                    names.append(XQConversions::s60DescToQString(depNode->Base().Name()));
+                }
+                
+
+                if (mark)
+                {
+                    if (depCount > 1) 
+                    {
+                        text.append("This update needs also updates "); 
+                        text.append(names);
+                        text.append(" for working");
+                        //resourceId = R_IAUPDATE_DEPENDENCY_MARK_MANY;
+                    } 
+                    else
+                    {
+                        text.append("This update needs also \""); 
+                        text.append(names);
+                        text.append("\" for working");
+                        //resourceId = R_IAUPDATE_DEPENDENCY_MARK_ONE;    
+                    }
+                }
+                else
+                {
+                    if (depCount > 1) 
+                    {
+                        text.append("Updates "); 
+                        text.append(names);
+                        text.append(" need this update for working");
+                        //resourceId = R_IAUPDATE_DEPENDENCY_UNMARK_MANY;
+                    } 
+                    else
+                    {
+                        text.append("Update \""); 
+                        text.append(names);
+                        text.append("\" needs this update for working");
+                        //resourceId = R_IAUPDATE_DEPENDENCY_UNMARK_ONE;  
+                    }   
+                }
+                
+                if (mark && mAllNodes[index]->Base().Importance() == MIAUpdateBaseNode::EMandatory)
+                {
+                    // depencencies of mandatory update are also selected without showing dialog
+                    accepted = true;
+                }
+                else
+                {
+                    accepted = showDependenciesFoundDialog(text);
+                }
+            }
+            
+            if (accepted)
+            {
+                for(int j = 0; j < depCount; j++)
+                {
+                    int depNodeInd = mAllNodes.Find(deps[j]);
+                    mAllNodes[depNodeInd]->Base().SetSelected(mark);
+                }
+                deps.Close();
+                int nodeInd = mAllNodes.Find(node);
+                mAllNodes[nodeInd]->Base().SetSelected(mark);
+            }
+            else
+            {
+                //user rejects the dependency dialog
+                deps.Close();
+                if (mark)
+                {
+                    mands.Close();
+                }
+                return;
+            }
+                
+            //mark all of the mandatory items
+            int mandCount = mands.Count();
+            if (mandCount > 0 && mark)
+            {
+                for(int j = 0; j < mandCount; j++)
+                {
+                    int mandNodeInd = mAllNodes.Find(mands[j]);
+                    mAllNodes[mandNodeInd]->Base().SetSelected(mark);
+                    if (mAllNodes[mandNodeInd]->NodeType() == MIAUpdateAnyNode::ENodeTypeNormal)
+                    {
+                        // mark also all dependencies of a mandatory item
+                        MIAUpdateNode* dependencyNode = static_cast<MIAUpdateNode*>(mAllNodes[mandNodeInd]);
+                        RPointerArray<MIAUpdateNode> dependencies;
+                        TRAPD(err,IAUpdateDepUtils::GetDependenciesL(*dependencyNode, mAllNodes, dependencies));
+                        if (err)
+                        {
+                            dependencies.Close(); 
+                            if (mark)
+                            {
+                                mands.Close();
+                            }
+                            return;
+                        }
+                        for(int k = 0; k < dependencies.Count(); k++)
+                        {
+                            int depNodeInd = mAllNodes.Find(dependencies[k]);
+                            mAllNodes[depNodeInd]->Base().SetSelected(true);
+                        }
+                        dependencies.Close();
+                    }
+                }
+            }
+            if (mark)
+            {
+                mands.Close();
+            }
+        }  
+        return;
+        }
+    return;
+    }
 
 
+bool IAUpdateMainView::getMandatoryNodes(RPointerArray<MIAUpdateAnyNode> &mandNodes) const
+{
+    bool ret = true;
+    for(int i = 0; i < mAllNodes.Count(); ++i)
+    {
+        if (mAllNodes[i]->Base().Importance() == MIAUpdateBaseNode::EMandatory)
+        {
+            if (mandNodes.Append(mAllNodes[i]) != KErrNone)
+            {
+                ret = false; 
+            }
+        }
+    }
+    return ret;
+}
+
+void IAUpdateMainView::showUpdateCannotOmitDialog() const
+{
+    HbMessageBox messageBox(HbMessageBox::MessageTypeInformation); 
+    messageBox.setText(QString("This required update cannot be omitted"));
+    HbAction okAction("Ok");
+    messageBox.setPrimaryAction(&okAction);
+    messageBox.setTimeout(HbPopup::StandardTimeout);
+    messageBox.show();
+    //messageBox.exec();
+}
+
+bool IAUpdateMainView::showDependenciesFoundDialog(QString &text) const
+{
+    bool accepted = false;
+    HbMessageBox messageBox(HbMessageBox::MessageTypeQuestion);
+    messageBox.setText(text);
+    HbAction continueAction("Continue");
+    messageBox.setPrimaryAction(&continueAction);
+    HbAction cancelAction("Cancel");
+    messageBox.setSecondaryAction(&cancelAction);
+    messageBox.setTimeout(HbPopup::NoTimeout);
+    messageBox.show();
+    //HbAction *selectedAction = messageBox.exec();
+    //if (selectedAction == messageBox.primaryAction())
+    {
+        accepted = true;
+    }
+    return accepted;
+}
+
+void IAUpdateMainView::updateSelectionsToList()
+{
+    for(int i = 0; i < mAllNodes.Count(); ++i)
+    {
+        if ( mAllNodes[i]->Base().IsSelected() != mListView->selectionModel()->isSelected(mListView->model()->index(i,0)))
+        {    
+            QItemSelectionModel::SelectionFlag selectionFlag;
+            if ( mAllNodes[i]->Base().IsSelected())
+            {
+                selectionFlag = QItemSelectionModel::Select;
+            }
+            else
+            {
+                selectionFlag = QItemSelectionModel::Deselect;
+            }
+            mListView->selectionModel()->select(mListView->model()->index(i,0),selectionFlag);   
+        }
+    }
+}
+
+
+                
+                
+                
+                
+                
--- a/iaupdate/IAD/ui/src/iaupdatemainwindow.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/src/iaupdatemainwindow.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2009 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"
@@ -25,11 +25,11 @@
 
 
 // ViewManager Constructor
-IAUpdateMainWindow::IAUpdateMainWindow()
+IAUpdateMainWindow::IAUpdateMainWindow(IAUpdateEngine *engine)
 {
     // Add the views to the main window
     //addHistoryView();
-    addMainView();
+    addMainView(engine);
     // show the main window (which will display the last view that was added)
     show();   //temp
 }
@@ -40,9 +40,9 @@
 }
 
 // Methods to add views to the main window
-void IAUpdateMainWindow::addMainView()
+void IAUpdateMainWindow::addMainView(IAUpdateEngine *engine)
 {
-    mMainView = new IAUpdateMainView();
+    mMainView = new IAUpdateMainView(engine);
     addView(mMainView);
 }
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/iaupdate/IAD/ui/src/iaupdateresultsdialog.cpp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,131 @@
+/*
+* 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 FILES
+
+#include <hbaction.h>
+#include <hbdialog.h>
+#include <hbtextitem.h>
+
+#include "iaupdateresultsdialog.h"
+#include "iaupdateresultsinfo.h"
+#include "iaupdatedebug.h"
+
+
+IAUpdateResultsDialog::IAUpdateResultsDialog(QObject *parent)
+    : QObject(parent)
+{
+    
+}
+
+IAUpdateResultsDialog::~IAUpdateResultsDialog()
+{
+}
+
+void IAUpdateResultsDialog::showResults(const TIAUpdateResultsInfo &param)
+{
+    QString buf;
+    constructText(param,buf);
+    HbDialog dialog;
+    HbTextItem *text = new HbTextItem(&dialog);
+    text->setFontSpec(HbFontSpec(HbFontSpec::Primary));
+    text->setText(buf);
+    dialog.setContentWidget(text);
+    HbAction *primaryAction = new HbAction("Ok");    
+    dialog.setPrimaryAction(primaryAction);
+    dialog.setTimeout(HbPopup::NoTimeout);
+    dialog.show();
+    //dialog.exec();    
+    return;  
+}
+
+// -----------------------------------------------------------------------------
+// IAUpdateResultsDialog::constructText
+//
+// -----------------------------------------------------------------------------
+//
+void IAUpdateResultsDialog::constructText(const TIAUpdateResultsInfo &param, QString &buf)
+{ 
+    if (param.iCountSuccessfull == 0 && param.iCountCancelled == 0 &&
+        param.iCountFailed == 0)
+    {
+        QString stringCount;
+        stringCount.setNum(param.iCountSuccessfull);    
+        buf.append(stringCount);
+        buf.append(" updates successful");
+        buf.append("\n");
+        return;
+    } 
+  
+    if (param.iCountSuccessfull != 0)
+    {
+        QString stringCount;
+        stringCount.setNum(param.iCountSuccessfull);    
+        buf.append(stringCount);
+        if (param.iCountSuccessfull == 1)
+        {
+            buf.append(" application updated"); 
+        }
+        else
+        {
+            buf.append(" applications updated"); 
+        }
+        buf.append("\n");
+    }
+    
+    if (param.iCountCancelled != 0)
+    {
+        QString stringCount;
+        stringCount.setNum(param.iCountCancelled);    
+        buf.append(stringCount);
+        if (param.iCountCancelled == 1)
+        {
+            buf.append(" update cancelled");
+        }
+        else
+        {
+            buf.append(" updates cancelled");
+        }
+        buf.append("\n");
+    }
+
+    if (param.iCountFailed != 0)
+    {
+        QString stringCount;
+        stringCount.setNum(param.iCountFailed);    
+        buf.append(stringCount);
+        if (param.iCountFailed == 1)
+        {
+            buf.append(" update failed");
+        }
+        else
+        {
+            buf.append(" updates failed");
+        }
+        buf.append("\n");
+    }
+    
+    if (param.iFileInUseError)
+    {
+    	buf.append("Close all applications and try again.");
+    	buf.append("\n");
+    }
+} 
+
+//  End of File  
--- a/iaupdate/IAD/ui/src/iaupdateserviceprovider.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/src/iaupdateserviceprovider.cpp	Fri May 14 15:58:48 2010 +0300
@@ -23,6 +23,7 @@
 #include "iaupdatedebug.h"
 
 const TSecureId KSIDBackgroundChecker = 0x200211f4;
+const TSecureId KSIDCwrtWidget = 0x200267C0;
 
 
 IAUpdateServiceProvider::IAUpdateServiceProvider(IAUpdateEngine& engine)
@@ -76,12 +77,12 @@
                   stringType,
                   stringRefresh);
   
-        if ( requestInfo().clientSecureId() != KSIDBackgroundChecker )      
+        if ((requestInfo().clientSecureId() != KSIDBackgroundChecker) && (requestInfo().clientSecureId() != KSIDCwrtWidget))      
         {
             // other processes than backroundchecker are not allowed to cause refresh from network 
             params->SetRefresh( EFalse );
         }
-    mEngine->CheckUpdatesRequestL(stringWgId.toInt(),params);
+    mEngine->CheckUpdatesRequestL(stringWgId.toInt(),params, params->Refresh() && requestInfo().clientSecureId() == KSIDCwrtWidget);
     IAUPDATE_TRACE("[IAUPDATE] IAUpdateServiceProvider::checkUpdates() end");
     }
     
--- a/iaupdate/IAD/ui/src/iaupdateuicontroller.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/IAD/ui/src/iaupdateuicontroller.cpp	Fri May 14 15:58:48 2010 +0300
@@ -319,20 +319,22 @@
         }
      
     TBool agreementAccepted( EFalse ); 
-    CIAUpdateAgreement* agreement = CIAUpdateAgreement::NewLC();
-    agreementAccepted = agreement->AgreementAcceptedL();
-    if ( ( !agreementAccepted )&& ( iRequestType != IAUpdateUiDefines::ECheckUpdates ) )
+    if ( !ForcedRefresh() )
         {
-        // agreement (disclaimer) dialog is not prompted when CheckUpdates is called
-        //
-        // Refresh from network is allowed when first time case 
-        iRefreshFromNetworkDenied = EFalse;
-    	agreementAccepted = agreement->AcceptAgreementL();	
+        CIAUpdateAgreement* agreement = CIAUpdateAgreement::NewLC();
+        agreementAccepted = agreement->AgreementAcceptedL();
+        if ( ( !agreementAccepted )&& ( iRequestType != IAUpdateUiDefines::ECheckUpdates ) )
+            {
+            // agreement (disclaimer) dialog is not prompted when CheckUpdates is called
+            //
+            // Refresh from network is allowed when first time case 
+            iRefreshFromNetworkDenied = EFalse;
+            agreementAccepted = agreement->AcceptAgreementL();  
+            }
+        CleanupStack::PopAndDestroy( agreement );
         }
-        	
-    CleanupStack::PopAndDestroy( agreement );
-             
-    if ( !agreementAccepted )
+  	             
+    if ( !agreementAccepted && !ForcedRefresh() )
         {
         if ( iRequestType == IAUpdateUiDefines::ECheckUpdates )
             {
@@ -420,7 +422,8 @@
             HbAction action("OK");
             messageBox.setPrimaryAction(&action);
             messageBox.setTimeout(HbPopup::NoTimeout);
-            messageBox.exec();
+            messageBox.show();
+            //messageBox.exec();
         }
     else
         {
@@ -512,6 +515,7 @@
                     selectedNode->DownloadL( *this );
                     iState = EDownloading;
                     iClosingAllowedByClient = ETrue;
+                    selectedNode->SetDownloading( ETrue);
                     /*ShowUpdatingDialogL( R_IAUPDATE_DOWNLOADING_NOTE,
                                          selectedNode->Base().Name(),
                                          iNodeIndex + 1,
@@ -2288,25 +2292,32 @@
     	        {
     	    	if ( params->Refresh() )
     	    	    {
-      	      		// Check from the central repocitory what are the automatic checking and 
-                    // roaming settings.     
-                    TInt autoUpdateCheckValue( 0 );
-                    CRepository* cenrep( 
+    	    	    if ( ForcedRefresh() )
+    	    	        {
+    	    	        allowRefresh = ETrue;
+    	    	        }
+    	    	    else
+    	    	        {
+      	      		    // Check from the central repocitory what are the automatic checking and 
+                        // roaming settings.     
+                        TInt autoUpdateCheckValue( 0 );
+                        CRepository* cenrep( 
                              CRepository::NewLC( KCRUidIAUpdateSettings ) );
-                    // Notice, that KIAUpdateSettingAutoUpdateCheck can give following values
-                    // 0 = No automatic update check
-                    // 1 = Automatic update check enabled when not roaming
-                    // 2 = Automatic update enabled
+                        // Notice, that KIAUpdateSettingAutoUpdateCheck can give following values
+                        // 0 = No automatic update check
+                        // 1 = Automatic update check enabled when not roaming
+                        // 2 = Automatic update enabled
 
-                    User::LeaveIfError( cenrep->Get( KIAUpdateAutoUpdateCheck, 
-                                                     autoUpdateCheckValue ) );
-                    CleanupStack::PopAndDestroy( cenrep );
-                    if ( ( autoUpdateCheckValue == EIAUpdateSettingValueEnable ) || 
-    	               ( autoUpdateCheckValue == EIAUpdateSettingValueDisableWhenRoaming &&
-    	                 !iRoamingHandler->IsRoaming() ) )
-                        {
-                    	allowRefresh = ETrue;
-                        }
+                        User::LeaveIfError( cenrep->Get( KIAUpdateAutoUpdateCheck, 
+                                                         autoUpdateCheckValue ) );
+                        CleanupStack::PopAndDestroy( cenrep );
+                        if ( ( autoUpdateCheckValue == EIAUpdateSettingValueEnable ) || 
+    	                    ( autoUpdateCheckValue == EIAUpdateSettingValueDisableWhenRoaming &&
+    	                      !iRoamingHandler->IsRoaming() ) )
+                            {
+                    	    allowRefresh = ETrue;
+                            }
+    	    	        }
      	    	    }
     	        }
     	    }
@@ -2624,6 +2635,26 @@
     return params;
     }
 
+// ---------------------------------------------------------------------------
+// CIAUpdateUiController::ForcedRefresh
+// 
+// ---------------------------------------------------------------------------
+//
+TBool CIAUpdateUiController::ForcedRefresh() const
+    {
+    return iForcedRefresh;
+    }
+
+
+// ---------------------------------------------------------------------------
+// CIAUpdateUiController::SetForcedRefresh
+// 
+// ---------------------------------------------------------------------------
+//
+void CIAUpdateUiController::SetForcedRefresh( TBool aForcedRefresh )
+    {
+    iForcedRefresh = aForcedRefresh;
+    }
 
 // ---------------------------------------------------------------------------
 // CIAUpdateUiController::ParamsWriteFileL
--- a/iaupdate/rom/iaupdate.iby	Mon May 03 12:38:03 2010 +0300
+++ b/iaupdate/rom/iaupdate.iby	Fri May 14 15:58:48 2010 +0300
@@ -43,8 +43,6 @@
 data=ZSYSTEM\install\iaupdate_stub.sis           system\install\iaupdate_stub.sis
 data=ZSYSTEM\install\iaupdater_stub.sis          system\install\iaupdater_stub.sis
 
-data= ZPRIVATE\200211f4\qgn_note_swupdate_notification.svg PRIVATE\200211f4\qgn_note_swupdate_notification.svg
-
 #endif //FF_IAUPDATE
 
 #endif //__IAUPDATE_IBY__
--- a/installationservices/refswinstallationplugin/group/sifrefinstallerserver.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/refswinstallationplugin/group/sifrefinstallerserver.mmp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2008-2010 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 "Eclipse Public License v1.0"
@@ -19,7 +19,7 @@
 TARGET				sifrefinstallerserver.exe
 TARGETTYPE			exe
 
-CAPABILITY			ProtServ ReadUserData
+CAPABILITY			ProtServ ReadUserData WriteDevicedata
 
 VENDORID			0x70000001
 
--- a/installationservices/refswinstallationplugin/group/sifrefpkgrec.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/refswinstallationplugin/group/sifrefpkgrec.mmp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2008-2010 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 "Eclipse Public License v1.0"
--- a/installationservices/refswinstallationplugin/group/sifrefplugin.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/refswinstallationplugin/group/sifrefplugin.mmp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2008-2010 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 "Eclipse Public License v1.0"
@@ -28,7 +28,7 @@
 UID 0x10009D8D 0x1028634F
 
 
-CAPABILITY			ProtServ TrustedUI ReadUserData
+CAPABILITY			ProtServ TrustedUI ReadUserData WriteDeviceData
 
 SOURCEPATH			../source
 SOURCE				sifrefplugin.cpp
--- a/installationservices/swcomponentregistry/bwins/scrdatabaseu.def	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/bwins/scrdatabaseu.def	Fri May 14 15:58:48 2010 +0300
@@ -18,4 +18,5 @@
 	?Int64ColumnL@CStatement@Usif@@QBE_JH@Z @ 17 NONAME ; long long Usif::CStatement::Int64ColumnL(int) const
 	?NewL@CDatabase@Usif@@SAPAV12@AAVRFile@@0@Z @ 18 NONAME ; class Usif::CDatabase * Usif::CDatabase::NewL(class RFile &, class RFile &)
 	?NewLC@CDatabase@Usif@@SAPAV12@AAVRFile@@0@Z @ 19 NONAME ; class Usif::CDatabase * Usif::CDatabase::NewLC(class RFile &, class RFile &)
+	?BindBinaryL@CStatement@Usif@@QAEXHABVTDesC8@@I@Z @ 20 NONAME ; void Usif::CStatement::BindBinaryL(int, class TDesC8 const &, unsigned int)
 
--- a/installationservices/swcomponentregistry/eabi/scrdatabaseu.def	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/eabi/scrdatabaseu.def	Fri May 14 15:58:48 2010 +0300
@@ -26,4 +26,5 @@
 	_ZTVN4Usif24CStatementImplementationE @ 25 NONAME
 	_ZN4Usif9CDatabase4NewLER5RFileS2_ @ 26 NONAME
 	_ZN4Usif9CDatabase5NewLCER5RFileS2_ @ 27 NONAME
+	_ZN4Usif10CStatement11BindBinaryLEiRK6TDesC8j @ 28 NONAME
 
--- a/installationservices/swcomponentregistry/group/bld.inf	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/group/bld.inf	Fri May 14 15:58:48 2010 +0300
@@ -82,6 +82,7 @@
 ../test/tscr/scripts/tscr_performance.ini			z:/tusif/tscr/tscr_performance.ini
 ../test/tscr/scripts/tscr_performance.script		z:/tusif/tscr/tscr_performance.script
 ../test/tscr/scripts/tscr_performance_cases.script	z:/tusif/tscr/tscr_performance_cases.script
+../test/tscr/scripts/tscr_app_performance_cases.script	z:/tusif/tscr/tscr_app_performance_cases.script
 
 ../test/tscr/scripts/tscr_versioning.script		z:/tusif/tscr/tscr_versioning.script
 ../test/tscr/scripts/tscr_oom.script		z:/tusif/tscr/tscr_oom.script
--- a/installationservices/swcomponentregistry/inc/tscr.iby	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/inc/tscr.iby	Fri May 14 15:58:48 2010 +0300
@@ -38,6 +38,7 @@
 data=ZDRIVE\tusif\tscr\tscr_performance.ini				\tusif\tscr\tscr_performance.ini
 data=ZDRIVE\tusif\tscr\tscr_performance.script			\tusif\tscr\tscr_performance.script
 data=ZDRIVE\tusif\tscr\tscr_performance_cases.script	\tusif\tscr\tscr_performance_cases.script
+data=ZDRIVE\tusif\tscr\tscr_app_performance_cases.script \tusif\tscr\tscr_app_performance_cases.script
 
 data=ZDRIVE\tusif\tscr\tscr_appreginfo.ini		\tusif\tscr\tscr_appreginfo.ini	
 data=ZDRIVE\tusif\tscr\tscr_appreginfo.script		\tusif\tscr\tscr_appreginfo.script
--- a/installationservices/swcomponentregistry/inc_private/scrclient.inl	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/inc_private/scrclient.inl	Fri May 14 15:58:48 2010 +0300
@@ -154,7 +154,27 @@
 			{// destroy the filter if created locally
 			CleanupStack::PopAndDestroy((C*)localCopyOfObject);
 			}
-		}// Emd of ExternalizeFilterL
+		}// End of ExternalizeObjectL
+	
+    template <class C>
+    inline void ExternalizeRefObjectL(const C& aObject, RBuf8& aBuf)
+        {
+        // Get the required buffer size for the externalized C object
+        TInt bufSize = GetObjectBufferSizeL(aObject);
+            
+        // Clean the buffer and re-create it with the required buffer size 
+        aBuf.Close();
+        aBuf.CreateL(bufSize);
+            
+        // Externalize the filter object into the buffer
+        RDesWriteStream wstream(aBuf);
+        wstream.PushL();
+        wstream << aObject;
+        wstream.CommitL();
+        wstream.Pop();
+        wstream.Release();
+            
+        }// End of ExternalizeObjectL	
 	}
 
 #endif /* SCRCLIENT_INL */
--- a/installationservices/swcomponentregistry/inc_private/scrdatabase.h	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/inc_private/scrdatabase.h	Fri May 14 15:58:48 2010 +0300
@@ -206,6 +206,22 @@
 			@leave Leaves with one of the error codes listed in @see CDatabase::PerformStatementLC 
 		 */
 		IMPORT_C void BindBinaryL(TInt aParameterIndex, const TDesC8 &aParameterStr);		
+
+		/**
+            Sets the parameter given with the index value to the specified 8-bit descriptor.
+            A parameter value can be set:
+            - immediately after this object has been created
+            - after a call to @see CStatement::Reset
+             
+            @param aParameterIndex The index value identifying the parameter; the first parameter 
+                   has an index of 1.
+            @param aParameterStr The 8-bit descriptor whose content is to be assigned to the parameter.
+            @param aCustomLength The maximum characters allowed
+            
+            @leave KErrArgument If the input string's length is more than aCustomLength            
+            @leave Leaves with one of the error codes listed in @see CDatabase::PerformStatementLC 
+         */
+		IMPORT_C void BindBinaryL(TInt aParameterIndex, const TDesC8 &aParameterStr, TUint aCustomLength);
 		
 		/** 
 			Retrieves the value of a string column. The caller must know the string column index.
--- a/installationservices/swcomponentregistry/inc_private/scrrequestimpl.h	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/inc_private/scrrequestimpl.h	Fri May 14 15:58:48 2010 +0300
@@ -356,7 +356,8 @@
 		TBool GetIntforConditionL(const TDesC& aSelectColumn, const TDesC& aTableInfo, const TDesC& aConditionColumn,TInt aConditionValue,TInt& aRetrievedValue) const;
 		TInt  GetServiceIdForDataTypeL(const TDesC& aType) const;
 		TBool GetAppUidForServiceIdL(const TInt ServiceId, TUid& aAppUid) const;
-		TBool GetNearestAppLanguageL(TLanguage aRequiredLocale,TUid appUid,TLanguage& aFinalAppLocale) const;
+		TBool GetNearestAppLanguageL(TLanguage aRequiredLocale,TUid aAppUid,TLanguage& aFinalAppLocale) const;
+		void GetNearestAppLanguageForOpaqueDataL(TLanguage aRequiredLocale,TUid aAppUid,TUid aServiceUid,TLanguage& aFinalAppLocale) const;
 
 		// DB Version management
 		void InitializeDbVersionL();
--- a/installationservices/swcomponentregistry/source/database/scrdatabase.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/source/database/scrdatabase.cpp	Fri May 14 15:58:48 2010 +0300
@@ -407,16 +407,16 @@
 	iDb.iDbImpl->CheckSqlErrCodeL(err);
 	}
 
-template <class A> void VerifyDescriptorLengthL(const A& aDesc)
+template <class A> void VerifyDescriptorLengthL(const A& aDesc, TUint aMaxDescriptorLength)
 	{
-	const TInt KMaxInputDescriptorLength = 512;	
-	if (aDesc.Length() > KMaxInputDescriptorLength)
+	if (aDesc.Length() > aMaxDescriptorLength)
 		User::Leave(KErrArgument);	
 	}
 	
 EXPORT_C void CStatement::BindStrL(TInt aParameterIndex, const TDesC &aParameterStr)
 	{
-	VerifyDescriptorLengthL(aParameterStr);	
+    const TInt KMaxInputDescriptorLength = 512; 
+	VerifyDescriptorLengthL(aParameterStr, KMaxInputDescriptorLength);	
 	TInt err = sqlite3_bind_text16(iStmtImpl->Handle(), aParameterIndex, aParameterStr.Ptr(), aParameterStr.Size(), SQLITE_TRANSIENT);
 	// The fifth argument has the value SQLITE_TRANSIENT, it means that SQLite makes its own private copy of the data immediately
 	iDb.iDbImpl->CheckSqlErrCodeL(err);
@@ -424,10 +424,16 @@
 
 EXPORT_C void CStatement::BindBinaryL(TInt aParameterIndex, const TDesC8 &aParameterStr)
 	{
-	VerifyDescriptorLengthL(aParameterStr);
-	TInt err = sqlite3_bind_blob(iStmtImpl->Handle(), aParameterIndex, reinterpret_cast<const char *>(aParameterStr.Ptr()), aParameterStr.Size(), SQLITE_TRANSIENT);
-	iDb.iDbImpl->CheckSqlErrCodeL(err);	
-	}
+    const TInt KMaxInputDescriptorLength = 512;
+    BindBinaryL(aParameterIndex, aParameterStr, KMaxInputDescriptorLength);
+    }
+
+EXPORT_C void CStatement::BindBinaryL(TInt aParameterIndex, const TDesC8 &aParameterStr, TUint aCustomLength)
+    {
+    VerifyDescriptorLengthL(aParameterStr, aCustomLength);
+    TInt err = sqlite3_bind_blob(iStmtImpl->Handle(), aParameterIndex, reinterpret_cast<const char *>(aParameterStr.Ptr()), aParameterStr.Size(), SQLITE_TRANSIENT);
+    iDb.iDbImpl->CheckSqlErrCodeL(err); 
+    }
 
 EXPORT_C TPtrC8 CStatement::BinaryColumnL(TInt aColIdx) const
 	{
--- a/installationservices/swcomponentregistry/source/server/scrrequestimpl.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/source/server/scrrequestimpl.cpp	Fri May 14 15:58:48 2010 +0300
@@ -196,6 +196,7 @@
 
 HBufC* CScrRequestImpl::GenerateGlobalIdL(const TDesC& aUniqueSwTypeName, const TDesC& aGlobalId) const
 	{ 
+	DEBUG_PRINTF(_L8("Generating Global ID."));
 	HBufC *globalIdBuf = HBufC::NewL(aUniqueSwTypeName.Length() + aGlobalId.Length() + 1); // 1 is extra memory to put NULL char
 	TPtr globalIdDes(globalIdBuf->Des());
 	
@@ -348,6 +349,8 @@
 	
 	TPckg<TComponentId> componentIdDes(newComponentId);
 	aMessage.WriteL(3, componentIdDes);
+	
+	DEBUG_PRINTF(_L8("New component added successfully."));
 	}
 
 HBufC* CScrRequestImpl::ReadAndGetGlobalIdLC(const RMessage2& aMessage, TInt aSlot) const
@@ -453,6 +456,8 @@
 	ExecuteStatementL(insertStmtStr, numberOfValues, EValueInteger, globalIdsHash, EValueInteger, depGlobalIdHash, EValueInteger, suppGlobalIdHash, EValueString, depGlobalId, EValueString, suppGlobalId, EValueString, firstVersionParam, EValueString, secondVersionParam);
 	
 	CleanupStack::PopAndDestroy(5, verCompId); // verCompId, suppGlobalId, depGlobalId, insertStmtStr, insertStmtEndStr
+	
+	DEBUG_PRINTF(_L8("New component dependency added successfully."));
 	}
 
 CStatement* CScrRequestImpl::CreateGeneralPropertyStatementWithLocaleL(const TDesC& aStmtStr, TInt aIdColumnValue, TLanguage aLocale, const TDesC& aPropName, TBool aDoLocaleResolving) const
@@ -947,6 +952,8 @@
 
 void CScrRequestImpl::SetComponentLocalizableL(TComponentId aComponentId, TLanguage aLocale, const TDesC& aColumnName, const TDesC& aName, const TDesC& aVendor)
 	{
+	DEBUG_PRINTF(_L8("Setting component Localizable."));
+	
 	_LIT(KFindComponentLocalizable, "SELECT CompLocalId FROM ComponentLocalizables WHERE ComponentId=? AND Locale=?;");
 	TInt numberOfValues = 2;
 	CStatement *stmt = CreateStatementObjectWithLocaleL(KFindComponentLocalizable, aLocale, numberOfValues, EValueInteger, aComponentId, EValueLanguage);	
@@ -1420,6 +1427,7 @@
 
 void CScrRequestImpl::AddComponentEntryLocalizablesL(TComponentId aComponentId, CComponentEntry& aEntry, TLanguage aLocale) const
 	{
+	DEBUG_PRINTF(_L8("Adding Component Entry Localizables."));
 	_LIT(KSelectLocalizableNames, "SELECT Name,Vendor FROM ComponentLocalizables WHERE ComponentId=? AND Locale=?;");
 	_LIT(KSelectAnyNames, "SELECT Name,Vendor FROM ComponentLocalizables WHERE ComponentId=?;");
 	
@@ -1447,6 +1455,7 @@
 
 void CScrRequestImpl::AddSoftwareTypeNameToComponentEntryL(CStatement& aStmt, CComponentEntry& aEntry, TLanguage aLocale) const
 	{
+	DEBUG_PRINTF(_L8("Adding SoftwareType Name To Component Entry."));
 	TInt softwareTypeId = aStmt.IntColumnL(1);
 	_LIT(KSelectLocalizableSwTypeName, "SELECT Name FROM SoftwareTypeNames WHERE SoftwareTypeId=? AND Locale=?;");
 	CStatement *stmtLoc = ExecuteLocalizableStatementL(KSelectLocalizableSwTypeName, KSelectLocalizableSwTypeName, softwareTypeId, aLocale);
@@ -1546,6 +1555,8 @@
 
 void CScrRequestImpl::AddGeneralPropertiesArrayWithLocaleL(const TDesC& aStmtStr, TLanguage aLocale, TComponentId aIdColumnValue, RPointerArray<CPropertyEntry>& aProperties) const
 	{
+	DEBUG_PRINTF(_L8("Adding General Properties Array With Locale."));
+	
 	TInt numberOfValues = 2;
 	CStatement *stmt = CreateStatementObjectWithLocaleL(aStmtStr, aLocale, numberOfValues, EValueInteger, aIdColumnValue, EValueLanguage);
 	if(!stmt)
@@ -1573,6 +1584,8 @@
 
 void CScrRequestImpl::GetGeneralPropertiesArrayL(const TDesC& aTableName, const TDesC& aIdColumnName , TComponentId aIdColumnValue, TLanguage aLocale, RPointerArray<CPropertyEntry>& aProperties) const
 	{
+	DEBUG_PRINTF(_L8("Returning General Properties Array."));
+	
 	_LIT(KSelectGeneralLocalizableProperties, "SELECT Name,IntValue,StrValue,Locale,IsStr8Bit FROM %S WHERE %S=? AND Locale=?;");
 	TInt formattedLen = aTableName.Length() + aIdColumnName.Length();
 	HBufC *statementStr = FormatStatementLC(KSelectGeneralLocalizableProperties, formattedLen, &aTableName, &aIdColumnName );
@@ -1625,6 +1638,8 @@
 
 CPropertyEntry* CScrRequestImpl::GetPropertyEntryL(CStatement& aStmt, const TDesC& aPropName, TInt aStartingIndex) const
 	{
+	DEBUG_PRINTF(_L8("Returning the file properties entry."));
+	
 	CPropertyEntry *entry(0);
 		
 	if(!aStmt.IsFieldNullL(aStartingIndex))
@@ -1701,6 +1716,7 @@
 
 void CScrRequestImpl::GetComponentFilesCountL(const RMessage2& aMessage) const
 	{
+	DEBUG_PRINTF(_L8("Returning the Component Files Count."));
 	TComponentId componentId = GetComponentIdFromMsgL(aMessage);
 
 	DEBUG_PRINTF2(_L8("Returning the files count for component %d."), componentId);
@@ -1724,6 +1740,7 @@
 
 void CScrRequestImpl::GetFileComponentsL(const TDesC& aFileName, RArray<TComponentId>& aComponents) const
 	{
+	DEBUG_PRINTF(_L8("Returning the File Components."));
 	_LIT(KSelectFileComponents, "SELECT ComponentId FROM ComponentsFiles WHERE LocationHash=?;");
 	CStatement *stmt = iDbHandle->PrepareStatementLC(KSelectFileComponents);
 	TUint32 hash = HashCaseInsensitiveL(aFileName);
@@ -1749,6 +1766,7 @@
 
 void CScrRequestImpl::GetFileComponentsDataL(const RMessage2& aMessage) const
 	{
+	DEBUG_PRINTF(_L8("Returning the File Components Data."));
 	WriteArrayDataL(aMessage, 0, iFileComponents);
 	}
 	
@@ -1853,6 +1871,7 @@
 
 void CScrRequestImpl::GetGeneralDependencyListL(const TDesC& aSelectColumn, const TDesC& aConditionColumn, const TDesC& aConditionValue, RPointerArray<CVersionedComponentId> &aVerCompIdList) const
 	{
+	DEBUG_PRINTF(_L8("Returning General Dependency List."));
 	_LIT(KSelectDependencies, "SELECT %S,VersionFrom,VersionTo FROM ComponentDependencies WHERE %S=?;");
 	TInt formattedLen = aSelectColumn.Length() + aConditionColumn.Length();
 	HBufC *stmtStr = FormatStatementLC(KSelectDependencies(), formattedLen, &aSelectColumn, &aConditionColumn);
@@ -1915,6 +1934,7 @@
 
 void CScrRequestImpl::GetDependantComponentsDataL(const RMessage2& aMessage) const
 	{
+	DEBUG_PRINTF(_L8("Returning Dependant Components Data."));
 	WriteArrayDataL(aMessage, 0, iVerCompIdList);
 	}
 		
@@ -1931,6 +1951,7 @@
 
 TBool CScrRequestImpl::CheckForMediaPresenceL(TComponentId aComponentId) const
 	{
+	DEBUG_PRINTF(_L8("Check For Media Presence."));
 	TInt componentDrivesBitmask = GetInstalledDrivesBitmaskL(aComponentId);	
 	
 	TDriveList presentDriveSet;
@@ -1982,6 +2003,7 @@
 
 TBool CScrRequestImpl::GetSifPluginUidIInternalL(TInt aSoftwareTypeId, TInt& aValue) const
 	{
+	DEBUG_PRINTF(_L8("Returning Sif Plugin UidI Internal."));
 	TBool found = EFalse;	
 		
 	_LIT(KSelectSifPluginUid, "SELECT SifPluginUid FROM SoftwareTypes WHERE SoftwareTypeId=?;");
@@ -2042,6 +2064,7 @@
 
 void CScrRequestImpl::GetPluginUidWithComponentIdL(const RMessage2& aMessage) const
 	{
+	DEBUG_PRINTF(_L8("Returning Plugin Uid With ComponentId."));
 	TComponentId componentId = GetComponentIdFromMsgL(aMessage);
 	DEBUG_PRINTF2(_L8("Returning the plugin of component(%d)."), componentId);
 	
@@ -2210,6 +2233,7 @@
 
 TInt CScrRequestImpl::GetServiceIdForDataTypeL(const TDesC& aType) const
     {
+	DEBUG_PRINTF(_L8("Returning ServiceId For DataType."));
     TInt serviceId = 0;
     _LIT(KSelectAppForDataTypeAndService, "SELECT ServiceId FROM DataType WHERE Type=? ORDER BY Priority DESC;");    
     CStatement* stmt = iDbHandle->PrepareStatementLC(KSelectAppForDataTypeAndService);
@@ -2229,6 +2253,7 @@
     
 TBool CScrRequestImpl::GetAppUidForServiceIdL(const TInt ServiceId, TUid& aAppUid) const
     {
+	DEBUG_PRINTF(_L8("Returning App Uid for ServiceId."));
     _LIT(KSelectColumn, "AppUid");
     _LIT(KTable, "ServiceInfo");
     _LIT(KConditionColumn, "ServiceId");
@@ -2243,8 +2268,82 @@
         }
     }
 
-TBool CScrRequestImpl::GetNearestAppLanguageL(TLanguage aRequiredLocale,TUid appUid, TLanguage& aFinalAppLocale) const
+void CScrRequestImpl::GetNearestAppLanguageForOpaqueDataL(TLanguage aRequiredLocale, TUid aAppUid, TUid aServiceUid, TLanguage& aFinalAppLocale) const
     {
+	DEBUG_PRINTF(_L8("Returning Nearest App Language For OpaqueData."));
+    // Set the default language
+    aFinalAppLocale = TLanguage(0);
+    
+    if (aRequiredLocale == KUnspecifiedLocale)
+        {
+        aRequiredLocale = User::Language();
+        }
+        
+    // Get the list of locales supported by the application
+    RArray<TInt> appLocales;
+    CleanupClosePushL(appLocales);
+    GetLocalesForAppIdL(appLocales, aAppUid);
+    
+    // Return the default language if the app doesn't have localized info
+    if (!appLocales.Count())
+        {
+        CleanupStack::PopAndDestroy(&appLocales);
+        return;            
+        }
+  
+    // Check if current language is supported by application
+    if (KErrNotFound != appLocales.Find((TInt)aRequiredLocale))
+        {
+        aFinalAppLocale = aRequiredLocale;
+        }
+    else // Get the nearest languages corresponding to the required language
+        {    
+        TLanguagePath equivalentLanguages;
+        BaflUtils::GetEquivalentLanguageList(aRequiredLocale, equivalentLanguages);
+            
+        // Identify the application locale corresponding to the nearest required locale
+        TInt index = 0;
+        while (1)
+            {
+            if (equivalentLanguages[index] == ELangNone)
+                {
+                break;
+                }
+            
+            if (appLocales.FindInOrder((TInt)equivalentLanguages[index]) != KErrNotFound)
+                {
+                aFinalAppLocale = equivalentLanguages[index];
+                break;
+                }           
+    
+            index++;
+            }
+        }
+    
+    // Check the opaque data exists in the selected language
+    if (aFinalAppLocale != TLanguage(0))
+        {
+        _LIT(KOpaqueData, "SELECT StrValue FROM AppProperties where Name = ? AND ServiceUid = ?  AND AppUid = ? AND Locale = ?");
+        CStatement *stmt = iDbHandle->PrepareStatementLC(KOpaqueData);        
+        stmt->BindStrL(1, _L("OpaqueData"));
+        stmt->BindIntL(2, aServiceUid.iUid);
+        stmt->BindIntL(3, aAppUid.iUid);
+        stmt->BindIntL(4, (TInt)aFinalAppLocale);
+        
+        if (!stmt->ProcessNextRowL())
+            {
+            // No opaque data for given locale, hence set to the default locale
+            aFinalAppLocale = TLanguage(0);
+            }
+        CleanupStack::PopAndDestroy(stmt);
+        }
+       
+    CleanupStack::PopAndDestroy(&appLocales);
+    }
+
+TBool CScrRequestImpl::GetNearestAppLanguageL(TLanguage aRequiredLocale, TUid aAppUid, TLanguage& aFinalAppLocale) const
+    {
+	DEBUG_PRINTF(_L8("Returning Nearest App Language."));
     TLanguagePath equivalentLanguages;
     TInt index = 0;
     RArray<TInt> appLocales;
@@ -2256,43 +2355,43 @@
         {
         aRequiredLocale = User::Language();
         }
-    
-    
-    //Get the app language list.    
-    GetLocalesForAppIdL(appLocales,appUid);
+        
+    //Get the app language list.
+    CleanupClosePushL(appLocales);
+    GetLocalesForAppIdL(appLocales,aAppUid);
   
     //Check if current language is supported by application
-    if ( KErrNotFound!=appLocales.Find((TInt)aRequiredLocale))
+    if (KErrNotFound != appLocales.Find((TInt)aRequiredLocale))
         {
         aFinalAppLocale = aRequiredLocale;
         isLocalizedInfoPresent = ETrue;
-		appLocales.Close();
+        CleanupStack::PopAndDestroy(&appLocales);
         return isLocalizedInfoPresent;
         }
+    
     //Get the nearest languages corresponding to the required language.
     BaflUtils::GetEquivalentLanguageList(aRequiredLocale, equivalentLanguages);
-    
-    
+        
     //Identify the app language corresponding to the nearest required language.
     if(0 != appLocales.Count()) 
         {
         while(1)
-            {                                      
-            if(equivalentLanguages[index] != ELangNone && appLocales.FindInOrder((TInt)equivalentLanguages[index]) != KErrNotFound)
+            {
+            if(equivalentLanguages[index] == ELangNone)
+                {
+                break;
+                }
+            
+            if(appLocales.FindInOrder((TInt)equivalentLanguages[index]) != KErrNotFound)
                 {
                 aFinalAppLocale = equivalentLanguages[index];
                 isLocalizedInfoPresent = ETrue;
                 break;
-                }
-                
-            if(equivalentLanguages[index] == ELangNone)
-                {
-                break;
-                }
+                }           
 
             index++;
-
-            } 
+            }
+        
         // If a matching language is not found in the list of equivalent languages,
         // we check if a default locale (KNonLocalized) is present.
         if(!isLocalizedInfoPresent && appLocales[0] == (TInt)KNonLocalized)
@@ -2300,8 +2399,9 @@
             isLocalizedInfoPresent = ETrue;
             aFinalAppLocale = KNonLocalized;
             }        
-        } 
-    appLocales.Close();
+        }
+    
+    CleanupStack::PopAndDestroy(&appLocales);
     return isLocalizedInfoPresent;
     }
 
@@ -2585,6 +2685,7 @@
 
 CStatement* CScrRequestImpl::OpenComponentViewL(CComponentFilter& aFilter, RArray<TComponentId>& aComponentFilterSuperset, TBool& aFilterSupersetInUse) const
 	{
+	DEBUG_PRINTF(_L8("Opening Component View."));
 	aComponentFilterSuperset.Reset();
 	aFilterSupersetInUse = EFalse;
 
@@ -2683,6 +2784,7 @@
 
 void CScrRequestImpl::AddComponentEntryLocalizablesL(TComponentId aComponentId, CComponentEntry& aEntry, TLanguage aLocale, const CComponentFilter& aFilter) const
 	{
+	DEBUG_PRINTF(_L8("Adding  Component Entry Localizables."));
 	if(aFilter.iSetFlag & (CComponentFilter::EName | CComponentFilter::EVendor))
 		{ // If a name or vendor is specified in the filter, the locale is ignored
 		  // and the provided names are retrieved from the ComponentLocalizables table.
@@ -2705,6 +2807,7 @@
 
 TBool CScrRequestImpl::IsSoftwareTypeExistingL(TInt aSoftwareTypeId) const
 	{
+	DEBUG_PRINTF(_L8("verify Software Type Exists."));
 	TBool result = EFalse;
 	_LIT(KComponentSoftwareType, "SELECT SoftwareTypeId FROM SoftwareTypes WHERE SoftwareTypeId=?;");	
 		
@@ -3558,6 +3661,7 @@
 
 void CScrRequestImpl::GetAppUidsL(CAppInfoViewSubsessionContext* aSubsessionContext, TBool aScreenModePresent) const
     {
+	DEBUG_PRINTF(_L8("Returning the App Uid."));
     CStatement* stmt;
     _LIT(KAllAppIds,"SELECT AppUid from AppRegistrationInfo"); 
     stmt = iDbHandle->PrepareStatementLC(KAllAppIds);
@@ -3572,7 +3676,7 @@
         	{
             if(DoesAppWithScreenModeExistL(appUidWithLocaleInfo.iAppUid, aSubsessionContext->iScreenMode, appUidWithLocaleInfo.iLocale))
                 {
-                 aSubsessionContext->iApps.AppendL(appUidWithLocaleInfo);
+                aSubsessionContext->iApps.AppendL(appUidWithLocaleInfo);
                 }
         	}
         
@@ -3586,6 +3690,7 @@
         
 void CScrRequestImpl::GetEmbeddableAppUidsL(CAppInfoViewSubsessionContext* aSubsessionContext, TBool aScreenModePresent) const
     {
+	DEBUG_PRINTF(_L8("Returning the Embeddable App Uids."));
     CStatement *stmt1;
     _LIT (KGetAppIdWithEmbeddability, "SELECT DISTINCT AppUid from AppRegistrationInfo where Embeddable IN(1,2)"); 
     stmt1 = iDbHandle->PrepareStatementLC(KGetAppIdWithEmbeddability);
@@ -3600,7 +3705,7 @@
         	{
             if(DoesAppWithScreenModeExistL(appUidWithLocaleInfo.iAppUid, aSubsessionContext->iScreenMode, appUidWithLocaleInfo.iLocale))
                 {
-                 aSubsessionContext->iApps.AppendL(appUidWithLocaleInfo);
+                aSubsessionContext->iApps.AppendL(appUidWithLocaleInfo);
                 }
         	}
         else
@@ -3629,7 +3734,7 @@
         	{
             if(DoesAppWithScreenModeExistL(appUidWithLocaleInfo.iAppUid, aSubsessionContext->iScreenMode, appUidWithLocaleInfo.iLocale))
                 {
-                 aSubsessionContext->iApps.AppendL(appUidWithLocaleInfo);
+                aSubsessionContext->iApps.AppendL(appUidWithLocaleInfo);
                 }
         	}
         else
@@ -3660,7 +3765,7 @@
                 	{
                     if(DoesAppWithScreenModeExistL(appUidWithLocaleInfo.iAppUid, aSubsessionContext->iScreenMode, appUidWithLocaleInfo.iLocale))
                         {
-                         aSubsessionContext->iApps.AppendL(appUidWithLocaleInfo);
+                        aSubsessionContext->iApps.AppendL(appUidWithLocaleInfo);
                         }
                 	}
                 else
@@ -3694,7 +3799,7 @@
             	{
                 if(DoesAppWithScreenModeExistL(appUidWithLocaleInfo.iAppUid, aSubsessionContext->iScreenMode, appUidWithLocaleInfo.iLocale))
                     {
-                     aSubsessionContext->iApps.AppendL(appUidWithLocaleInfo);
+                    aSubsessionContext->iApps.AppendL(appUidWithLocaleInfo);
                     }
             	}
             else
@@ -3741,7 +3846,7 @@
 
 void CScrRequestImpl::OpenAppInfoViewL(CAppInfoFilter& aFilter, CAppInfoViewSubsessionContext* aSubsessionContext)
     {
-               
+	DEBUG_PRINTF(_L8("Opening App Info View."));			
     switch(aFilter.iSetFlag)
         {
         
@@ -3907,11 +4012,12 @@
         }
           
     CleanupStack::PopAndDestroy(regInfo);
-    DEBUG_PRINTF(_L8("Adding the application details into SCR done "));
+    DEBUG_PRINTF(_L8("Added the application details into SCR successfully "));
     }
 
 void CScrRequestImpl::AddFileOwnershipInfoL(TUid aAppUid, const TDesC& aFileName)
     {
+	DEBUG_PRINTF(_L8("Adding the File Ownership Info details into SCR"));
     if(aAppUid == KNullUid || !aFileName.CompareF(KNullDesC()))
     	{
     	DEBUG_PRINTF(_L8("Mandatory values not provided."));
@@ -3925,6 +4031,7 @@
 
 void CScrRequestImpl::AddLocalizableAppInfoL(TUid aAppUid, Usif::CLocalizableAppInfo* aLocalizableAppInfoEntry)
     {
+	DEBUG_PRINTF(_L8("Adding the Localizable App Info details into SCR"));
 	TInt captionAndIconInfoId = 0;
 	if(NULL != aLocalizableAppInfoEntry->iCaptionAndIconInfo)
 	    {
@@ -3943,6 +4050,7 @@
 
 void CScrRequestImpl::AddViewDataL(TInt aLocalAppInfoId, Usif::CAppViewData* aViewDataEntry)
     {
+	DEBUG_PRINTF(_L8("Adding the ViewData details into SCR"));
 	if(aLocalAppInfoId == 0 || aViewDataEntry->Uid() == KNullUid )
 		{
 		DEBUG_PRINTF(_L8("Mandatory values not provided."));
@@ -3962,6 +4070,7 @@
 
 TInt CScrRequestImpl::AddCaptionAndIconInfoL(Usif::CCaptionAndIconInfo* aCaptionAndIconEntry)
     {
+	DEBUG_PRINTF(_L8("Adding the Caption And Icon Info details into SCR"));
 	_LIT(KCaptionAndIconInfo,"INSERT INTO CaptionAndIconInfo(Caption, NumberOfIcons, IconFile) VALUES(?,?,?);");
     TInt numberOfValues = 3;
     ExecuteStatementL(KCaptionAndIconInfo(), numberOfValues, EValueString, &(aCaptionAndIconEntry->Caption()), EValueInteger, aCaptionAndIconEntry->NumOfAppIcons(), EValueString, &(aCaptionAndIconEntry->IconFileName()));
@@ -3970,6 +4079,7 @@
 
 void CScrRequestImpl::AddServiceInfoL(TUid aAppUid, Usif::CServiceInfo* aAppServiceInfoEntry)
     {
+	DEBUG_PRINTF(_L8("Adding the Service Info details into SCR"));
     if(aAppUid == KNullUid)
     	{
     	DEBUG_PRINTF(_L8("Values for app uid is absent"));
@@ -3996,6 +4106,7 @@
 
 void CScrRequestImpl::AddServiceDataTypeL(TInt aServiceUid, Usif::CDataType* aDataTypeEntry)
 	{
+	DEBUG_PRINTF(_L8("Adding the Service Data Type details into SCR"));
     if(!((aDataTypeEntry->Type()).CompareF(KNullDesC())))
     	{
     	DEBUG_PRINTF(_L8("Values for service uid or type is absent"));
@@ -4008,6 +4119,7 @@
 
 void CScrRequestImpl::AddPropertyL(TUid aAppUid, Usif::CPropertyEntry* aAppPropertiesEntry)
     {
+	DEBUG_PRINTF(_L8("Adding the Property details into SCR"));
     if(aAppUid == KNullUid || !((aAppPropertiesEntry->PropertyName().CompareF(KNullDesC()))))
     	{
     	DEBUG_PRINTF(_L8("Property name is absent and hence cannot be entered into the DB."));
@@ -4067,9 +4179,10 @@
 		}
     }
 
-
 void CScrRequestImpl::AddOpaqueDataL(TUid aAppUid, Usif::COpaqueData* aOpaqueDataEntry, TUid aServiceUid)
     {
+	DEBUG_PRINTF(_L8("Adding the Opaque Data details into SCR"));
+    const TInt KMaxOpaqueDataLength = 1024;
     /* AppUid cannot be NULL since this function is invoked from AddApplicationEntryL */ 
     __ASSERT_DEBUG(aAppUid != TUid::Null(), User::Leave(KErrArgument));
     
@@ -4081,7 +4194,7 @@
     stmt->BindStrL(2, _L("OpaqueData"));
     stmt->BindIntL(3, (TInt)aOpaqueDataEntry->iLanguage);
     stmt->BindIntL(4, aServiceUid.iUid);
-    stmt->BindBinaryL(5, *(aOpaqueDataEntry->iOpaqueData));
+    stmt->BindBinaryL(5, *(aOpaqueDataEntry->iOpaqueData), KMaxOpaqueDataLength);
     stmt->ExecuteStatementL();
     CleanupStack::PopAndDestroy(stmt);
     }
@@ -4134,6 +4247,7 @@
 
 void CScrRequestImpl::DeleteApplicationEntryL(const RMessage2& aMessage)
     {
+	DEBUG_PRINTF(_L8("Deleting Application Entry details from SCR"));
     TInt applicationUid = aMessage.Int0();
     DeleteApplicationEntryInternalL(applicationUid);
     }
@@ -4183,6 +4297,7 @@
 
 CCaptionAndIconInfo* CScrRequestImpl::GetCaptionAndIconInfoL(TInt aCaptionAndIconId) const
     {
+	DEBUG_PRINTF2(_L8("Returning the Caption And Icon Info associated with CaptionAndIconId (%d) from SCR."), aCaptionAndIconId);
     _LIT(KGetLocalizedCaptionAndIconInfo, "Select Caption,NumberOfIcons,Iconfile from CaptionAndIconInfo where CaptionAndIconId = ?");
     CStatement *stmt = iDbHandle->PrepareStatementLC(KGetLocalizedCaptionAndIconInfo);
     stmt->BindIntL(1, aCaptionAndIconId);
@@ -4395,9 +4510,7 @@
         DEBUG_PRINTF2(_L("The Service Uid for this App is 0x%x "), serviceInfo->iUid);
         if(serviceInfo->iUid.iUid)
             {
-            TLanguage storedLanguage = aLanguage;
-            GetNearestAppLanguageL(aLanguage, aAppUid, storedLanguage);
-            GetOpaqueDataArrayL(aAppUid, serviceInfo->iUid, serviceInfo->iOpaqueDataArray, storedLanguage);
+            GetOpaqueDataArrayL(aAppUid, serviceInfo->iUid, serviceInfo->iOpaqueDataArray, aLanguage);
             }
 
         //populate the data types for a service Id 
@@ -4416,10 +4529,10 @@
         {
         Usif::CLocalizableAppInfo* localizedAppInfo = NULL;        
         _LIT(KGetServiceInfo, "Select ShortCaption,GroupName,Locale,CaptionAndIconId from LocalizableAppInfo where AppUid = ? and Locale = ?");
-       CStatement *stmt = iDbHandle->PrepareStatementLC(KGetServiceInfo);
-       stmt->BindIntL(1, aAppUid.iUid);
-       stmt->BindIntL(2, (TInt)storedLanguage);
-       if(stmt->ProcessNextRowL())
+        CStatement *stmt = iDbHandle->PrepareStatementLC(KGetServiceInfo);
+        stmt->BindIntL(1, aAppUid.iUid);
+        stmt->BindIntL(2, (TInt)storedLanguage);
+        if(stmt->ProcessNextRowL())
            {
            localizedAppInfo = Usif::CLocalizableAppInfo::NewLC();
            DeleteObjectZ(localizedAppInfo->iShortCaption);
@@ -4443,7 +4556,7 @@
            }
         CleanupStack::PopAndDestroy(stmt);
         }
-    else
+        else
         {
         DEBUG_PRINTF(_L8("No Nearest locale found for AppUid %d in the SCR"));
         }    
@@ -4451,9 +4564,7 @@
 
 void CScrRequestImpl::GetAppRegOpaqueDataL(CApplicationRegistrationData& aApplicationRegistration, TUid aAppUid, TLanguage aLanguage) const
     {
-    TLanguage storedLanguage = aLanguage;
-    GetNearestAppLanguageL(aLanguage, aAppUid, storedLanguage);
-    GetOpaqueDataArrayL(aAppUid, TUid::Null(), aApplicationRegistration.iOpaqueDataArray, storedLanguage);
+    GetOpaqueDataArrayL(aAppUid, TUid::Null(), aApplicationRegistration.iOpaqueDataArray, aLanguage);
     }
 
 void CScrRequestImpl::NextApplicationRegistrationInfoSizeL(const RMessage2& aMessage, CApplicationRegistrationData*& aApplicationRegistration, CAppRegistrySubsessionContext*  aSubsessionContext)
@@ -4668,9 +4779,7 @@
             CServiceInfo* serviceInfo = CServiceInfo::NewLC();
             serviceInfo->iUid = TUid::Uid(stmt->IntColumnL(1));
 
-            TLanguage finalLocale = KUnspecifiedLocale;
-            GetNearestAppLanguageL(aLocale, aAppUid, finalLocale);
-            GetOpaqueDataArrayL(aAppUid, serviceInfo->iUid, serviceInfo->iOpaqueDataArray, finalLocale);
+            GetOpaqueDataArrayL(aAppUid, serviceInfo->iUid, serviceInfo->iOpaqueDataArray, aLocale);
             GetDataTypesL(serviceInfo->iDataTypes, stmt->IntColumnL(0));
             aServiceInfoArray.AppendL(serviceInfo);
             CleanupStack::Pop(serviceInfo);
@@ -4697,9 +4806,7 @@
             
             serviceInfo->iUid = TUid::Uid(stmt->IntColumnL(1));
             TUid appUid = TUid::Uid(stmt->IntColumnL(2));
-            TLanguage finalLocale = KUnspecifiedLocale;
-            GetNearestAppLanguageL(aLocale, appUid, finalLocale);
-            GetOpaqueDataArrayL(appUid, serviceInfo->iUid, serviceInfo->iOpaqueDataArray, finalLocale);
+            GetOpaqueDataArrayL(appUid, serviceInfo->iUid, serviceInfo->iOpaqueDataArray, aLocale);
             GetDataTypesL(serviceInfo->iDataTypes, stmt->IntColumnL(0));
             
             aServiceInfoArray.AppendL(serviceInfo);
@@ -4728,9 +4835,7 @@
             serviceInfo->iUid = TUid::Uid(stmt->IntColumnL(0));
             
             TUid appUid = TUid::Uid(stmt->IntColumnL(3));
-            TLanguage finalLocale = KUnspecifiedLocale;
-            GetNearestAppLanguageL(aLocale, appUid, finalLocale);
-            GetOpaqueDataArrayL(appUid, serviceInfo->iUid, serviceInfo->iOpaqueDataArray, finalLocale);
+            GetOpaqueDataArrayL(appUid, serviceInfo->iUid, serviceInfo->iOpaqueDataArray, aLocale);
             TInt priority(stmt->IntColumnL(1));
             TPtrC datatype(stmt->StrColumnL(2));
             CDataType* dataType = CDataType::NewL(priority,datatype);
@@ -4763,9 +4868,7 @@
             CServiceInfo* serviceInfo = CServiceInfo::NewLC();
             
             serviceInfo->iUid = TUid::Uid(stmt->IntColumnL(1));
-            TLanguage finalLocale = KUnspecifiedLocale;
-            GetNearestAppLanguageL(aLocale, aAppUid, finalLocale);
-            GetOpaqueDataArrayL(aAppUid, serviceInfo->iUid, serviceInfo->iOpaqueDataArray, finalLocale);
+            GetOpaqueDataArrayL(aAppUid, serviceInfo->iUid, serviceInfo->iOpaqueDataArray, aLocale);
             GetDataTypesL(serviceInfo->iDataTypes, stmt->IntColumnL(0));
 
             aServiceInfoArray.AppendL(serviceInfo);
@@ -4778,19 +4881,22 @@
 
 void CScrRequestImpl::GetOpaqueDataArrayL(TUid aAppUid, TUid aServiceUid, RPointerArray<COpaqueData>& aOpaqueDataArray, TLanguage aLanguage) const
     {
+    TLanguage finalAppLocale;
+    GetNearestAppLanguageForOpaqueDataL(aLanguage, aAppUid, aServiceUid, finalAppLocale);
+            
     _LIT(KOpaqueData, "SELECT StrValue FROM AppProperties where Name = ? AND ServiceUid = ?  AND AppUid = ? AND Locale = ?");
     CStatement *stmt = iDbHandle->PrepareStatementLC(KOpaqueData);
     
     stmt->BindStrL(1, _L("OpaqueData"));
     stmt->BindIntL(2, aServiceUid.iUid);
     stmt->BindIntL(3, aAppUid.iUid);
-    stmt->BindIntL(4, (TInt)aLanguage);
+    stmt->BindIntL(4, (TInt)finalAppLocale);
     
     aOpaqueDataArray.ResetAndDestroy();
     while (stmt->ProcessNextRowL())
         {
         Usif::COpaqueData* opaqueData = Usif::COpaqueData::NewLC();
-        opaqueData->iLanguage = aLanguage;
+        opaqueData->iLanguage = finalAppLocale;
         DeleteObjectZ(opaqueData->iOpaqueData);
         opaqueData->iOpaqueData = stmt->BinaryColumnL(0).AllocL();
         DEBUG_PRINTF2(_L("Locale for opaque entry for this App is %d "), opaqueData->iLanguage);
@@ -4922,6 +5028,7 @@
 
 void CScrRequestImpl::GetAppPropertiesInfoL(CApplicationRegistrationData& aApplicationRegistration,TUid aAppUid, TLanguage aLanguage)
     {
+	DEBUG_PRINTF2(_L8("returning App Properties Info for AppUid %d in the SCR"), aAppUid);
     TLanguage appSupportedLanguage;
     if(GetNearestAppLanguageL(aLanguage, aAppUid, appSupportedLanguage))
         {
@@ -4978,6 +5085,7 @@
 
 void CScrRequestImpl::GenerateNonNativeAppUidL(const RMessage2& aMessage)
     {    
+	DEBUG_PRINTF(_L8("Generating Non Native AppUid"));
     //Get access to the repository instance.
     CScrRepository* scrRepository = CScrRepository::GetRepositoryInstanceL();
     
--- a/installationservices/swcomponentregistry/test/tscr/inc/tscrstep.h	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/test/tscr/inc/tscrstep.h	Fri May 14 15:58:48 2010 +0300
@@ -117,25 +117,24 @@
 	// Read Application info filter from config file
 	void ReadAppInfoFilterFromConfigL(Usif::CAppInfoFilter** aFilter);
 	Usif::TAppRegInfo* CScrTestStep::GetAppInfoFromConfigL(TBool aIsSingle , TInt aIndex=0 );
+	
 	void StartTimer();
-	
-	
+	void StopTimerAndPrintResultL();
+	void PrintPerformanceLog(TTime aTime);
+
+private:
+	TInt ReadSharedComponentIdL(TInt aOffset);	
+
 protected:
 	CScrTestServer& iParent;
 	Usif::RSoftwareComponentRegistry iScrSession;
-
-private:
-	TInt ReadSharedComponentIdL(TInt aOffset);
-	void StopTimerAndPrintResultL();
-	void PrintPerformanceLog(TTime aTime);
-
-protected:
+	TBool iIsPerformanceTest;
+	
 	// For plugin management test cases, the time is measured externally because they are performed via another accessor server (scr accessor).
 	// The actual test time is measured on the scr accessor server side and returned to the test code.
 	TInt iTimeMeasuredExternally;
-	
-private:
-	TBool iIsPerformanceTest;
+		
+private:	
 	TTime iStartTime;
 	};
 
Binary file installationservices/swcomponentregistry/test/tscr/scripts/data/scr_large.db has changed
Binary file installationservices/swcomponentregistry/test/tscr/scripts/data/scr_medium.db has changed
Binary file installationservices/swcomponentregistry/test/tscr/scripts/data/scr_small.db has changed
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swcomponentregistry/test/tscr/scripts/tscr_app_performance_cases.script	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,87 @@
+//
+// 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 the License "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: 
+// This script implements SCR Applicaiton Registry Performance Tests.
+//
+
+PRINT Run SCR Applicaiton Registry Performance Tests
+
+LOAD_SUITE tscr
+LOAD_SUITE tscrapparc
+// Load the event logger test suite
+LOAD_SUITE EventLogServer -SharedData
+
+// Load SCR test suite
+LOAD_SUITE tscr -SharedData // SharedData is used for sharing the componentid between test steps
+SHARED_DATA z:\tusif\tscr\tscr_performance.ini shared_data
+
+RUN_TEST_STEP 100 tscr SCRDeleteDbFile z:\tusif\tscr\tscr.ini db_file
+
+//! @SYMTestCaseID				APPINSTALL-SCR-APP-PERFORMANCE-0001
+//! @SYMTestCaseDesc 			The time taken to add a minimal appregistration data (without localized info and opaque data).
+//! SYMTestPerformanceTarget	100ms
+START_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0001
+RUN_TEST_STEP 100 tscr Performance-SCRAddApplicationEntry z:\tusif\tscr\tscr_performance.ini add_minimal_app_reg_info
+RUN_TEST_STEP 100 tscrapparc Performance-ScrGetApplicationRegistrationView z:\tusif\tscr\tscr_performance.ini get_add_minimal_app_reg_info
+END_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0001
+
+//! @SYMTestCaseID				APPINSTALL-SCR-APP-PERFORMANCE-0002
+//! @SYMTestCaseDesc 			The time taken to add a minimal appregistration data (without localized info).
+//! SYMTestPerformanceTarget	150ms
+START_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0002
+RUN_TEST_STEP 100 tscr Performance-SCRAddApplicationEntry z:\tusif\tscr\tscr_performance.ini add_minimal_app_reg_info_with_opaquedata
+RUN_TEST_STEP 100 tscrapparc Performance-ScrGetApplicationRegistrationView z:\tusif\tscr\tscr_performance.ini get_add_minimal_app_reg_info_with_opaquedata
+END_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0002
+
+//! @SYMTestCaseID				APPINSTALL-SCR-APP-PERFORMANCE-0003
+//! @SYMTestCaseDesc 			The time taken to add an appregistration data (without localized info and opaque data).
+//! SYMTestPerformanceTarget	150ms
+START_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0003
+RUN_TEST_STEP 100 tscr Performance-SCRAddApplicationEntry z:\tusif\tscr\tscr_performance.ini add_app_reg_info_no_localized
+RUN_TEST_STEP 100 tscrapparc Performance-ScrGetApplicationRegistrationView z:\tusif\tscr\tscr_performance.ini get_add_app_reg_info_no_localized
+END_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0003
+
+//! @SYMTestCaseID				APPINSTALL-SCR-APP-PERFORMANCE-0004
+//! @SYMTestCaseDesc 			The time taken to add an appregistration data (without localized info).
+//! SYMTestPerformanceTarget	200ms
+START_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0004
+RUN_TEST_STEP 100 tscr Performance-SCRAddApplicationEntry z:\tusif\tscr\tscr_performance.ini add_app_reg_info_no_localized_with_opaquedata
+RUN_TEST_STEP 100 tscrapparc Performance-ScrGetApplicationRegistrationView z:\tusif\tscr\tscr_performance.ini get_add_app_reg_info_no_localized_with_opaquedata
+END_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0004
+
+//! @SYMTestCaseID				APPINSTALL-SCR-APP-PERFORMANCE-0005
+//! @SYMTestCaseDesc 			The time taken to add an appregistration data with 1 localized info.
+//! SYMTestPerformanceTarget	200ms
+START_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0005
+RUN_TEST_STEP 100 tscr Performance-SCRAddApplicationEntry z:\tusif\tscr\tscr_performance.ini add_app_reg_info_1_localized
+RUN_TEST_STEP 100 tscrapparc Performance-ScrGetApplicationRegistrationView z:\tusif\tscr\tscr_performance.ini get_add_app_reg_info_1_localized
+END_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0005
+
+//! @SYMTestCaseID				APPINSTALL-SCR-APP-PERFORMANCE-0006
+//! @SYMTestCaseDesc 			The time taken to add an appregistration data with 2 localized info.
+//! SYMTestPerformanceTarget	200ms
+START_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0006
+RUN_TEST_STEP 100 tscr Performance-SCRAddApplicationEntry z:\tusif\tscr\tscr_performance.ini add_app_reg_info_2_localized
+RUN_TEST_STEP 100 tscrapparc Performance-ScrGetApplicationRegistrationView z:\tusif\tscr\tscr_performance.ini get_add_app_reg_info_2_localized
+END_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0006
+
+//! @SYMTestCaseID				APPINSTALL-SCR-APP-PERFORMANCE-0007
+//! @SYMTestCaseDesc 			The time taken to add an appregistration data with 5 localized info.
+//! SYMTestPerformanceTarget	200ms
+START_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0007
+RUN_TEST_STEP 100 tscr Performance-SCRAddApplicationEntry z:\tusif\tscr\tscr_performance.ini add_app_reg_info_5_localized
+RUN_TEST_STEP 100 tscrapparc Performance-ScrGetApplicationRegistrationView z:\tusif\tscr\tscr_performance.ini get_add_app_reg_info_5_localized
+END_TESTCASE APPINSTALL-SCR-APP-PERFORMANCE-0007
+
+//RUN_TEST_STEP 100 tscr SCRDeleteDbFile z:\tusif\tscr\tscr.ini db_file
--- a/installationservices/swcomponentregistry/test/tscr/scripts/tscr_appreginfo.ini	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/test/tscr/scripts/tscr_appreginfo.ini	Fri May 14 15:58:48 2010 +0300
@@ -1375,7 +1375,7 @@
 LocAppLanguage0=01
 LocGroupName0=tools01
 ViewDataCount0=2
-VwUid0=3333336001
+VwUid0=333336001
 VwScreenMode0=0
 VwCaption0=vc3333336001
 VwIconFileName0=vcf3333336001
@@ -1389,12 +1389,12 @@
 LocAppLanguage1=02
 LocGroupName1=tools02
 ViewDataCount1=2
-VwUid2=3333336003
+VwUid2=333336003
 VwScreenMode2=1
 VwCaption2=vc3333336003
 VwIconFileName2=vc3333336003
 VwNumberOfAppIcons2=0
-VwUid3=3333336004
+VwUid3=333336004
 VwScreenMode3=0
 VwCaption3=vc3333336004
 VwIconFileName3=vc3333336004
@@ -1425,7 +1425,7 @@
 LocAppLanguage0=01
 LocGroupName0=tools01
 ViewDataCount0=2
-VwUid0=3333336001
+VwUid0=333336001
 VwScreenMode0=0
 VwCaption0=vc3333336001
 VwIconFileName0=vcf3333336001
@@ -1439,12 +1439,12 @@
 LocAppLanguage1=02
 LocGroupName1=tools02
 ViewDataCount1=2
-VwUid2=3333336003
+VwUid2=333336003
 VwScreenMode2=1
 VwCaption2=vc3333336003
 VwIconFileName2=vc3333336003
 VwNumberOfAppIcons2=0
-VwUid3=3333336004
+VwUid3=333336004
 VwScreenMode3=0
 VwCaption3=vc3333336004
 VwIconFileName3=vc3333336004
--- a/installationservices/swcomponentregistry/test/tscr/scripts/tscr_performance.ini	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/test/tscr/scripts/tscr_performance.ini	Fri May 14 15:58:48 2010 +0300
@@ -377,3 +377,419 @@
 InstalledDrives=
 Version=
 
+[add_minimal_app_reg_info]
+MaxDuration=100
+IsMultiApp=True
+ComponentName=Component
+VendorName=OSSITeam
+SoftwareType=plain
+GlobalIdName=Component_Global
+AppUid=ABCD1234
+AppFile=minimal_app
+Attributes=4
+Hidden=1
+Embeddability=2
+NewFile=1
+Launch=1
+GroupName=Games
+DefaultScreenNumber=2
+
+[get_add_minimal_app_reg_info]
+MaxDuration=50
+Locale=01
+NoOfEntries=1
+AppRegAppUidCount=1
+AppRegAppUid0=ABCD1234
+AppRegEntriesConfigCount=1
+configsection0=add_minimal_app_reg_info
+
+[add_minimal_app_reg_info_with_opaquedata]
+MaxDuration=150
+IsMultiApp=True
+ComponentName=Component
+VendorName=OSSITeam
+SoftwareType=plain
+GlobalIdName=Component_Global
+AppUid=ABCD1235
+AppFile=minimal_app_with_opaquedata
+Attributes=4
+Hidden=1
+Embeddability=2
+NewFile=1
+Launch=1
+GroupName=Games
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=1
+AppOpaqueLocale0=0
+AppOpaqueData0=somedata_for_minimal_app_with_opaquedata
+
+[get_add_minimal_app_reg_info_with_opaquedata]
+MaxDuration=50
+Locale=04
+NoOfEntries=1
+AppRegAppUidCount=1
+AppRegAppUid0=ABCD1235
+AppRegEntriesConfigCount=1
+configsection0=add_minimal_app_reg_info_with_opaquedata
+
+[add_app_reg_info_no_localized]
+MaxDuration=150
+IsMultiApp=True
+ComponentName=Component
+VendorName=OSSITeam
+SoftwareType=plain
+GlobalIdName=Component_Global
+AppUid=ABCD1236
+AppFile=app_no_localizedata
+Attributes=4
+Hidden=1
+Embeddability=2
+NewFile=1
+Launch=1
+GroupName=Games
+DefaultScreenNumber=2
+OwnedFileCount=2
+FileName0=c:\some\path\file0
+FileName1=k:\some\path\file2
+ServiceInfoCount=2
+ServiceUid0=3ADE68B1
+ServiceDataTypeCount0=1
+ServiceDataTypePriority0=1
+ServiceDataType0=text/plain
+ServiceUid1=3ADE68B2
+ServiceDataTypeCount1=2
+ServiceDataTypePriority1=2
+ServiceDataType1=text/plain1
+ServiceDataType2=text/plain2
+LocalizableAppInfoCount=0
+
+[get_add_app_reg_info_no_localized]
+MaxDuration=50
+Locale=01
+NoOfEntries=1
+AppRegAppUidCount=1
+AppRegAppUid0=ABCD1236
+AppRegEntriesConfigCount=1
+configsection0=add_app_reg_info_no_localized
+
+[add_app_reg_info_no_localized_with_opaquedata]
+MaxDuration=200
+IsMultiApp=True
+ComponentName=Component
+VendorName=OSSITeam
+SoftwareType=plain
+GlobalIdName=Component_Global
+AppUid=ABCD1237
+AppFile=app_no_localizedata_with_opaquedata
+Attributes=4
+Hidden=1
+Embeddability=2
+NewFile=1
+Launch=1
+GroupName=Games
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=1
+AppOpaqueLocale0=0
+AppOpaqueData0=somedata_for_app_with_opaquedata
+OwnedFileCount=2
+FileName0=c:\some\path\file0
+FileName1=k:\some\path\file2
+ServiceInfoCount=2
+ServiceUid0=3ADE68B1
+ServiceDataTypeCount0=1
+ServiceDataTypePriority0=1
+ServiceDataType0=text/plain
+ServiceOpaqueDataInfoCount0=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=servicedata_3ADE68B1_for_app_with_opaquedata
+ServiceUid1=3ADE68B2
+ServiceDataTypeCount1=2
+ServiceDataTypePriority1=2
+ServiceDataType1=text/plain1
+ServiceDataType2=text/plain2
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=servicedata_3ADE68B2_for_app_with_opaquedata
+LocalizableAppInfoCount=0
+
+[get_add_app_reg_info_no_localized_with_opaquedata]
+MaxDuration=50
+Locale=04
+NoOfEntries=1
+AppRegAppUidCount=1
+AppRegAppUid0=ABCD1237
+AppRegEntriesConfigCount=1
+configsection0=add_app_reg_info_no_localized_with_opaquedata
+
+[add_app_reg_info_1_localized]
+MaxDuration=200
+IsMultiApp=True
+ComponentName=Component
+VendorName=OSSITeam
+SoftwareType=plain
+GlobalIdName=Component_Global
+AppUid=ABCD1238
+AppFile=app_1_localizedata
+Attributes=4
+Hidden=1
+Embeddability=2
+NewFile=1
+Launch=1
+GroupName=Games
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=1
+AppOpaqueLocale0=0
+AppOpaqueData0=somedata_for_app_with_opaquedata
+OwnedFileCount=2
+FileName0=c:\some\path\file0
+FileName1=k:\some\path\file2
+ServiceInfoCount=2
+ServiceUid0=3ADE68B1
+ServiceDataTypeCount0=1
+ServiceDataTypePriority0=1
+ServiceDataType0=text/plain
+ServiceOpaqueDataInfoCount0=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=servicedata_3ADE68B1_for_app_with_opaquedata
+ServiceUid1=3ADE68B2
+ServiceDataTypeCount1=2
+ServiceDataTypePriority1=2
+ServiceDataType1=text/plain1
+ServiceDataType2=text/plain2
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=servicedata_3ADE68B2_for_app_with_opaquedata
+LocalizableAppInfoCount=1
+LocShortCaption0=shortcaption0
+LocAppLanguage0=0
+LocGroupName0=Games0
+LocCaption0=caption0
+LocIconFileName0=some/iconfile
+LocNumberOfAppIcons0=2
+ViewDataCount0=1
+VwUid0=123456
+VwScreenMode0=0
+VwCaption0=someviewcaption
+VwIconFileName0=viewiconfile
+VwNumberOfAppIcons0=0
+
+[get_add_app_reg_info_1_localized]
+MaxDuration=50
+Locale=01
+NoOfEntries=1
+AppRegAppUidCount=1
+AppRegAppUid0=ABCD1238
+AppRegEntriesConfigCount=1
+configsection0=add_app_reg_info_1_localized
+
+[add_app_reg_info_2_localized]
+MaxDuration=200
+IsMultiApp=True
+ComponentName=Component
+VendorName=OSSITeam
+SoftwareType=plain
+GlobalIdName=Component_Global
+AppUid=ABCD1239
+AppFile=app_2_localizedata
+Attributes=4
+Hidden=1
+Embeddability=2
+NewFile=1
+Launch=1
+GroupName=Games
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=2
+AppOpaqueLocale0=0
+AppOpaqueData0=somedata_for_app_with_opaquedata
+AppOpaqueLocale1=1
+AppOpaqueData1=somedata_for_app_with_opaquedata_EN
+OwnedFileCount=2
+FileName0=c:\some\path\file0
+FileName1=k:\some\path\file2
+ServiceInfoCount=2
+ServiceUid0=3ADE68B1
+ServiceDataTypeCount0=1
+ServiceDataTypePriority0=1
+ServiceDataType0=text/plain
+ServiceOpaqueDataInfoCount0=2
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=servicedata_3ADE68B1_for_app_with_opaquedata
+ServiceOpaqueLocale1=1
+ServiceOpaqueData1=servicedata_3ADE68B1_for_app_with_opaquedata_EN
+ServiceUid1=3ADE68B2
+ServiceDataTypeCount1=2
+ServiceDataTypePriority1=2
+ServiceDataType1=text/plain1
+ServiceDataType2=text/plain2
+ServiceOpaqueDataInfoCount1=2
+ServiceOpaqueLocale2=0
+ServiceOpaqueData2=servicedata_3ADE68B2_for_app_with_opaquedata
+ServiceOpaqueLocale3=1
+ServiceOpaqueData3=servicedata_3ADE68B2_for_app_with_opaquedata_EN
+LocalizableAppInfoCount=2
+LocShortCaption0=shortcaption0
+LocAppLanguage0=0
+LocGroupName0=Games0
+LocCaption0=caption0
+LocIconFileName0=some/iconfile0
+LocNumberOfAppIcons0=24
+ViewDataCount0=1
+VwUid0=123456
+VwScreenMode0=0
+VwCaption0=someviewcaption0
+VwIconFileName0=viewiconfile0
+VwNumberOfAppIcons0=1
+LocShortCaption1=shortcaption1
+LocAppLanguage1=1
+LocGroupName1=Games1
+LocCaption1=caption1
+LocIconFileName1=some/iconfile1
+LocNumberOfAppIcons1=25
+ViewDataCount1=1
+VwUid1=456789
+VwScreenMode1=0
+VwCaption1=someviewcaption1
+VwIconFileName1=viewiconfile1
+VwNumberOfAppIcons1=12
+
+[get_add_app_reg_info_2_localized]
+MaxDuration=50
+Locale=01
+NoOfEntries=1
+AppRegAppUidCount=1
+AppRegAppUid0=ABCD1239
+AppRegEntriesConfigCount=1
+configsection0=add_app_reg_info_2_localized
+
+[add_app_reg_info_5_localized]
+MaxDuration=300
+IsMultiApp=True
+ComponentName=Component
+VendorName=OSSITeam
+SoftwareType=plain
+GlobalIdName=Component_Global
+AppUid=ABCD1240
+AppFile=app_5_localizedata
+Attributes=4
+Hidden=1
+Embeddability=2
+NewFile=1
+Launch=1
+GroupName=Games
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=5
+AppOpaqueLocale0=0
+AppOpaqueData0=somedata_for_app_with_opaquedata
+AppOpaqueLocale1=1
+AppOpaqueData1=somedata_for_app_with_opaquedata_EN
+AppOpaqueLocale2=2
+AppOpaqueData2=somedata_for_app_with_opaquedata_FR
+AppOpaqueLocale3=3
+AppOpaqueData3=somedata_for_app_with_opaquedata_GE
+AppOpaqueLocale4=4
+AppOpaqueData4=somedata_for_app_with_opaquedata_SP
+OwnedFileCount=2
+FileName0=c:\some\path\file0
+FileName1=k:\some\path\file2
+ServiceInfoCount=2
+ServiceUid0=3ADE68B1
+ServiceDataTypeCount0=1
+ServiceDataTypePriority0=1
+ServiceDataType0=text/plain
+ServiceOpaqueDataInfoCount0=5
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=servicedata_3ADE68B1_for_app_with_opaquedata
+ServiceOpaqueLocale1=1
+ServiceOpaqueData1=servicedata_3ADE68B1_for_app_with_opaquedata_EN
+ServiceOpaqueLocale2=2
+ServiceOpaqueData2=servicedata_3ADE68B1_for_app_with_opaquedata_FR
+ServiceOpaqueLocale3=3
+ServiceOpaqueData3=servicedata_3ADE68B1_for_app_with_opaquedata_GE
+ServiceOpaqueLocale4=4
+ServiceOpaqueData4=servicedata_3ADE68B1_for_app_with_opaquedata_SP
+ServiceUid1=3ADE68B2
+ServiceDataTypeCount1=2
+ServiceDataTypePriority1=2
+ServiceDataType1=text/plain1
+ServiceDataType2=text/plain2
+ServiceOpaqueDataInfoCount1=5
+ServiceOpaqueLocale5=0
+ServiceOpaqueData5=servicedata_3ADE68B2_for_app_with_opaquedata
+ServiceOpaqueLocale6=1
+ServiceOpaqueData6=servicedata_3ADE68B2_for_app_with_opaquedata_EN
+ServiceOpaqueLocale7=2
+ServiceOpaqueData7=servicedata_3ADE68B2_for_app_with_opaquedata_FR
+ServiceOpaqueLocale8=3
+ServiceOpaqueData8=servicedata_3ADE68B2_for_app_with_opaquedata_GE
+ServiceOpaqueLocale9=4
+ServiceOpaqueData9=servicedata_3ADE68B2_for_app_with_opaquedata_SP
+LocalizableAppInfoCount=5
+LocShortCaption0=shortcaption0
+LocAppLanguage0=0
+LocGroupName0=Games0
+LocCaption0=caption0
+LocIconFileName0=some/iconfile0
+LocNumberOfAppIcons0=24
+ViewDataCount0=1
+VwUid0=123456
+VwScreenMode0=0
+VwCaption0=someviewcaption0
+VwIconFileName0=viewiconfile0
+VwNumberOfAppIcons0=1
+LocShortCaption1=shortcaption1
+LocAppLanguage1=1
+LocGroupName1=Games1
+LocCaption1=caption1
+LocIconFileName1=some/iconfile1
+LocNumberOfAppIcons1=25
+ViewDataCount1=1
+VwUid1=456789
+VwScreenMode1=0
+VwCaption1=someviewcaption1
+VwIconFileName1=viewiconfile1
+VwNumberOfAppIcons1=12
+LocShortCaption2=shortcaption1
+LocAppLanguage2=2
+LocGroupName2=Games2
+LocCaption2=caption2
+LocIconFileName2=some/iconfile2
+LocNumberOfAppIcons1=26
+ViewDataCount2=1
+VwUid2=4567891
+VwScreenMode2=0
+VwCaption2=someviewcaption2
+VwIconFileName2=viewiconfile2
+VwNumberOfAppIcons2=122
+LocShortCaption3=shortcaption3
+LocAppLanguage3=3
+LocGroupName3=Games3
+LocCaption3=caption3
+LocIconFileName3=some/iconfile3
+LocNumberOfAppIcons3=23
+ViewDataCount3=1
+VwUid3=4567893
+VwScreenMode3=0
+VwCaption3=someviewcaption3
+VwIconFileName3=viewiconfile3
+VwNumberOfAppIcons3=123
+LocShortCaption4=shortcaption4
+LocAppLanguage4=4
+LocGroupName4=Games4
+LocCaption4=caption4
+LocIconFileName4=some/iconfile4
+LocNumberOfAppIcons4=254
+ViewDataCount4=4
+VwUid4=4567894
+VwScreenMode4=0
+VwCaption4=someviewcaption4
+VwIconFileName4=viewiconfile4
+VwNumberOfAppIcons4=12
+
+[get_add_app_reg_info_5_localized]
+MaxDuration=100
+Locale=01
+NoOfEntries=1
+AppRegAppUidCount=1
+AppRegAppUid0=ABCD1240
+AppRegEntriesConfigCount=1
+configsection0=add_app_reg_info_5_localized
--- a/installationservices/swcomponentregistry/test/tscr/source/appreginfosteps.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/test/tscr/source/appreginfosteps.cpp	Fri May 14 15:58:48 2010 +0300
@@ -31,7 +31,7 @@
 
 void CScrAddApplicationEntryStep::ImplTestStepPreambleL()
     {
-    CScrTestStep::ImplTestStepPreambleL();
+    User::LeaveIfError(iScrSession.Connect());    
     }
 
 void CScrAddApplicationEntryStep::ImplTestStepL()
@@ -67,8 +67,13 @@
 
 	INFO_PRINTF1(_L("Get reg info from config file."));
 	const CApplicationRegistrationData* appRegData = GetAppRegInfoFromConfigLC();
-	TRAPD(err, iScrSession.AddApplicationEntryL(compId, *appRegData));	
 	
+	if (iIsPerformanceTest)
+        StartTimer(); // Start the timer in the case of a performance tests        
+	TRAPD(err, iScrSession.AddApplicationEntryL(compId, *appRegData));
+    if (iIsPerformanceTest)
+        StopTimerAndPrintResultL(); // Stop the timer and analyze the time taken after performance tests
+        
 	if (err != KErrNone)
 	    {
 		if (newComponentAdded)
@@ -84,7 +89,7 @@
     
 void CScrAddApplicationEntryStep::ImplTestStepPostambleL()
     {
-    CScrTestStep::ImplTestStepPostambleL();
+   
     }
 
 
--- a/installationservices/swcomponentregistry/test/tscr/source/tscrserver.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/test/tscr/source/tscrserver.cpp	Fri May 14 15:58:48 2010 +0300
@@ -255,7 +255,6 @@
     else if (strippedStepName == KScrGetAppInfoStep)
         testStep = new CScrGetAppInfoStep(*this);
   	
-
 	if(performanceStep)
 		{
 		CScrTestStep *scrTestStep = dynamic_cast<CScrTestStep*>(testStep);
--- a/installationservices/swcomponentregistry/test/tscrapparc/inc/appreginfoapparcsteps.h	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/test/tscrapparc/inc/appreginfoapparcsteps.h	Fri May 14 15:58:48 2010 +0300
@@ -42,20 +42,20 @@
 public:
     CScrGetApplicationRegistrationViewSubsessionStep();
     ~CScrGetApplicationRegistrationViewSubsessionStep();
-protected:
     
-    Usif::RSoftwareComponentRegistry iScrSession;
+    void MarkAsPerformanceStep();
+    
+protected:    
     void ImplTestStepPreambleL();
     void ImplTestStepL();
-    void ImplTestStepPostambleL();
-    
+    void ImplTestStepPostambleL();   
     
     // Utility Functions
     void PrintErrorL(const TDesC& aMsg, TInt aErrNum,...);
     
     static void GenerateIndexedAttributeNameL(TDes& aInitialAttributeName, TInt aIndex);
     TBool GetUidFromConfig(const TDesC& aSectName, const TDesC& aKeyName, TUid& aUid);
-    //for reading data from ini file
+    // For reading data from ini file
     Usif::CApplicationRegistrationData* GetAppRegInfoFromConfigLC(HBufC* aConfigSection = NULL);
     void GetAppOwnedFilesL(RPointerArray<HBufC>& aOwnedFileArray, HBufC* aConfigSection = NULL);
     void GetAppServiceInfoL(RPointerArray<Usif::CServiceInfo>& aServiceInfoArray, HBufC* aConfigSection = NULL);
@@ -66,9 +66,8 @@
     CPropertyEntry* GetPropertyFromConfigLC(TBool aIsSingle, TInt aIndex, TBool aSupportLocalized, HBufC* aConfigsection = NULL);
     void GetAppPropertiesL(RPointerArray<Usif::CPropertyEntry>& aAppPropertyArray, TBool aSupportLocalized, HBufC* aConfigSection = NULL );
     void GetAppUidL(TUid& aAppUid, HBufC* aConfigsection = NULL);
-    
-    
-    //for comparing data 
+        
+    // For comparing data 
     TBool CompareApplicationRegistrationDataL(Usif::CApplicationRegistrationData *aActualData, Usif::CApplicationRegistrationData *aExpectedData);
     TBool CompareFileOwnershipInfo(RPointerArray<HBufC> aActualData, RPointerArray<HBufC> aExpectedData);
     TBool CompareServiceInfoL(RPointerArray<Usif::CServiceInfo> aActualData,  RPointerArray<Usif::CServiceInfo> aExpectedData);
@@ -77,9 +76,19 @@
     TBool CompareCaptionandIconInfo(const CCaptionAndIconInfo* aActualData, const CCaptionAndIconInfo* aExpectedData);
     TBool CompareViewData(RPointerArray<Usif::CAppViewData> aActualData,  RPointerArray<Usif::CAppViewData> aExpectedData);
     TBool CompareOpaqueDataL(RPointerArray<Usif::COpaqueData> aActualData,  RPointerArray<Usif::COpaqueData> aExpectedData);
-//private:
     
     void GetApplicationRegistrationDataFromConfigL(RPointerArray<Usif::CApplicationRegistrationData>& aEntries);
+    
+    void StartTimer();
+    void StopTimerAndPrintResultL();
+    void PrintPerformanceLog(TTime aTime);
+    
+protected:    
+    Usif::RSoftwareComponentRegistry iScrSession;
+    TBool iIsPerformanceTest;
+    
+private:    
+    TTime iStartTime;
     };
 
 
@@ -91,14 +100,13 @@
 public:
     CScrMultipleSubsessionsForAppRegistryViewStep();
     ~CScrMultipleSubsessionsForAppRegistryViewStep();
-protected:
-      
+    
+protected:      
     void ImplTestStepPreambleL();
     void ImplTestStepL();
     void ImplTestStepPostambleL();
     };
 
-
 #endif /* APPREGINFOAPPARCSTEPS_H_ */
 
 
--- a/installationservices/swcomponentregistry/test/tscrapparc/inc/tscrapparcserver.h	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/test/tscrapparc/inc/tscrapparcserver.h	Fri May 14 15:58:48 2010 +0300
@@ -37,6 +37,9 @@
     static CScrApparcTestServer* NewL();
     virtual CTestStep* CreateTestStep(const TDesC& aStepName);
     ~CScrApparcTestServer();
+
+private:
+    TBool IsPerformanceTestStep(const TDesC& aStepName, TPtrC& aStrippedName);
     };
     
 #endif /* TSCRAPPARCSERVER_H_ */
--- a/installationservices/swcomponentregistry/test/tscrapparc/source/appreginfoapparcsteps.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/test/tscrapparc/source/appreginfoapparcsteps.cpp	Fri May 14 15:58:48 2010 +0300
@@ -22,6 +22,50 @@
 #include <barsread.h> 
 using namespace Usif;
 
+void CScrGetApplicationRegistrationViewSubsessionStep::PrintPerformanceLog(TTime aTime)
+    {
+    TDateTime timer = aTime.DateTime();
+    INFO_PRINTF6(_L("%S,%d:%d:%d:%d"), &KPerformanceTestInfo(), timer.Hour(), timer.Minute(), timer.Second(), timer.MicroSecond());
+    }
+
+void CScrGetApplicationRegistrationViewSubsessionStep::StartTimer()
+    {
+    iStartTime.HomeTime();
+    PrintPerformanceLog(iStartTime);
+    }
+
+void CScrGetApplicationRegistrationViewSubsessionStep::StopTimerAndPrintResultL()
+    {
+    TTime endTime;
+    endTime.HomeTime();
+    PrintPerformanceLog(endTime);
+    
+    TTimeIntervalMicroSeconds duration = endTime.MicroSecondsFrom(iStartTime);
+    TInt actualDuration = I64INT(duration.Int64())/1000; // in millisecond
+        
+    TInt maxDuration = 0;
+    if(!GetIntFromConfig(ConfigSection(), KMaxDurationName, maxDuration))
+        {
+        ERR_PRINTF2(_L("%S could not be found in configuration."), &KMaxDurationName());
+        User::Leave(KErrNotFound);
+        }
+    else
+        {
+        INFO_PRINTF3(_L("%S,%d"), &KMaxTestCaseDuration(), maxDuration);
+        INFO_PRINTF3(_L("%S,%d"), &KActualTestCaseDuration(), actualDuration);
+        }
+    
+    if(actualDuration <= maxDuration)
+        {
+        INFO_PRINTF2(_L("This test meets performance requirement (Duration=%d)."), actualDuration);
+        }
+    else
+        {
+        ERR_PRINTF2(_L("This test does not meet performance requirement (Duration=%d)."), actualDuration);
+        SetTestStepResult(EFail);
+        }
+    }
+
 void CScrGetApplicationRegistrationViewSubsessionStep::GenerateIndexedAttributeNameL(TDes& aInitialAttributeName, TInt aIndex)
     {
     const TInt MAX_INT_STR_LEN = 8;
@@ -102,7 +146,6 @@
     delete configsection;
     }
     
-
 void CScrGetApplicationRegistrationViewSubsessionStep::GetAppServiceInfoL(
         RPointerArray<CServiceInfo>& aServiceInfoArray, HBufC* aConfigSection)
     {
@@ -902,6 +945,11 @@
     iScrSession.Close();
     }
 
+void CScrGetApplicationRegistrationViewSubsessionStep:: MarkAsPerformanceStep()
+    {
+    iIsPerformanceTest = ETrue;
+    }
+
 void CScrGetApplicationRegistrationViewSubsessionStep::ImplTestStepPreambleL()
     {
     User::LeaveIfError(iScrSession.Connect());
@@ -1014,8 +1062,14 @@
     while(1)
     {    
     actualAppRegData.ResetAndDestroy();
+    
+    if(iIsPerformanceTest)
+        StartTimer();
     TRAP(err,subSession.GetNextApplicationRegistrationInfoL(noOfEntries, actualAppRegData))
-    if(KErrNone != err)
+    if(iIsPerformanceTest)
+        StopTimerAndPrintResultL();
+    
+    if( (KErrNone != err) || (iIsPerformanceTest && (EFail == TestStepResult())) )
         {
         CleanupStack::Pop(1); //poping actualAppRegData 
         actualAppRegData.ResetAndDestroy();
--- a/installationservices/swcomponentregistry/test/tscrapparc/source/tscrapparcserver.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swcomponentregistry/test/tscrapparc/source/tscrapparcserver.cpp	Fri May 14 15:58:48 2010 +0300
@@ -83,16 +83,40 @@
     return err;
     }
 
+TBool CScrApparcTestServer::IsPerformanceTestStep(const TDesC& aStepName, TPtrC& aStrippedName)
+    {
+    _LIT(KPerformanceStepKeyWord, "Performance-");
+    if (KErrNotFound == aStepName.FindF(KPerformanceStepKeyWord()))
+        {
+        aStrippedName.Set(aStepName);
+        return EFalse;
+        }
+    
+    TInt len = KPerformanceStepKeyWord().Length();
+    aStrippedName.Set(aStepName.Mid(len));
+    return ETrue;
+    }
+
 CTestStep* CScrApparcTestServer::CreateTestStep(const TDesC& aStepName)    
     {    
     CTestStep* testStep = NULL;
     
-    if (aStepName == KScrApplicationRegistrationViewSubsessionStep)
-        testStep = new CScrGetApplicationRegistrationViewSubsessionStep();
-           
-    if (aStepName == KScrMultipleSubsessionsForAppRegistryViewStep)
+    TBool performanceStep = EFalse;
+    TPtrC strippedStepName;
+    performanceStep = IsPerformanceTestStep(aStepName, strippedStepName);
+    
+    if (strippedStepName == KScrApplicationRegistrationViewSubsessionStep)
+        testStep = new CScrGetApplicationRegistrationViewSubsessionStep();           
+    else if (strippedStepName == KScrMultipleSubsessionsForAppRegistryViewStep)
         testStep = new CScrMultipleSubsessionsForAppRegistryViewStep();
     
+    if (performanceStep && (strippedStepName == KScrApplicationRegistrationViewSubsessionStep))
+        {
+        // Currently we support performace testing for only CScrGetApplicationRegistrationViewSubsessionStep
+        CScrGetApplicationRegistrationViewSubsessionStep* scrTestStep = dynamic_cast<CScrGetApplicationRegistrationViewSubsessionStep*>(testStep);
+        scrTestStep->MarkAsPerformanceStep();
+        }
+    
     return testStep;
     }
 
--- a/installationservices/swi/group/bld.inf	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/group/bld.inf	Fri May 14 15:58:48 2010 +0300
@@ -65,7 +65,9 @@
 // swi.iby split into two part swi.iby and swiplugin.iby, swiplugin can be used by other team for implementing swi observer plug-in independently
 ../inc/swiplugin.iby /epoc32/rom/include/swiplugin.iby
 ../inc/switextshell.iby /epoc32/rom/include/switextshell.iby
+#ifndef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
 ../inc/sisregistry_5.3.txt z:/system/data/sisregistry_5.3.txt
+#endif
 
 // export certstoretobin
 ../source/certstoretobin/Swicertstoretobin.pl	/epoc32/tools/swicertstoretobin.pl
@@ -941,40 +943,40 @@
 ../test/trevocation/scripts/trevocationocsp_emulator.script	/epoc32/winscw/c/tswi/trevocation/scripts/trevocationocsp_emulator.script
 ../test/trevocation/scripts/trevocationocsp_emulator_pre.bat /epoc32/winscw/c/tswi/trevocation/scripts/trevocationocsp_emulator_pre.bat
 ../test/trevocation/scripts/trevocationocsp_emulator_post.bat /epoc32/winscw/c/tswi/trevocation/scripts/trevocationocsp_emulator_post.bat
-../test/trevocation/sisinteg/winscw/ocsp_01.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsp_01.sis
-../test/trevocation/sisinteg/winscw/ocsp_02.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsp_02.sis
-../test/trevocation/sisinteg/winscw/ocsp_03.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsp_03.sis
-../test/trevocation/sisinteg/winscw/ocsp_04.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsp_04.sis
-../test/trevocation/sisinteg/winscw/ocsp_05.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsp_05.sis
-../test/trevocation/sisinteg/winscw/certifiedsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/certifiedsignedval.sis
-../test/trevocation/sisinteg/winscw/certifiedsignedverisignval.sis /epoc32/winscw/c/tswi/trevocation/data/certifiedsignedverisignval.sis
-../test/trevocation/sisinteg/winscw/expresssignedval.sis /epoc32/winscw/c/tswi/trevocation/data/expresssignedval.sis
-../test/trevocation/sisinteg/winscw/allsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/allsignedval.sis
-../test/trevocation/sisinteg/winscw/selfsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/selfsignedval.sis
-../test/trevocation/sisinteg/winscw/certifiedsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/certifiedsignedrev.sis
-../test/trevocation/sisinteg/winscw/certifiedsignedverisignrev.sis /epoc32/winscw/c/tswi/trevocation/data/certifiedsignedverisignrev.sis
-../test/trevocation/sisinteg/winscw/expresssignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/expresssignedrev.sis
-../test/trevocation/sisinteg/winscw/allsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/allsignedrev.sis
-../test/trevocation/sisinteg/winscw/selfsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/selfsignedrev.sis
-../test/trevocation/sisinteg/winscw/ocsprevocation.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsprevocation.sis
-../test/trevocation/sisinteg/winscw/ocsprevocation-sub1.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsprevocation-sub1.sis
-../test/trevocation/sisinteg/armv5/ocsp_01.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsp_01.sis
-../test/trevocation/sisinteg/armv5/ocsp_02.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsp_02.sis
-../test/trevocation/sisinteg/armv5/ocsp_03.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsp_03.sis
-../test/trevocation/sisinteg/armv5/ocsp_04.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsp_04.sis
-../test/trevocation/sisinteg/armv5/certifiedsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/certifiedsignedval.sis
-../test/trevocation/sisinteg/armv5/certifiedsignedverisignval.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/certifiedsignedverisignval.sis
-../test/trevocation/sisinteg/armv5/expresssignedval.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/expresssignedval.sis
-../test/trevocation/sisinteg/armv5/allsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/allsignedval.sis
-../test/trevocation/sisinteg/armv5/selfsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/selfsignedval.sis
-../test/trevocation/sisinteg/armv5/certifiedsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/certifiedsignedrev.sis
-../test/trevocation/sisinteg/armv5/certifiedsignedverisignrev.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/certifiedsignedverisignrev.sis
-../test/trevocation/sisinteg/armv5/expresssignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/expresssignedrev.sis
-../test/trevocation/sisinteg/armv5/allsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/allsignedrev.sis
-../test/trevocation/sisinteg/armv5/selfsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/selfsignedrev.sis
+../test/trevocation/sisInteg/winscw/ocsp_01.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsp_01.sis
+../test/trevocation/sisInteg/winscw/ocsp_02.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsp_02.sis
+../test/trevocation/sisInteg/winscw/ocsp_03.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsp_03.sis
+../test/trevocation/sisInteg/winscw/ocsp_04.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsp_04.sis
+../test/trevocation/sisInteg/winscw/ocsp_05.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsp_05.sis
+../test/trevocation/sisInteg/winscw/certifiedsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/certifiedsignedval.sis
+../test/trevocation/sisInteg/winscw/certifiedsignedverisignval.sis /epoc32/winscw/c/tswi/trevocation/data/certifiedsignedverisignval.sis
+../test/trevocation/sisInteg/winscw/expresssignedval.sis /epoc32/winscw/c/tswi/trevocation/data/expresssignedval.sis
+../test/trevocation/sisInteg/winscw/allsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/allsignedval.sis
+../test/trevocation/sisInteg/winscw/selfsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/selfsignedval.sis
+../test/trevocation/sisInteg/winscw/certifiedsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/certifiedsignedrev.sis
+../test/trevocation/sisInteg/winscw/certifiedsignedverisignrev.sis /epoc32/winscw/c/tswi/trevocation/data/certifiedsignedverisignrev.sis
+../test/trevocation/sisInteg/winscw/expresssignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/expresssignedrev.sis
+../test/trevocation/sisInteg/winscw/allsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/allsignedrev.sis
+../test/trevocation/sisInteg/winscw/selfsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/selfsignedrev.sis
+../test/trevocation/sisInteg/winscw/ocsprevocation.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsprevocation.sis
+../test/trevocation/sisInteg/winscw/ocsprevocation-sub1.sis	/epoc32/winscw/c/tswi/trevocation/data/ocsprevocation-sub1.sis
+../test/trevocation/sisInteg/armv5/ocsp_01.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsp_01.sis
+../test/trevocation/sisInteg/armv5/ocsp_02.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsp_02.sis
+../test/trevocation/sisInteg/armv5/ocsp_03.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsp_03.sis
+../test/trevocation/sisInteg/armv5/ocsp_04.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsp_04.sis
+../test/trevocation/sisInteg/armv5/certifiedsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/certifiedsignedval.sis
+../test/trevocation/sisInteg/armv5/certifiedsignedverisignval.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/certifiedsignedverisignval.sis
+../test/trevocation/sisInteg/armv5/expresssignedval.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/expresssignedval.sis
+../test/trevocation/sisInteg/armv5/allsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/allsignedval.sis
+../test/trevocation/sisInteg/armv5/selfsignedval.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/selfsignedval.sis
+../test/trevocation/sisInteg/armv5/certifiedsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/certifiedsignedrev.sis
+../test/trevocation/sisInteg/armv5/certifiedsignedverisignrev.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/certifiedsignedverisignrev.sis
+../test/trevocation/sisInteg/armv5/expresssignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/expresssignedrev.sis
+../test/trevocation/sisInteg/armv5/allsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/allsignedrev.sis
+../test/trevocation/sisInteg/armv5/selfsignedrev.sis /epoc32/winscw/c/tswi/trevocation/data/armv5/selfsignedrev.sis
 
-../test/trevocation/sisinteg/armv5/ocsprevocation.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsprevocation.sis
-../test/trevocation/sisinteg/armv5/ocsprevocation-sub1.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsprevocation-sub1.sis
+../test/trevocation/sisInteg/armv5/ocsprevocation.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsprevocation.sis
+../test/trevocation/sisInteg/armv5/ocsprevocation-sub1.sis	/epoc32/winscw/c/tswi/trevocation/data/armv5/ocsprevocation-sub1.sis
 
 // legacy SIS file
 ../test/tsisfile/data/files/legacy.sis /epoc32/winscw/c/tswi/tsis/data/legacy.sis
--- a/installationservices/swi/source/backuprestore/backupsession.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/backuprestore/backupsession.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2005-2010 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 "Eclipse Public License v1.0"
@@ -184,7 +184,7 @@
 		
 		for (TInt i = 0; i < augmentationCount; ++i)
 			{			
-			RSisRegistryEntry augmentation;
+			RSisRegistryWritableEntry augmentation;
 			augmentation.OpenL(iSession, *packages[i]);
 			CleanupClosePushL(augmentation);
 			
@@ -212,7 +212,7 @@
 			// were backed up.
 			augmentationDrives.AppendL(augmentation.SelectedDriveL());
 			// Get the matching supported languages
-			entry.GetMatchingSupportedLanguagesL(matchingSupportedLanguagesArray);
+			augmentation.GetMatchingSupportedLanguagesL(matchingSupportedLanguagesArray);
 
 			// Appending ELangNone at the end as marker for the end of the language IDs
 			// as we also append the language ID's from other Augmentations
--- a/installationservices/swi/source/sislauncher/client/sislauncherclient.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/sislauncher/client/sislauncherclient.cpp	Fri May 14 15:58:48 2010 +0300
@@ -93,7 +93,6 @@
             }
         }    
     }
-
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
 EXPORT_C void RSisLauncherSession::Close()
     {	
@@ -106,7 +105,6 @@
     RSessionBase::Close();
     }
 #endif
-
 EXPORT_C void RSisLauncherSession::RunExecutableL(const TDesC& aFileName, TBool aWait)
     {
     TPckgC<TBool> wait(aWait);
@@ -410,7 +408,7 @@
     Usif::CApplicationRegistrationData* applicationData= Usif::CApplicationRegistrationData::NewLC();
     // Got the buffer, internalise the arrays
     RDesReadStream readStream(*appRegData);
-    CleanupClosePushL(readStream);
+    CleanupClosePushL(readStream);    
     applicationData->InternalizeL(readStream);
     CleanupStack::PopAndDestroy(&readStream); 
     CleanupStack::Pop(applicationData);
--- a/installationservices/swi/source/sislauncher/server/sislauncherserver.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/sislauncher/server/sislauncherserver.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2004-2010 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 "Eclipse Public License v1.0"
@@ -34,10 +34,10 @@
 #include "queueprocessor.h"
 
 #ifndef SWI_TEXTSHELL_ROM
-	#include <apmstd.h>
-	#include <apgcli.h>
-	#include <apgwgnam.h>
-	#include <apgtask.h>
+    #include <apmstd.h>
+    #include <apgcli.h>
+    #include <apgwgnam.h>
+    #include <apgtask.h>
 #endif
 
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
@@ -48,75 +48,75 @@
 using namespace Swi;
 
 CServer2* CSisLauncherServer::NewLC()
-	{
-	CSisLauncherServer* self=new(ELeave) CSisLauncherServer;
-	CleanupStack::PushL(self);
-	self->ConstructL();
-	return self;
-	}
+    {
+    CSisLauncherServer* self=new(ELeave) CSisLauncherServer;
+    CleanupStack::PushL(self);
+    self->ConstructL();
+    return self;
+    }
 
 CSisLauncherServer::~CSisLauncherServer()
-	{
+    {
 #ifndef SWI_TEXTSHELL_ROM
-	if (iBootMode != KTextShell)
-		{
-		iWsSession.Close();	
-		}
+    if (iBootMode != KTextShell)
+        {
+        iWsSession.Close(); 
+        }
 #endif
-	delete iShutdown;
-	delete iQueueProcessor;
-	CSecurityPolicy::ReleaseResource();
-	}
+    delete iShutdown;
+    delete iQueueProcessor;
+    CSecurityPolicy::ReleaseResource();
+    }
 
 void CSisLauncherServer::ConstructL()
-	{
-	StartL(KSisLauncherServerName);
-	iShutdown = new (ELeave) CSisLauncherServerShutdown;
-	iShutdown->ConstructL();
-	TInt connectErr = KErrNotFound;
+    {
+    StartL(KSisLauncherServerName);
+    iShutdown = new (ELeave) CSisLauncherServerShutdown;
+    iShutdown->ConstructL();
+    TInt connectErr = KErrNotFound;
 #ifndef SWI_TEXTSHELL_ROM
-	// Connect to Window Session
-	connectErr = iWsSession.Connect();
-	if (connectErr != KErrNotFound)
-		{
-		User::LeaveIfError(connectErr);
-		}
+    // Connect to Window Session
+    connectErr = iWsSession.Connect();
+    if (connectErr != KErrNotFound)
+        {
+        User::LeaveIfError(connectErr);
+        }
 #endif
-	if (connectErr == KErrNotFound)
-		{
-		// emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
-		iBootMode = KTextShell;
-		}
-	iQueueProcessor = CQueueProcessor::NewL(*this);
-	}
+    if (connectErr == KErrNotFound)
+        {
+        // emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
+        iBootMode = KTextShell;
+        }
+    iQueueProcessor = CQueueProcessor::NewL(*this);
+    }
 
 CSession2* CSisLauncherServer::NewSessionL(const TVersion&,const RMessage2&) const
-	{
-	return new(ELeave) CSisLauncherSession();
-	}
+    {
+    return new(ELeave) CSisLauncherSession();
+    }
 
 void CSisLauncherServer::AddSession()
-	{
-	++iSessionCount;
-	
-	DEBUG_PRINTF2(_L8("Sis Launcher Server - Adding Session (%d sessions total.)"), iSessionCount);
-	
-	CancelShutdown();	
-	}
+    {
+    ++iSessionCount;
+    
+    DEBUG_PRINTF2(_L8("Sis Launcher Server - Adding Session (%d sessions total.)"), iSessionCount);
+    
+    CancelShutdown();   
+    }
 
 void CSisLauncherServer::DropSession()
-	{
-	--iSessionCount;
-	
-	DEBUG_PRINTF2(_L8("Sis Launcher Server - Dropping Session (%d sessions total.)"), iSessionCount);
-	
-	if (0==iSessionCount && iShutdown)
-		{
-		DEBUG_PRINTF(_L8("Sis Launcher Server - Starting shutdown timer."));
-		// ignored if a long timer is active
-		iShutdown->StartShort(EFalse);
-		} 
-	}
+    {
+    --iSessionCount;
+    
+    DEBUG_PRINTF2(_L8("Sis Launcher Server - Dropping Session (%d sessions total.)"), iSessionCount);
+    
+    if (0==iSessionCount && iShutdown)
+        {
+        DEBUG_PRINTF(_L8("Sis Launcher Server - Starting shutdown timer."));
+        // ignored if a long timer is active
+        iShutdown->StartShort(EFalse);
+        } 
+    }
 /**
  * Cancels an existing shutdown timer before renabling with the long timeout. This is used to catch
  * the case where we need to allow ECOM to work before killing the server. ECOM should finish scanning 
@@ -125,449 +125,447 @@
  * resource file, we don't want to hang around forever waiting for an event that never comes.
  * */
 void CSisLauncherServer::LongServerShutdown()
-	{
-	DEBUG_PRINTF(_L8("Sis Launcher Server - Switching to long shutdown timer"));
-	if (iShutdown)
-		{
-		iShutdown->StartLong();
-		}
-	}
+    {
+    DEBUG_PRINTF(_L8("Sis Launcher Server - Switching to long shutdown timer"));
+    if (iShutdown)
+        {
+        iShutdown->StartLong();
+        }
+    }
 
 void CSisLauncherServer::CancelShutdown()
-	{
-	DEBUG_PRINTF(_L8("Sis Launcher Server - Cancelling shutdown timer"));
-		
-	if (iShutdown)
-		{
-		iShutdown->Cancel();
-		}	
-	}
+    {
+    DEBUG_PRINTF(_L8("Sis Launcher Server - Cancelling shutdown timer"));
+        
+    if (iShutdown)
+        {
+        iShutdown->Cancel();
+        }   
+    }
 
 void CSisLauncherServer::ShortServerShutdown()
-	{
-	DEBUG_PRINTF(_L8("Sis Launcher Server - Re-enabling short shutdown timer"));
-	if (0==iSessionCount && iShutdown)
-		{
-		DEBUG_PRINTF(_L8("Sis Launcher Server - Starting shutdown timer"));
-		iShutdown->StartShort(ETrue);
-		} 
-	}
+    {
+    DEBUG_PRINTF(_L8("Sis Launcher Server - Re-enabling short shutdown timer"));
+    if (0==iSessionCount && iShutdown)
+        {
+        DEBUG_PRINTF(_L8("Sis Launcher Server - Starting shutdown timer"));
+        iShutdown->StartShort(ETrue);
+        } 
+    }
 
-	// All functions require TCB capability
+    // All functions require TCB capability
 const TInt CSisLauncherServer::iRanges[iRangeCount] = 
-	{
-	0, // All connect attempts
+    {
+    0, // All connect attempts
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-	// Range of utility services for Post manufacture management of Layered Execution Environemnts
-	EParseSwTypeRegFile,
-	EUnregisterSifLauncherMimeTypes,
-	EAsyncParseResourceFileSize,
+    // Range of utility services for Post manufacture management of Layered Execution Environemnts
+    EParseSwTypeRegFile,
+    EUnregisterSifLauncherMimeTypes,
+    EAsyncParseResourceFileSize,
 #endif
-	ESeparatorEndAll,
-	};
+    ESeparatorEndAll,
+    };
 
 const TUint8 CSisLauncherServer::iElementsIndex[iRangeCount] = 
-	{
-	0, // Used by Client which is only swis and TCB is needed.
+    {
+    0, // Used by Client which is only swis and TCB is needed.
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-	1, // Utility services used by InstallServer
-	2, // Utility services used by SisRegistryServer
-	CPolicyServer::EAlwaysPass,
-#endif	
-	CPolicyServer::ENotSupported,
-	};
+    1, // Utility services used by InstallServer
+    2, // Utility services used by SisRegistryServer
+    CPolicyServer::EAlwaysPass,
+#endif  
+    CPolicyServer::ENotSupported,
+    };
 const CPolicyServer::TPolicyElement CSisLauncherServer::iPolicyElements[] = 
-	{
-	{_INIT_SECURITY_POLICY_C1(ECapabilityTCB), CPolicyServer::EFailClient},
+    {
+    {_INIT_SECURITY_POLICY_C1(ECapabilityTCB), CPolicyServer::EFailClient},
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-	{_INIT_SECURITY_POLICY_S0(KInstallServerUid), CPolicyServer::EFailClient},
-	{_INIT_SECURITY_POLICY_S0(KSisRegistryServerUid), CPolicyServer::EFailClient},	
+    {_INIT_SECURITY_POLICY_S0(KInstallServerUid), CPolicyServer::EFailClient},
+    {_INIT_SECURITY_POLICY_S0(KSisRegistryServerUid), CPolicyServer::EFailClient},  
 #endif
-	};
+    };
 
 const CPolicyServer::TPolicy CSisLauncherServer::iPolicy =
-	{
-	0,					//specifies all connect attempts need TCB
-	iRangeCount,
-	iRanges,
-	iElementsIndex,
-	iPolicyElements,
-	};
-	
-	
+    {
+    0,                  //specifies all connect attempts need TCB
+    iRangeCount,
+    iRanges,
+    iElementsIndex,
+    iPolicyElements,
+    };
+    
+    
 // shutdown timer
 
 CSisLauncherServerShutdown::~CSisLauncherServerShutdown()
-	{
-	Cancel();
-	}
+    {
+    Cancel();
+    }
 
 void CSisLauncherServerShutdown::RunL()
-	{
-	CActiveScheduler::Stop();
-	}
-	
+    {
+    CActiveScheduler::Stop();
+    }
+    
 void CSisLauncherServerShutdown::StartShort(TBool aCancelLongTimer)
-	{
-	if (iLongTimerActive & !aCancelLongTimer)
-		{
-		return;
-		}
-	else
-		{
-		Cancel();
-		iLongTimerActive=EFalse;
-		After(KSisLauncherShutdownDelay);
-		}
-	}
+    {
+    if (iLongTimerActive & !aCancelLongTimer)
+        {
+        return;
+        }
+    else
+        {
+        Cancel();
+        iLongTimerActive=EFalse;
+        After(KSisLauncherShutdownDelay);
+        }
+    }
 
 inline void CSisLauncherServerShutdown::StartLong()
-	{
-	Cancel();
-	iLongTimerActive=ETrue;
-	After(KSisLauncherLongShutdownDelay);
-	}
+    {
+    Cancel();
+    iLongTimerActive=ETrue;
+    After(KSisLauncherLongShutdownDelay);
+    }
 
 
 void CSisLauncherServer::RunExecutableL(const TDesC& aFileName, TBool aWait)
-	{
-	DEBUG_CODE_SECTION(
-		if (aWait)
-			{
-			DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to run executable by filename ('%S'), waiting for termination."),
-				&aFileName);
-			}
-		else
-			{
-			DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to run executable by filename ('%S'), not waiting for termination."),
-				&aFileName);
-			}
-	); // DEBUG_CODE_SECTION
-	
-	RProcess process;
-	_LIT(KNullArgs, "");
-	User::LeaveIfError(process.Create(aFileName, KNullArgs));
-	CleanupClosePushL(process);
-	
-	// Get the thread id of the main thread in the process
-	// From CApaExeRecognizer::RunL	
-	TFullName fullName(process.Name());
-	_LIT(KCCMain,"::Main");
-	fullName.Append(KCCMain);
-	TFindThread fT(fullName);
-	User::LeaveIfError(fT.Next(fullName));
-	RThread thread;
-	User::LeaveIfError(thread.Open(fT));
-	TThreadId threadId = thread.Id();
-	thread.Close();
-	process.Resume();
-	
-	CleanupStack::PopAndDestroy(&process);
-	if (aWait)
-		HandleShutdownL(threadId, ETrue);
-	}
+    {
+    DEBUG_CODE_SECTION(
+        if (aWait)
+            {
+            DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to run executable by filename ('%S'), waiting for termination."),
+                &aFileName);
+            }
+        else
+            {
+            DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to run executable by filename ('%S'), not waiting for termination."),
+                &aFileName);
+            }
+    ); // DEBUG_CODE_SECTION
+    
+    RProcess process;
+    _LIT(KNullArgs, "");
+    User::LeaveIfError(process.Create(aFileName, KNullArgs));
+    CleanupClosePushL(process);
+    
+    // Get the thread id of the main thread in the process
+    // From CApaExeRecognizer::RunL 
+    TFullName fullName(process.Name());
+    _LIT(KCCMain,"::Main");
+    fullName.Append(KCCMain);
+    TFindThread fT(fullName);
+    User::LeaveIfError(fT.Next(fullName));
+    RThread thread;
+    User::LeaveIfError(thread.Open(fT));
+    TThreadId threadId = thread.Id();
+    thread.Close();
+    process.Resume();
+    
+    CleanupStack::PopAndDestroy(&process);
+    if (aWait)
+        HandleShutdownL(threadId, ETrue);
+    }
 
 void CSisLauncherServer::ForceShutdownL(TUid aUid)
-	{
-	TBool needToScanFullList;
-	TFullName fullName;
-	do
-		{
-		needToScanFullList = EFalse;
-		TFindProcess findProcess;
+    {
+    TBool needToScanFullList;
+    TFullName fullName;
+    do
+        {
+        needToScanFullList = EFalse;
+        TFindProcess findProcess;
 
-		while(findProcess.Next(fullName) == KErrNone)
-			{
-			RProcess process;
-			User::LeaveIfError(process.Open(findProcess));
-			TUid sid(process.SecureId());
-			if (sid == aUid && process.ExitType() == EExitPending)
-				{
-				process.Kill(KErrNone);
-				needToScanFullList = ETrue;
-				}
-			process.Close();
-			}
-		} while (needToScanFullList);
-	}
+        while(findProcess.Next(fullName) == KErrNone)
+            {
+            RProcess process;
+            User::LeaveIfError(process.Open(findProcess));
+            TUid sid(process.SecureId());
+            if (sid == aUid && process.ExitType() == EExitPending)
+                {
+                process.Kill(KErrNone);
+                needToScanFullList = ETrue;
+                }
+            process.Close();
+            }
+        } while (needToScanFullList);
+    }
 
 
 void CSisLauncherServer::HandleShutdownL(TThreadId aThread, TBool aKillOnTimeout)
-	{
-	RWsSession* wsSession = NULL;
-	if (iBootMode == KTextShell) 
-		{
-		// emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
-		DEBUG_PRINTF(_L8("Sis Launcher Server - textshell - skipping shutdown of user applications"));	
-		}
-	else
-		{
-		#ifndef SWI_TEXTSHELL_ROM
-			DEBUG_CODE_SECTION(
-				if (aKillOnTimeout)
-					{
-					DEBUG_PRINTF(_L8("Sis Launcher Server - Awaiting thread shutdown, will forcibly kill process on timeout."));
-					}
-				else
-					{
-					DEBUG_PRINTF(_L8("Sis Launcher Server - Awaiting thread shutdown, will not forcibly kill process on timeout."));
-					}
-				);
-			wsSession = &iWsSession;	
-		#endif
-		}
-	// Read timeout value from software install security
-	// policy.
-	CSecurityPolicy* secPolicy = CSecurityPolicy::GetSecurityPolicyL();
-	TInt runWaitTimeout = secPolicy->RunWaitTimeout();
-	TInt shutdownTimeout = secPolicy->ApplicationShutdownTimeout();
-	// Wait until the thread finishes or a timeout occurs
-	CThreadMonitor* threadMonitor = CThreadMonitor::NewLC(aThread, wsSession);
-	threadMonitor->SyncShutdownL(runWaitTimeout, aKillOnTimeout, shutdownTimeout);
-	CleanupStack::PopAndDestroy(threadMonitor);
-	}
+    {
+    RWsSession* wsSession = NULL;
+    if (iBootMode == KTextShell) 
+        {
+        // emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
+        DEBUG_PRINTF(_L8("Sis Launcher Server - textshell - skipping shutdown of user applications"));  
+        }
+    else
+        {
+        #ifndef SWI_TEXTSHELL_ROM
+            DEBUG_CODE_SECTION(
+                if (aKillOnTimeout)
+                    {
+                    DEBUG_PRINTF(_L8("Sis Launcher Server - Awaiting thread shutdown, will forcibly kill process on timeout."));
+                    }
+                else
+                    {
+                    DEBUG_PRINTF(_L8("Sis Launcher Server - Awaiting thread shutdown, will not forcibly kill process on timeout."));
+                    }
+                );
+            wsSession = &iWsSession;    
+        #endif
+        }
+    // Read timeout value from software install security
+    // policy.
+    CSecurityPolicy* secPolicy = CSecurityPolicy::GetSecurityPolicyL();
+    TInt runWaitTimeout = secPolicy->RunWaitTimeout();
+    TInt shutdownTimeout = secPolicy->ApplicationShutdownTimeout();
+    // Wait until the thread finishes or a timeout occurs
+    CThreadMonitor* threadMonitor = CThreadMonitor::NewLC(aThread, wsSession);
+    threadMonitor->SyncShutdownL(runWaitTimeout, aKillOnTimeout, shutdownTimeout);
+    CleanupStack::PopAndDestroy(threadMonitor);
+    }
 
 
 #ifndef SWI_TEXTSHELL_ROM
 void CSisLauncherServer::StartDocumentL(RFile& aFile, TBool aWait)
-	{
-	DEBUG_CODE_SECTION(
-	if (aWait)
-		{
-		DEBUG_PRINTF(_L8("Sis Launcher Server - Attempting to start document by filehandle, waiting for termination."));
-		}
-	else
-		{
-		DEBUG_PRINTF(_L8("Sis Launcher Server - Attempting to start document by filehandle, not waiting for termination."));
-		}
-	);
+    {
+    DEBUG_CODE_SECTION(
+    if (aWait)
+        {
+        DEBUG_PRINTF(_L8("Sis Launcher Server - Attempting to start document by filehandle, waiting for termination."));
+        }
+    else
+        {
+        DEBUG_PRINTF(_L8("Sis Launcher Server - Attempting to start document by filehandle, not waiting for termination."));
+        }
+    );
 
-	RApaLsSession apaSession;
-	User::LeaveIfError(apaSession.Connect());
-	CleanupClosePushL(apaSession);
+    RApaLsSession apaSession;
+    User::LeaveIfError(apaSession.Connect());
+    CleanupClosePushL(apaSession);
 
-	TThreadId threadId;	
-	User::LeaveIfError(apaSession.StartDocument(aFile, threadId));
+    TThreadId threadId; 
+    User::LeaveIfError(apaSession.StartDocument(aFile, threadId));
 
-	CleanupStack::PopAndDestroy(&apaSession);
-	if (aWait)
-		HandleShutdownL(threadId);
-	}
+    CleanupStack::PopAndDestroy(&apaSession);
+    if (aWait)
+        HandleShutdownL(threadId);
+    }
 
 void CSisLauncherServer::StartByMimeL(RFile& aFile, TDesC8& aMimeType, TBool aWait)
-	{
-	DEBUG_CODE_SECTION(
-	if (aWait)
-		{
-		DEBUG_PRINTF2(_L8("Sis Launcher Server - Attempting to start document by mimetype '%S' (filehandle supplied), waiting for termination."),
-			&aMimeType);
-		}
-	else
-		{
-		DEBUG_PRINTF2(_L8("Sis Launcher Server - Attempting to start document by mimetype '%S' (filehandle supplied), not waiting for termination."),
-			&aMimeType);
-		}
-	);
+    {
+    DEBUG_CODE_SECTION(
+    if (aWait)
+        {
+        DEBUG_PRINTF2(_L8("Sis Launcher Server - Attempting to start document by mimetype '%S' (filehandle supplied), waiting for termination."),
+            &aMimeType);
+        }
+    else
+        {
+        DEBUG_PRINTF2(_L8("Sis Launcher Server - Attempting to start document by mimetype '%S' (filehandle supplied), not waiting for termination."),
+            &aMimeType);
+        }
+    );
 
-	RApaLsSession apaSession;
-	User::LeaveIfError(apaSession.Connect());
-	CleanupClosePushL(apaSession);
+    RApaLsSession apaSession;
+    User::LeaveIfError(apaSession.Connect());
+    CleanupClosePushL(apaSession);
 
-	TThreadId threadId;
-	TDataType dataType = TDataType(aMimeType);	
-	User::LeaveIfError(apaSession.StartDocument(aFile, dataType, threadId));
+    TThreadId threadId;
+    TDataType dataType = TDataType(aMimeType);  
+    User::LeaveIfError(apaSession.StartDocument(aFile, dataType, threadId));
 
-	CleanupStack::PopAndDestroy(&apaSession);
-	if (aWait)
-		HandleShutdownL(threadId);
-	}
-	
+    CleanupStack::PopAndDestroy(&apaSession);
+    if (aWait)
+        HandleShutdownL(threadId);
+    }
+    
 void CSisLauncherServer::StartDocumentL(const TDesC& aFileName, TBool aWait)
-	{
-	DEBUG_CODE_SECTION(
-	if (aWait)
-		{
-		DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to start document by filename '%S', waiting for termination."),
-			&aFileName);
-		}
-	else
-		{
-		DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to start document by filename '%S', not waiting for termination."),
-			&aFileName);
-		}
-	);
+    {
+    DEBUG_CODE_SECTION(
+    if (aWait)
+        {
+        DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to start document by filename '%S', waiting for termination."),
+            &aFileName);
+        }
+    else
+        {
+        DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to start document by filename '%S', not waiting for termination."),
+            &aFileName);
+        }
+    );
 
-	RApaLsSession apaSession;
-	User::LeaveIfError(apaSession.Connect());
-	CleanupClosePushL(apaSession);
+    RApaLsSession apaSession;
+    User::LeaveIfError(apaSession.Connect());
+    CleanupClosePushL(apaSession);
 
-	TThreadId threadId;
-	User::LeaveIfError(apaSession.StartDocument(aFileName, threadId));
+    TThreadId threadId;
+    User::LeaveIfError(apaSession.StartDocument(aFileName, threadId));
 
-	CleanupStack::PopAndDestroy(&apaSession);
-	if (aWait)
-		HandleShutdownL(threadId);
-	}
+    CleanupStack::PopAndDestroy(&apaSession);
+    if (aWait)
+        HandleShutdownL(threadId);
+    }
 
 void CSisLauncherServer::StartByMimeL(const TDesC& aFileName, TDesC8& aMimeType, TBool aWait)
-	{
-	DEBUG_CODE_SECTION(
-	if (aWait)
-		{
-		DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to start document by filename '%S', waiting for termination."),
-			&aFileName);
-		}
-	else
-		{
-		DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to start document by filename '%S', not waiting for termination."),
-			&aFileName);
-		}
-	);
-	DEBUG_PRINTF2(_L8("Sis Launcher Server - Supplied MIME type is '%S'."), &aMimeType);	
+    {
+    DEBUG_CODE_SECTION(
+    if (aWait)
+        {
+        DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to start document by filename '%S', waiting for termination."),
+            &aFileName);
+        }
+    else
+        {
+        DEBUG_PRINTF2(_L("Sis Launcher Server - Attempting to start document by filename '%S', not waiting for termination."),
+            &aFileName);
+        }
+    );
+    DEBUG_PRINTF2(_L8("Sis Launcher Server - Supplied MIME type is '%S'."), &aMimeType);    
 
-	RApaLsSession apaSession;
-	User::LeaveIfError(apaSession.Connect());
-	CleanupClosePushL(apaSession);
+    RApaLsSession apaSession;
+    User::LeaveIfError(apaSession.Connect());
+    CleanupClosePushL(apaSession);
 
-	TThreadId threadId;
-	TDataType dataType = TDataType(aMimeType);
-	User::LeaveIfError(apaSession.StartDocument(aFileName, dataType, threadId));
+    TThreadId threadId;
+    TDataType dataType = TDataType(aMimeType);
+    User::LeaveIfError(apaSession.StartDocument(aFileName, dataType, threadId));
 
-	CleanupStack::PopAndDestroy(&apaSession);
-	if (aWait)
-		HandleShutdownL(threadId);
-	}
+    CleanupStack::PopAndDestroy(&apaSession);
+    if (aWait)
+        HandleShutdownL(threadId);
+    }
 
 void CSisLauncherServer::ShutdownL(TUid aUid, TInt aTimeout)
-	{
-	// This method shuts down running exes matching the SID provided in aUid.
-	// It first attempts a graceful shutdown, killing processes if a graceful
-	// shutdown is not supported or fails to work within aTimeout microseconds.
+    {
+    // This method shuts down running exes matching the SID provided in aUid.
+    // It first attempts a graceful shutdown, killing processes if a graceful
+    // shutdown is not supported or fails to work within aTimeout microseconds.
 
-	DEBUG_PRINTF2(_L8("Sis Launcher Server - Attempting to kill process with SID: 0x%08x."),
-		aUid.iUid);
+    DEBUG_PRINTF2(_L8("Sis Launcher Server - Attempting to kill process with SID: 0x%08x."),
+        aUid.iUid);
 
-	TInt wgId=0;
+    TInt wgId=0;
 
-	CApaWindowGroupName* wgName = CApaWindowGroupName::NewL(iWsSession);
-	CleanupStack::PushL(wgName);
-	CApaWindowGroupName::FindByAppUid(aUid, iWsSession, wgId);
-	
-	while (wgId != KErrNotFound)
-		{	
-		wgName->ConstructFromWgIdL(wgId);
-		if(wgName->RespondsToShutdownEvent())
-			{
-			TApaTask task(iWsSession);
-			task.SetWgId(wgId);
+    CApaWindowGroupName* wgName = CApaWindowGroupName::NewL(iWsSession);
+    CleanupStack::PushL(wgName);
+    CApaWindowGroupName::FindByAppUid(aUid, iWsSession, wgId);
+    
+    while (wgId != KErrNotFound)
+        {   
+        wgName->ConstructFromWgIdL(wgId);
+        if(wgName->RespondsToShutdownEvent())
+            {
+            TApaTask task(iWsSession);
+            task.SetWgId(wgId);
 
-			RThread thread;
-			User::LeaveIfError(thread.Open(task.ThreadId()));
-			CleanupClosePushL(thread);
-			
-			RProcess process;
-			User::LeaveIfError(thread.Process(process));
-			CleanupClosePushL(process);
+            RThread thread;
+            User::LeaveIfError(thread.Open(task.ThreadId()));
+            CleanupClosePushL(thread);
+            
+            RProcess process;
+            User::LeaveIfError(thread.Process(process));
+            CleanupClosePushL(process);
 
-			TRequestStatus processStatus;
-			process.Logon(processStatus);
-			
-			task.SendSystemEvent(EApaSystemEventShutdown);
+            TRequestStatus processStatus;
+            process.Logon(processStatus);
+            
+            task.SendSystemEvent(EApaSystemEventShutdown);
 
-			RTimer timer;
-			CleanupClosePushL(timer);
-			TRequestStatus timerStatus;
-			timer.CreateLocal();
-			timer.After(timerStatus, aTimeout);
+            RTimer timer;
+            CleanupClosePushL(timer);
+            TRequestStatus timerStatus;
+            timer.CreateLocal();
+            timer.After(timerStatus, aTimeout);
 
-			User::WaitForRequest(processStatus,timerStatus);
+            User::WaitForRequest(processStatus,timerStatus);
 
-			if (processStatus==KRequestPending)
-				{
-				// Failed to terminate gracefully, so kill the task.
-				DEBUG_PRINTF(_L8("Sis Launcher Server - Process did not die before timeout. Forcibly killing it."));
-				process.Kill(KErrNone);
-				}
-			else if (timerStatus==KRequestPending)
-				{
-				// Rendezvous completed so cancel timer
-				timer.Cancel();
-				}
-			// Handle second request
-			User::WaitForRequest(processStatus,timerStatus);
-			CleanupStack::PopAndDestroy(3, &thread);
-			}
+            if (processStatus==KRequestPending)
+                {
+                // Failed to terminate gracefully, so kill the task.
+                DEBUG_PRINTF(_L8("Sis Launcher Server - Process did not die before timeout. Forcibly killing it."));
+                process.Kill(KErrNone);
+                }
+            else if (timerStatus==KRequestPending)
+                {
+                // Rendezvous completed so cancel timer
+                timer.Cancel();
+                }
+            // Handle second request
+            User::WaitForRequest(processStatus,timerStatus);
+            CleanupStack::PopAndDestroy(3, &thread);
+            }
 
-		// See if there's another instance of this App running.
-		CApaWindowGroupName::FindByAppUid(aUid, iWsSession, wgId);
-		}
-	CleanupStack::PopAndDestroy(wgName);
-	}
+        // See if there's another instance of this App running.
+        CApaWindowGroupName::FindByAppUid(aUid, iWsSession, wgId);
+        }
+    CleanupStack::PopAndDestroy(wgName);
+    }
 
 void CSisLauncherServer::ShutdownL()
-	{
-	TInt wgId=0;
+    {
+    TInt wgId=0;
     
-	CApaWindowGroupName* wgName = CApaWindowGroupName::NewL(iWsSession);
-	CleanupStack::PushL(wgName);
-	TBuf<1> matchAny;
-	matchAny.Append(KMatchAny);
-	CApaWindowGroupName::FindByCaption(matchAny, iWsSession, wgId);
-	while (wgId != KErrNotFound)
-		{
-		wgName->ConstructFromWgIdL(wgId);
-		//DEF057706 - shut down hidden apps during uninstallation if
-		// SH flag is specified
-		if (!wgName->IsSystem() /* && !wgName->Hidden() */)
-			{
-			// leave if we cannot shutdown the app because its busy
-			if(!wgName->IsBusy())
-				{
-				TApaTask task(iWsSession);
-				task.SetWgId(wgId);
-				// show shutdown dialog for this app?
-				task.SendSystemEvent(EApaSystemEventShutdown);
-				}
-			else
-				{
-				// could not shutdown an app
-				User::Leave(KErrInUse);
-				}
-			}
-	
-		// get next app to shutdown
-		CApaWindowGroupName::FindByCaption(matchAny, iWsSession, wgId);
-		}
-	CleanupStack::PopAndDestroy(wgName);
-	}
+    CApaWindowGroupName* wgName = CApaWindowGroupName::NewL(iWsSession);
+    CleanupStack::PushL(wgName);
+    TBuf<1> matchAny;
+    matchAny.Append(KMatchAny);
+    CApaWindowGroupName::FindByCaption(matchAny, iWsSession, wgId);
+    while (wgId != KErrNotFound)
+        {
+        wgName->ConstructFromWgIdL(wgId);
+        //DEF057706 - shut down hidden apps during uninstallation if
+        // SH flag is specified
+        if (!wgName->IsSystem() /* && !wgName->Hidden() */)
+            {
+            // leave if we cannot shutdown the app because its busy
+            if(!wgName->IsBusy())
+                {
+                TApaTask task(iWsSession);
+                task.SetWgId(wgId);
+                // show shutdown dialog for this app?
+                task.SendSystemEvent(EApaSystemEventShutdown);
+                }
+            else
+                {
+                // could not shutdown an app
+                User::Leave(KErrInUse);
+                }
+            }
+    
+        // get next app to shutdown
+        CApaWindowGroupName::FindByCaption(matchAny, iWsSession, wgId);
+        }
+    CleanupStack::PopAndDestroy(wgName);
+    }
 
 void CSisLauncherServer::NotifyNewAppsL(const RPointerArray<TDesC>& aFiles)
-	{
-	RApaLsSession apaSession;
-	User::LeaveIfError(apaSession.Connect());
-	CleanupClosePushL(apaSession);
+    {
+    RApaLsSession apaSession;
+    User::LeaveIfError(apaSession.Connect());
+    CleanupClosePushL(apaSession);
 
-	// UI frameworks advise ignoring the return code
-	apaSession.ForceRegistration(aFiles);
+    // UI frameworks advise ignoring the return code
+    apaSession.ForceRegistration(aFiles);
 
-	CleanupStack::PopAndDestroy();
-	}
+    CleanupStack::PopAndDestroy();
+    }
 
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
 void CSisLauncherServer::NotifyNewAppsL(const RPointerArray<Usif::CApplicationRegistrationData>& aApplicationRegistrationData)
-	{
-	RApaLsSession apaSession;
-	User::LeaveIfError(apaSession.Connect());
-	CleanupClosePushL(apaSession);
+    {
+    RApaLsSession apaSession;
+    User::LeaveIfError(apaSession.Connect());
+    CleanupClosePushL(apaSession);
 
-	// UI frameworks advise ignoring the return code
-	// Uncomment below line when apparc has implemented the following
-	// apaSession.ForceRegistration(aApplicationRegistrationData);
-	TInt appCount = aApplicationRegistrationData.Count(); //TODO: A fix for compiler warning, to be removed
-
-	CleanupStack::PopAndDestroy();
-	}
+    // UI frameworks advise ignoring the return code
+    // Proceeding even if force registration fails so that installtion is not aborted
+    apaSession.ForceRegistration(aApplicationRegistrationData);
+    CleanupStack::PopAndDestroy();
+    }
 #endif
 #endif
 
-	
+    
--- a/installationservices/swi/source/sislauncher/server/sislaunchersession.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/sislauncher/server/sislaunchersession.cpp	Fri May 14 15:58:48 2010 +0300
@@ -63,328 +63,328 @@
 
 template <>
 class TTraits<TDesC>
-	{
+    {
 public:
-	static TDesC* CopyLC(const TDesC& aOther) { return aOther.AllocLC(); }
-	static TDesC* ReadFromStreamLC(RReadStream& aStream) { return HBufC::NewLC(aStream, KMaxTInt); }
-	static void WriteToStreamL(const TDesC& aItem, RWriteStream& aStream) { aStream << aItem; }
-	};
+    static TDesC* CopyLC(const TDesC& aOther) { return aOther.AllocLC(); }
+    static TDesC* ReadFromStreamLC(RReadStream& aStream) { return HBufC::NewLC(aStream, KMaxTInt); }
+    static void WriteToStreamL(const TDesC& aItem, RWriteStream& aStream) { aStream << aItem; }
+    };
 
 CSisLauncherSession::CSisLauncherSession()
-	{
-	}
+    {
+    }
 
 void CSisLauncherSession::CreateL()
-	{
-	Server().AddSession();
-	}
+    {
+    Server().AddSession();
+    }
 
 CSisLauncherSession::~CSisLauncherSession()
-	{
-	#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-	delete iCurrentAppRegData;
-	#endif
-	Server().DropSession();
-	}
+    {
+    #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+    delete iCurrentAppRegData;
+    #endif
+    Server().DropSession();
+    }
 void CSisLauncherSession::DoRunExecutableL(const RMessage2& aMessage) 
-	{
-	TFileName filename;
-	aMessage.ReadL(0, filename);
+    {
+    TFileName filename;
+    aMessage.ReadL(0, filename);
 
-	TBool wait;
-	TPckg <TBool> waitPckg(wait);
+    TBool wait;
+    TPckg <TBool> waitPckg(wait);
 
-	aMessage.ReadL(1, waitPckg);
-	Server().RunExecutableL(filename, wait);
+    aMessage.ReadL(1, waitPckg);
+    Server().RunExecutableL(filename, wait);
 
-	aMessage.Complete(KErrNone);
-	}
+    aMessage.Complete(KErrNone);
+    }
 
 void CSisLauncherSession::DoStartDocumentL(const RMessage2& aMessage)
-	{
-	TFileName filename;
-	aMessage.ReadL(0, filename);
-	
-	TBool wait;
-	TPckg <TBool> waitPckg(wait);
-	
-	aMessage.ReadL(1, waitPckg);
-	if (Server().BootUpMode() == KTextShell) 
-		{
-		// emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
-		DEBUG_PRINTF2(_L8("Sis Launcher Server - textshell - skipping start document by file handle. wait = %d"), wait);	
-		}
-	else
-		{ 
-		// emulatore running with GUI
-		#ifndef SWI_TEXTSHELL_ROM
-			Server().StartDocumentL(filename, wait);
-		#endif
-		}
+    {
+    TFileName filename;
+    aMessage.ReadL(0, filename);
+    
+    TBool wait;
+    TPckg <TBool> waitPckg(wait);
+    
+    aMessage.ReadL(1, waitPckg);
+    if (Server().BootUpMode() == KTextShell) 
+        {
+        // emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
+        DEBUG_PRINTF2(_L8("Sis Launcher Server - textshell - skipping start document by file handle. wait = %d"), wait);    
+        }
+    else
+        { 
+        // emulatore running with GUI
+        #ifndef SWI_TEXTSHELL_ROM
+            Server().StartDocumentL(filename, wait);
+        #endif
+        }
 
-	aMessage.Complete(KErrNone);	
-	}
+    aMessage.Complete(KErrNone);    
+    }
 
 
 void CSisLauncherSession::DoStartDocumentByHandleL(const RMessage2& aMessage)
-	{
-	RFile file;
-	file.AdoptFromClient(aMessage, 0, 1);
-	CleanupClosePushL(file);
+    {
+    RFile file;
+    file.AdoptFromClient(aMessage, 0, 1);
+    CleanupClosePushL(file);
 
-	TBool wait;
-	TPckg <TBool> waitPckg(wait);
+    TBool wait;
+    TPckg <TBool> waitPckg(wait);
 
-	aMessage.ReadL(2, waitPckg);
-	if (Server().BootUpMode() == KTextShell)
-		{
-		// emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
-		DEBUG_PRINTF3(_L8("Sis Launcher Server - textshell - skipping start document %S, wait = %d"),
-				&file, wait);
-		}
-	else
-		{
-		// emulatore running with GUI
+    aMessage.ReadL(2, waitPckg);
+    if (Server().BootUpMode() == KTextShell)
+        {
+        // emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
+        DEBUG_PRINTF3(_L8("Sis Launcher Server - textshell - skipping start document %S, wait = %d"),
+                &file, wait);
+        }
+    else
+        {
+        // emulatore running with GUI
 #ifndef SWI_TEXTSHELL_ROM
-		Server().StartDocumentL(file, wait);
+        Server().StartDocumentL(file, wait);
 #endif
-		}
-	CleanupStack::PopAndDestroy(&file);
-	aMessage.Complete(KErrNone);
+        }
+    CleanupStack::PopAndDestroy(&file);
+    aMessage.Complete(KErrNone);
 }
 void CSisLauncherSession::DoStartByMimeL(const RMessage2& aMessage)
-	{
-	TFileName filename;
-	aMessage.ReadL(0, filename);
+    {
+    TFileName filename;
+    aMessage.ReadL(0, filename);
 
-	TInt srcLen = aMessage.GetDesLengthL(1);
+    TInt srcLen = aMessage.GetDesLengthL(1);
 
-	HBufC8* mimeType = HBufC8::NewLC(srcLen);
-	TPtr8 ptr(mimeType->Des());
-	aMessage.ReadL(1, ptr);
+    HBufC8* mimeType = HBufC8::NewLC(srcLen);
+    TPtr8 ptr(mimeType->Des());
+    aMessage.ReadL(1, ptr);
 
-	TBool wait;
-	TPckg <TBool> waitPckg(wait);
-	aMessage.ReadL(2, waitPckg);
-	if (Server().BootUpMode() == KTextShell) 
-		{
-		// emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
-		DEBUG_PRINTF3(_L8("Sis Launcher Server - textshell - skipping start document by file handle mimetype %S, wait = %d"),
-				mimeType, wait);	
-		}
-	else
-		{
-		// emulatore running with GUI
+    TBool wait;
+    TPckg <TBool> waitPckg(wait);
+    aMessage.ReadL(2, waitPckg);
+    if (Server().BootUpMode() == KTextShell) 
+        {
+        // emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
+        DEBUG_PRINTF3(_L8("Sis Launcher Server - textshell - skipping start document by file handle mimetype %S, wait = %d"),
+                mimeType, wait);    
+        }
+    else
+        {
+        // emulatore running with GUI
 #ifndef SWI_TEXTSHELL_ROM
-		Server().StartByMimeL(filename, *mimeType, wait);
+        Server().StartByMimeL(filename, *mimeType, wait);
 #endif
-		}		
-	CleanupStack::PopAndDestroy(mimeType);
+        }       
+    CleanupStack::PopAndDestroy(mimeType);
 
-	aMessage.Complete(KErrNone);
-	}
+    aMessage.Complete(KErrNone);
+    }
 void CSisLauncherSession::DoStartByMimeByHandleL(const RMessage2& aMessage)
-	{
-	RFile file;
-	file.AdoptFromClient(aMessage, 0, 1);			
-	CleanupClosePushL(file);
+    {
+    RFile file;
+    file.AdoptFromClient(aMessage, 0, 1);           
+    CleanupClosePushL(file);
 
-	TInt srcLen = aMessage.GetDesLengthL(2);
+    TInt srcLen = aMessage.GetDesLengthL(2);
 
-	HBufC8* mimeType = HBufC8::NewLC(srcLen);
-	TPtr8 ptr(mimeType->Des());
-	aMessage.ReadL(2, ptr);
+    HBufC8* mimeType = HBufC8::NewLC(srcLen);
+    TPtr8 ptr(mimeType->Des());
+    aMessage.ReadL(2, ptr);
 
-	TBool wait;
-	TPckg <TBool> waitPckg(wait);
+    TBool wait;
+    TPckg <TBool> waitPckg(wait);
 
-	aMessage.ReadL(3, waitPckg);
-	if (Server().BootUpMode() == KTextShell) 
-		{
-		// emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
-		DEBUG_PRINTF4(_L("Sis Launcher Server - textshell - skipping launch of document %S, mimetype %s, wait %d"),
-				&file, mimeType, wait);
-		}
-	else
-		{
-		// emulatore running with GUI
+    aMessage.ReadL(3, waitPckg);
+    if (Server().BootUpMode() == KTextShell) 
+        {
+        // emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
+        DEBUG_PRINTF4(_L("Sis Launcher Server - textshell - skipping launch of document %S, mimetype %s, wait %d"),
+                &file, mimeType, wait);
+        }
+    else
+        {
+        // emulatore running with GUI
 #ifndef SWI_TEXTSHELL_ROM
-		Server().StartByMimeL(file, *mimeType, wait);
+        Server().StartByMimeL(file, *mimeType, wait);
 #endif
-		}		
-	CleanupStack::PopAndDestroy(mimeType);
-	CleanupStack::PopAndDestroy(&file);
+        }       
+    CleanupStack::PopAndDestroy(mimeType);
+    CleanupStack::PopAndDestroy(&file);
 
-	aMessage.Complete(KErrNone);
+    aMessage.Complete(KErrNone);
 
-	}
+    }
 void CSisLauncherSession::ServiceL(const RMessage2& aMessage)
-	{
-	DEBUG_PRINTF2(_L8("Sis Launcher Server - Servicing Message %d"), aMessage.Function());
-	
-	switch (aMessage.Function())
-		{
-		case ERunExecutable:
-			DoRunExecutableL(aMessage);
-			break;
-		case EStartDocument:
-			DoStartDocumentL(aMessage);			
-			break;
-		case EStartDocumentByHandle:
-			DoStartDocumentByHandleL(aMessage);
-			break;	
-		case EStartByMime:
-			DoStartByMimeL(aMessage);
-			break;
-		case EStartByMimeByHandle:
-			DoStartByMimeByHandleL(aMessage);
-			break;
-		case EShutdown:
-			{
-			TInt srcLen=aMessage.GetDesLengthL(0);
-			
-			HBufC8* uidBuffer = HBufC8::NewLC(srcLen);
-			TPtr8 uidPtr = uidBuffer->Des();
-			aMessage.ReadL(0, uidPtr, 0);
-			
-			TUint8* dataPtr=const_cast<TUint8*>(uidPtr.Ptr());
-			TUid* tUidPtr=reinterpret_cast<TUid*>(dataPtr);
-			TInt8 uidCount=srcLen/sizeof(TUid);
-			TInt shutdownTimeout = aMessage.Int1();
-			if (Server().BootUpMode() == KTextShell) 
-				{
-				// emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
-				DEBUG_PRINTF(_L8("Sis Launcher Server - textshell - skipping graceful shutdown of GUI applications"));
-				}
-			else
-				{
-				// emulatore running with GUI
-				#ifndef SWI_TEXTSHELL_ROM
-					for (TInt i = 0; i < uidCount; i++)
-						{
-						// graceful shutdown
-						Server().ShutdownL(tUidPtr[i], shutdownTimeout);	
-						}
-				#endif
-				}
-			// Having tried graceful shutdown, we need to kill any remaining processes
-			// matching the SID.  Note that killing a process may re-order the list of
-			// remaining processes, so the search must start from the top again.
-			for (TInt i = 0; i < uidCount; i++)
-				{
-				Server().ForceShutdownL(tUidPtr[i]);
-				}			
-			CleanupStack::PopAndDestroy(uidBuffer);
-			aMessage.Complete(KErrNone);
-			
-			break;
-			}
-		case EShutdownAll:
-			{
-			if (Server().BootUpMode() == KTextShell) 
-				{
-				// emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
-				DEBUG_PRINTF(_L8("Sis Launcher Server - textshell - skipping shutdown of user applications"));	
-				}
-			else
-				{
-				// emulatore running with GUI
-				#ifndef SWI_TEXTSHELL_ROM
-				Server().ShutdownL();
-				#endif
-				}
-			aMessage.Complete(KErrNone);
-			break;	
-			}
-		case ECheckApplicationInUse:
-			{
-			TInt srcLen=aMessage.GetDesLengthL(0);
-				
-			HBufC8* appInUseBuffer = HBufC8::NewLC(srcLen);
-			TPtr8 appInUseBufferPtr = appInUseBuffer->Des();	
-			aMessage.ReadL(0, appInUseBufferPtr, 0);
-	 
-			TAppInUse* appInUsePtr = (TAppInUse*) User::AllocL(srcLen);
-			CleanupStack::PushL(appInUsePtr);	
-			Mem::Copy(appInUsePtr, appInUseBufferPtr.Ptr(), srcLen);
+    {
+    DEBUG_PRINTF2(_L8("Sis Launcher Server - Servicing Message %d"), aMessage.Function());
+    
+    switch (aMessage.Function())
+        {
+        case ERunExecutable:
+            DoRunExecutableL(aMessage);
+            break;
+        case EStartDocument:
+            DoStartDocumentL(aMessage);         
+            break;
+        case EStartDocumentByHandle:
+            DoStartDocumentByHandleL(aMessage);
+            break;  
+        case EStartByMime:
+            DoStartByMimeL(aMessage);
+            break;
+        case EStartByMimeByHandle:
+            DoStartByMimeByHandleL(aMessage);
+            break;
+        case EShutdown:
+            {
+            TInt srcLen=aMessage.GetDesLengthL(0);
+            
+            HBufC8* uidBuffer = HBufC8::NewLC(srcLen);
+            TPtr8 uidPtr = uidBuffer->Des();
+            aMessage.ReadL(0, uidPtr, 0);
+            
+            TUint8* dataPtr=const_cast<TUint8*>(uidPtr.Ptr());
+            TUid* tUidPtr=reinterpret_cast<TUid*>(dataPtr);
+            TInt8 uidCount=srcLen/sizeof(TUid);
+            TInt shutdownTimeout = aMessage.Int1();
+            if (Server().BootUpMode() == KTextShell) 
+                {
+                // emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
+                DEBUG_PRINTF(_L8("Sis Launcher Server - textshell - skipping graceful shutdown of GUI applications"));
+                }
+            else
+                {
+                // emulatore running with GUI
+                #ifndef SWI_TEXTSHELL_ROM
+                    for (TInt i = 0; i < uidCount; i++)
+                        {
+                        // graceful shutdown
+                        Server().ShutdownL(tUidPtr[i], shutdownTimeout);    
+                        }
+                #endif
+                }
+            // Having tried graceful shutdown, we need to kill any remaining processes
+            // matching the SID.  Note that killing a process may re-order the list of
+            // remaining processes, so the search must start from the top again.
+            for (TInt i = 0; i < uidCount; i++)
+                {
+                Server().ForceShutdownL(tUidPtr[i]);
+                }           
+            CleanupStack::PopAndDestroy(uidBuffer);
+            aMessage.Complete(KErrNone);
+            
+            break;
+            }
+        case EShutdownAll:
+            {
+            if (Server().BootUpMode() == KTextShell) 
+                {
+                // emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
+                DEBUG_PRINTF(_L8("Sis Launcher Server - textshell - skipping shutdown of user applications"));  
+                }
+            else
+                {
+                // emulatore running with GUI
+                #ifndef SWI_TEXTSHELL_ROM
+                Server().ShutdownL();
+                #endif
+                }
+            aMessage.Complete(KErrNone);
+            break;  
+            }
+        case ECheckApplicationInUse:
+            {
+            TInt srcLen=aMessage.GetDesLengthL(0);
+                
+            HBufC8* appInUseBuffer = HBufC8::NewLC(srcLen);
+            TPtr8 appInUseBufferPtr = appInUseBuffer->Des();    
+            aMessage.ReadL(0, appInUseBufferPtr, 0);
+     
+            TAppInUse* appInUsePtr = (TAppInUse*) User::AllocL(srcLen);
+            CleanupStack::PushL(appInUsePtr);   
+            Mem::Copy(appInUsePtr, appInUseBufferPtr.Ptr(), srcLen);
  
-			TUint appInUseCount=srcLen/sizeof(TAppInUse);
-			for (TInt i=0;i<appInUseCount;i++)
-				{
-				TRAPD(err, CheckApplicationInUseL(appInUsePtr[i].iAppUid));
-				if (err==KErrInUse)  
-					{
- 					appInUsePtr[i].iInUse=ETrue;
-					}			 
-				}	
-	 
-			TUint8* dataPtr=reinterpret_cast<TUint8*>(appInUsePtr);
- 			const TPtrC8 data(dataPtr, srcLen);	
- 		
- 			//Indicate the client apps in use
- 			aMessage.WriteL(0, data);							
-			aMessage.Complete(KErrNone);
-			CleanupStack::PopAndDestroy(appInUsePtr);
-			CleanupStack::PopAndDestroy(appInUseBuffer); 	
-			break;
-			}
-	    case ENotifyNewApps:
-			{
-			TInt size = aMessage.GetDesLengthL(0);
+            TUint appInUseCount=srcLen/sizeof(TAppInUse);
+            for (TInt i=0;i<appInUseCount;i++)
+                {
+                TRAPD(err, CheckApplicationInUseL(appInUsePtr[i].iAppUid));
+                if (err==KErrInUse)  
+                    {
+                    appInUsePtr[i].iInUse=ETrue;
+                    }            
+                }   
+     
+            TUint8* dataPtr=reinterpret_cast<TUint8*>(appInUsePtr);
+            const TPtrC8 data(dataPtr, srcLen); 
+        
+            //Indicate the client apps in use
+            aMessage.WriteL(0, data);                           
+            aMessage.Complete(KErrNone);
+            CleanupStack::PopAndDestroy(appInUsePtr);
+            CleanupStack::PopAndDestroy(appInUseBuffer);    
+            break;
+            }
+        case ENotifyNewApps:
+            {
+            TInt size = aMessage.GetDesLengthL(0);
 
-			HBufC8* buf = HBufC8::NewLC(size);
-			TPtr8 bufPtr = buf->Des();
-			aMessage.ReadL(0, bufPtr);
+            HBufC8* buf = HBufC8::NewLC(size);
+            TPtr8 bufPtr = buf->Des();
+            aMessage.ReadL(0, bufPtr);
 
-			RDesReadStream stream(*buf);
-			RPointerArray<TDesC> files;
-			InternalizePointerArrayL(files, stream);
-			
-			if (Server().BootUpMode() == KTextShell) 
-				{
-				// emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
-				DEBUG_PRINTF(_L8("Sis Launcher Server - textshell - skipping notification of new applications."));
-				}
-			else
-				{
-				// emulatore running with GUI
-				#ifndef SWI_TEXTSHELL_ROM
-				Server().NotifyNewAppsL(files);
-				#endif // SWI_TEXTSHELL_ROM
-				}
-			
-			files.ResetAndDestroy();
-			CleanupStack::PopAndDestroy(buf);
-			
-			aMessage.Complete(KErrNone);
-			break;
-			}
-		case EParseSwTypeRegFile:
-			#ifndef SWI_TEXTSHELL_ROM
-			#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-			ParseSwTypeRegFileL(aMessage);
-			#endif
-			#endif
-			aMessage.Complete(KErrNone);
-			break;
-		case ERegisterSifLauncherMimeTypes:
-			#ifndef SWI_TEXTSHELL_ROM
-			#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-			RegisterSifLauncherMimeTypesL(aMessage);
-			#endif
-			#endif
-			aMessage.Complete(KErrNone);
-			break;
-		case EUnregisterSifLauncherMimeTypes:
-			#ifndef SWI_TEXTSHELL_ROM
-			#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-			UnregisterSifLauncherMimeTypesL(aMessage);
-			#endif
-			#endif
-			aMessage.Complete(KErrNone);
-			break;
+            RDesReadStream stream(*buf);
+            RPointerArray<TDesC> files;
+            InternalizePointerArrayL(files, stream);
+            
+            if (Server().BootUpMode() == KTextShell) 
+                {
+                // emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
+                DEBUG_PRINTF(_L8("Sis Launcher Server - textshell - skipping notification of new applications."));
+                }
+            else
+                {
+                // emulatore running with GUI
+                #ifndef SWI_TEXTSHELL_ROM
+                Server().NotifyNewAppsL(files);
+                #endif // SWI_TEXTSHELL_ROM
+                }
+            
+            files.ResetAndDestroy();
+            CleanupStack::PopAndDestroy(buf);
+            
+            aMessage.Complete(KErrNone);
+            break;
+            }
+        case EParseSwTypeRegFile:
+            #ifndef SWI_TEXTSHELL_ROM
+            #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+            ParseSwTypeRegFileL(aMessage);
+            #endif
+            #endif
+            aMessage.Complete(KErrNone);
+            break;
+        case ERegisterSifLauncherMimeTypes:
+            #ifndef SWI_TEXTSHELL_ROM
+            #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+            RegisterSifLauncherMimeTypesL(aMessage);
+            #endif
+            #endif
+            aMessage.Complete(KErrNone);
+            break;
+        case EUnregisterSifLauncherMimeTypes:
+            #ifndef SWI_TEXTSHELL_ROM
+            #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+            UnregisterSifLauncherMimeTypesL(aMessage);
+            #endif
+            #endif
+            aMessage.Complete(KErrNone);
+            break;
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-	    case EAsyncParseResourceFileSize:
+        case EAsyncParseResourceFileSize:
             {
             TRAPD(err,err = AsyncParseResourceFileSizeL(aMessage));            
             aMessage.Complete(err);            
@@ -396,105 +396,105 @@
             aMessage.Complete(err);
             break;
             }
- 		case ENotifyNewAppsData:
-			{
-			RIpcReadStream readStream;
-			readStream.Open(aMessage, 0);
-			CleanupClosePushL(readStream);
+        case ENotifyNewAppsData:
+            {
+            RIpcReadStream readStream;
+            readStream.Open(aMessage, 0);
+            CleanupClosePushL(readStream);
 
-			RPointerArray<Usif::CApplicationRegistrationData> appRegInfo;
-			CleanupClosePushL(appRegInfo);
+            RPointerArray<Usif::CApplicationRegistrationData> appRegInfo;
+            CleanupClosePushL(appRegInfo);
 
-			const TInt numElems = readStream.ReadInt32L();
-			for (TInt i=0; i<numElems; ++i)
-				{
-				Usif::CApplicationRegistrationData* info = Usif::CApplicationRegistrationData::NewL(readStream);
-				CleanupStack::PushL(info);
-				appRegInfo.AppendL(info);
-				CleanupStack::Pop(info);
-				}
+            const TInt numElems = readStream.ReadInt32L();
+            for (TInt i=0; i<numElems; ++i)
+                {
+                Usif::CApplicationRegistrationData* info = Usif::CApplicationRegistrationData::NewL(readStream);
+                CleanupStack::PushL(info);
+                appRegInfo.AppendL(info);
+                CleanupStack::Pop(info);
+                }
 
-			if (Server().BootUpMode() == KTextShell) 
-				{
-				// emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
-				DEBUG_PRINTF(_L8("Sis Launcher Server - textshell - skipping notification of new applications."));
-				}
-			else
-				{
-				// emulatore running with GUI
-				#ifndef SWI_TEXTSHELL_ROM
-				Server().NotifyNewAppsL(appRegInfo);
-			#endif // SWI_TEXTSHELL_ROM
-				}
-			appRegInfo.ResetAndDestroy();
-			CleanupStack::PopAndDestroy(2);
-			aMessage.Complete(KErrNone);
-			break;
-			}
- 		case ENotifyApparcForApps:
- 		    {
+            if (Server().BootUpMode() == KTextShell) 
+                {
+                // emulator tests running in textshell or in textshell ROM (#def SWI_TEXTSHELL_ROM)
+                DEBUG_PRINTF(_L8("Sis Launcher Server - textshell - skipping notification of new applications."));
+                }
+            else
+                {
+                // emulatore running with GUI
+                #ifndef SWI_TEXTSHELL_ROM
+                Server().NotifyNewAppsL(appRegInfo);
+            #endif // SWI_TEXTSHELL_ROM
+                }
+            appRegInfo.ResetAndDestroy();
+            CleanupStack::PopAndDestroy(2);
+            aMessage.Complete(KErrNone);
+            break;
+            }
+        case ENotifyApparcForApps:
+            {
             #ifndef SWI_TEXTSHELL_ROM
- 		    NotifyApparcForApps(aMessage); 	
+            NotifyApparcForAppsL(aMessage);  
             #endif
- 		    break;
- 		    }
+            break;
+            }
 #endif // SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-	    case EQueueRunExecutable:
-	    	//fall through
-	    case EQueueStartDocumentByHandle:
-	    	//fall through
-	    case EQueueStartByMimeByHandle:
-	    	Server().RunQueue().AddToQueueL(aMessage);
-	    	aMessage.Complete(KErrNone);
-	    	break;
-	    case EExecuteQueue:
-	    	aMessage.Complete(Server().RunQueue().ExecuteQueue());
-	    	break;
-	    case EKillQueue:
-	    	Server().RunQueue().ResetQueue();
-	    	aMessage.Complete(KErrNone);
-	    	break;
-	    default:
-			{
-			PanicClient(aMessage,EPanicIllegalFunction);
-			break;
-			}
-		}
-	}
+        case EQueueRunExecutable:
+            //fall through
+        case EQueueStartDocumentByHandle:
+            //fall through
+        case EQueueStartByMimeByHandle:
+            Server().RunQueue().AddToQueueL(aMessage);
+            aMessage.Complete(KErrNone);
+            break;
+        case EExecuteQueue:
+            aMessage.Complete(Server().RunQueue().ExecuteQueue());
+            break;
+        case EKillQueue:
+            Server().RunQueue().ResetQueue();
+            aMessage.Complete(KErrNone);
+            break;
+        default:
+            {
+            PanicClient(aMessage,EPanicIllegalFunction);
+            break;
+            }
+        }
+    }
 
 
 void CSisLauncherSession::ServiceError(const RMessage2& aMessage,TInt aError)
-	{
-	DEBUG_PRINTF2(_L8("Sis Launcher Server - ServiceL failed with error code %d."), aError);
-	
-	if (aError==KErrBadDescriptor)
-		{
-		PanicClient(aMessage,EPanicBadDescriptor);
-		}
-	CSession2::ServiceError(aMessage,aError);
-	}
+    {
+    DEBUG_PRINTF2(_L8("Sis Launcher Server - ServiceL failed with error code %d."), aError);
+    
+    if (aError==KErrBadDescriptor)
+        {
+        PanicClient(aMessage,EPanicBadDescriptor);
+        }
+    CSession2::ServiceError(aMessage,aError);
+    }
 
 
 void CSisLauncherSession::CheckApplicationInUseL(TUid aUid)
-	{
-	
-	TFindProcess findProcess;
-	TFullName fullName;
+    {
+    
+    TFindProcess findProcess;
+    TFullName fullName;
  
-	while(findProcess.Next(fullName) == KErrNone)
-		{
-		RProcess process;
-		User::LeaveIfError(process.Open(findProcess));
-		TUid sid(process.SecureId());
-		TExitType exitType = process.ExitType();
-		process.Close();
-		if (sid == aUid && exitType == EExitPending)
-					User::Leave(KErrInUse);
-		}
-	}
+    while(findProcess.Next(fullName) == KErrNone)
+        {
+        RProcess process;
+        User::LeaveIfError(process.Open(findProcess));
+        TUid sid(process.SecureId());
+        TExitType exitType = process.ExitType();
+        process.Close();
+        if (sid == aUid && exitType == EExitPending)
+                    User::Leave(KErrInUse);
+        }
+    }
 
 
-#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK	 
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK   
 TInt CSisLauncherSession::AsyncParseResourceFileSizeL(const RMessage2& aMessage)
     {
     // We only support one call at once currently
@@ -511,9 +511,9 @@
         RFs fs;
         RFile file;
         User::LeaveIfError(fs.Connect());
-		CleanupClosePushL(fs);
+        CleanupClosePushL(fs);
         file.AdoptFromClient(aMessage, 0, 1);   
-		CleanupClosePushL(file);
+        CleanupClosePushL(file);
         //Read languages need to pass
         TInt bufSize=0;
         bufSize = aMessage.GetDesMaxLength(2);
@@ -525,7 +525,7 @@
         CleanupClosePushL(inStream);
         TInt32 languageCount = inStream.ReadInt32L();
 
-		RArray<TLanguage> appLanguages;
+        RArray<TLanguage> appLanguages;
         CleanupClosePushL(appLanguages);
 
         for (TInt i=0; i<languageCount; i++)
@@ -535,20 +535,20 @@
         CleanupStack::PushL(appRegInfoReader);
         
         TRAPD(err,iCurrentAppRegData = appRegInfoReader->ReadL(appLanguages));
-      	if (KErrNone != err)
-			{
-			iInAsyncParseResourceFile=EFalse;
+        if (KErrNone != err)
+            {
+            iInAsyncParseResourceFile=EFalse;
             User::Leave(err);
-			}
-		
-		iInAsyncParseResourceFile=EFalse;	
+            }
+        
+        iInAsyncParseResourceFile=EFalse;   
         TInt objectSize=0;
         objectSize= GetObjectSizeL(iCurrentAppRegData);
         if (objectSize > 0)
             {
             //Everything went fine so return the buffer size.            
             CleanupStack::PopAndDestroy(6,&fs);  
-            return objectSize;			
+            return objectSize;          
             }
         else
             User::Leave(KErrUnknown);
@@ -569,40 +569,40 @@
     }
 
 void CSisLauncherSession::ParseSwTypeRegFileL(const RMessage2& aMessage)
-	{
-	// Unpack the file handle
-	RFile file;
-	User::LeaveIfError(file.AdoptFromClient(aMessage, 0, 1));
-	CleanupClosePushL(file);
-	
-	// Read the registration file
-	TInt fileSize = 0;
-	User::LeaveIfError(file.Size(fileSize));
-	HBufC8* buf = HBufC8::NewLC(fileSize);
-	TPtr8 bufPtr = buf->Des();
-	User::LeaveIfError(file.Read(bufPtr));
+    {
+    // Unpack the file handle
+    RFile file;
+    User::LeaveIfError(file.AdoptFromClient(aMessage, 0, 1));
+    CleanupClosePushL(file);
+    
+    // Read the registration file
+    TInt fileSize = 0;
+    User::LeaveIfError(file.Size(fileSize));
+    HBufC8* buf = HBufC8::NewLC(fileSize);
+    TPtr8 bufPtr = buf->Des();
+    User::LeaveIfError(file.Read(bufPtr));
 
-	// Parse the registration file
-	RCPointerArray<CSoftwareTypeRegInfo> regInfoArray;
-	CleanupClosePushL(regInfoArray);
-	
-	CSoftwareTypeRegInfoParser* parser = CSoftwareTypeRegInfoParser::NewL();
-	CleanupStack::PushL(parser);
-	parser->ParseL(*buf, regInfoArray);
+    // Parse the registration file
+    RCPointerArray<CSoftwareTypeRegInfo> regInfoArray;
+    CleanupClosePushL(regInfoArray);
+    
+    CSoftwareTypeRegInfoParser* parser = CSoftwareTypeRegInfoParser::NewL();
+    CleanupStack::PushL(parser);
+    parser->ParseL(*buf, regInfoArray);
 
-	// Pack the registration data
-	RBuf8 serializedRegInfo;
-	serializedRegInfo.CleanupClosePushL();
-	SoftwareTypeRegInfoUtils::SerializeArrayL(regInfoArray, serializedRegInfo);
-	aMessage.Write(2, serializedRegInfo);
+    // Pack the registration data
+    RBuf8 serializedRegInfo;
+    serializedRegInfo.CleanupClosePushL();
+    SoftwareTypeRegInfoUtils::SerializeArrayL(regInfoArray, serializedRegInfo);
+    aMessage.Write(2, serializedRegInfo);
 
-	CleanupStack::PopAndDestroy(5, &file); // buf, regInfoArray, parser, serializedRegInfo
-	}
+    CleanupStack::PopAndDestroy(5, &file); // buf, regInfoArray, parser, serializedRegInfo
+    }
 
 #ifndef SWI_TEXTSHELL_ROM
-void CSisLauncherSession::NotifyApparcForApps(const RMessage2& aMessage)
+void CSisLauncherSession::NotifyApparcForAppsL(const RMessage2& aMessage)
     {
-    /*RIpcReadStream readStream;
+    RIpcReadStream readStream;
     readStream.Open(aMessage, 0);
     CleanupClosePushL(readStream);    
     RArray<TApaAppUpdateInfo> apparcAppInfoArray;
@@ -610,7 +610,7 @@
     RApaLsSession apaSession;
     User::LeaveIfError(apaSession.Connect());
     CleanupClosePushL(apaSession);
-    TApaAppAction appaction;
+    TApaAppUpdateInfo::TApaAppAction appaction = TApaAppUpdateInfo::EAppNotPresent;
     const TInt numElems = readStream.ReadInt32L();
     //Convert the local structure into the structure required by apparc
     for (TInt i=0; i<numElems; ++i)
@@ -619,84 +619,85 @@
         appInfo.InternalizeL(readStream);   
         if(appInfo.iAction == EAppInstalled)
             {
-            appaction = EApparcAppInstalled;
+            appaction = TApaAppUpdateInfo::EAppPresent;
             }
         else if(appInfo.iAction == EAppUninstalled)
             {
-            appaction = EApparcAppUninstalled;
+            appaction = TApaAppUpdateInfo::EAppNotPresent;
             }
         TApaAppUpdateInfo apparcAppUpdateInfo(appInfo.iAppUid, appaction);
-        apparcAppInfoArray.Append(apparcAppUpdateInfo);                    
+        apparcAppInfoArray.AppendL(apparcAppUpdateInfo);                    
         DEBUG_PRINTF2(_L("AppUid is 0x%x"), appInfo.iAppUid);
         DEBUG_PRINTF2(_L("Action is %d"), appInfo.iAction);         
         }    
     
-    if(numElems)
+    if(numElems > 0)
         {
         apaSession.UpdateAppListL(apparcAppInfoArray);
         }
         
     CleanupStack::PopAndDestroy(3, &readStream);
-    */aMessage.Complete(KErrNone);       
+    aMessage.Complete(KErrNone);
+       
     }
 
 void CSisLauncherSession::RegisterSifLauncherMimeTypesL(const RMessage2& aMessage)
-	{
-	RegisterSifLauncherMimeTypesImplL(aMessage, ETrue);
-	}
+    {
+    RegisterSifLauncherMimeTypesImplL(aMessage, ETrue);
+    }
 
 void CSisLauncherSession::UnregisterSifLauncherMimeTypesL(const RMessage2& aMessage)
-	{
-	RegisterSifLauncherMimeTypesImplL(aMessage, EFalse);
-	}
+    {
+    RegisterSifLauncherMimeTypesImplL(aMessage, EFalse);
+    }
 
 void CSisLauncherSession::RegisterSifLauncherMimeTypesImplL(const RMessage2& aMessage, TBool aRegister)
-	{
-	// Read serialized MIME types from aMessage
-	HBufC8* buf = HBufC8::NewLC(aMessage.GetDesLengthL(0));
-	TPtr8 bufPtr(buf->Des());
-	aMessage.ReadL(0, bufPtr);
-	
-	// Unserialize MIME types
-	RDesReadStream rs(*buf);
-	CleanupClosePushL(rs);
-	
-	RCPointerArray<HBufC8> mimeTypes;
-	CleanupClosePushL(mimeTypes);
-	
-	InternalizePointerArrayL(mimeTypes, rs);
-	
-	// Connect to AppArc
-	RApaLsSession apa;
-	TInt err = apa.Connect();
-	if (err != KErrNone)
-		{
-		DEBUG_PRINTF2(_L8("Failed to connect to the AppArc server, err = %d\n"),err);
-		User::Leave(err);
-		}
-	CleanupClosePushL(apa);
+    {
+    // Read serialized MIME types from aMessage
+    HBufC8* buf = HBufC8::NewLC(aMessage.GetDesLengthL(0));
+    TPtr8 bufPtr(buf->Des());
+    aMessage.ReadL(0, bufPtr);
+    
+    // Unserialize MIME types
+    RDesReadStream rs(*buf);
+    CleanupClosePushL(rs);
+    
+    RCPointerArray<HBufC8> mimeTypes;
+    CleanupClosePushL(mimeTypes);
+    
+    InternalizePointerArrayL(mimeTypes, rs);
+    
+    // Connect to AppArc
+    RApaLsSession apa;
+    TInt err = apa.Connect();
+    if (err != KErrNone)
+        {
+        DEBUG_PRINTF2(_L8("Failed to connect to the AppArc server, err = %d\n"),err);
+        User::Leave(err);
+        }
+    CleanupClosePushL(apa);
 
-	// Iterate over the MIME types and (un)register them
-	for (TInt i=0; i<mimeTypes.Count(); ++i)
-		{
-		TDataType dataType(*mimeTypes[i]);
-		if (aRegister)
-			{
-			const TUid KSifLauncherUid = {0x10285BD0};
-			err = apa.InsertDataMapping(dataType, KDataTypePriorityTrustedHigh, KSifLauncherUid);
-			}
-		else
-			{
-			err = apa.DeleteDataMapping(dataType);
-			}
-		if (err != KErrNone)
-			{
-			DEBUG_PRINTF2(_L8("Failed to (un)register MIME types to AppArc, err = %d\n"),err);
-			}
-		}
-	
-	CleanupStack::PopAndDestroy(4, buf); //rs, mimeTypes, apa
-	}
+    // Iterate over the MIME types and (un)register them
+    for (TInt i=0; i<mimeTypes.Count(); ++i)
+        {
+        TDataType dataType(*mimeTypes[i]);
+        if (aRegister)
+            {
+            const TUid KSifLauncherUid = {0x10285BD0};
+            err = apa.InsertDataMapping(dataType, KDataTypePriorityTrustedHigh, KSifLauncherUid);
+            }
+        else
+            {
+            err = apa.DeleteDataMapping(dataType);
+            }
+        if (err != KErrNone)
+            {
+            DEBUG_PRINTF2(_L8("Failed to (un)register MIME types to AppArc, err = %d\n"),err);
+            }
+        }
+    
+    CleanupStack::PopAndDestroy(4, buf); //rs, mimeTypes, apa
+    }
 
 #endif // SWI_TEXTSHELL_ROM
 #endif // SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
--- a/installationservices/swi/source/sislauncher/server/sislaunchersession.h	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/sislauncher/server/sislaunchersession.h	Fri May 14 15:58:48 2010 +0300
@@ -62,7 +62,7 @@
 	void RegisterSifLauncherMimeTypesL(const RMessage2& aMessage);
 	void UnregisterSifLauncherMimeTypesL(const RMessage2& aMessage);
 	void RegisterSifLauncherMimeTypesImplL(const RMessage2& aMessage, TBool aRegister);
-	void NotifyApparcForApps(const RMessage2& aMessage);
+	void NotifyApparcForAppsL(const RMessage2& aMessage);
 #endif
 #endif
 	void DoRunExecutableL(const RMessage2& aMessage);
--- a/installationservices/swi/source/sisregistry/server_legacy/sisregistrycache.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/sisregistry/server_legacy/sisregistrycache.cpp	Fri May 14 15:58:48 2010 +0300
@@ -514,13 +514,6 @@
 	
 void CSisRegistryCache::InitStartUpL()
 	{
-    TRAPD(res, UpdateRecentFWVersionL(););
-    if (res != KErrNone)
-        {
-        // log that
-        DEBUG_PRINTF2(_L8("Updating recent Firmware Version failed with error code = %d."), res);
-        }
-	
 	// else reinit lists- initial settings, esp at the first reboot
 	BuildUidListL();
 	iUseIntegServices = EFalse; // temporarily "turn off" integrity services. It is not needed to process ROM stubs
@@ -532,6 +525,13 @@
 			
 	// only when all is processed one can check the package state		
 	UpdatePackagePresentStateL();
+	
+    TRAPD(res, UpdateRecentFWVersionL(););
+    if (res != KErrNone)
+        {
+        // log that
+        DEBUG_PRINTF2(_L8("Updating recent Firmware Version failed with error code = %d."), res);
+        }
 	}
 
 void CSisRegistryCache::StoreBackupL()
--- a/installationservices/swi/source/swis/server/installationprocessor.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/swis/server/installationprocessor.cpp	Fri May 14 15:58:48 2010 +0300
@@ -208,6 +208,7 @@
 		iFileExtractor->Cancel();
 		}
 
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK  	
 	if (iAppRegExtractor != NULL)
         {
 		if (iAppRegExtractor->IsActive())
@@ -215,6 +216,7 @@
 			iAppRegExtractor->Cancel();
 			}
 		}
+#endif
 	}
 
 void CInstallationProcessor::DisplayFileL(const CSisRegistryFileDescription& aFileDescription, Sis::TSISFileOperationOptions aFileOperationOption)
@@ -773,8 +775,7 @@
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK		
 		
 		// Find out all the regisration resource files associated with this package UID and add to the list of 
-		// files to be processed later for parsing
-		// Continue processing the next file if a registration resource file is not found(in case of SA over SA)
+		// files to be processed later for parsing		
 		TRAPD(err, AddAppArcRegResourceFilesL());
 		if ( err != KErrNotFound && err != KErrNone)
 		    User::Leave(err);
@@ -914,9 +915,10 @@
     
     if (iCurrent < iApparcRegFilesForParsing.Count())
         { 
-        TDesC& fileDescription = (iApparcRegFilesForParsing[iCurrent++]->GetAppRegFile());                          
+        TDesC& fileDescription = (iApparcRegFilesForParsing[iCurrent++]->GetAppRegFile());   
+        // Continue processing the next file if a registration resource file is not found(in case of SA over SA)
         TRAPD(err,ParseRegistrationResourceFileL(fileDescription));        
-        if(KErrNotFound == err)
+        if(KErrNotFound == err || KErrPathNotFound == err)
             {               
             delete iApparcRegFilesForParsing[--iCurrent];
             iApparcRegFilesForParsing.Remove(iCurrent); 
@@ -997,7 +999,8 @@
 	RArray<TAppUpdateInfo> affectedApps;    
 	CleanupClosePushL(affectedApps);
 	const CApplication& application = ApplicationL();
-	if(iApparcRegFilesForParsing.Count() != 0)
+	//if there are reg files in the package or if its an upgrade (in case of SA (with app) over SA(with no app))
+	if(iApparcRegFilesForParsing.Count() != 0 || application.IsUpgrade())
 	    {
 	    //Create the list of Application Uids which are affected by the Installation    	    	    
 	    Usif::TComponentId componentId = 0;
@@ -1023,36 +1026,41 @@
             if(application.ControllerL().Info().InstallType() == Sis::EInstInstallation )
                 {        
                 //Get the compid for base package
-                componentId = iRegistryWrapper.RegistrySession().GetComponentIdForUidL(packageUid);
-                if(!componentId)
-                    {
-                    DEBUG_PRINTF(_L("ComponentID not found for the base package"));
-                    User::Leave(KErrNotFound);
-                    }
+                componentId = iRegistryWrapper.RegistrySession().GetComponentIdForUidL(packageUid);               
                       
                 TInt index = componentIds.Find(componentId);
-                if(index != KErrNotFound)
-                    {
-                    //Exclude the Base SA compId from the list 
-                    componentIds.Remove(index);
-                    }
+
+                //Exclude the Base SA compId from the list 
+                componentIds.Remove(index);
                 //Get the apps for Base SA compId and mark them as to be deleted
                 existingAppUids.Reset();
-                iRegistryWrapper.RegistrySession().GetAppUidsForComponentL(componentId, existingAppUids);                 
-                for(TInt i = 0 ; i < existingAppUids.Count(); i++)
+                TRAPD(err,iRegistryWrapper.RegistrySession().GetAppUidsForComponentL(componentId, existingAppUids);)  
+                //If Base Package does not contain any app then GetAppUidsForComponentL will return KErrNotFound, ignore the error else leave
+                if (KErrNone != err && KErrNotFound != err)
+                    {
+                    User::Leave(err);
+                    }
+                
+                for(TInt i = 0 ; i < existingAppUids.Count(); ++i)
                     {
                     existingAppInfo = TAppUpdateInfo(existingAppUids[i], EAppUninstalled);    
-                    affectedApps.Append(existingAppInfo);
+                    affectedApps.AppendL(existingAppInfo);
                     }                
                 //Get the apps for Remaining CompIds and mark them as to be upgraded               
-                for(TInt i = 0 ; i < componentIds.Count(); i++)
+                for(TInt i = 0 ; i < componentIds.Count(); ++i)
                     {
                     existingAppUids.Reset();                    
-                    iRegistryWrapper.RegistrySession().GetAppUidsForComponentL(componentIds[i], existingAppUids); 
-                    for(TInt i = 0 ; i < existingAppUids.Count(); i++)
+                    //If there are no apps within the existing components (SP's) then it will return KErrNotFound
+                    TRAPD(err, iRegistryWrapper.RegistrySession().GetAppUidsForComponentL(componentIds[i], existingAppUids);) 
+                    if (KErrNone != err && KErrNotFound != err)
                         {
-                        existingAppInfo = TAppUpdateInfo(existingAppUids[i], EAppInstalled);    
-                        affectedApps.Append(existingAppInfo);
+                        User::Leave(err);
+                        }
+                    
+                    for(TInt k = 0 ; k < existingAppUids.Count(); ++k)
+                        {
+                        existingAppInfo = TAppUpdateInfo(existingAppUids[k], EAppInstalled);    
+                        affectedApps.AppendL(existingAppInfo);
                         }
                     }                                
                 }
@@ -1060,36 +1068,23 @@
             //SP over SP
             if(application.ControllerL().Info().InstallType() == Sis::EInstAugmentation)
                 {
-                componentId = iRegistryWrapper.RegistrySession().GetComponentIdForPackageL(application.PackageL().Name(), application.PackageL().Vendor());
-                //if SP upgrades the SP
-                if(componentId)
-                    {
-                    //Get the apps for Base SP compId and mark them as to be deleted
-                    existingAppUids.Reset();
-                    iRegistryWrapper.RegistrySession().GetAppUidsForComponentL(componentId, existingAppUids); 
-                    for(TInt i = 0 ; i < existingAppUids.Count(); i++)
-                       {
-                       existingAppInfo = TAppUpdateInfo(existingAppUids[i], EAppUninstalled);    
-                       affectedApps.Append(existingAppInfo);
-                       }  
-                    }            
+                componentId = iRegistryWrapper.RegistrySession().GetComponentIdForPackageL(application.PackageL().Name(), application.PackageL().Vendor());     
+                //Get the apps for Base SP compId and mark them as to be deleted
+                existingAppUids.Reset();
+                //If there are no apps within the existing component (SP) then it will return KErrNotFound
+                TRAPD(err, iRegistryWrapper.RegistrySession().GetAppUidsForComponentL(componentId, existingAppUids);) 
+                if (KErrNone != err && KErrNotFound != err)
+					{
+                    User::Leave(err);
+					}
+                
+                for(TInt i = 0 ; i < existingAppUids.Count(); ++i)
+                   {
+                   existingAppInfo = TAppUpdateInfo(existingAppUids[i], EAppUninstalled);    
+                   affectedApps.Append(existingAppInfo);
+                   }                                  
                 }        
-            }	    
-        
-        else if(application.IsPartialUpgrade() || application.IsAugmentation() || application.IsPreInstalledPatch())
-            {       
-            //Get the apps for Remaining CompIds and mark them as to be upgraded               
-            for(TInt i = 0 ; i < componentIds.Count(); i++)
-                {
-                existingAppUids.Reset();                    
-                iRegistryWrapper.RegistrySession().GetAppUidsForComponentL(componentIds[i], existingAppUids); 
-                for(TInt i = 0 ; i < existingAppUids.Count(); i++)
-                    {
-                    existingAppInfo = TAppUpdateInfo(existingAppUids[i], EAppInstalled);    
-                    affectedApps.Append(existingAppInfo);
-                    }
-                }        
-            }
+            }	                   
         CleanupStack::PopAndDestroy(2, &componentIds);
 	    }		
 #endif
@@ -1235,9 +1230,10 @@
 	// RSisRegistryWritableSession::UpdateEntryL()
 	InstallSoftwareTypeHelper::RegisterMimeTypesL(iSoftwareTypeRegInfoArray);
 	
-	if(iApparcRegFilesForParsing.Count() != 0)
+	//if there are reg files in the package or if its an upgrade (in case of SA (with app) over SA(with no app))
+	if(iApparcRegFilesForParsing.Count() != 0 || application.IsUpgrade())
 	    {
-	    //Create the list of Application Uids which are affected by the Installation                            
+	    //Create the list of Application Uids which are affected by the Restore                           
         RArray<Usif::TComponentId> componentIds;
         CleanupClosePushL(componentIds);
         RArray<TUid> newAppUids;    
@@ -1255,9 +1251,11 @@
             newAppUids.Reset();                    
             TRAPD(err,iRegistryWrapper.RegistrySession().GetAppUidsForComponentL(componentIds[i], newAppUids))
             if (KErrNone != err && KErrNotFound != err)
+                {
                 User::Leave(err);
+                }
             
-            for(TInt i = 0 ; i < newAppUids.Count(); i++)
+            for(TInt i = 0 ; i < newAppUids.Count(); ++i)
                 {
                 existingAppInfo = TAppUpdateInfo(newAppUids[i], EAppUninstalled);
                 TInt index = 0;
@@ -1267,7 +1265,7 @@
                     affectedApps.Remove(index);
                     }
                 existingAppInfo = TAppUpdateInfo(newAppUids[i],EAppInstalled);
-                affectedApps.Append(existingAppInfo);            
+                affectedApps.AppendL(existingAppInfo);            
                 }        
             }
         
--- a/installationservices/swi/source/swis/server/installmachine.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/swis/server/installmachine.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,4 +1,4 @@
-/*
+	/*
 * Copyright (c) 2004-2010 Nokia Corporation and/or its subsidiary(-ies).
 * All rights reserved.
 * This component and the accompanying materials are made available
@@ -60,6 +60,7 @@
 #include "swi/sisversion.h"
 #include "swi/nativecomponentinfo.h"
 #include <usif/usifcommon.h>
+#include <usif/scr/appregentries.h>
 #include "scrdbconstants.h"
 #endif
 
@@ -70,6 +71,23 @@
 _LIT(KCertifiedSignedOID, "1.2.826.0.1.1796587.1.1.2.2"); 
 _LIT(KCertifiedSignedWithVerisignOID, "1.2.826.0.1.1796587.1.1.2.3"); 
 
+
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+
+void DeRegisterForceRegisteredAppsL()
+	{
+	// Deregister the force registered applications from AppArc
+	DEBUG_PRINTF(_L8("Deregistering the force registered applications with AppArc"));
+	RSisLauncherSession launcher;
+	CleanupClosePushL(launcher);
+	User::LeaveIfError(launcher.Connect());
+	RPointerArray<Usif::CApplicationRegistrationData> emptyAppRegDataArray;
+	launcher.NotifyNewAppsL(emptyAppRegDataArray);
+	CleanupStack::PopAndDestroy(&launcher);
+	}
+
+#endif
+
 //
 // TInstallState
 //
@@ -525,8 +543,13 @@
 
 	        TRAPD(err, (allowSelfSigned = secSettingsSession.SettingValueL(KUidInstallationRepository , KAllowSelfSignedInstallKey)));
 
-	        if( err == KErrNone || err == KErrSettingNotFound || err == KErrNotFound)
+	        if( err == KErrNone || err == KErrSettingNotFound || err == KErrNotFound || err == KErrCorrupt)
 				{
+                 if (err == KErrCorrupt)
+	                {
+                         DEBUG_PRINTF(_L8("Install Machine - CenRep file 2002cff6.txt is corrupt. Using Default Value to Install."));
+	                }
+				                  
 	             if (!allowSelfSigned || !SecurityAlertL(ETrue))
 					{
 	                 User::Leave(KErrCancel);
@@ -1213,6 +1236,11 @@
 void CInstallMachine::TIntegritySupportState::Cancel()
 	{
 	DEBUG_PRINTF(_L8("Install Machine - Cancelling Integrity Support State"));
+
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+	DeRegisterForceRegisteredAppsL();
+#endif
+
 	if (iInstallMachine.iProcessor)
 		{
 		iInstallMachine.iProcessor->Cancel();
@@ -1400,7 +1428,11 @@
 			}
 		}
 	
-	iInstallMachine.CompleteSelf();
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+	DeRegisterForceRegisteredAppsL();
+#endif
+
+    iInstallMachine.CompleteSelf();
 	iInstallMachine.SetActive();
 	}
     
@@ -1420,6 +1452,9 @@
 
 void CInstallMachine::TFinalState::Cancel()
 	{
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+	DeRegisterForceRegisteredAppsL();
+#endif
 	}
 
 //
--- a/installationservices/swi/source/swis/server/restorecontroller.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/swis/server/restorecontroller.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2004-2010 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 "Eclipse Public License v1.0"
@@ -93,13 +93,15 @@
 			application->UserSelections().SetDrive(iInstallDrive);		
 			
 			//if there are macthing languages then populate iMatchingDeviceLanguages array of application object
-			if ( noOfMatchingLanguages )
-				{
+			if (noOfMatchingLanguages)
+				{				
 				while( iMatchingSupportedLanguagesArray[matchingLanguageCount] != ELangNone)
-					{
-					application->PopulateMatchingDeviceLanguagesL(iMatchingSupportedLanguagesArray[matchingLanguageCount++]);
-					}
+					{		
+					DEBUG_PRINTF2(_L8("Device matching language for Restore - %d"),iMatchingSupportedLanguagesArray[matchingLanguageCount]);
+					application->PopulateMatchingDeviceLanguagesL(iMatchingSupportedLanguagesArray[matchingLanguageCount++]);					
+					}				
 				}
+			++matchingLanguageCount;
  			break;
  		
  		case EInstPartialUpgrade:
@@ -128,13 +130,16 @@
 			application->UserSelections().SetDrive(iAugmentationDrives[augmentationIndex++]);
 			
 			//if there are macthing languages then populate iMatchingDeviceLanguages array of application object
-			if ( noOfMatchingLanguages )
-				{
+			if ( noOfMatchingLanguages)
+				{				
 				while( iMatchingSupportedLanguagesArray[matchingLanguageCount] != ELangNone)
 					  {
-					   application->PopulateMatchingDeviceLanguagesL(iMatchingSupportedLanguagesArray[matchingLanguageCount++]);
-					  }
+					  DEBUG_PRINTF2(_L8("Device matching language for Restore - %d"),iMatchingSupportedLanguagesArray[matchingLanguageCount]);
+					  application->PopulateMatchingDeviceLanguagesL(iMatchingSupportedLanguagesArray[matchingLanguageCount++]);
+					   
+					  }				
 				}
+			++matchingLanguageCount;
 			break;
  			
  		default:
--- a/installationservices/swi/source/swis/server/restoremachine.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/swis/server/restoremachine.cpp	Fri May 14 15:58:48 2010 +0300
@@ -881,13 +881,33 @@
 		ASSERT(controllerBinaries.Count() == iPlans.Count());
 		DEBUG_PRINTF3(_L8("Restoring plan %d out of %d"), iPlanIndex, iPlans.Count());
 		const TDesC8& controllerBinary = *controllerBinaries[iPlanIndex];
+		
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+		/*During restore the controllers are processed sequentialy one by one, ecah controller has one CPlan object (which internally has
+		CApplication object), we maintain the set of affected apps for each controller within its CPlan object(done while doning processing)
+		and we use the same set of affected apps for the subsequent controllers. For example In case of SP over SA ,while processing the SA controller we will not have
+		any affected apps as it is the first controller but for the second SP controller we will tahke the affected apps from the previously 
+		processed controller ie SA.
+		*/
+		RArray<TAppUpdateInfo> appInfo;
+		CleanupClosePushL(appInfo);		
+		if(iPlanIndex > 0)
+		    {
+		    iPlans[iPlanIndex-1]->GetAffectedApps(appInfo);
+		    }
+#endif
+		
 		iProcessor = CRestoreProcessor::NewL(*(iPlans[iPlanIndex]), controllerBinary, iSecurityManager,
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-			iStsSession, iRegistrySession,
+			iStsSession, iRegistrySession, appInfo,
 #else
 			iIntegrityServices,
 #endif
 			iRestoreController.Verifiers(), baseSids, iMachine.Observer()); 
+
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK		
+		CleanupStack::Pop(&appInfo);
+#endif
 		iProcessor->ProcessPlanL(iStatus);
 		CleanupStack::PopAndDestroy(&baseSids);
 		
@@ -1078,6 +1098,41 @@
 		// failure - therefore we commit STS first and then the registry 
 		iStsSession.CommitL();
 		iRegistrySession.CommitTransactionL();
+   
+		CPlan* lastPlan = iPlans[iPlans.Count()-1];
+		if (lastPlan)
+            {
+            RSisLauncherSession launcher;  
+            CleanupClosePushL(launcher);
+            if (launcher.Connect() != KErrNone)
+                {
+                iMachine.Observer().CommitL();
+                User::LeaveIfError(RProperty::Set(pubsubCategory, KUidSoftwareInstallKey, ESwisNone));
+                iClientMessage.Complete(iStatus.Int());
+                DEBUG_PRINTF(_L8("Install Machine - Failed to connect to SisLauncher"));
+                CleanupStack::Pop(&launcher);
+                launcher.Close();
+                return;
+                }             
+             //Notify apparc for the the change in the Applications
+             RArray<TAppUpdateInfo> affectedApps;
+             CleanupClosePushL(affectedApps);
+             lastPlan->GetAffectedApps(affectedApps);
+#ifdef _DEBUG             
+             for(TInt i = 0; i < affectedApps.Count(); i++)
+                  {
+                  DEBUG_PRINTF2(_L("Affected AppUid during restore is 0x%x"), affectedApps[i].iAppUid);
+                  DEBUG_PRINTF2(_L("Action to be performed is %d"), affectedApps[i].iAction);
+                  }  
+#endif             
+             if (affectedApps.Count() > 0)
+                  {
+                  launcher.NotifyNewAppsL(affectedApps);
+                  }          
+             CleanupStack::PopAndDestroy(2, &launcher);             
+             }        
+       
+		
 #else
 		iIntegrityServices.CommitL();
 #endif
--- a/installationservices/swi/source/swis/server/restoreprocessor.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/swis/server/restoreprocessor.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2004-2010 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 "Eclipse Public License v1.0"
@@ -22,6 +22,7 @@
 #include <usif/sts/sts.h>
 #include "swtypereginfo.h"
 #include "installswtypehelper.h"
+#include "cleanuputils.h"
 #else
 #include "integrityservices.h"
 #endif
@@ -38,6 +39,8 @@
 #include "securitycheckutil.h"
 #include "sidcache.h"
 #include <f32file.h>
+#include "userselections.h"
+#include "sissupportedlanguages.h"
 
 using namespace Swi; 
 
@@ -45,23 +48,28 @@
 //
 // CRestoreProcessor
 //
-	
+
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+_LIT(KApparcRegDir, "\\private\\10003a3f\\import\\apps\\");
+#endif
+
 CRestoreProcessor::CRestoreProcessor(const CPlan& aPlan, const TDesC8& aControllerBuffer,
 	CSecurityManager& aSecurityManager,	
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-	Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession,
+	Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession, RArray<TAppUpdateInfo>& aAppInfo,
 #else
 	CIntegrityServices& aIntegrityServices,
 #endif
-	const RPointerArray<CRestoreController::CSisCertificateVerifier>& aVerifiers,RSwiObserverSession& aObserver)
+	const RPointerArray<CRestoreController::CSisCertificateVerifier>& aVerifiers, RSwiObserverSession& aObserver)
 	: CActive(CActive::EPriorityStandard),
 	  iVerifiers(aVerifiers),
 	  iSecurityManager(aSecurityManager),
 	  iControllerBuffer(aControllerBuffer),	  
-	  iPlan(aPlan),
+	  iPlan(aPlan),	  
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
 	  iStsSession(aStsSession),
 	  iRegistrySession(aRegistrySession),
+	  iAppInfo(aAppInfo),
 #else
 	  iIntegrityServices(aIntegrityServices),
 #endif
@@ -73,7 +81,7 @@
 		
 CRestoreProcessor* CRestoreProcessor::NewL(const CPlan& aPlan, const TDesC8& aControllerBuffer, CSecurityManager& aSecurityManager,
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-	Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession,
+	Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession, RArray<TAppUpdateInfo>& aAppInfo,
 #else
 	CIntegrityServices& aIntegrityServices,
 #endif
@@ -82,7 +90,7 @@
 	{
 	CRestoreProcessor* self = CRestoreProcessor::NewLC(aPlan, aControllerBuffer, aSecurityManager,
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-			aStsSession, aRegistrySession,
+			aStsSession, aRegistrySession,aAppInfo,
 #else
 			aIntegrityServices, 
 #endif
@@ -93,7 +101,7 @@
 		
 CRestoreProcessor* CRestoreProcessor::NewLC(const CPlan& aPlan, const TDesC8& aControllerBuffer, CSecurityManager& aSecurityManager,
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-	Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession,
+	Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession, RArray<TAppUpdateInfo>& aAppInfo,
 #else
 	CIntegrityServices& aIntegrityServices,
 #endif
@@ -102,7 +110,7 @@
 	{
 	CRestoreProcessor* self = new (ELeave) CRestoreProcessor(aPlan, aControllerBuffer, aSecurityManager,
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-		aStsSession, aRegistrySession,
+		aStsSession, aRegistrySession,aAppInfo,
 #else
 		aIntegrityServices, 
 #endif
@@ -256,7 +264,13 @@
 			}
 			
 		//Get file description	
-		CSisRegistryFileDescription* regFileDes = iApplication->FilesToAdd()[iCurrent++];											
+		CSisRegistryFileDescription* regFileDes = iApplication->FilesToAdd()[iCurrent++];
+
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK 		
+		// Add apparc registerd files in list.
+		AddApparcFilesInListL(regFileDes->Target(), *iApplication);
+#endif
+		
 		//Complete actual file installation
 		InstallFileL(*regFileDes);
 		TUint8 fileFlag(EFileAdded);
@@ -288,6 +302,110 @@
 	
 TBool CRestoreProcessor::DoStateUpdateRegistryL()
 	{
+	
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK 
+    // Taking the previous controller's affected apps
+    RArray<TAppUpdateInfo>& affectedApps = iAppInfo;        
+    const CApplication& application = *iApplication;   // current application
+	//if there are reg files in the package or if its an upgrade (in case of SA (with app) over SA(with no app))
+    if(iApparcRegFilesForParsing.Count() != 0 || application.IsUpgrade())
+        {
+        //Create the list of Application Uids which are affected by the Restore                   
+        Usif::TComponentId componentId = 0;
+        RArray<Usif::TComponentId> componentIds;
+        CleanupClosePushL(componentIds);
+        RArray<TUid> existingAppUids;
+        CleanupClosePushL(existingAppUids);
+        TAppUpdateInfo existingAppInfo;     
+        TUid packageUid = application.ControllerL().Info().Uid().Uid();
+        
+        if(application.IsUpgrade())
+            {           
+            //Get all componentIds
+            iRegistrySession.GetComponentIdsForUidL(packageUid, componentIds);            
+            TInt count = componentIds.Count();
+            if(0 == count)
+                {
+                DEBUG_PRINTF(_L("ComponentIDs not found for the base package"));
+                User::Leave(KErrNotFound);
+                }
+                                
+            //SA over SA
+            if(application.ControllerL().Info().InstallType() == Sis::EInstInstallation )
+                {        
+                //Get the compid for base package
+                componentId = iRegistrySession.GetComponentIdForUidL(packageUid);              
+                      
+                TInt index = componentIds.Find(componentId);
+             
+                //Exclude the Base SA compId from the list 
+                componentIds.Remove(index);
+             
+                //Get the apps for Base SA compId and mark them as to be deleted
+                existingAppUids.Reset();
+                TRAPD(err,iRegistrySession.GetAppUidsForComponentL(componentId, existingAppUids);)  
+                //If Base Package does not contain any app then GetAppUidsForComponentL will return KErrNotFound, ignore the error else leave
+                if (KErrNone != err && KErrNotFound != err)
+                    {
+                    User::Leave(err);
+                    }
+                
+                for(TInt i = 0 ; i < existingAppUids.Count(); ++i)
+                    {
+                    existingAppInfo = TAppUpdateInfo(existingAppUids[i], EAppUninstalled);    
+                    affectedApps.AppendL(existingAppInfo);
+                    }                
+                //Get the apps for Remaining CompIds(SP's) and mark them as to be upgraded               
+                for(TInt i = 0 ; i < componentIds.Count(); ++i)
+                    {
+                    existingAppUids.Reset();             
+                    //If there are no apps within the components (SP's) then it will return KErrNotFound
+                    TRAP(err, iRegistrySession.GetAppUidsForComponentL(componentIds[i], existingAppUids);) 
+                    if (KErrNone != err && KErrNotFound != err)
+                        {
+                        User::Leave(err);
+                        }
+                    
+                    for(TInt k = 0 ; k < existingAppUids.Count(); ++k)
+                        {
+                        existingAppInfo = TAppUpdateInfo(existingAppUids[i], EAppInstalled);    
+                        affectedApps.AppendL(existingAppInfo);
+                        }
+                    }                                
+                }
+                
+            //SP over SP
+            if(application.ControllerL().Info().InstallType() == Sis::EInstAugmentation)
+                {
+                componentId = iRegistrySession.GetComponentIdForPackageL(application.PackageL().Name(), application.PackageL().Vendor());                
+                //Get the apps for Base SP compId and mark them as to be deleted
+                existingAppUids.Reset();
+                TRAPD(err, iRegistrySession.GetAppUidsForComponentL(componentId, existingAppUids);) 
+                if (KErrNone != err && KErrNotFound != err)
+                    {
+                    User::Leave(err);
+                    }
+                
+                for(TInt k = 0 ; k < existingAppUids.Count(); ++k)
+                   {
+                   // Search for the app in the existing set of affected apps, if already present mark them as UnInstalled else add a new entry
+                   TInt index = FindAppEntry(affectedApps, existingAppUids[k]);
+                   if (KErrNotFound != index)
+                       {
+                       affectedApps[index].iAction = EAppUninstalled;
+                       }
+                   else
+                       {
+                       existingAppInfo = TAppUpdateInfo(existingAppUids[k], EAppUninstalled);    
+                       affectedApps.AppendL(existingAppInfo);
+                       }                   
+                   }                                  
+                }        
+            }                   
+        CleanupStack::PopAndDestroy(2, &componentIds);   
+        }       
+#endif
+	
 #ifndef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
 	RSisRegistryWritableSession session;
 	User::LeaveIfError(session.Connect());
@@ -319,6 +437,11 @@
 			{
 			iRegistrySession.UpdateEntryL(*iApplication, iControllerBuffer, iStsSession.TransactionIdL());
 			}
+		TInt count = iApparcRegFileData.Count();
+        for (int i = 0; i < count; i++)
+            {
+            iRegistrySession.UpdateEntryL(*iApplication, *iApparcRegFileData[i], iApparcRegFilesForParsing[i]->GetSisRegistryPackage());
+            }
 #else
  		session.UpdateEntryL(*iApplication, iControllerBuffer, iIntegrityServices.TransactionId());
 #endif
@@ -334,6 +457,11 @@
 			{
 			iRegistrySession.AddEntryL(*iApplication, iControllerBuffer, iStsSession.TransactionIdL());
 			}
+		TInt count = iApparcRegFileData.Count();
+        for (int i = 0; i < count; i++)
+            {
+            iRegistrySession.AddEntryL(*iApparcRegFileData[i], iApparcRegFilesForParsing[i]->GetSisRegistryPackage());
+            }
 #else
  		session.AddEntryL(*iApplication, iControllerBuffer, iIntegrityServices.TransactionId());
 #endif
@@ -342,11 +470,75 @@
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
 	// Registration of MIME types of the software types being installed to AppArc
 	InstallSoftwareTypeHelper::RegisterMimeTypesL(iSoftwareTypeRegInfoArray);
+	
+	//if there are reg files in the package or if its an upgrade (in case of SA (with app) over SA(with no app))
+	if(iApparcRegFilesForParsing.Count() != 0 || application.IsUpgrade())
+	        {
+	        //Create the list of Application Uids which are affected by the Restore                            
+	        RArray<Usif::TComponentId> componentIds;
+	        CleanupClosePushL(componentIds);
+	        RArray<TUid> newAppUids;    
+	        CleanupClosePushL(newAppUids);
+	        TAppUpdateInfo existingAppInfo, newAppInfo;     
+	        TUid packageUid = application.ControllerL().Info().Uid().Uid();
+	        //Get all componentIds for the application
+	        componentIds.Reset();
+	        iRegistrySession.GetComponentIdsForUidL(packageUid, componentIds);
+	        TInt count = componentIds.Count();
+	        
+	        //Get the apps for All CompIds               
+	        for(TInt i = 0 ; i < count; i++)
+	            {
+	            newAppUids.Reset();                    
+	            TRAPD(err,iRegistrySession.GetAppUidsForComponentL(componentIds[i], newAppUids))
+	            if (KErrNone != err && KErrNotFound != err)
+	                {
+	                User::Leave(err);
+	                }
+	            
+	            for(TInt i = 0 ; i < newAppUids.Count(); ++i)
+	                {	               	                
+	                TInt index = 0;		
+	                // Search for the app in the existing set of affected apps, if already present mark them as UnInstalled else add a new entry
+	                index = FindAppEntry(affectedApps, newAppUids[i]);
+	                if(index != KErrNotFound)
+	                    {
+	                    affectedApps[index].iAction = EAppInstalled;
+	                    }
+	                else
+	                    {
+	                    existingAppInfo = TAppUpdateInfo(newAppUids[i], EAppInstalled);
+	                    affectedApps.AppendL(existingAppInfo);
+	                    }
+	                }  		           
+	            }
+	        
+	        const_cast<CPlan&>(iPlan).ResetAffectedApps();
+	        const_cast<CPlan&>(iPlan).SetAffectedApps(affectedApps);
+	        
+	        CleanupStack::PopAndDestroy(2, &componentIds);
+	        }
+	
 #else
 	CleanupStack::PopAndDestroy(&session);
 #endif
 	return ETrue;
 	}
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+TInt CRestoreProcessor::FindAppEntry(RArray<TAppUpdateInfo>& aAffectedApps, TUid& aNewAppUid)
+    {
+    TInt count = aAffectedApps.Count();
+    for(TInt index = 0; index < count ; index++)
+        {
+        if(aAffectedApps[index].iAppUid == aNewAppUid)
+            {           
+            return index;
+            }
+        }
+    return KErrNotFound;
+    }
+#endif
+
 
 TBool CRestoreProcessor::DoStateProcessFilesL()
 	{
@@ -405,12 +597,78 @@
 		return EFalse;		
 		}
 	else 
-		{			
+		{
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK                
+        // Find out all the regisration resource files associated with this package UID and add to the list of 
+        // files to be processed later for parsing      
+        TRAPD(err, AddAppArcRegResourceFilesL());
+        if ( err != KErrNotFound && err != KErrNone)
+            {
+            User::Leave(err);
+            }
+#endif
 		iCurrent = 0;
 		return ETrue;		
 		}		
 	}
 	
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+void CRestoreProcessor::AddAppArcRegResourceFilesL()
+    {
+    RSisRegistryEntry entry;
+    TInt err = KErrNone;
+    if (!iApplication->IsUninstall())
+        err = entry.Open(iRegistrySession, iApplication->ControllerL().Info().Uid().Uid());
+    else
+        return;
+    
+    User::LeaveIfError(err);
+    CleanupClosePushL(entry);
+    AddAppArcRegResourceFilesForRegEntryL(entry);
+    
+    RPointerArray<CSisRegistryPackage> augmentationArray;
+    CleanupResetAndDestroyPushL(augmentationArray);
+    entry.AugmentationsL(augmentationArray);
+    CleanupStack::Pop(&augmentationArray);
+    CleanupStack::PopAndDestroy(&entry);    
+        
+    CleanupResetAndDestroyPushL(augmentationArray);
+    TInt count = augmentationArray.Count();
+    for ( TInt i=0; i < count; ++i)
+        {
+        TInt err = entry.OpenL(iRegistrySession,*augmentationArray[i]);
+        User::LeaveIfError(err);
+        CleanupClosePushL(entry);
+        AddAppArcRegResourceFilesForRegEntryL(entry);
+        CleanupStack::PopAndDestroy(&entry);
+        }
+    
+    CleanupStack::PopAndDestroy(&augmentationArray);
+    }
+
+void CRestoreProcessor::AddAppArcRegResourceFilesForRegEntryL(RSisRegistryEntry& aEntry)
+    {
+    RPointerArray<HBufC> filesArray;
+    CleanupResetAndDestroyPushL(filesArray);
+    aEntry.FilesL(filesArray);    
+    TInt count = filesArray.Count();
+    CSisRegistryPackage *regPkg = aEntry.PackageL();
+    CleanupStack::PushL(regPkg);
+    
+    for (TInt i=0; i<count; ++i)
+        {
+        if (FileIsApparcReg(*filesArray[i]))
+            {
+            CAppRegFileData *tmpAppRegFileData = CAppRegFileData::NewLC(*filesArray[i],*regPkg);
+            iApparcRegFilesForParsing.AppendL(tmpAppRegFileData);
+            CleanupStack::Pop(tmpAppRegFileData);
+            }
+        }
+    CleanupStack::PopAndDestroy(2,&filesArray);
+    }
+#endif
+
+
 TBool CRestoreProcessor::DoStateVerifyPathsL() 
 	{
 	if (iCurrent < iApplication->FilesToAdd().Count())
@@ -475,10 +733,21 @@
 	case EInstallFiles:
 		if (DoStateInstallFilesL())
 			{
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK           
+            SwitchState(EParseApplicationRegistrationFiles);
+#else
+            SwitchState(EUpdateRegistry);
+#endif          
+            }
+        break;
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+    case EParseApplicationRegistrationFiles:
+        if (DoParseApplicationRegistrationFilesL())
+            {
 			SwitchState(EUpdateRegistry);
 			}
 		break;
-
+#endif
 	case EUpdateRegistry:
 		if (DoStateUpdateRegistryL())
 			{
@@ -548,8 +817,134 @@
 	delete iFileMan;
 	iFs.Close();
 	iSids.Close();
-	
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-	iSoftwareTypeRegInfoArray.Close();
+    iSoftwareTypeRegInfoArray.Close();  
+    iApparcRegFilesForParsing.ResetAndDestroy();
+    iApparcRegFileData.ResetAndDestroy();
+    delete iAppRegExtractor;   
+    iAppInfo.Close();
 #endif
 	}
+
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+
+TBool CRestoreProcessor::ParseRegistrationResourceFileL(const TDesC& aTargetFileName)
+    {
+    DEBUG_PRINTF2(_L("Restore Processor - ParseRegistrationResourceFileL - Parsing '%S' registration resource file"), &aTargetFileName);
+ 
+    if ( NULL == iAppRegExtractor )
+        {
+        DEBUG_PRINTF(_L("Restore Processor - ParseRegistrationResourceFileL - Creating CAppRegExtractor for async parsing of registration resource file"));
+        CApplication& app = const_cast<CApplication&>(*iApplication);
+        const RArray<TInt>& matchingLanguages = app.GetMatchingDeviceLanguages();        
+        TInt userSelectedLanguage = (TInt)iApplication->UserSelections().Language();
+        TInt res = matchingLanguages.Find(userSelectedLanguage);
+        if(res == KErrNotFound)
+            {
+            app.PopulateMatchingDeviceLanguagesL(userSelectedLanguage);
+            }            
+        const RArray<TInt>& matchingLanguages1 = app.GetMatchingDeviceLanguages();        
+        RArray<TLanguage> devLanguages;
+        CleanupClosePushL(devLanguages);       
+        TInt count = matchingLanguages1.Count();
+        DEBUG_PRINTF2(_L("Restore Processor - ParseRegistrationResourceFileL - %d matching languages found"),count);
+        for ( TInt i=0; i<count; i++)
+            {
+            devLanguages.Append((TLanguage)matchingLanguages1[i]);            
+            }
+        
+        iAppRegExtractor = CAppRegExtractor::NewL(iFs,devLanguages,iApparcRegFileData);
+        CleanupStack::Pop(&devLanguages);            
+        }
+        
+    iAppRegExtractor->ExtractAppRegInfoSizeL(aTargetFileName, iStatus);
+    return EFalse;
+    }
+
+TBool CRestoreProcessor::DoParseApplicationRegistrationFilesL()
+    {
+    if (iCurrent == 0)
+        DEBUG_PRINTF2(_L("Restore Processor - DoParseApplicationRegistrationFilesL - Number of Application registration resource files to be parsed %d"), iApparcRegFilesForParsing.Count());
+    
+    if (iAppRegExtractor != NULL)
+        {
+        if (iAppRegExtractor->GetErrorCode() == KErrCorrupt)
+            {
+            delete iApparcRegFilesForParsing[--iCurrent];
+            iApparcRegFilesForParsing.Remove(iCurrent);
+            }
+        }
+    
+    if (iCurrent < iApparcRegFilesForParsing.Count())
+        { 
+        TDesC& fileDescription = (iApparcRegFilesForParsing[iCurrent++]->GetAppRegFile());   
+        // Continue processing the next file if a registration resource file is not found(in case of SA over SA)
+        TRAPD(err,ParseRegistrationResourceFileL(fileDescription));        
+        if(KErrNotFound == err || KErrPathNotFound == err)
+            {               
+            delete iApparcRegFilesForParsing[--iCurrent];
+            iApparcRegFilesForParsing.Remove(iCurrent); 
+            TRequestStatus* status = &iStatus;
+            User::RequestComplete(status, KErrNone);     
+            SetActive();
+            }
+        else if(KErrNone != err )
+            {
+            User::Leave(err);
+            }
+        else
+            {
+            SetActive();
+            }
+        return EFalse;
+        }
+    else
+        {
+        iCurrent = 0;
+        return ETrue;
+        }
+    }
+
+TBool CRestoreProcessor::FileIsApparcReg(const TDesC& aFilename) const
+    {
+    TParsePtrC filename(aFilename);
+    return filename.Path().CompareF(KApparcRegDir) == 0;
+    }
+	
+void CRestoreProcessor::AddApparcFilesInListL(const TDesC& aTargetFileName, const CApplication& aApplication)
+    {    
+    if (FileIsApparcReg(aTargetFileName))
+        {
+        // we're installing a reg file so add it to our list for parsing it and 
+        // populating SCR in EParseApplicationRegistrationFiles state of CProcessor     
+        TInt index = UserSelectedLanguageIndexL(aApplication);
+        CSisRegistryPackage *regPkg = CSisRegistryPackage::NewLC(aApplication.ControllerL().Info().Uid().Uid(),\
+                aApplication.ControllerL().Info().Names()[index]->Data(),\
+                aApplication.ControllerL().Info().UniqueVendorName().Data());
+        CAppRegFileData *appRegData =CAppRegFileData::NewLC(aTargetFileName,*regPkg);
+        iApparcRegFilesForParsing.AppendL(appRegData);
+        CleanupStack::Pop(appRegData);  
+        CleanupStack::PopAndDestroy(regPkg);
+        }
+    }
+
+TInt CRestoreProcessor::UserSelectedLanguageIndexL(const CApplication& aApplication) const
+// used to find out which is the index of the selected language, 
+// based on the language selection. This will be used for the relevant package and vendor names
+    {
+    TLanguage language = aApplication.UserSelections().Language();
+    
+    TInt index = KErrNotFound;
+    for (TInt i = 0; i < aApplication.ControllerL().SupportedLanguages().Count(); i++)
+        {
+        if (aApplication.ControllerL().SupportedLanguages()[i] == language)
+            {
+            index = i;
+            break;  
+            }
+        }
+    User::LeaveIfError(index);
+    return index;
+    }   
+#endif
+
--- a/installationservices/swi/source/swis/server/restoreprocessor.h	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/swis/server/restoreprocessor.h	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2004-2010 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 "Eclipse Public License v1.0"
@@ -39,6 +39,7 @@
 namespace Swi 
 	{
 	class CPlan;
+
 	
 	/**
 	 * State machine to handle securely restoring files the user
@@ -58,6 +59,9 @@
 			EProcessFiles,
 			EVerifyPaths,
 			EInstallFiles,
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+			EParseApplicationRegistrationFiles,
+#endif
 			EUpdateRegistry,
 			EFinished,
 			ECurrentState=128, // Used to change to the current state
@@ -68,7 +72,7 @@
 		static CRestoreProcessor* NewL(const CPlan& aPlan, const TDesC8& aControllerBuffer, 
 			CSecurityManager& aSecurityManager,	
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-			Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession,
+			Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession, RArray<TAppUpdateInfo>& aAppInfo,
 #else
 			CIntegrityServices& aIntegrityServices,
 #endif
@@ -78,7 +82,7 @@
 		static CRestoreProcessor* NewLC(const CPlan& aPlan, const TDesC8& aControllerBuffer,
 			CSecurityManager& aSecurityManager, 
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-			Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession,
+			Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession, RArray<TAppUpdateInfo>& aAppInfo,
 #else
 			CIntegrityServices& aIntegrityServices,
 #endif
@@ -100,7 +104,7 @@
 		CRestoreProcessor(const CPlan& aPlan, const TDesC8& aControllerBuffer,
 			CSecurityManager& aSecurityManager,	
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-			Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession,
+			Usif::RStsSession& aStsSession, RSisRegistryWritableSession& aRegistrySession, RArray<TAppUpdateInfo>& aAppInfo,
 #else
 			CIntegrityServices& aIntegrityServices,
 #endif
@@ -108,7 +112,18 @@
 			RSwiObserverSession& aObserver);
 		
 		void ConstructL(RArray<TUid>& aSids);
-		void ProcessApplicationL(const CApplication& aApplication, TRequestStatus& aClientStatus);		
+		void ProcessApplicationL(const CApplication& aApplication, TRequestStatus& aClientStatus);	
+
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK		
+		TBool FileIsApparcReg(const TDesC& aFilename) const;
+		void AddApparcFilesInListL(const TDesC& aTargetFileName, const CApplication& aApplication);
+		TInt UserSelectedLanguageIndexL(const CApplication& aApplication) const;
+		TBool DoParseApplicationRegistrationFilesL();
+		TBool ParseRegistrationResourceFileL(const TDesC& aTargetFileName);
+		void AddAppArcRegResourceFilesL();
+		void AddAppArcRegResourceFilesForRegEntryL( RSisRegistryEntry& aEntry);
+		TInt FindAppEntry(RArray<TAppUpdateInfo>& aAffectedApps, TUid& aNewAppUid);
+#endif
 	private:
 	
 		// Processor states, called by the state machine
@@ -140,6 +155,13 @@
 		RSisRegistryWritableSession& iRegistrySession;
 		/** The list of software types to be registered found in the XML registration file. */
 		RCPointerArray<CSoftwareTypeRegInfo> iSoftwareTypeRegInfoArray;
+		/**
+        * The list of Apparc registration files to parse to populate SCR
+        */ 
+        RPointerArray<CAppRegFileData> iApparcRegFilesForParsing;
+        CAppRegExtractor *iAppRegExtractor;  
+        RPointerArray<Usif::CApplicationRegistrationData> iApparcRegFileData;   
+        RArray<TAppUpdateInfo> iAppInfo;
 #else
 		CIntegrityServices& iIntegrityServices;
 #endif
@@ -148,8 +170,8 @@
 		
 		/// The drive on which to store device integrity data (hashes, registry etc) 
 		TChar iSystemDriveChar;
-		RSwiObserverSession& iObserver; ///< SWI Observer session handle provided by SWIS.
-		};
+		RSwiObserverSession& iObserver; ///< SWI Observer session handle provided by SWIS.				
+		};	
 	}
 
 #endif //__RESTOREPROCESSOR_H__
--- a/installationservices/swi/source/swis/server/statemachine.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/source/swis/server/statemachine.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2004-2010 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 "Eclipse Public License v1.0"
@@ -20,6 +20,7 @@
 #include "log.h"
 #include "plan.h"
 #include "swispubsubdefs.h"
+#include <usif/scr/appregentries.h>
 
 namespace Swi
 {
@@ -349,6 +350,18 @@
 		}
 #endif
 
+	
+#ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
+	// Deregister the force registered applications from AppArc
+	DEBUG_PRINTF(_L8("Deregistering the force registered applications with AppArc"));
+	RSisLauncherSession launcher;
+	CleanupClosePushL(launcher);
+	User::LeaveIfError(launcher.Connect());
+	RPointerArray<Usif::CApplicationRegistrationData> emptyAppRegDataArray;
+	launcher.NotifyNewAppsL(emptyAppRegDataArray);
+	CleanupStack::PopAndDestroy(&launcher);
+#endif
+
 	iMessage.Complete(aError);
 	return KErrNone;
 	}
--- a/installationservices/swi/test/tbackuprestore/scripts/batchfiles/tbackuprestore_post.bat	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/tbackuprestore/scripts/batchfiles/tbackuprestore_post.bat	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 @rem
-@rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+@rem Copyright (c) 2009-2010 Nokia Corporation and/or its subsidiary(-ies).
 @rem All rights reserved.
 @rem This component and the accompanying materials are made available
 @rem under the terms of the License "Eclipse Public License v1.0"
@@ -22,11 +22,16 @@
 del /s /f /q \epoc32\winscw\c\tswi\tbackuprestore\backup*.*
 del /s /f /q \epoc32\winscw\c\tswi\tbackuprestore\metadata*
 
+copy /y \epoc32\release\winscw\udeb\z\resource\temp\swicertstore.dat \epoc32\release\winscw\udeb\z\resource\swicertstore.dat
+copy /y \epoc32\release\winscw\urel\z\resource\temp\swicertstore.dat \epoc32\release\winscw\urel\z\resource\swicertstore.dat
+
+
 rem cleanup anything from previous tests.
+RMDIR /s /q \epoc32\release\winscw\udeb\z\resource\temp
 del /f /q \epoc32\winscw\c\sys\install\scr\scr.*
 del /s /f /q \epoc32\winscw\c\sys\install\sisregistry\802730A0
 del /s /f /q \epoc32\winscw\c\sys\install\sisregistry\80000077
 del /s /f /q \epoc32\winscw\c\sys\install\sisregistry\80000076
 del /s /f /q \epoc32\winscw\c\sys\install\sisregistry\
 del /s /f /q \epoc32\winscw\c\sys\bin\
-del /s /f /q \epoc32\winscw\c\sys\hash\
\ No newline at end of file
+del /s /f /q \epoc32\winscw\c\sys\hash\
--- a/installationservices/swi/test/tbackuprestore/scripts/batchfiles/tbackuprestore_pre.bat	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/tbackuprestore/scripts/batchfiles/tbackuprestore_pre.bat	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 @rem
-@rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+@rem Copyright (c) 2009-2010 Nokia Corporation and/or its subsidiary(-ies).
 @rem All rights reserved.
 @rem This component and the accompanying materials are made available
 @rem under the terms of the License "Eclipse Public License v1.0"
@@ -19,6 +19,15 @@
 
 copy \epoc32\release\winscw\urel\tswisidupgradeexe.exe \epoc32\release\winscw\urel\z\sys\bin\tswisidupgradeexe.exe
 
+mkdir \epoc32\release\winscw\udeb\z\resource\temp
+mkdir \epoc32\release\winscw\urel\z\resource\temp
+
+copy \epoc32\release\winscw\udeb\z\resource\swicertstore.dat \epoc32\release\winscw\urel\z\resource\temp\swicertstore.dat
+copy \epoc32\release\winscw\urel\z\resource\swicertstore.dat \epoc32\release\winscw\urel\z\resource\temp\swicertstore.dat
+
+copy /y \epoc32\winscw\c\tswi\certstore\swicertstore_sucert.dat \epoc32\release\winscw\udeb\z\resource\swicertstore.dat
+copy /y \epoc32\winscw\c\tswi\certstore\swicertstore_sucert.dat \epoc32\release\winscw\urel\z\resource\swicertstore.dat
+
 rem cleanup anything from previous tests.
 del /f /q \epoc32\winscw\c\sys\install\scr\scr.db
 del /s /f /q \epoc32\winscw\c\sys\install\sisregistry\
\ No newline at end of file
--- a/installationservices/swi/test/tbackuprestore/scripts/ini	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/tbackuprestore/scripts/ini	Fri May 14 15:58:48 2010 +0300
@@ -1334,3 +1334,162 @@
 [API-INST-PAS-SWI-0001-A]
 PublishedUidCount=1
 PublishedUidValue0=88000106
+
+[AppRegData_Install]
+sis=z:\tswi\tsis\data\swiappregintegration01.sis
+script=z:\tswi\tuiscriptadaptors\scripts\devlangsel.xml
+devicelanguage0=01
+devicelanguage1=03
+devicelanguage2=24
+
+[AppRegData]
+SIS1 = z:\tswi\tsis\swiappregintegration01.sis
+UID1 = 80010002
+FILE1.1 = C:\sys\bin\swiappregintegration.exe
+FILE1.2 = C:\private\10003a3f\import\apps\swiappregintegration01_reg.rsc
+FILE1.3 = C:\resource\apps\swiappregintegration01_loc.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration01_rsc.mbm
+FILE1.5 = C:\resource\apps\swiappregintegration01_loc.r01
+FILE1.6 = C:\resource\apps\swiappregintegration01_01.mbm
+FILE1.7 = C:\resource\apps\swiappregintegration01_loc.r03
+FILE1.8 = C:\resource\apps\swiappregintegration01_03.mbm
+FILE1.9 = C:\resource\apps\swiappregintegration01_loc.r24
+FILE1.10 = C:\resource\apps\swiappregintegration01_24.mbm
+INSTALLDRIVE1 = C
+
+[AppRegData_Base]
+SIS1 = z:\tswi\tsis\swiappregintegration_base01.sis
+UID1 = 80010003
+FILE1.1 = C:\sys\bin\swiappregintegration_base01.exe
+FILE1.2 = C:\private\10003a3f\import\apps\swiappregintegration_base01_reg.rsc
+FILE1.3 = C:\resource\apps\swiappregintegration_base01_loc.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration_base01_rsc.mbm
+FILE1.5 = C:\resource\apps\swiappregintegration_base01_loc.r01
+FILE1.6 = C:\resource\apps\swiappregintegration_base01_01.mbm
+FILE1.7 = C:\resource\apps\swiappregintegration_base01_loc.r02
+FILE1.8 = C:\resource\apps\swiappregintegration_base01_02.mbm
+INSTALLDRIVE1 = C
+
+[AppRegData_WithUpgrade]
+SIS1 = z:\tswi\tsis\swiappregintegration_base02.sis
+UID1 = 80010003
+FILE1.1 = C:\sys\bin\swiappregintegration_base01.exe
+FILE1.2 = C:\sys\bin\swiappregintegration02.exe
+FILE1.3 = C:\private\10003a3f\import\apps\swiappregintegration_base01_reg.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration_base01_loc.rsc
+FILE1.5 = C:\resource\apps\swiappregintegration_base01_rsc.mbm
+FILE1.6 = C:\resource\apps\swiappregintegration_base01_loc.r01
+FILE1.7 = C:\resource\apps\swiappregintegration_base01_01.mbm
+FILE1.8 = C:\resource\apps\swiappregintegration_base01_loc.r02
+FILE1.9 = C:\resource\apps\swiappregintegration_base01_02.mbm
+FILE1.10 = C:\resource\apps\swiappregintegration_base01_loc.r03
+FILE1.11 = C:\resource\apps\swiappregintegration_base01_03.mbm
+FILE1.12 = C:\resource\apps\swiappregintegration02_loc.rsc
+FILE1.13 = C:\resource\apps\swiappregintegration02_rsc.mbm
+FILE1.14 = C:\resource\apps\swiappregintegration02_loc.r01
+FILE1.15 = C:\resource\apps\swiappregintegration02_01.mbm
+FILE1.16 = C:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc
+INSTALLDRIVE1 = C
+
+[swiappregintegration_sa_app]
+SIS1 = z:\tswi\tsis\swiappregintegration_case08_1_sa2.sis
+UID1 = 80010099
+FILE1.1 = C:\private\10003a3f\import\apps\swiappregintegration_case05_reg.rsc
+FILE1.2 = C:\resource\apps\swiappregintegration_case05_loc.r01
+FILE1.3 = C:\resource\apps\swiappregintegration.mbm
+INSTALLDRIVE1 = C
+
+[swiappregintegration_no_app]
+SIS1 = z:\tswi\tsis\swiappregintegration_case08_1_sa2.sis
+UID1 = 80010099
+
+[Install_NonRemovableBase]
+sis=z:\tswi\tsis\data\nonremovablebase_sucert.sis
+script=z:\tswi\tuiscriptadaptors\scripts\simple.xml
+
+[Upgrade_SP_Over_SA-NR]
+sis=z:\tswi\tsis\data\nonremovableupgrade.sis
+script=z:\tswi\tuiscriptadaptors\scripts\devlangsel.xml
+devicelanguage0=01
+
+[SP_Over_SA-NR]
+SIS1 = z:\tswi\tsis\nonremovableupgrade.sis
+UID1 = 0x80000002
+FILE1.1 = C:\sys\bin\swiappregintegration02.exe
+FILE1.2 = C:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc
+FILE1.3 = C:\resource\apps\swiappregintegration02_loc.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration02_rsc.mbm
+FILE1.5 = C:\resource\apps\swiappregintegration02_loc.r01
+FILE1.6 = C:\resource\apps\swiappregintegration02_01.mbm
+
+[uninstall_SP_Over_SA-NR]
+uid=80000002
+vendorName=Vendor
+packageName=swiappregintegration_base01_sp_EN
+script=z:\tswi\tuiscriptadaptors\scripts\uninstall.xml
+
+[Restore_SP_Upgrade]
+SIS1 = z:\tswi\tsis\data\swiappregintegration_base01.SIS
+UID1 = 80010003
+FILE1.1 = C:\sys\bin\swiappregintegration_base01.exe
+FILE1.2 = C:\private\10003a3f\import\apps\swiappregintegration_base01_reg.rsc
+FILE1.3 = C:\resource\apps\swiappregintegration_base01_loc.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration_base01_rsc.mbm
+FILE1.5 = C:\resource\apps\swiappregintegration_base01_loc.r01
+FILE1.6 = C:\resource\apps\swiappregintegration_base01_01.mbm
+FILE1.7 = C:\resource\apps\swiappregintegration_base01_loc.r02
+FILE1.8 = C:\resource\apps\swiappregintegration_base01_02.mbm
+FILE1.9 = C:\sys\bin\swiappregintegration02.exe
+FILE1.10 = C:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc
+FILE1.11 = C:\resource\apps\swiappregintegration02_loc.rsc
+FILE1.12 = C:\resource\apps\swiappregintegration02_rsc.mbm
+FILE1.13 = C:\resource\apps\swiappregintegration02_loc.r01
+FILE1.14 = C:\resource\apps\swiappregintegration02_01.mbm
+FILE1.15 = C:\resource\apps\swiappregintegration_base01_loc.r03
+FILE1.16 = C:\resource\apps\swiappregintegration_base01_03.mbm
+INSTALLDRIVE1 = C
+
+[Restore_PU_Upgrade]
+SIS1 = z:\tswi\tsis\data\swiappregintegration_base01.SIS
+UID1 = 80010003
+FILE1.1 = C:\sys\bin\swiappregintegration_base01.exe
+FILE1.2 = C:\private\10003a3f\import\apps\swiappregintegration_base01_reg.rsc
+FILE1.3 = C:\resource\apps\swiappregintegration_base01_loc.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration_base01_rsc.mbm
+FILE1.5 = C:\resource\apps\swiappregintegration_base01_loc.r01
+FILE1.6 = C:\resource\apps\swiappregintegration_base01_01.mbm
+FILE1.7 = C:\resource\apps\swiappregintegration_base01_loc.r02
+FILE1.8 = C:\resource\apps\swiappregintegration_base01_02.mbm
+FILE1.9 = C:\sys\bin\swiappregintegration02.exe
+FILE1.10 = C:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc
+FILE1.11 = C:\resource\apps\swiappregintegration02_loc.rsc
+FILE1.12 = C:\resource\apps\swiappregintegration02_rsc.mbm
+FILE1.13 = C:\resource\apps\swiappregintegration02_loc.r01
+FILE1.14 = C:\resource\apps\swiappregintegration02_01.mbm
+FILE1.15 = C:\resource\apps\swiappregintegration_base01_loc.r03
+FILE1.16 = C:\resource\apps\swiappregintegration_base01_03.mbm
+INSTALLDRIVE1 = C
+
+[AppRegData_embedded]
+SIS1 = z:\tswi\tsis\data\swiappregintegration_case06_sa.SIS
+UID1 = 80010099
+FILE1.1 = C:\private\10003a3f\import\apps\swiappregintegration_case05_reg.rsc
+FILE1.2 = C:\resource\apps\swiappregintegration_case05_loc.r01
+FILE1.3 = C:\resource\apps\swiappregintegration.mbm
+
+FILE1.4 = C:\sys\bin\swiappregintegration02.exe
+FILE1.5 = C:\resource\apps\swiappregintegration_case05_loc.r02
+FILE1.6 = C:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc
+FILE1.7 = C:\resource\apps\swiappregintegration02_loc.rsc
+FILE1.8 = C:\resource\apps\swiappregintegration02_rsc.mbm
+
+FILE1.9 = C:\sys\bin\swiappregintegration_case06.exe
+FILE1.10 = C:\private\10003a3f\import\apps\swiappregintegration_case06_reg.rsc
+FILE1.11 = C:\resource\apps\swiappregintegration_case06_loc.rsc
+
+FILE1.12 = C:\resource\apps\swiappregintegration_case05_loc.r04
+FILE1.13 = C:\sys\bin\swiappregintegration_case07.exe
+FILE1.14 = C:\private\10003a3f\import\apps\swiappregintegration_case07_reg.rsc
+FILE1.15 = C:\resource\apps\swiappregintegration_case07_loc.rsc
+INSTALLDRIVE1 = C
+
--- a/installationservices/swi/test/tbackuprestore/scripts/ini_armv5	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/tbackuprestore/scripts/ini_armv5	Fri May 14 15:58:48 2010 +0300
@@ -912,3 +912,163 @@
 [API-INST-PAS-SWI-0002]
 PublishedUidCount=1
 PublishedUidValue0=81113001
+
+[AppRegData_Install]
+sis=z:\tswi\tsis\data\swiappregintegration01.sis
+script=z:\tswi\tuiscriptadaptors\scripts\devlangsel.xml
+devicelanguage0=01
+devicelanguage1=03
+devicelanguage2=24
+
+[AppRegData]
+SIS1 = z:\tswi\tsis\swiappregintegration01.sis
+UID1 = 80010002
+FILE1.1 = C:\sys\bin\swiappregintegration.exe
+FILE1.2 = C:\private\10003a3f\import\apps\swiappregintegration01_reg.rsc
+FILE1.3 = C:\resource\apps\swiappregintegration01_loc.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration01_rsc.mbm
+FILE1.5 = C:\resource\apps\swiappregintegration01_loc.r01
+FILE1.6 = C:\resource\apps\swiappregintegration01_01.mbm
+FILE1.7 = C:\resource\apps\swiappregintegration01_loc.r03
+FILE1.8 = C:\resource\apps\swiappregintegration01_03.mbm
+FILE1.9 = C:\resource\apps\swiappregintegration01_loc.r24
+FILE1.10 = C:\resource\apps\swiappregintegration01_24.mbm
+INSTALLDRIVE1 = C
+
+[AppRegData_Base]
+SIS1 = z:\tswi\tsis\swiappregintegration_base01.sis
+UID1 = 80010003
+FILE1.1 = C:\sys\bin\swiappregintegration_base01.exe
+FILE1.2 = C:\private\10003a3f\import\apps\swiappregintegration_base01_reg.rsc
+FILE1.3 = C:\resource\apps\swiappregintegration_base01_loc.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration_base01_rsc.mbm
+FILE1.5 = C:\resource\apps\swiappregintegration_base01_loc.r01
+FILE1.6 = C:\resource\apps\swiappregintegration_base01_01.mbm
+FILE1.7 = C:\resource\apps\swiappregintegration_base01_loc.r02
+FILE1.8 = C:\resource\apps\swiappregintegration_base01_02.mbm
+INSTALLDRIVE1 = C
+
+[AppRegData_WithUpgrade]
+SIS1 = z:\tswi\tsis\swiappregintegration_base02.sis
+UID1 = 80010003
+FILE1.1 = C:\sys\bin\swiappregintegration_base01.exe
+FILE1.2 = C:\sys\bin\swiappregintegration02.exe
+FILE1.3 = C:\private\10003a3f\import\apps\swiappregintegration_base01_reg.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration_base01_loc.rsc
+FILE1.5 = C:\resource\apps\swiappregintegration_base01_rsc.mbm
+FILE1.6 = C:\resource\apps\swiappregintegration_base01_loc.r01
+FILE1.7 = C:\resource\apps\swiappregintegration_base01_01.mbm
+FILE1.8 = C:\resource\apps\swiappregintegration_base01_loc.r02
+FILE1.9 = C:\resource\apps\swiappregintegration_base01_02.mbm
+FILE1.10 = C:\resource\apps\swiappregintegration_base01_loc.r03
+FILE1.11 = C:\resource\apps\swiappregintegration_base01_03.mbm
+FILE1.12 = C:\resource\apps\swiappregintegration02_loc.rsc
+FILE1.13 = C:\resource\apps\swiappregintegration02_rsc.mbm
+FILE1.14 = C:\resource\apps\swiappregintegration02_loc.r01
+FILE1.15 = C:\resource\apps\swiappregintegration02_01.mbm
+FILE1.16 = C:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc
+INSTALLDRIVE1 = C
+
+[swiappregintegration_sa_app]
+SIS1 = z:\tswi\tsis\swiappregintegration_case08_1_sa2.sis
+UID1 = 80010099
+FILE1.1 = C:\private\10003a3f\import\apps\swiappregintegration_case05_reg.rsc
+FILE1.2 = C:\resource\apps\swiappregintegration_case05_loc.r01
+FILE1.3 = C:\resource\apps\swiappregintegration.mbm
+INSTALLDRIVE1 = C
+
+[swiappregintegration_no_app]
+SIS1 = z:\tswi\tsis\swiappregintegration_case08_1_sa2.sis
+UID1 = 80010099
+
+[Install_NonRemovableBase]
+sis=z:\tswi\tsis\data\nonremovablebase_sucert.sis
+script=z:\tswi\tuiscriptadaptors\scripts\simple.xml
+
+[Upgrade_SP_Over_SA-NR]
+sis=z:\tswi\tsis\data\nonremovableupgrade.sis
+script=z:\tswi\tuiscriptadaptors\scripts\devlangsel.xml
+devicelanguage0=01
+
+[SP_Over_SA-NR]
+SIS1 = z:\tswi\tsis\nonremovableupgrade.sis
+UID1 = 0x80000002
+FILE1.1 = C:\sys\bin\swiappregintegration02.exe
+FILE1.2 = C:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc
+FILE1.3 = C:\resource\apps\swiappregintegration02_loc.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration02_rsc.mbm
+FILE1.5 = C:\resource\apps\swiappregintegration02_loc.r01
+FILE1.6 = C:\resource\apps\swiappregintegration02_01.mbm
+
+[uninstall_SP_Over_SA-NR]
+uid=80000002
+vendorName=Vendor
+packageName=swiappregintegration_base01_sp_EN
+script=z:\tswi\tuiscriptadaptors\scripts\uninstall.xml
+
+
+[Restore_SP_Upgrade]
+SIS1 = z:\tswi\tsis\data\swiappregintegration_base01.SIS
+UID1 = 80010003
+FILE1.1 = C:\sys\bin\swiappregintegration_base01.exe
+FILE1.2 = C:\private\10003a3f\import\apps\swiappregintegration_base01_reg.rsc
+FILE1.3 = C:\resource\apps\swiappregintegration_base01_loc.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration_base01_rsc.mbm
+FILE1.5 = C:\resource\apps\swiappregintegration_base01_loc.r01
+FILE1.6 = C:\resource\apps\swiappregintegration_base01_01.mbm
+FILE1.7 = C:\resource\apps\swiappregintegration_base01_loc.r02
+FILE1.8 = C:\resource\apps\swiappregintegration_base01_02.mbm
+FILE1.9 = C:\sys\bin\swiappregintegration02.exe
+FILE1.10 = C:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc
+FILE1.11 = C:\resource\apps\swiappregintegration02_loc.rsc
+FILE1.12 = C:\resource\apps\swiappregintegration02_rsc.mbm
+FILE1.13 = C:\resource\apps\swiappregintegration02_loc.r01
+FILE1.14 = C:\resource\apps\swiappregintegration02_01.mbm
+FILE1.15 = C:\resource\apps\swiappregintegration_base01_loc.r03
+FILE1.16 = C:\resource\apps\swiappregintegration_base01_03.mbm
+INSTALLDRIVE1 = C
+
+[Restore_PU_Upgrade]
+SIS1 = z:\tswi\tsis\data\swiappregintegration_base01.SIS
+UID1 = 80010003
+FILE1.1 = C:\sys\bin\swiappregintegration_base01.exe
+FILE1.2 = C:\private\10003a3f\import\apps\swiappregintegration_base01_reg.rsc
+FILE1.3 = C:\resource\apps\swiappregintegration_base01_loc.rsc
+FILE1.4 = C:\resource\apps\swiappregintegration_base01_rsc.mbm
+FILE1.5 = C:\resource\apps\swiappregintegration_base01_loc.r01
+FILE1.6 = C:\resource\apps\swiappregintegration_base01_01.mbm
+FILE1.7 = C:\resource\apps\swiappregintegration_base01_loc.r02
+FILE1.8 = C:\resource\apps\swiappregintegration_base01_02.mbm
+FILE1.9 = C:\sys\bin\swiappregintegration02.exe
+FILE1.10 = C:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc
+FILE1.11 = C:\resource\apps\swiappregintegration02_loc.rsc
+FILE1.12 = C:\resource\apps\swiappregintegration02_rsc.mbm
+FILE1.13 = C:\resource\apps\swiappregintegration02_loc.r01
+FILE1.14 = C:\resource\apps\swiappregintegration02_01.mbm
+FILE1.15 = C:\resource\apps\swiappregintegration_base01_loc.r03
+FILE1.16 = C:\resource\apps\swiappregintegration_base01_03.mbm
+INSTALLDRIVE1 = C
+
+[AppRegData_embedded]
+SIS1 = z:\tswi\tsis\data\swiappregintegration_case06_sa.SIS
+UID1 = 80010099
+FILE1.1 = C:\private\10003a3f\import\apps\swiappregintegration_case05_reg.rsc
+FILE1.2 = C:\resource\apps\swiappregintegration_case05_loc.r01
+FILE1.3 = C:\resource\apps\swiappregintegration.mbm
+
+FILE1.4 = C:\sys\bin\swiappregintegration02.exe
+FILE1.5 = C:\resource\apps\swiappregintegration_case05_loc.r02
+FILE1.6 = C:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc
+FILE1.7 = C:\resource\apps\swiappregintegration02_loc.rsc
+FILE1.8 = C:\resource\apps\swiappregintegration02_rsc.mbm
+
+FILE1.9 = C:\sys\bin\swiappregintegration_case06.exe
+FILE1.10 = C:\private\10003a3f\import\apps\swiappregintegration_case06_reg.rsc
+FILE1.11 = C:\resource\apps\swiappregintegration_case06_loc.rsc
+
+FILE1.12 = C:\resource\apps\swiappregintegration_case05_loc.r04
+FILE1.13 = C:\sys\bin\swiappregintegration_case07.exe
+FILE1.14 = C:\private\10003a3f\import\apps\swiappregintegration_case07_reg.rsc
+FILE1.15 = C:\resource\apps\swiappregintegration_case07_loc.rsc
+INSTALLDRIVE1 = C
+
--- a/installationservices/swi/test/tbackuprestore/scripts/tbackuprestore.script	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/tbackuprestore/scripts/tbackuprestore.script	Fri May 14 15:58:48 2010 +0300
@@ -20,6 +20,8 @@
 LOAD_SUITE tbackuprestore
 LOAD_SUITE tuiscriptadaptors
 LOAD_SUITE tSisRegistryTest
+LOAD_SUITE tscrapparc
+LOAD_SUITE tscr
 
 // Make sure emulated X drive is not corrupt and is empty.
 RUN_TEST_STEP 100 tuiscriptadaptors MmcFormatStep z:\tswi\tuiscriptadaptors\scripts\drives.ini X
@@ -1931,5 +1933,396 @@
 
 RUN_UTILS DeleteFile C:\Documents\abc*.txt
 
+
+// Delete the SCR Database file
+RUN_TEST_STEP 100 tscr SCRDeleteDbFile z:\tusif\tscr\tscr_appreginfo.ini db_file
+
+//! @SYMTestCaseID		API-SEC-BACKUPRESTORE_AppRegData-0001
+//! @SYMTestCaseDesc		Checks restore of a package containg an applicaion
+//! @SYMTestPriority		High
+//! @SYMTestStatus		3. Released
+//! @SYMTestActions		Installs, backs up, uninstalls, restores and uninstalls a single package containg an applicaion
+//! @SYMTestExpectedResults	Success, clean environment.
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0001
+RUN_TEST_STEP	100	tuiscriptadaptors 	InstallStep	z:\tswi\tbackuprestore\scripts\ini		AppRegData_Install
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		AppRegData
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case01_EN
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_french
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case01_IF
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_spanish
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case01_RSC
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case01_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_case01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0001
+
+
+//! @SYMTestCaseID		API-SEC-BACKUPRESTORE_AppRegData-0002
+//! @SYMTestCaseDesc		Upgrades an existing SA pacakge with an SA having new application and new details for FR and GE through Restore
+//! @SYMTestPriority		Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data then do backup, uninstall, restore. Now install an upgrade
+//				then do backup, uninstall, restore
+//! @SYMTestExpectedResults	Upgrade through Restore happens successfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0002
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_No_Eclipsing_EN
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_french
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_No_Eclipsing_FR
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_No_Eclipsing_RSC
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base02
+
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+
+
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_french
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_FR
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0002
+
+//! @SYMTestCaseID		API-SEC-BACKUPRESTORE_AppRegData-0003
+//! @SYMTestCaseDesc		Tests the installation of an SIS file which delivers no files followed by a SA upgrade that delivers an app.
+//! @SYMTestPriority		Medium
+//! @SYMTestActions		Installs a SIS file having no appplication then do backup, uninstall and restore. Now install an upgrade with application
+//				then do backup, uninstall and restore.
+//! @SYMTestExpectedResults	Upgrade through Restore happens successfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0003
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_no_app
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini no_app
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_sa_app
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+
+
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_sa_app
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_no_app
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0003
+
+
+//! @SYMTestCaseID		API-SEC-BACKUPRESTORE_AppRegData-0004
+//! @SYMTestCaseDesc		Tests the installation of an SIS file which delivers some files followed by a SA upgrade that delivers no files.
+//! @SYMTestPriority		Medium
+//! @SYMTestActions		Installs a SIS file having with appplication then do backup, uninstall and restore. Now install an upgrade with no application
+//				then do backup, uninstall and restore.
+//! @SYMTestExpectedResults	Upgrade through Restore happens successfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0004
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_sa_app
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_sa_app
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_no_app
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+
+
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini no_app
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_no_app
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0004
+
+//! @SYMTestCaseID		API-SEC-BACKUPRESTORE_AppRegData-0005
+//! @SYMTestCaseDesc		Checks restore of a package containg an applicaion
+//! @SYMTestPriority		High
+//! @SYMTestStatus		3. Released
+//! @SYMTestActions		Installs a NR SIS file without an appplication then do backup, uninstall and restore. Now install an SP upgrade(Non NR) with application
+//				then do backup, uninstall and restore.
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0005
+RUN_TEST_STEP	100	tuiscriptadaptors 	InstallStep	z:\tswi\tbackuprestore\scripts\ini		Install_NonRemovableBase
+
+RUN_TEST_STEP	100	tuiscriptadaptors 	InstallStep	z:\tswi\tbackuprestore\scripts\ini		Upgrade_SP_Over_SA-NR
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallAugStep z:\tswi\tbackuprestore\scripts\ini uninstall_SP_Over_SA-NR
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0005
+
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-0006
+//! @SYMTestCaseDesc	Upgrades an existing SA pacakge with an SP having new application and new details for GE,backup the  package,
+//			Uninstall the package , restore and verify the data.
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0006
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_sp
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0006
+
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-0007
+//! @SYMTestCaseDesc	Upgrades an existing SA pacakge with an SP having new application and new details for GE,backup the  package,
+//			Uninstall the package , restore and verify the data
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0007
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_sp
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0007
+
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-0008
+//! @SYMTestCaseDesc	Upgrades an existing SA pacakge with an PU having new application and new details for FR and GE, backup the  package,
+//			Uninstall the package , restore and verify the data
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0008
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_pu
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_french
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_FR
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0008
+
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-0009
+//! @SYMTestCaseDesc	Upgrades an existing SA pacakge with an PU having new application and new details for FR and GE, backup the  package,
+//			Uninstall the package , restore and verify the data
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE 	API-SEC-BACKUPRESTORE_AppRegData-0009
+RUN_TEST_STEP   100 	tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP 	100 	tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_pu
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_french
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_FR
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE 	API-SEC-BACKUPRESTORE_AppRegData-0009
+
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-0010
+//! @SYMTestCaseDesc	Install an  SA pacakge with app, take backup , upgrade it with an SP having new application and new loc(Ge) for SA,
+//!			restore Base SA and verify the data.
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0010
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_sp
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0010
+
+
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-0010
+//! @SYMTestCaseDesc	Tests the installation of an SIS file embeds an SP, which embeds a PU, which in turn embeds another SP, that embeds another SP. (SA->SP->PU->SP->SP)
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Install a SIS file that embeds recursively other SIS files with various upgrade combinations.
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! Test Case commented as it leaves stray files and same test case is in twiappregitegration for install which fails with KErrOverWrite
+
+//START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0010
+//RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case06_base
+//RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_case06_base
+//RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case06_sa
+//RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_case06_sa
+
+//RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+//RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+
+//RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+//RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+
+//RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+//RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+
+//RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_case06
+//END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-0010
+
 // Ensure that SWIS shuts down after the above tests to make sure heap checks run
 RUN_TEST_STEP 5 tuiscriptadaptors SwisNotRunning
--- a/installationservices/swi/test/tbackuprestore/scripts/tbackuprestore_armv5.script	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/tbackuprestore/scripts/tbackuprestore_armv5.script	Fri May 14 15:58:48 2010 +0300
@@ -19,6 +19,8 @@
 LOAD_SUITE tbackuprestore
 LOAD_SUITE tuiscriptadaptors
 LOAD_SUITE tSisRegistryTest
+LOAD_SUITE tscrapparc
+LOAD_SUITE tscr
 
 
 //! @SYMTestCaseID		API-SEC-BACKUPRESTORE-HW-0001
@@ -1741,6 +1743,393 @@
 
 RUN_UTILS DeleteFile C:\Documents\abc*.txt
 
+// Delete the SCR Database file
+RUN_TEST_STEP 100 tscr SCRDeleteDbFile z:\tusif\tscr\tscr_appreginfo.ini db_file
+
+
+//! @SYMTestCaseID		API-SEC-BACKUPRESTORE_AppRegData-HW-0001
+//! @SYMTestCaseDesc		Checks restore of a package containg an applicaion
+//! @SYMTestPriority		High
+//! @SYMTestStatus		3. Released
+//! @SYMTestActions		Installs, backs up, uninstalls, restores and uninstalls a single package containg an applicaion
+//! @SYMTestExpectedResults	Success, clean environment.
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0001
+RUN_TEST_STEP	100	tuiscriptadaptors 	InstallStep	z:\tswi\tbackuprestore\scripts\ini		AppRegData_Install
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		AppRegData
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData
+
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case01_EN
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_french
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case01_IF
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_spanish
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case01_RSC
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case01_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_case01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0001
+
+
+//! @SYMTestCaseID		API-SEC-BACKUPRESTORE_AppRegData-HW-0002
+//! @SYMTestCaseDesc		Upgrades an existing SA pacakge with an SA having new application and new details for FR and GE through Restore
+//! @SYMTestPriority		Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data then do backup, uninstall, restore. Now install an upgrade
+//				then do backup, uninstall, restore
+//! @SYMTestExpectedResults	Upgrade through Restore happens successfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0002
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_No_Eclipsing_EN
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_french
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_No_Eclipsing_FR
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_No_Eclipsing_RSC
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base02
+
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_WithUpgrade
+
+
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_french
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_FR
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0002
+
+//! @SYMTestCaseID		API-SEC-BACKUPRESTORE_AppRegData-HW-0003
+//! @SYMTestCaseDesc		Tests the installation of an SIS file which delivers no files followed by a SA upgrade that delivers an app.
+//! @SYMTestPriority		Medium
+//! @SYMTestActions		Installs a SIS file having no appplication then do backup, uninstall and restore. Now install an upgrade with application
+//				then do backup, uninstall and restore.
+//! @SYMTestExpectedResults	Upgrade through Restore happens successfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0003
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_no_app
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini no_app
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_sa_app
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_sa_app
+
+
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_sa_app
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_no_app
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0003
+
+
+//! @SYMTestCaseID		API-SEC-BACKUPRESTORE_AppRegData-HW-0004
+//! @SYMTestCaseDesc		Tests the installation of an SIS file which delivers some files followed by a SA upgrade that delivers no files.
+//! @SYMTestPriority		Medium
+//! @SYMTestActions		Installs a SIS file having with appplication then do backup, uninstall and restore. Now install an upgrade with no application
+//				then do backup, uninstall and restore.
+//! @SYMTestExpectedResults	Upgrade through Restore happens successfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0004
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_sa_app
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_sa_app
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_no_app
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		swiappregintegration_no_app
+
+
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini no_app
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_no_app
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0004
+
+//! @SYMTestCaseID		API-SEC-BACKUPRESTORE_AppRegData-HW-0005
+//! @SYMTestCaseDesc		Checks restore of a package containg an applicaion
+//! @SYMTestPriority		High
+//! @SYMTestStatus		3. Released
+//! @SYMTestActions		Installs a NR SIS file without an appplication then do backup, uninstall and restore. Now install an SP upgrade(Non NR) with application
+//				then do backup, uninstall and restore.
+//! @SYMTestExpectedResults	Success, clean environment.
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0005
+RUN_TEST_STEP	100	tuiscriptadaptors 	InstallStep	z:\tswi\tbackuprestore\scripts\ini		Install_NonRemovableBase
+
+RUN_TEST_STEP	100	tuiscriptadaptors 	InstallStep	z:\tswi\tbackuprestore\scripts\ini		Upgrade_SP_Over_SA-NR
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		SP_Over_SA-NR
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallAugStep z:\tswi\tbackuprestore\scripts\ini uninstall_SP_Over_SA-NR
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0005
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-HW-0006
+//! @SYMTestCaseDesc	Upgrades an existing SA pacakge with an SP having new application and new details for GE,backup the  package,
+//			Uninstall the package , restore and verify the data.
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0006
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_sp
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0006
+
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-HW-0007
+//! @SYMTestCaseDesc	Upgrades an existing SA pacakge with an SP having new application and new details for GE,backup the  package,
+//			Uninstall the package , restore and verify the data
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0007
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_sp
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_SP_Upgrade
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0007
+
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-HW-0008
+//! @SYMTestCaseDesc	Upgrades an existing SA pacakge with an PU having new application and new details for FR and GE, backup the  package,
+//			Uninstall the package , restore and verify the data
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0008
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_pu
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_french
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_FR
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0008
+
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-HW-0009
+//! @SYMTestCaseDesc	Upgrades an existing SA pacakge with an PU having new application and new details for FR and GE, backup the  package,
+//			Uninstall the package , restore and verify the data
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE 	API-SEC-BACKUPRESTORE_AppRegData-HW-0009
+RUN_TEST_STEP   100 	tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP 	100 	tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_pu
+
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		Restore_PU_Upgrade
+
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_french
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_FR
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE 	API-SEC-BACKUPRESTORE_AppRegData-HW-0009
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-HW-0010
+//! @SYMTestCaseDesc	Install an  SA pacakge with app, take backup , upgrade it with an SP having new application and new loc(Ge) for SA,
+//!			restore Base SA and verify the data.
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installs a SIS file having complete appregistration data
+//! @SYMTestExpectedResults	Restore done  sucessfully
+//! @SYMREQ			PREQ 1835 Phase II
+//! @SYMTestType		UT
+
+START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0010
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01
+
+RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_base01_sp
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_german
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_GE
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_Base
+
+RUN_TEST_STEP 100 tSisRegistryTest ChangeLocale z:\tswi\tuiscriptadaptors\scripts\testdevicelanguages.ini langauge_to_english
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case02_EN
+
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_base01
+END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0010
+
+
+//! @SYMTestCaseID	API-SEC-BACKUPRESTORE_AppRegData-HW-0010
+//! @SYMTestCaseDesc	Tests the installation of an SIS file embeds an SP, which embeds a PU, which in turn embeds another SP, that embeds another SP. (SA->SP->PU->SP->SP)
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Install a SIS file that embeds recursively other SIS files with various upgrade combinations.
+//! @SYMTestExpectedResults	File installs sucessfully
+
+//START_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0010
+//RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case06_base
+//RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_case06_base
+//RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case06_sa
+//RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_case06_sa
+
+//RUN_TEST_STEP	100	tbackuprestore		BACKUP		z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+//RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+
+//RUN_TEST_STEP	100	tbackuprestore		UNINSTALL	z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+//RUN_TEST_STEP	100	tbackuprestore		ABSENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+
+//RUN_TEST_STEP	100	tbackuprestore		RESTORE		z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+//RUN_TEST_STEP	100	tbackuprestore		PRESENT		z:\tswi\tbackuprestore\scripts\ini		AppRegData_embedded
+
+//RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_case06
+//END_TESTCASE API-SEC-BACKUPRESTORE_AppRegData-HW-0010
+
 // Ensure that SWIS shuts down after the above tests to make sure heap checks run
 RUN_TEST_STEP 5 tuiscriptadaptors SwisNotRunning
 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/packages/int_nr_option_04.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,34 @@
+;
+; 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 the License "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:
+;
+; Install file for multi-lingual application
+; supporting two language variants.
+;
+
+; Languages - 
+&EN,GE
+
+; List of localised vendor names.
+%{"Nokia Software Ltd", "Nokia Software Ltd"}
+
+; Single, non-localised (global) vendor name.
+:"Nokia Software Ltd"
+
+; Installation header.
+; Two component names as we support English and German
+#{"Interpretsis_NR_option", "Interpretsis_NR_option1"}, (0x80000076), 1,0,0, Type=SA,RU,NR
+
+;Ordinary file to selected drive
+"osver.txt"-"!:\Documents\abc1.txt"
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/packages/int_nr_option_05.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,34 @@
+;
+; 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 the License "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:
+;
+; Install file for multi-lingual application
+; supporting two language variants.
+;
+
+; Languages - 
+&EN,GE
+
+; List of localised vendor names.
+%{"Nokia Software Ltd", "Nokia Software Ltd"}
+
+; Single, non-localised (global) vendor name.
+:"Nokia Software Ltd"
+
+; Installation header.
+; Two component names as we support English and German
+#{"Interpretsis_NR_option", "Interpretsis_NR_option1"}, (0x80000077), 1,0,0, Type=SA,RU,NR
+
+;Ordinary file to selected drive
+"osver.txt"-"!:\Documents\abc4.txt"
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/packages/nonremovableupgrade.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,37 @@
+; 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 the License "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:
+; SP package containing complete resource files for English and German 
+;
+
+;Languages
+&EN, GE
+
+#{"swiappregintegration_base01_sp_EN","swiappregintegration_base01_sp_GE"},(0x80000002),1,1,1,TYPE=SP
+
+;Localised Vendor name
+%{"Vendor_EN","Vendor_GE"}
+
+;Unique Vendor name
+:"Vendor"
+
+"\epoc32\release\<PLATFORM>\<CONFIGURATION>\swiappregintegration02.exe" - "!:\sys\bin\swiappregintegration02.exe"
+
+"\epoc32\data\z\tswi\tuiscriptadaptors\data\swiappregintegration02\swiappregintegration02_reg.rsc" - "!:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc"
+"\epoc32\data\z\tswi\tuiscriptadaptors\data\swiappregintegration02\swiappregintegration02_loc.rsc" -"!:\resource\apps\swiappregintegration02_loc.rsc"
+"\epoc32\data\z\tswi\tuiscriptadaptors\data\swiappregintegration01\swiappregintegration.mbm"  -"!:\resource\apps\swiappregintegration02_rsc.mbm"
+
+if supported_language=01
+"\epoc32\data\z\tswi\tuiscriptadaptors\data\swiappregintegration02\swiappregintegration02_loc.r01" -"!:\resource\apps\swiappregintegration02_loc.r01"
+"\epoc32\data\z\tswi\tuiscriptadaptors\data\swiappregintegration01\swiappregintegration.mbm"  -"!:\resource\apps\swiappregintegration02_01.mbm"
+endif
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/packages/sp_int_nr_option_04.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,34 @@
+;
+; 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 the License "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:
+;
+; Install file for multi-lingual application
+; supporting two language variants.
+;
+
+; Languages - 
+&EN,GE
+
+; List of localised vendor names.
+%{"Nokia", "Nokia"}
+
+; Single, non-localised (global) vendor name.
+:"Nokia"
+
+; Installation header.
+; Two component names as we support English and German
+#{"Interpretsis_NR_option_SP", "Interpretsis_NR_option1_SP"}, (0x80000076), 1,0,0, Type=SP
+
+;Ordinary file to selected drive
+"osver.txt"-"!:\Documents\abc3.txt"
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/packages/sp_int_nr_option_06.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,34 @@
+;
+; 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 the License "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:
+;
+; Install file for multi-lingual application
+; supporting two language variants.
+;
+
+; Languages - 
+&EN,GE
+
+; List of localised vendor names.
+%{"Nokia", "Nokia"}
+
+; Single, non-localised (global) vendor name.
+:"Nokia"
+
+; Installation header.
+; Two component names as we support English and German
+#{"Interpretsis_NR_option_SP_NR", "Interpretsis_NR_option1_SP_NR"}, (0x80000076), 1,0,0, Type=SP,NR,RU
+
+;Ordinary file to selected drive
+"osver.txt"-"!:\Documents\abc5.txt"
\ No newline at end of file
--- a/installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_01.pkg	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_01.pkg	Fri May 14 15:58:48 2010 +0300
@@ -2,7 +2,7 @@
 ; 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"
+; under the terms of the License "Eclipse Public License v1.0"
 ; which accompanies this distribution, and is available
 ; at the URL "http://www.eclipse.org/legal/epl-v10.html".
 ;
--- a/installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_02.pkg	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_02.pkg	Fri May 14 15:58:48 2010 +0300
@@ -2,7 +2,7 @@
 ; 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"
+; under the terms of the License "Eclipse Public License v1.0"
 ; which accompanies this distribution, and is available
 ; at the URL "http://www.eclipse.org/legal/epl-v10.html".
 ;
--- a/installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_03.pkg	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_03.pkg	Fri May 14 15:58:48 2010 +0300
@@ -2,7 +2,7 @@
 ; 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"
+; under the terms of the License "Eclipse Public License v1.0"
 ; which accompanies this distribution, and is available
 ; at the URL "http://www.eclipse.org/legal/epl-v10.html".
 ;
--- a/installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_04.pkg	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_04.pkg	Fri May 14 15:58:48 2010 +0300
@@ -2,7 +2,7 @@
 ; 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"
+; under the terms of the License "Eclipse Public License v1.0"
 ; which accompanies this distribution, and is available
 ; at the URL "http://www.eclipse.org/legal/epl-v10.html".
 ;
--- a/installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_05.pkg	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/testexes/packages_interpretsis_testcase/int_nr_option_05.pkg	Fri May 14 15:58:48 2010 +0300
@@ -2,7 +2,7 @@
 ; 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"
+; under the terms of the License "Eclipse Public License v1.0"
 ; which accompanies this distribution, and is available
 ; at the URL "http://www.eclipse.org/legal/epl-v10.html".
 ;
--- a/installationservices/swi/test/testexes/packages_interpretsis_testcase/pu_int_nr_option_01.pkg	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/testexes/packages_interpretsis_testcase/pu_int_nr_option_01.pkg	Fri May 14 15:58:48 2010 +0300
@@ -2,7 +2,7 @@
 ; 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"
+; under the terms of the License "Eclipse Public License v1.0"
 ; which accompanies this distribution, and is available
 ; at the URL "http://www.eclipse.org/legal/epl-v10.html".
 ;
--- a/installationservices/swi/test/testexes/packages_interpretsis_testcase/sp_int_nr_option_01.pkg	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/testexes/packages_interpretsis_testcase/sp_int_nr_option_01.pkg	Fri May 14 15:58:48 2010 +0300
@@ -2,7 +2,7 @@
 ; 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"
+; under the terms of the License "Eclipse Public License v1.0"
 ; which accompanies this distribution, and is available
 ; at the URL "http://www.eclipse.org/legal/epl-v10.html".
 ;
--- a/installationservices/swi/test/testexes/packages_interpretsis_testcase/sp_int_nr_option_04.pkg	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/testexes/packages_interpretsis_testcase/sp_int_nr_option_04.pkg	Fri May 14 15:58:48 2010 +0300
@@ -2,7 +2,7 @@
 ; 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"
+; under the terms of the License "Eclipse Public License v1.0"
 ; which accompanies this distribution, and is available
 ; at the URL "http://www.eclipse.org/legal/epl-v10.html".
 ;
--- a/installationservices/swi/test/testexes/packages_interpretsis_testcase/sp_int_nr_option_06.pkg	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/testexes/packages_interpretsis_testcase/sp_int_nr_option_06.pkg	Fri May 14 15:58:48 2010 +0300
@@ -2,7 +2,7 @@
 ; 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"
+; under the terms of the License "Eclipse Public License v1.0"
 ; which accompanies this distribution, and is available
 ; at the URL "http://www.eclipse.org/legal/epl-v10.html".
 ;
--- a/installationservices/swi/test/testexes/tswiappregintegration/bld.inf	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/testexes/tswiappregintegration/bld.inf	Fri May 14 15:58:48 2010 +0300
@@ -22,3 +22,6 @@
 tswiappregintegration_base01.mmp
 tswiappregintegration03.mmp
 tswiappregintegration04.mmp
+tswiappregintegration05.mmp
+tswiappregintegration06.mmp
+tswiappregintegration07.mmp
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case05/01-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for UK
+//
+
+rls_string Localized_Short_Caption "HW_EN"
+rls_string Localized_Caption "HelloWorld_EN"
+rls_long Localized_NumberOfIcon 123
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_EN"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case05/02-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for FR
+//
+
+rls_string Localized_Short_Caption "HW_FR"
+rls_string Localized_Caption "HelloWorld_FR"
+rls_long Localized_NumberOfIcon 124
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_FR"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case05/03-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for GE
+//
+
+rls_string Localized_Short_Caption "HW_GE"
+rls_string Localized_Caption "HelloWorld_GE"
+rls_long Localized_NumberOfIcon 125
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_GE"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case05/04-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for FR 2
+//
+
+rls_string Localized_Short_Caption "HW_FR_2"
+rls_string Localized_Caption "HelloWorld_FR_2"
+rls_long Localized_NumberOfIcon 126
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_FR2"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case05/rsc-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,23 @@
+// 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 the License "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:
+// localise01strings
+// Strings localised for RSC
+//
+
+rls_string Localized_Short_Caption "HW_RSC"
+rls_string Localized_Caption "HelloWorld_RSC"
+rls_long Localized_NumberOfIcon 127
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_RSC"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case05/swiappregintegration_case05_loc.rss	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,54 @@
+// 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:
+//
+
+/**
+ @file swiappregintegration_case05_loc.rss
+ @internalComponent - Internal Symbian test code
+*/
+
+#include <techview/eikon.rh>
+#include <uiklafgt/eikcore.rsg>
+#include <appinfo.rh>
+
+
+RESOURCE RSS_SIGNATURE { }
+
+#ifdef LANGUAGE_01
+ #include "01-strings.rls"
+#elif defined LANGUAGE_02
+ #include "02-strings.rls"
+#elif defined LANGUAGE_03
+ #include "03-strings.rls"
+#elif defined LANGUAGE_04
+ #include "04-strings.rls"
+#else
+ #include "rsc-strings.rls"
+#endif      
+
+RESOURCE LOCALISABLE_APP_INFO r_lai
+	{
+	short_caption = Localized_Short_Caption;
+	caption_and_icon =
+		{
+		CAPTION_AND_ICON_INFO
+			{
+			caption = Localized_Caption;
+			number_of_icons = Localized_NumberOfIcon;
+			icon_file = Localized_Iconfile;
+			}
+		};
+
+	group_name = Localized_GroupName;		
+	}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case05/swiappregintegration_case05_reg.rss	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,40 @@
+// 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:
+//
+
+/**
+ @file swiappregintegration05_reg.rss
+ @internalComponent - Internal Symbian test code
+*/
+
+#include <appinfo.rh>
+#include <swiappregintegration_case05_loc.rsg>
+
+UID2 KUidAppRegistrationResourceFile
+UID3 0x90000009
+
+RESOURCE APP_REGISTRATION_INFO
+	{
+	app_file = "swiappregintegration_case05";
+	localisable_resource_file = "C:\\resource\\apps\\swiappregintegration_case05_loc";
+	localisable_resource_id = R_LAI;	
+	
+    	hidden = KAppNotHidden;
+    	embeddability = KAppNotEmbeddable;
+    	newfile = KAppDoesNotSupportNewFile;
+    	launch = KAppLaunchInForeground;
+    	group_name = "GroupI";    
+    	default_screen_number = 2;
+	}
+	
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case05/swiappregintegration_case05_su_reg.rss	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,40 @@
+// 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:
+//
+
+/**
+ @file swiappregintegration05_reg.rss
+ @internalComponent - Internal Symbian test code
+*/
+
+#include <appinfo.rh>
+#include <swiappregintegration_case05_loc.rsg>
+
+UID2 KUidAppRegistrationResourceFile
+UID3 0x90000009
+
+RESOURCE APP_REGISTRATION_INFO
+	{
+	app_file = "swiappregintegration_case05";
+	localisable_resource_file = "C:\\resource\\apps\\swiappregintegration_case05_loc";
+	localisable_resource_id = R_LAI;	
+	
+    	hidden = KAppNotHidden;
+    	embeddability = KAppNotEmbeddable;
+    	newfile = KAppDoesNotSupportNewFile;
+    	launch = KAppLaunchInForeground;
+    	group_name = "GroupII";    
+    	default_screen_number = 2;
+	}
+	
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case06/01-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for UK
+//
+
+rls_string Localized_Short_Caption "HW_EN"
+rls_string Localized_Caption "HelloWorld_EN"
+rls_long Localized_NumberOfIcon 123
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_EN"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case06/02-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for FR
+//
+
+rls_string Localized_Short_Caption "HW_FR"
+rls_string Localized_Caption "HelloWorld_FR"
+rls_long Localized_NumberOfIcon 124
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_FR"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case06/03-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for GE
+//
+
+rls_string Localized_Short_Caption "HW_GE"
+rls_string Localized_Caption "HelloWorld_GE"
+rls_long Localized_NumberOfIcon 125
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_GE"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case06/04-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for FR 2
+//
+
+rls_string Localized_Short_Caption "HW_FR_2"
+rls_string Localized_Caption "HelloWorld_FR_2"
+rls_long Localized_NumberOfIcon 126
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_FR2"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case06/rsc-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,23 @@
+// 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 the License "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:
+// localise01strings
+// Strings localised for RSC
+//
+
+rls_string Localized_Short_Caption "HW_RSC"
+rls_string Localized_Caption "HelloWorld_RSC"
+rls_long Localized_NumberOfIcon 127
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_RSC"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case06/swiappregintegration_case06_loc.rss	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,54 @@
+// 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:
+//
+
+/**
+ @file swiappregintegration_case06_loc.rss
+ @internalComponent - Internal Symbian test code
+*/
+
+#include <techview/eikon.rh>
+#include <uiklafgt/eikcore.rsg>
+#include <appinfo.rh>
+
+
+RESOURCE RSS_SIGNATURE { }
+
+#ifdef LANGUAGE_01
+ #include "01-strings.rls"
+#elif defined LANGUAGE_02
+ #include "02-strings.rls"
+#elif defined LANGUAGE_03
+ #include "03-strings.rls"
+#elif defined LANGUAGE_04
+ #include "04-strings.rls"
+#else
+ #include "rsc-strings.rls"
+#endif      
+
+RESOURCE LOCALISABLE_APP_INFO r_lai
+	{
+	short_caption = Localized_Short_Caption;
+	caption_and_icon =
+		{
+		CAPTION_AND_ICON_INFO
+			{
+			caption = Localized_Caption;
+			number_of_icons = Localized_NumberOfIcon;
+			icon_file = Localized_Iconfile;
+			}
+		};
+
+	group_name = Localized_GroupName;		
+	}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case06/swiappregintegration_case06_reg.rss	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,40 @@
+// 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:
+//
+
+/**
+ @file swiappregintegration06_reg.rss
+ @internalComponent - Internal Symbian test code
+*/
+
+#include <appinfo.rh>
+#include <swiappregintegration_case06_loc.rsg>
+
+UID2 KUidAppRegistrationResourceFile
+UID3 0x90000006
+
+RESOURCE APP_REGISTRATION_INFO
+	{
+	app_file = "swiappregintegration_case06";
+	localisable_resource_file = "C:\\resource\\apps\\swiappregintegration_case06_loc";
+	localisable_resource_id = R_LAI;	
+	
+    	hidden = KAppNotHidden;
+    	embeddability = KAppNotEmbeddable;
+    	newfile = KAppDoesNotSupportNewFile;
+    	launch = KAppLaunchInForeground;
+    	group_name = "GroupI";    
+    	default_screen_number = 2;
+	}
+	
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case07/01-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for UK
+//
+
+rls_string Localized_Short_Caption "HW_EN"
+rls_string Localized_Caption "HelloWorld_EN"
+rls_long Localized_NumberOfIcon 123
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_EN"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case07/02-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for FR
+//
+
+rls_string Localized_Short_Caption "HW_FR"
+rls_string Localized_Caption "HelloWorld_FR"
+rls_long Localized_NumberOfIcon 124
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_FR"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case07/03-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for GE
+//
+
+rls_string Localized_Short_Caption "HW_GE"
+rls_string Localized_Caption "HelloWorld_GE"
+rls_long Localized_NumberOfIcon 125
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_GE"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case07/04-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,22 @@
+// 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 the License "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:
+// Strings localised for FR 2
+//
+
+rls_string Localized_Short_Caption "HW_FR_2"
+rls_string Localized_Caption "HelloWorld_FR_2"
+rls_long Localized_NumberOfIcon 126
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_FR2"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case07/rsc-strings.rls	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,23 @@
+// 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 the License "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:
+// localise01strings
+// Strings localised for RSC
+//
+
+rls_string Localized_Short_Caption "HW_RSC"
+rls_string Localized_Caption "HelloWorld_RSC"
+rls_long Localized_NumberOfIcon 127
+rls_string Localized_Iconfile "C:\\resource\\apps\\swiappregintegration.mbm"
+
+rls_string Localized_GroupName "Group_RSC"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case07/swiappregintegration_case07_loc.rss	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,54 @@
+// 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:
+//
+
+/**
+ @file swiappregintegration_case07_loc.rss
+ @internalComponent - Internal Symbian test code
+*/
+
+#include <techview/eikon.rh>
+#include <uiklafgt/eikcore.rsg>
+#include <appinfo.rh>
+
+
+RESOURCE RSS_SIGNATURE { }
+
+#ifdef LANGUAGE_01
+ #include "01-strings.rls"
+#elif defined LANGUAGE_02
+ #include "02-strings.rls"
+#elif defined LANGUAGE_03
+ #include "03-strings.rls"
+#elif defined LANGUAGE_04
+ #include "04-strings.rls"
+#else
+ #include "rsc-strings.rls"
+#endif      
+
+RESOURCE LOCALISABLE_APP_INFO r_lai
+	{
+	short_caption = Localized_Short_Caption;
+	caption_and_icon =
+		{
+		CAPTION_AND_ICON_INFO
+			{
+			caption = Localized_Caption;
+			number_of_icons = Localized_NumberOfIcon;
+			icon_file = Localized_Iconfile;
+			}
+		};
+
+	group_name = Localized_GroupName;		
+	}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/case07/swiappregintegration_case07_reg.rss	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,40 @@
+// 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:
+//
+
+/**
+ @file swiappregintegration07_reg.rss
+ @internalComponent - Internal Symbian test code
+*/
+
+#include <appinfo.rh>
+#include <swiappregintegration_case07_loc.rsg>
+
+UID2 KUidAppRegistrationResourceFile
+UID3 0x90000007
+
+RESOURCE APP_REGISTRATION_INFO
+	{
+	app_file = "swiappregintegration_case07";
+	localisable_resource_file = "C:\\resource\\apps\\swiappregintegration_case07_loc";
+	localisable_resource_id = R_LAI;	
+	
+    	hidden = KAppNotHidden;
+    	embeddability = KAppNotEmbeddable;
+    	newfile = KAppDoesNotSupportNewFile;
+    	launch = KAppLaunchInForeground;
+    	group_name = "GroupI";    
+    	default_screen_number = 2;
+	}
+	
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/tswiappregintegration05.mmp	Fri May 14 15:58:48 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 the License "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:
+* tswiappregintegration_case05.mmp for swi application reg integration testing
+*
+*/
+
+TARGET			swiappregintegration_case05.exe
+TARGETTYPE		exe
+
+UID			0x10000007 0x90000009
+VENDORID		0x0
+
+SOURCEPATH		.
+SOURCE			swiappregintegration.cpp
+
+SYSTEMINCLUDE	/epoc32/include
+
+START RESOURCE	case05/swiappregintegration_case05_loc.rss
+HEADER
+TARGETPATH		tswi/tuiscriptadaptors/data/swiappregintegration_case05
+LANG  SC 01 02 03 04	
+END
+
+// Application exe registration resource file
+START RESOURCE 	case05/swiappregintegration_case05_reg.rss
+TARGETPATH	tswi/tuiscriptadaptors/data/swiappregintegration_case05
+END
+
+// Application exe registration resource file upgraded
+START RESOURCE 	case05/swiappregintegration_case05_su_reg.rss
+TARGETPATH	tswi/tuiscriptadaptors/data/swiappregintegration_case05
+END
+
+LIBRARY			euser.lib
+SMPSAFE
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/tswiappregintegration06.mmp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,43 @@
+/*
+* 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 the License "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:
+* tswiappregintegration_case06.mmp for swi application reg integration testing
+*
+*/
+
+TARGET			swiappregintegration_case06.exe
+TARGETTYPE		exe
+
+UID			0x10000007 0x90000099
+VENDORID		0x0
+
+SOURCEPATH		.
+SOURCE			swiappregintegration.cpp
+
+SYSTEMINCLUDE	/epoc32/include
+
+START RESOURCE	case06/swiappregintegration_case06_loc.rss
+HEADER
+TARGETPATH		tswi/tuiscriptadaptors/data/swiappregintegration_case06
+LANG  SC 01 02 03 04	
+END
+
+// Application exe registration resource file
+START RESOURCE 	case06/swiappregintegration_case06_reg.rss
+TARGETPATH	tswi/tuiscriptadaptors/data/swiappregintegration_case06
+END
+
+
+LIBRARY			euser.lib
+SMPSAFE
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swi/test/testexes/tswiappregintegration/tswiappregintegration07.mmp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,43 @@
+/*
+* 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 the License "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:
+* tswiappregintegration_case07.mmp for swi application reg integration testing
+*
+*/
+
+TARGET			swiappregintegration_case07.exe
+TARGETTYPE		exe
+
+UID			0x10000007 0x90000011
+VENDORID		0x0
+
+SOURCEPATH		.
+SOURCE			swiappregintegration.cpp
+
+SYSTEMINCLUDE	/epoc32/include
+
+START RESOURCE	case07/swiappregintegration_case07_loc.rss
+HEADER
+TARGETPATH		tswi/tuiscriptadaptors/data/swiappregintegration_case07
+LANG  SC 01 02 03 04	
+END
+
+// Application exe registration resource file
+START RESOURCE 	case07/swiappregintegration_case07_reg.rss
+TARGETPATH	tswi/tuiscriptadaptors/data/swiappregintegration_case07
+END
+
+
+LIBRARY			euser.lib
+SMPSAFE
--- a/installationservices/swi/test/tuiscriptadaptors/scripts/tswiappregintegration.ini	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/tuiscriptadaptors/scripts/tswiappregintegration.ini	Fri May 14 15:58:48 2010 +0300
@@ -35,7 +35,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-AppOpaqueDataInfoCount=0
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 
 OwnedFileCount=2
 FileName0=c:\temp\AppNameTempFile.txt
@@ -50,14 +52,18 @@
 ServiceDataTypePriority1=0
 ServiceDataType1=image/gif1
 ServiceUid1=01020304
-ServiceOpaqueDataInfoCount1=0
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
 ServiceDataTypePriority3=0
 ServiceDataType3=image/gif2
 ServiceUid2=02030405
-ServiceOpaqueDataInfoCount2=0
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg3
@@ -96,7 +102,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-AppOpaqueDataInfoCount=0
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 
 OwnedFileCount=2
 FileName0=c:\temp\AppNameTempFile.txt
@@ -111,14 +119,18 @@
 ServiceDataTypePriority1=0
 ServiceDataType1=image/gif1
 ServiceUid1=01020304
-ServiceOpaqueDataInfoCount1=0
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
 ServiceDataTypePriority3=0
 ServiceDataType3=image/gif2
 ServiceUid2=02030405
-ServiceOpaqueDataInfoCount2=0
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg3
@@ -894,3 +906,277 @@
 devicelanguage0=01
 devicelanguage1=02
 CompareWithDb=True
+
+//APPINSTALL-SWI-APPREG-INTEGRATION-0012
+[swiappregintegration_case06_base]
+sis=z:\tusif\tsif\data\swiappregintegration_case06_base.sis
+script=z:\tswi\tuiscriptadaptors\scripts\devlangsel.xml
+devicelanguage0=01
+
+[swiappregintegration_case06_sa]
+sis=z:\tusif\tsif\data\swiappregintegration_case06_sa.sis
+script=z:\tswi\tuiscriptadaptors\scripts\devlangsel.xml
+devicelanguage0=01
+devicelanguage1=02
+devicelanguage2=03
+devicelanguage3=24
+
+[u_swiappregintegration_case06]
+uid=80010099
+script=z:\tswi\tuiscriptadaptors\scripts\uninstall.xml
+
+[verify_case06_base]
+AppRegEntriesConfigCount=1
+configsection0 = verify_case06_base_data
+CompareWithDb=True
+
+[verify_case06_base_data]
+AppUid=90000009
+AppFile=C:\sys\bin\swiappregintegration_case05.exe
+Attributes=0
+Hidden=0
+Embeddability=0
+NewFile=0
+Launch=0
+GroupName=GroupI
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=0
+OwnedFileCount=0
+ServiceInfoCount=0
+LocalizableAppInfoCount=1
+LocAppLanguage0=0
+LocShortCaption0=HW_RSC
+LocCaption0=HelloWorld_RSC
+LocNumberOfAppIcons0=127
+LocIconFileName0=C:\resource\apps\swiappregintegration.mbm
+LocGroupName0=Group_RSC
+PropertiesCount=0
+
+[verify_case06_sa]
+AppRegEntriesConfigCount=4
+configsection0 = verify_case06_data2
+configsection1 = verify_case06_data4
+configsection2 = verify_case06_data5
+configsection3 = verify_case06_data1
+CompareWithDb=True
+
+[verify_case06_data1]
+AppUid=90000009
+AppFile=C:\sys\bin\swiappregintegration_case05.exe
+Attributes=0
+Hidden=0
+Embeddability=0
+NewFile=0
+Launch=0
+GroupName=GroupI
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=0
+OwnedFileCount=0
+ServiceInfoCount=0
+LocalizableAppInfoCount=1
+LocAppLanguage0=1
+LocShortCaption0=HW_EN
+LocCaption0=HelloWorld_EN
+LocNumberOfAppIcons0=123
+LocIconFileName0=C:\resource\apps\swiappregintegration.mbm
+LocGroupName0=Group_EN
+PropertiesCount=0
+
+[verify_case06_data2]
+AppUid=90000005
+AppFile=C:\sys\bin\swiappregintegration02.exe
+Attributes=0
+Hidden=0
+Embeddability=0
+NewFile=0
+Launch=0
+GroupName=AppGroup02
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=0
+OwnedFileCount=0
+ServiceInfoCount=1
+ServiceUid0=10208DCA
+ServiceDataTypeCount0=2
+ServiceDataTypePriority0=0
+ServiceDataType0=doc/txt
+ServiceDataTypePriority1=0
+ServiceDataType1=doc/pdf
+ServiceOpaqueDataInfoCount0=0
+LocalizableAppInfoCount=1
+LocAppLanguage0=0
+LocShortCaption0=HW_App2_RSC
+LocCaption0=HelloWorld_App2_RSC
+LocNumberOfAppIcons0=29
+LocIconFileName0=C:\resource\apps\swiappregintegration02_rsc.mbm
+PropertiesCount=0
+
+[verify_case06_data3]
+AppUid=90000006
+AppFile=C:\sys\bin\swiappregintegration03.exe
+OwnedFileCount=0
+ServiceInfoCount=2
+ServiceUid0=01020305
+ServiceDataTypeCount0=2
+ServiceDataTypePriority0=0
+ServiceDataType0=image/jpeg3
+ServiceDataTypePriority1=0
+ServiceDataType1=image/gif3
+ServiceOpaqueDataInfoCount0=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=RSC Localised text for service UID 0x01020305
+ServiceUid1=10208DCA
+ServiceDataTypeCount1=2
+ServiceDataTypePriority2=0
+ServiceDataType2=doc/jpeg2
+ServiceDataTypePriority3=0
+ServiceDataType3=doc/gif2
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=RSC Localised text for service UID 0x10208DCA
+LocalizableAppInfoCount=1
+LocAppLanguage0=0
+LocShortCaption0=C03_RSC
+LocCaption0=Case03_RSC
+LocNumberOfAppIcons0=113
+LocIconFileName0=C:\Icon\swiappregintegration03_rsc.mbm
+AppOpaqueDataInfoCount=1
+AppOpaqueLocale0=0
+AppOpaqueData0=RSC Localised text App
+PropertiesCount=0
+
+[verify_case06_data4]
+AppUid=90000006
+AppFile=C:\sys\bin\swiappregintegration_case06.exe
+Attributes=0
+Hidden=0
+Embeddability=0
+NewFile=0
+Launch=0
+GroupName=GroupI
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=0
+OwnedFileCount=0
+ServiceInfoCount=0
+LocalizableAppInfoCount=1
+LocAppLanguage0=0
+LocShortCaption0=HW_RSC
+LocCaption0=HelloWorld_RSC
+LocNumberOfAppIcons0=127
+LocIconFileName0=C:\resource\apps\swiappregintegration.mbm
+LocGroupName0=Group_RSC
+PropertiesCount=0
+
+[verify_case06_data5]
+AppUid=90000007
+AppFile=C:\sys\bin\swiappregintegration_case07.exe
+Attributes=0
+Hidden=0
+Embeddability=0
+NewFile=0
+Launch=0
+GroupName=GroupI
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=0
+OwnedFileCount=0
+ServiceInfoCount=0
+LocalizableAppInfoCount=1
+LocAppLanguage0=0
+LocShortCaption0=HW_RSC
+LocCaption0=HelloWorld_RSC
+LocNumberOfAppIcons0=127
+LocIconFileName0=C:\resource\apps\swiappregintegration.mbm
+LocGroupName0=Group_RSC
+PropertiesCount=0
+
+
+//APPINSTALL-SWI-APPREG-INTEGRATION-0009
+[swiappregintegration_SA]
+sis=z:\tusif\tsif\data\swiappregintegration_case05.SIS
+script=z:\tswi\tuiscriptadaptors\scripts\simple.xml
+
+[swiappregintegration_SA_SU]
+sis=z:\tusif\tsif\data\swiappregintegration_case05_SU.SIS
+script=z:\tswi\tuiscriptadaptors\scripts\simple.xml
+
+[u_swiappregintegration_SA]
+uid=80010009
+script=z:\tswi\tuiscriptadaptors\scripts\uninstall.xml
+
+[verify_reg_SA]
+AppRegEntriesConfigCount=1
+configsection0 = verify_reg_SA_data
+CompareWithDb=True
+
+[verify_reg_SA_SU]
+AppRegEntriesConfigCount=1
+configsection0 = verify_reg_SA_SU_data
+CompareWithDb=True
+
+[verify_reg_SA_data]
+AppUid=90000009
+AppFile=C:\sys\bin\swiappregintegration_case05.exe
+Attributes=0
+Hidden=0
+Embeddability=0
+NewFile=0
+Launch=0
+GroupName=GroupI
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=0
+OwnedFileCount=0
+ServiceInfoCount=0
+LocalizableAppInfoCount=1
+LocAppLanguage0=0
+LocShortCaption0=HW_RSC
+LocCaption0=HelloWorld_RSC
+LocNumberOfAppIcons0=127
+LocIconFileName0=C:\resource\apps\swiappregintegration.mbm
+LocGroupName0=Group_RSC
+PropertiesCount=0
+
+[verify_reg_SA_SU_data]
+AppUid=90000009
+AppFile=C:\sys\bin\swiappregintegration_case05.exe
+Attributes=0
+Hidden=0
+Embeddability=0
+NewFile=0
+Launch=0
+GroupName=GroupII
+DefaultScreenNumber=2
+AppOpaqueDataInfoCount=0
+OwnedFileCount=0
+ServiceInfoCount=0
+LocalizableAppInfoCount=1
+LocAppLanguage0=0
+LocShortCaption0=HW_RSC
+LocCaption0=HelloWorld_RSC
+LocNumberOfAppIcons0=127
+LocIconFileName0=C:\resource\apps\swiappregintegration.mbm
+LocGroupName0=Group_RSC
+PropertiesCount=0
+
+
+//APPINSTALL-SWI-APPREG-INTEGRATION-0010,11
+[swiappregintegration_no_app]
+sis=z:\tusif\tsif\data\swiappregintegration_case08_sa1.sis
+script=z:\tswi\tuiscriptadaptors\scripts\simple.xml
+
+[swiappregintegration_sa_app]
+sis=z:\tusif\tsif\data\swiappregintegration_case08_sa2.sis
+script=z:\tswi\tuiscriptadaptors\scripts\devlangsel.xml
+devicelanguage0=01
+
+[u_swiappregintegration_no_app]
+uid=80010099
+script=z:\tswi\tuiscriptadaptors\scripts\uninstall.xml
+
+[no_app]
+AppRegEntriesConfigCount=0
+CompareWithDb=True
+
+[verify_sa_app]
+AppRegEntriesConfigCount=1
+configsection0 = verify_case06_data1
+CompareWithDb=True
+
--- a/installationservices/swi/test/tuiscriptadaptors/scripts/tswiappregintegration.script	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swi/test/tuiscriptadaptors/scripts/tswiappregintegration.script	Fri May 14 15:58:48 2010 +0300
@@ -151,5 +151,57 @@
 //RUN_TEST_STEP_RESULT -20 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case04_wronguid2
 //END_TESTCASE APPINSTALL-SWI-APPREG-INTEGRATION-0008
 
+//! @SYMTestCaseID		APPINSTALL-SWI-APPREG-INTEGRATION-0009
+//! @SYMTestCaseDesc	Tests the SA upgrade that is SU signed.
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Install a SIS file that followed by an SA upgrade that is SU signed and reflects the latest SA installation. Reg data updated in second SA(Group name changed.)
+//! @SYMTestExpectedResults	File installs sucessfully
+START_TESTCASE APPINSTALL-SWI-APPREG-INTEGRATION-0009
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_SA
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_reg_SA
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_SA_SU
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_reg_SA_SU
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_SA
+END_TESTCASE APPINSTALL-SWI-APPREG-INTEGRATION-0009
+
+//! @SYMTestCaseID		APPINSTALL-SWI-APPREG-INTEGRATION-0010
+//! @SYMTestCaseDesc	Tests the installation of an SIS file which delivers no files followed by a SA upgrade that delivers an app.
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installation succeeds
+//! @SYMTestExpectedResults	File installs sucessfully
+START_TESTCASE APPINSTALL-SWI-APPREG-INTEGRATION-0010
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_no_app
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini no_app
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_sa_app
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_sa_app
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_no_app
+END_TESTCASE APPINSTALL-SWI-APPREG-INTEGRATION-0010
+
+//! @SYMTestCaseID		APPINSTALL-SWI-APPREG-INTEGRATION-0011
+//! @SYMTestCaseDesc	Tests the installation of an SIS file which delivers some files followed by a SA upgrade that delivers no files.
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Installation succeeds
+//! @SYMTestExpectedResults	File installs sucessfully
+START_TESTCASE APPINSTALL-SWI-APPREG-INTEGRATION-0011
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_sa_app
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_sa_app
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_no_app
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini no_app
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_no_app
+END_TESTCASE APPINSTALL-SWI-APPREG-INTEGRATION-0011
+
+//! @SYMTestCaseID		APPINSTALL-SWI-APPREG-INTEGRATION-0012
+//! @SYMTestCaseDesc	Tests the installation of an SIS file embeds an SP, which embeds a PU, which in turn embeds another SP, that embeds another SP. (SA->SP->PU->SP->SP)
+//! @SYMTestPriority	Medium
+//! @SYMTestActions		Install a SIS file that embeds recursively other SIS files with various upgrade combinations.
+//! @SYMTestExpectedResults	File installs sucessfully
+START_TESTCASE APPINSTALL-SWI-APPREG-INTEGRATION-0012
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case06_base
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_case06_base
+RUN_TEST_STEP 100 tuiscriptadaptors InstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini swiappregintegration_case06_sa
+RUN_TEST_STEP 100 tscrapparc ScrGetApplicationRegistrationView z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini verify_case06_sa
+RUN_TEST_STEP 100 tuiscriptadaptors UninstallStep z:\tswi\tuiscriptadaptors\scripts\tswiappregintegration.ini u_swiappregintegration_case06
+END_TESTCASE APPINSTALL-SWI-APPREG-INTEGRATION-0012
+
 // Ensure that SWIS shuts down after the above tests to make sure heap checks run
 RUN_TEST_STEP 5 tuiscriptadaptors SwisNotRunning
Binary file installationservices/swiconfig/conf/appinstallconfig_2002cff6.crml has changed
--- a/installationservices/swiconfig/swi/swiconfig.iby	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swiconfig/swi/swiconfig.iby	Fri May 14 15:58:48 2010 +0300
@@ -20,7 +20,6 @@
 
 data = EPOCROOT##epoc32\data\z\system\data\swipolicy.ini \system\data\swipolicy.ini
 data = EPOCROOT##epoc32\data\z\system\data\2002cff6.txt \private\10202be9\2002cff6.txt
-data = EPOCROOT##epoc32\data\z\system\data\sisregistry_5.3.txt \system\data\sisregistry_5.3.txt
 data = MULTI_LINGUIFY(RSC ZRESOURCE\Errors\swierrors Resource\Errors\swierrors)
 
 #endif
Binary file installationservices/swiconfig/usif/scr/scr.db has changed
Binary file installationservices/swiconfig/usif/scr/update_db_production.xml has changed
--- a/installationservices/swiconfig/usif/siflauncher/siflauncher_reg.rss	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swiconfig/usif/siflauncher/siflauncher_reg.rss	Fri May 14 15:58:48 2010 +0300
@@ -33,6 +33,15 @@
 	newfile=KAppDoesNotSupportNewFile;
 	datatype_list=
 		{
-		DATATYPE { priority=EDataTypePriorityHigh; type="x-epoc/x-sisx-app"; }
+		DATATYPE { priority=EDataTypePrioritySystem; type="x-epoc/x-sisx-app"; },
+		DATATYPE { priority=EDataTypePrioritySystem; type="x-epoc/x-app268436505"; },
+		DATATYPE { priority=EDataTypePrioritySystem; type="application/vnd.symbian.install"; },
+		DATATYPE { priority=EDataTypePrioritySystem; type="application/x-pip"; },
+		DATATYPE { priority=EDataTypePrioritySystem; type="text/vnd.sun.j2me.app-descriptor"; },
+		DATATYPE { priority=EDataTypePrioritySystem; type="application/java"; },
+		DATATYPE { priority=EDataTypePrioritySystem; type="application/java-archive"; },
+		DATATYPE { priority=EDataTypePrioritySystem; type="application/x-java-archive"; },
+		DATATYPE { priority=EDataTypePrioritySystem; type="application/widget"; },
+		DATATYPE { priority=EDataTypePrioritySystem; type="application/x-nokia-widget"; }
 		};
 	}
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/bwins/sifnotificationu.def	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,54 @@
+EXPORTS
+	?Total@CSifOperationProgressData@Usif@@QBEHXZ @ 1 NONAME ; int Usif::CSifOperationProgressData::Total(void) const
+	?PublishCompletionL@CPublishSifOperationInfo@Usif@@QAEXAAVCSifOperationEndData@2@@Z @ 2 NONAME ; void Usif::CPublishSifOperationInfo::PublishCompletionL(class Usif::CSifOperationEndData &)
+	?ComponentName@CSifOperationStartData@Usif@@QBEABVHBufC16@@XZ @ 3 NONAME ; class HBufC16 const & Usif::CSifOperationStartData::ComponentName(void) const
+	?NewLC@CSifOperationEndData@Usif@@SAPAV12@ABVTDesC16@@W4TErrorCategory@2@H00@Z @ 4 NONAME ; class Usif::CSifOperationEndData * Usif::CSifOperationEndData::NewLC(class TDesC16 const &, enum Usif::TErrorCategory, int, class TDesC16 const &, class TDesC16 const &)
+	?GlobalComponentId@CSifOperationProgressData@Usif@@QBEABVHBufC16@@XZ @ 5 NONAME ; class HBufC16 const & Usif::CSifOperationProgressData::GlobalComponentId(void) const
+	?ErrorMessageDetails@CSifOperationEndData@Usif@@QBEABVHBufC16@@XZ @ 6 NONAME ; class HBufC16 const & Usif::CSifOperationEndData::ErrorMessageDetails(void) const
+	?ApplicationIcons@CSifOperationStartData@Usif@@QBEABV?$RPointerArray@VHBufC16@@@@XZ @ 7 NONAME ; class RPointerArray<class HBufC16> const & Usif::CSifOperationStartData::ApplicationIcons(void) const
+	?ExternalizeL@CSifOperationProgressData@Usif@@QBEXAAVRWriteStream@@@Z @ 8 NONAME ; void Usif::CSifOperationProgressData::ExternalizeL(class RWriteStream &) const
+	?ErrorCode@CSifOperationEndData@Usif@@QBEHXZ @ 9 NONAME ; int Usif::CSifOperationEndData::ErrorCode(void) const
+	?NewL@CSifOperationStartData@Usif@@SAPAV12@ABVTDesC16@@0ABV?$RPointerArray@VHBufC16@@@@1H000@Z @ 10 NONAME ; class Usif::CSifOperationStartData * Usif::CSifOperationStartData::NewL(class TDesC16 const &, class TDesC16 const &, class RPointerArray<class HBufC16> const &, class RPointerArray<class HBufC16> const &, int, class TDesC16 const &, class TDesC16 const &, class TDesC16 const &)
+	?ExternalizeL@CSifOperationStartData@Usif@@QBEXAAVRWriteStream@@@Z @ 11 NONAME ; void Usif::CSifOperationStartData::ExternalizeL(class RWriteStream &) const
+	?NewLC@CSifNotifierBase@Usif@@SAPAV12@AAVMSifOperationsHandler@2@IW4TNotifierType@12@@Z @ 12 NONAME ; class Usif::CSifNotifierBase * Usif::CSifNotifierBase::NewLC(class Usif::MSifOperationsHandler &, unsigned int, enum Usif::CSifNotifierBase::TNotifierType)
+	?IconPath@CSifOperationStartData@Usif@@QBEABVHBufC16@@XZ @ 13 NONAME ; class HBufC16 const & Usif::CSifOperationStartData::IconPath(void) const
+	?ApplicationNames@CSifOperationStartData@Usif@@QBEABV?$RPointerArray@VHBufC16@@@@XZ @ 14 NONAME ; class RPointerArray<class HBufC16> const & Usif::CSifOperationStartData::ApplicationNames(void) const
+	?NewLC@CSifOperationStartData@Usif@@SAPAV12@ABVTDesC16@@0ABV?$RPointerArray@VHBufC16@@@@1H000@Z @ 15 NONAME ; class Usif::CSifOperationStartData * Usif::CSifOperationStartData::NewLC(class TDesC16 const &, class TDesC16 const &, class RPointerArray<class HBufC16> const &, class RPointerArray<class HBufC16> const &, int, class TDesC16 const &, class TDesC16 const &, class TDesC16 const &)
+	?Phase@CSifOperationProgressData@Usif@@QBE?AW4TSifOperationPhase@2@XZ @ 16 NONAME ; enum Usif::TSifOperationPhase Usif::CSifOperationProgressData::Phase(void) const
+	?NewLC@CSifOperationKey@Usif@@SAPAV12@XZ @ 17 NONAME ; class Usif::CSifOperationKey * Usif::CSifOperationKey::NewLC(void)
+	?NewL@CSifOperationKey@Usif@@SAPAV12@XZ @ 18 NONAME ; class Usif::CSifOperationKey * Usif::CSifOperationKey::NewL(void)
+	??1CSifOperationEndData@Usif@@UAE@XZ @ 19 NONAME ; Usif::CSifOperationEndData::~CSifOperationEndData(void)
+	?NewLC@CSifOperationProgressData@Usif@@SAPAV12@ABVTDesC16@@W4TSifOperationPhase@2@W4TSifOperationSubPhase@2@HH@Z @ 20 NONAME ; class Usif::CSifOperationProgressData * Usif::CSifOperationProgressData::NewLC(class TDesC16 const &, enum Usif::TSifOperationPhase, enum Usif::TSifOperationSubPhase, int, int)
+	?PublishStartL@CPublishSifOperationInfo@Usif@@QAEXAAVCSifOperationStartData@2@@Z @ 21 NONAME ; void Usif::CPublishSifOperationInfo::PublishStartL(class Usif::CSifOperationStartData &)
+	?SubPhase@CSifOperationProgressData@Usif@@QBE?AW4TSifOperationSubPhase@2@XZ @ 22 NONAME ; enum Usif::TSifOperationSubPhase Usif::CSifOperationProgressData::SubPhase(void) const
+	?CancelSubscribeL@CSifOperationsNotifier@Usif@@QAEXXZ @ 23 NONAME ; void Usif::CSifOperationsNotifier::CancelSubscribeL(void)
+	?ComponentIcon@CSifOperationStartData@Usif@@QBEABVHBufC16@@XZ @ 24 NONAME ; class HBufC16 const & Usif::CSifOperationStartData::ComponentIcon(void) const
+	?NewLC@CSifOperationsNotifier@Usif@@SAPAV12@AAVMSifOperationsHandler@2@@Z @ 25 NONAME ; class Usif::CSifOperationsNotifier * Usif::CSifOperationsNotifier::NewLC(class Usif::MSifOperationsHandler &)
+	?NewL@CSifOperationStartData@Usif@@SAPAV12@AAVRReadStream@@@Z @ 26 NONAME ; class Usif::CSifOperationStartData * Usif::CSifOperationStartData::NewL(class RReadStream &)
+	?ComponentSize@CSifOperationStartData@Usif@@QBEHXZ @ 27 NONAME ; int Usif::CSifOperationStartData::ComponentSize(void) const
+	?SoftwareType@CSifOperationStartData@Usif@@QBEABVHBufC16@@XZ @ 28 NONAME ; class HBufC16 const & Usif::CSifOperationStartData::SoftwareType(void) const
+	?NewL@CPublishSifOperationInfo@Usif@@SAPAV12@XZ @ 29 NONAME ; class Usif::CPublishSifOperationInfo * Usif::CPublishSifOperationInfo::NewL(void)
+	?NewL@CSifNotifierBase@Usif@@SAPAV12@AAVMSifOperationsHandler@2@IW4TNotifierType@12@@Z @ 30 NONAME ; class Usif::CSifNotifierBase * Usif::CSifNotifierBase::NewL(class Usif::MSifOperationsHandler &, unsigned int, enum Usif::CSifNotifierBase::TNotifierType)
+	?ErrorCategory@CSifOperationEndData@Usif@@QBE?AW4TErrorCategory@2@XZ @ 31 NONAME ; enum Usif::TErrorCategory Usif::CSifOperationEndData::ErrorCategory(void) const
+	?ExternalizeL@CSifOperationEndData@Usif@@QBEXAAVRWriteStream@@@Z @ 32 NONAME ; void Usif::CSifOperationEndData::ExternalizeL(class RWriteStream &) const
+	?GlobalComponentId@CSifOperationStartData@Usif@@QBEABVHBufC16@@XZ @ 33 NONAME ; class HBufC16 const & Usif::CSifOperationStartData::GlobalComponentId(void) const
+	??1CSifOperationStartData@Usif@@UAE@XZ @ 34 NONAME ; Usif::CSifOperationStartData::~CSifOperationStartData(void)
+	?CancelSubscribeL@CSifOperationsNotifier@Usif@@QAEXI@Z @ 35 NONAME ; void Usif::CSifOperationsNotifier::CancelSubscribeL(unsigned int)
+	?Key@CSifNotifierBase@Usif@@QAEIXZ @ 36 NONAME ; unsigned int Usif::CSifNotifierBase::Key(void)
+	?CurrentProgess@CSifOperationProgressData@Usif@@QBEHXZ @ 37 NONAME ; int Usif::CSifOperationProgressData::CurrentProgess(void) const
+	?NewL@CSifOperationProgressData@Usif@@SAPAV12@AAVRReadStream@@@Z @ 38 NONAME ; class Usif::CSifOperationProgressData * Usif::CSifOperationProgressData::NewL(class RReadStream &)
+	?PublishProgressL@CPublishSifOperationInfo@Usif@@QAEXAAVCSifOperationProgressData@2@@Z @ 39 NONAME ; void Usif::CPublishSifOperationInfo::PublishProgressL(class Usif::CSifOperationProgressData &)
+	??1CSifNotifierBase@Usif@@UAE@XZ @ 40 NONAME ; Usif::CSifNotifierBase::~CSifNotifierBase(void)
+	?NewL@CSifOperationEndData@Usif@@SAPAV12@ABVTDesC16@@W4TErrorCategory@2@H00@Z @ 41 NONAME ; class Usif::CSifOperationEndData * Usif::CSifOperationEndData::NewL(class TDesC16 const &, enum Usif::TErrorCategory, int, class TDesC16 const &, class TDesC16 const &)
+	??1CSifOperationsNotifier@Usif@@UAE@XZ @ 42 NONAME ; Usif::CSifOperationsNotifier::~CSifOperationsNotifier(void)
+	?GlobalComponentId@CSifOperationEndData@Usif@@QBEABVHBufC16@@XZ @ 43 NONAME ; class HBufC16 const & Usif::CSifOperationEndData::GlobalComponentId(void) const
+	?NewL@CSifOperationEndData@Usif@@SAPAV12@AAVRReadStream@@@Z @ 44 NONAME ; class Usif::CSifOperationEndData * Usif::CSifOperationEndData::NewL(class RReadStream &)
+	?SubscribeL@CSifOperationsNotifier@Usif@@QAEXIH@Z @ 45 NONAME ; void Usif::CSifOperationsNotifier::SubscribeL(unsigned int, int)
+	?ExternalizeL@CSifOperationKey@Usif@@QBEXAAVRWriteStream@@@Z @ 46 NONAME ; void Usif::CSifOperationKey::ExternalizeL(class RWriteStream &) const
+	?NewLC@CPublishSifOperationInfo@Usif@@SAPAV12@XZ @ 47 NONAME ; class Usif::CPublishSifOperationInfo * Usif::CPublishSifOperationInfo::NewLC(void)
+	?ErrorMessage@CSifOperationEndData@Usif@@QBEABVHBufC16@@XZ @ 48 NONAME ; class HBufC16 const & Usif::CSifOperationEndData::ErrorMessage(void) const
+	?NewL@CSifOperationsNotifier@Usif@@SAPAV12@AAVMSifOperationsHandler@2@@Z @ 49 NONAME ; class Usif::CSifOperationsNotifier * Usif::CSifOperationsNotifier::NewL(class Usif::MSifOperationsHandler &)
+	??1CSifOperationProgressData@Usif@@UAE@XZ @ 50 NONAME ; Usif::CSifOperationProgressData::~CSifOperationProgressData(void)
+	?NewL@CSifOperationProgressData@Usif@@SAPAV12@ABVTDesC16@@W4TSifOperationPhase@2@W4TSifOperationSubPhase@2@HH@Z @ 51 NONAME ; class Usif::CSifOperationProgressData * Usif::CSifOperationProgressData::NewL(class TDesC16 const &, enum Usif::TSifOperationPhase, enum Usif::TSifOperationSubPhase, int, int)
+	??1CPublishSifOperationInfo@Usif@@UAE@XZ @ 52 NONAME ; Usif::CPublishSifOperationInfo::~CPublishSifOperationInfo(void)
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/eabi/sifnotificationu.def	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,57 @@
+EXPORTS
+	_ZN4Usif16CSifNotifierBase4NewLERNS_21MSifOperationsHandlerEjNS0_13TNotifierTypeE @ 1 NONAME
+	_ZN4Usif16CSifNotifierBase5NewLCERNS_21MSifOperationsHandlerEjNS0_13TNotifierTypeE @ 2 NONAME
+	_ZN4Usif16CSifOperationKey4NewLEv @ 3 NONAME
+	_ZN4Usif20CSifOperationEndData4NewLER11RReadStream @ 4 NONAME
+	_ZN4Usif20CSifOperationEndData4NewLERK7TDesC16NS_14TErrorCategoryEiS3_S3_ @ 5 NONAME
+	_ZN4Usif20CSifOperationEndData5NewLCERK7TDesC16NS_14TErrorCategoryEiS3_S3_ @ 6 NONAME
+	_ZN4Usif20CSifOperationEndDataD0Ev @ 7 NONAME
+	_ZN4Usif20CSifOperationEndDataD1Ev @ 8 NONAME
+	_ZN4Usif20CSifOperationEndDataD2Ev @ 9 NONAME
+	_ZN4Usif22CSifOperationStartData4NewLER11RReadStream @ 10 NONAME
+	_ZN4Usif22CSifOperationStartData4NewLERK7TDesC16S3_RK13RPointerArrayI7HBufC16ES8_iS3_S3_S3_ @ 11 NONAME
+	_ZN4Usif22CSifOperationStartData5NewLCERK7TDesC16S3_RK13RPointerArrayI7HBufC16ES8_iS3_S3_S3_ @ 12 NONAME
+	_ZN4Usif22CSifOperationStartDataD0Ev @ 13 NONAME
+	_ZN4Usif22CSifOperationStartDataD1Ev @ 14 NONAME
+	_ZN4Usif22CSifOperationStartDataD2Ev @ 15 NONAME
+	_ZN4Usif22CSifOperationsNotifier10SubscribeLEji @ 16 NONAME
+	_ZN4Usif22CSifOperationsNotifier16CancelSubscribeLEj @ 17 NONAME
+	_ZN4Usif22CSifOperationsNotifier16CancelSubscribeLEv @ 18 NONAME
+	_ZN4Usif22CSifOperationsNotifier4NewLERNS_21MSifOperationsHandlerE @ 19 NONAME
+	_ZN4Usif22CSifOperationsNotifier5NewLCERNS_21MSifOperationsHandlerE @ 20 NONAME
+	_ZN4Usif24CPublishSifOperationInfo13PublishStartLERNS_22CSifOperationStartDataE @ 21 NONAME
+	_ZN4Usif24CPublishSifOperationInfo16PublishProgressLERNS_25CSifOperationProgressDataE @ 22 NONAME
+	_ZN4Usif24CPublishSifOperationInfo18PublishCompletionLERNS_20CSifOperationEndDataE @ 23 NONAME
+	_ZN4Usif24CPublishSifOperationInfo4NewLEv @ 24 NONAME
+	_ZN4Usif24CPublishSifOperationInfo5NewLCEv @ 25 NONAME
+	_ZN4Usif25CSifOperationProgressData4NewLER11RReadStream @ 26 NONAME
+	_ZN4Usif25CSifOperationProgressData4NewLERK7TDesC16NS_18TSifOperationPhaseENS_21TSifOperationSubPhaseEii @ 27 NONAME
+	_ZN4Usif25CSifOperationProgressData5NewLCERK7TDesC16NS_18TSifOperationPhaseENS_21TSifOperationSubPhaseEii @ 28 NONAME
+	_ZN4Usif25CSifOperationProgressDataD0Ev @ 29 NONAME
+	_ZN4Usif25CSifOperationProgressDataD1Ev @ 30 NONAME
+	_ZN4Usif25CSifOperationProgressDataD2Ev @ 31 NONAME
+	_ZNK4Usif16CSifOperationKey12ExternalizeLER12RWriteStream @ 32 NONAME
+	_ZNK4Usif20CSifOperationEndData12ErrorMessageEv @ 33 NONAME
+	_ZNK4Usif20CSifOperationEndData12ExternalizeLER12RWriteStream @ 34 NONAME
+	_ZNK4Usif20CSifOperationEndData13ErrorCategoryEv @ 35 NONAME
+	_ZNK4Usif20CSifOperationEndData17GlobalComponentIdEv @ 36 NONAME
+	_ZNK4Usif20CSifOperationEndData19ErrorMessageDetailsEv @ 37 NONAME
+	_ZNK4Usif20CSifOperationEndData9ErrorCodeEv @ 38 NONAME
+	_ZNK4Usif22CSifOperationStartData12ExternalizeLER12RWriteStream @ 39 NONAME
+	_ZNK4Usif22CSifOperationStartData12SoftwareTypeEv @ 40 NONAME
+	_ZNK4Usif22CSifOperationStartData13ComponentIconEv @ 41 NONAME
+	_ZNK4Usif22CSifOperationStartData13ComponentNameEv @ 42 NONAME
+	_ZNK4Usif22CSifOperationStartData13ComponentSizeEv @ 43 NONAME
+	_ZNK4Usif22CSifOperationStartData16ApplicationIconsEv @ 44 NONAME
+	_ZNK4Usif22CSifOperationStartData16ApplicationNamesEv @ 45 NONAME
+	_ZNK4Usif22CSifOperationStartData17GlobalComponentIdEv @ 46 NONAME
+	_ZNK4Usif22CSifOperationStartData8IconPathEv @ 47 NONAME
+	_ZNK4Usif25CSifOperationProgressData12ExternalizeLER12RWriteStream @ 48 NONAME
+	_ZNK4Usif25CSifOperationProgressData14CurrentProgessEv @ 49 NONAME
+	_ZNK4Usif25CSifOperationProgressData17GlobalComponentIdEv @ 50 NONAME
+	_ZNK4Usif25CSifOperationProgressData5PhaseEv @ 51 NONAME
+	_ZNK4Usif25CSifOperationProgressData5TotalEv @ 52 NONAME
+	_ZNK4Usif25CSifOperationProgressData8SubPhaseEv @ 53 NONAME
+	_ZTIN4Usif16CSifNotifierBaseE @ 54 NONAME
+	_ZTVN4Usif16CSifNotifierBaseE @ 55 NONAME
+
--- a/installationservices/swinstallationfw/examples/refnativeplugin/group/refnativeplugin.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/examples/refnativeplugin/group/refnativeplugin.mmp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2009 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 the License "Eclipse Public License v1.0"
@@ -27,7 +27,7 @@
 
 UID				0x10009D8D 0x10285BC3
 
-CAPABILITY		ProtServ TrustedUI ReadUserData
+CAPABILITY		ProtServ TrustedUI ReadUserData WriteDeviceData
 
 SOURCEPATH		../source
 SOURCE			refnativeplugin.cpp
--- a/installationservices/swinstallationfw/group/bld.inf	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/group/bld.inf	Fri May 14 15:58:48 2010 +0300
@@ -35,6 +35,7 @@
 ../inc/siftransportclient.h									SYMBIAN_MW_LAYER_PUBLIC_EXPORT_PATH(usif/sif/siftransportclient.h)
 ../inc/siftransportserverstartup.h							SYMBIAN_MW_LAYER_PUBLIC_EXPORT_PATH(usif/sif/siftransportserverstartup.h)
 ../inc/siftransporttask.h									SYMBIAN_MW_LAYER_PUBLIC_EXPORT_PATH(usif/sif/siftransporttask.h)
+../inc/sifnotification.h									SYMBIAN_MW_LAYER_PUBLIC_EXPORT_PATH(usif/sif/sifnotification.h)
 
 // ROMKIT includes
 ../inc/sif.iby												/epoc32/rom/include/sif.iby
@@ -44,6 +45,8 @@
 // TEF test scripts
 ../test/tusif/scripts/tsifintegration.ini				z:/tusif/tsifintegration/tsifintegration.ini
 ../test/tusif/scripts/tsifintegration.script				z:/tusif/tsifintegration/tsifintegration.script
+../test/tusif/scripts/tnotifier.ini					z:/tusif/tsif/tnotifier.ini
+../test/tusif/scripts/tnotifier.script					z:/tusif/tsif/tnotifier.script
 
 ../test/scripts/tsif.ini									z:/tusif/tsif/tsif.ini
 ../test/scripts/tsif.script									z:/tusif/tsif/tsif.script
@@ -64,7 +67,7 @@
 
 ../test/tusif/scripts/data/test.siftestpkg			z:/tusif/tswtype/data/test.siftestpkg
 ../test/tusif/scripts/data/swtypereginfo.xml			z:/tusif/tswtype/data/swtypereginfo.xml
-../test/tusif/scripts/data/corrupt_reg.rsc			z:/tusif/tsif/data/corrupt_reg.rsc
+../test/tusif/scripts/data/Corrupt_reg.rsc			z:/tusif/tsif/data/corrupt_reg.rsc
 
 // ROMKIT includes
 ../inc/tsif.iby							/epoc32/rom/include/tsif.iby
@@ -80,6 +83,7 @@
 ../group/sifutils.mmp
 ../group/sifserver.mmp
 ../group/siflauncher.mmp
+../group/sifnotification.mmp
 
 #endif // TOOLS2
 #endif // TOOLS
--- a/installationservices/swinstallationfw/group/siflauncher.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/group/siflauncher.mmp	Fri May 14 15:58:48 2010 +0300
@@ -20,7 +20,8 @@
 TARGETTYPE			exe
 TARGETPATH			/sys/bin
 
-CAPABILITY			TrustedUI
+// We need WriteDeviceData so that the installer data types can have priority EDataTypePrioritySystem
+CAPABILITY			TrustedUI WriteDeviceData
 
 VENDORID			0x70000001
 
@@ -36,6 +37,23 @@
 
 SOURCEPATH			../../swiconfig/usif/siflauncher
 
+START RESOURCE		siflauncher_reg.rss
+TARGETPATH			/private/10003a3f/apps
+END
+
+start resource		siflauncher_loc.rss
+targetpath			/resource/apps
+lang				sc
+end
+
+// Bitmaps
+START BITMAP		siflauncher.mbm
+SOURCEPATH			../../swiconfig/usif/siflauncher
+TARGETPATH			/resource/apps
+HEADER
+SOURCE				c8,1 INST24.bmp INST24M.BMP INST32.BMP INST32M.BMP INST48.BMP INST48M.BMP
+END
+
 LIBRARY				euser.lib efsrv.lib
 LIBRARY				apgrfx.lib apparc.lib apmime.lib
 LIBRARY				sif.lib
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/group/sifnotification.mmp	Fri May 14 15:58:48 2010 +0300
@@ -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 the License "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: 
+* SIF Notifier Library
+*
+*/
+
+
+/**
+ @file
+*/
+
+TARGET sifnotification.dll
+TARGETTYPE dll
+
+UID 0x1000008D 0x10286357
+
+CAPABILITY All -Tcb
+
+SOURCEPATH ../source
+SOURCE sifnotification.cpp
+SOURCE sifnotifierdata.cpp
+
+USERINCLUDE ../inc_private
+USERINCLUDE ../../swcomponentregistry/inc_private
+USERINCLUDE	../common/inc
+
+MW_LAYER_SYSTEMINCLUDE_SYMBIAN
+
+LIBRARY euser.lib efsrv.lib estor.lib ipcstream.lib
+SMPSAFE
\ No newline at end of file
--- a/installationservices/swinstallationfw/group/sifserver.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/group/sifserver.mmp	Fri May 14 15:58:48 2010 +0300
@@ -19,7 +19,7 @@
 TARGET				sifserver.exe        
 TARGETTYPE			exe
 
-CAPABILITY			ProtServ TrustedUI ReadUserData
+CAPABILITY			ProtServ TrustedUI ReadUserData WriteDeviceData
 
 VENDORID			0x70000001
 
@@ -29,6 +29,7 @@
 
 USERINCLUDE			../inc
 USERINCLUDE			../common/inc
+USERINCLUDE			../inc_private
 
 SOURCEPATH			../source
 SOURCE				sifserverstartup.cpp sifservertask.cpp
--- a/installationservices/swinstallationfw/group/siftransport.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/group/siftransport.mmp	Fri May 14 15:58:48 2010 +0300
@@ -35,8 +35,10 @@
 
 USERINCLUDE ../inc
 USERINCLUDE ../common/inc
+USERINCLUDE ../inc_private
+USERINCLUDE ../../swcomponentregistry/inc_private
 
 MW_LAYER_SYSTEMINCLUDE_SYMBIAN
 
-LIBRARY euser.lib efsrv.lib estor.lib scsclient.lib scsserver.lib ipcstream.lib
+LIBRARY euser.lib efsrv.lib estor.lib scsclient.lib scsserver.lib ipcstream.lib sifnotification.lib
 SMPSAFE
\ No newline at end of file
--- a/installationservices/swinstallationfw/inc/sif.iby	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/inc/sif.iby	Fri May 14 15:58:48 2010 +0300
@@ -21,13 +21,14 @@
 
 define ZDRIVE \epoc32\data\Z
 
-//#include "siflauncherconfig.iby"
+#include "siflauncherconfig.iby"
 
 REM Software Install Framework
 
 file=ABI_DIR\BUILD_DIR\sif.dll				\sys\bin\sif.dll
 file=ABI_DIR\BUILD_DIR\sifutils.dll			\sys\bin\sifutils.dll
 file=ABI_DIR\BUILD_DIR\siftransport.dll		\sys\bin\siftransport.dll
+file=ABI_DIR\BUILD_DIR\sifnotification.dll	\sys\bin\sifnotification.dll
 file=ABI_DIR\BUILD_DIR\sifserver.exe		\sys\bin\sifserver.exe
 file=ABI_DIR\BUILD_DIR\siflauncher.exe		\sys\bin\siflauncher.exe
 
--- a/installationservices/swinstallationfw/inc/sifcommon.h	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/inc/sifcommon.h	Fri May 14 15:58:48 2010 +0300
@@ -636,7 +636,7 @@
 		"AllowOverwrite" - TSifPolicy
 		Can files be overwritten 
 
-		"DisplayPackageInfo" - TSifPolicy
+		"PackageInfo" - TSifPolicy
 		Whether to skip infos 
 
 		"AllowDownload" - TSifPolicy
@@ -663,6 +663,9 @@
   		"Charset" -  TDesC
 		Represents charset to be used during HTTP download 
 
+		"AllowIncompatible" -  TSifPolicy
+		Check if installation of incompatible packages is allowed 
+
 		"ComponentId" - Array of TUInt
 		If returned in the custom results, provides the id's of the newly added components
 		after an install. Please note that not all installers (i.e. SIF Plugins) may support this.
@@ -699,7 +702,7 @@
 	_LIT(KSifInParam_AllowAppShutdown, "AllowAppShutdown");
 	_LIT(KSifInParam_AllowAppBreakDependency, "AllowAppBreakDependency");
 	_LIT(KSifInParam_AllowOverwrite, "AllowOverwrite");
-	_LIT(KSifInParam_DisplayPackageInfo, "DisplayPackageInfo");
+	_LIT(KSifInParam_PackageInfo, "PackageInfo");
 	_LIT(KSifInParam_AllowDownload, "AllowDownload");
 	_LIT(KSifInParam_UserName, "UserName");
 	_LIT(KSifInParam_Password, "Password");
@@ -708,6 +711,7 @@
 	_LIT(KSifInParam_SNAP, "SNAP");
 	_LIT(KSifInParam_MimeType, "MimeType");
 	_LIT(KSifInParam_Charset, "Charset");
+	_LIT(KSifInParam_AllowIncompatible, "AllowIncompatible");
 
 	_LIT(KSifOutParam_ComponentId, "ComponentId");
 	_LIT(KSifOutParam_ErrCategory, "ErrCategory");
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/inc/sifnotification.h	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,528 @@
+/*
+* 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 the License "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: 
+* sifnotification.h - Interfaces to publish (by installers) and get notified (for clients) to an SIF operation progress
+*
+*/
+
+/**
+ @file
+ @released
+ @publishedPartner
+*/
+
+#ifndef __SIFNOTIFICATION_H__
+#define __SIFNOTIFICATION_H__
+
+#include <e32std.h>
+#include <e32base.h>
+#include <s32strm.h>
+#include <usif/usiferror.h>
+#include <e32property.h> 
+
+namespace Usif
+{
+// Forward declaration.
+class CSifNotifierBase;
+class CDeleteKeyTimer;
+
+//Identifies the type of operation
+enum TSifOperationPhase
+    {
+    EInstalling = 1,
+    EUninstalling,
+    EUpgrading
+    };
+
+//Identifies a stage in type of operation
+enum TSifOperationSubPhase 
+    {
+    ENoSubPhase = 1,
+    EOCSPCheck,
+    EDownload,
+    EFileOperation
+    };
+
+enum TSifOperation
+    {
+    ESifOperationStart = 1,
+    ESifOperationEnd
+    };
+
+
+/*
+ * This contains the basic information of package going to be installed/uninstalled (provided at the start of the operation)
+ */
+NONSHARABLE_CLASS(CSifOperationStartData) : public CBase    
+    {
+public:
+    /**
+        Creates a CSifOperationStartData object from the stream.
+             
+        @param  aStream   The stream to read the CSifOperationStartData object from.
+        @return A pointer to the newly allocated CSifOperationStartData object, if creation is successful.
+     */ 
+    IMPORT_C static CSifOperationStartData* NewL(RReadStream& aStream);
+    
+    /**
+        Creates a CSifOperationStartData object.
+        
+        @param  aGlobalComponentId  The global component id which uniquely identifies the operation          
+        @param  aComponentName		The name of the software component
+        @param  aApplicationNames	The list of applications associated with the software component, an empty array in case of no applications
+        @param  aApplicationIcons   The list of corresponding application icon names(without path) for every application, an empty array in case of no applications                 
+        @param  aComponentSize		The total size of the component in bytes
+        @param  aIconPath			The path where all application and component icons are found
+        @param  aComponentIcon		The name of the component icon(without path)
+        @param  aSoftwareType		The software type name of the software component
+                                                   
+        @return A pointer to the newly allocated CSifOperationStartData object, if creation is successful.
+     */      
+    IMPORT_C static CSifOperationStartData* NewL(const TDesC& aGlobalComponentId, const TDesC& aComponentName, const RPointerArray<HBufC>& aApplicationNames,
+                                                  const RPointerArray<HBufC>& aApplicationIcons, TInt aComponentSize, const TDesC& aIconPath, const TDesC& aComponentIcon, const TDesC& aSoftwareType);
+
+    /**
+        Creates a CSifOperationStartData object.
+        
+        @param  aGlobalComponentId  The global component id which uniquely identifies the operation          
+        @param  aComponentName      The name of the software component
+        @param  aApplicationNames   The list of applications associated with the software component, an empty array in case of no applications
+        @param  aApplicationIcons   The list of corresponding application icon names(without path) for every application, an empty array in case of no applications                 
+        @param  aComponentSize      The total size of the component in bytes
+        @param  aIconPath           The path where all application and component icons are found
+        @param  aComponentIcon      The name of the component icon(without path)
+        @param  aSoftwareType       The software type name of the software component
+                                                   
+        @return A pointer to the newly allocated CSifOperationStartData object, if creation is successful.
+                The pointer is also put onto the cleanup stack. 
+     */     
+    IMPORT_C static CSifOperationStartData* NewLC(const TDesC& aGlobalComponentId, const TDesC& aComponentName, const RPointerArray<HBufC>& aApplicationNames,
+                                                  const RPointerArray<HBufC>& aApplicationIcons, TInt aComponentSize, const TDesC& aIconPath, const TDesC& aComponentIcon, const TDesC& aSoftwareType);
+    
+    /**
+     @return The global component Id associated with the operation.
+     */     
+    IMPORT_C const HBufC& GlobalComponentId() const;
+    
+    /**
+     @return The component name associated with the operation.
+     */     
+    IMPORT_C const HBufC& ComponentName() const;
+    
+    /**
+     @return An array of application names.
+     */     
+    IMPORT_C const RPointerArray<HBufC>& ApplicationNames() const;
+    
+    /**
+     @return An array of application icons.
+     */     
+    IMPORT_C const RPointerArray<HBufC>& ApplicationIcons() const;
+    
+    /**
+     @return The size of the component in bytes.
+     */      
+    IMPORT_C TInt ComponentSize() const;    
+    
+    /**
+     @return The path to the application icons.
+     */     
+    IMPORT_C const HBufC& IconPath() const; 
+   
+    /**
+     @return The icon associated with the component.
+     */      
+    IMPORT_C const HBufC& ComponentIcon() const;
+    
+    /**
+     @return The software type associated with the operation.
+     */      
+    IMPORT_C const HBufC& SoftwareType() const;    
+    
+    IMPORT_C ~CSifOperationStartData();          
+
+    IMPORT_C void ExternalizeL(RWriteStream& aStream) const;
+
+private:
+    CSifOperationStartData();
+    void ConstructL(const TDesC& aGlobalComponentId, const TDesC& aComponentName, const RPointerArray<HBufC>& aApplicationNames,  
+          const RPointerArray<HBufC>& aApplicationIcons, TInt aComponentSize, const TDesC& aIconPath, const TDesC& aComponentIcon, const TDesC& aSoftwareType);
+    void InternalizeL(RReadStream& aStream);
+
+private:
+    HBufC* iGlobalComponentId;                                    
+    HBufC* iComponentName;
+    HBufC* iComponentIcon;
+    RPointerArray<HBufC> iApplicationNames;
+    RPointerArray<HBufC> iApplicationIcons;          
+    TInt iComponentSize;
+    HBufC* iIconPath;      
+    HBufC* iSoftwareType;
+    TSifOperation iOperationType;
+    };
+
+
+/*
+ * This contains the error status information after an install/uninstall operation
+ */
+NONSHARABLE_CLASS(CSifOperationEndData) : public CBase
+    {      
+public:
+    /**
+        Creates a CSifOperationEndData object from the stream.
+             
+        @param  aStream   The stream to read the CSifOperationEndData object from.
+        @return A pointer to the newly allocated CSifOperationEndData object, if creation is successful.
+     */     
+    IMPORT_C static CSifOperationEndData* NewL(RReadStream& aStream);
+    
+    /**
+        Creates a CSifOperationEndData object.
+        
+        @param  aGlobalComponentId  The global component id which uniquely identifies the operation          
+        @param  aErrCategory		A SIF error category
+        @param  aErrCode			SIF plugin (or runtime) specific error code
+        @param  aErrMsg				SIF plugin (or runtime) specific localized error message         
+        @param  aErrMsgDetails		SIF plugin (or runtime) specific localized message details
+                                                        
+        @return A pointer to the newly allocated CSifOperationEndData object, if creation is successful.
+     */     
+    IMPORT_C static CSifOperationEndData* NewL(const TDesC& aGlobalComponentId, TErrorCategory aErrCategory, TInt aErrCode, const TDesC& aErrMsg, const TDesC& aErrMsgDetails);    
+
+    /**
+        Creates a CSifOperationEndData object.
+        
+        @param  aGlobalComponentId  The global component id which uniquely identifies the operation          
+        @param  aErrCategory		A SIF error category
+        @param  aErrCode			SIF plugin (or runtime) specific error code
+        @param  aErrMsg				SIF plugin (or runtime) specific localized error message         
+        @param  aErrMsgDetails		SIF plugin (or runtime) specific localized message details
+                                                        
+        @return A pointer to the newly allocated CSifOperationEndData object, if creation is successful.
+                The pointer is also put onto the cleanup stack. 
+     */         
+    IMPORT_C static CSifOperationEndData* NewLC(const TDesC& aGlobalComponentId, TErrorCategory aErrCategory, TInt aErrCode, const TDesC& aErrMsg, const TDesC& aErrMsgDetails);
+
+    /**
+     @return The global component Id associated with the operation.
+     */     
+    IMPORT_C const HBufC& GlobalComponentId() const;
+    
+    /**
+    @return The category to which the error belongs.
+    */     
+    IMPORT_C TErrorCategory ErrorCategory() const;
+       
+    /**
+    @return An error code associated with the operation.
+    */     
+    IMPORT_C TInt ErrorCode() const;  
+       
+    /**
+     @return An error message.
+     */     
+    IMPORT_C const HBufC& ErrorMessage() const;
+    
+    /**
+     @return More details regarding the error message. 
+     */     
+    IMPORT_C const HBufC& ErrorMessageDetails() const;
+       
+    IMPORT_C ~CSifOperationEndData();
+  
+    IMPORT_C void ExternalizeL(RWriteStream& aStream) const;
+
+private:
+    CSifOperationEndData();
+    void ConstructL(const TDesC& aGlobalComponentID, TErrorCategory aErrCategory, TInt aErrCode, const TDesC& aErrMsg, const TDesC& aErrMsgDetails);
+    void InternalizeL(RReadStream& aStream);
+
+private:     
+    HBufC* iGlobalComponentId;   
+    HBufC* iErrMsg;                                    
+    HBufC* iErrMsgDetails;
+    TErrorCategory iErrCategory; 
+    TInt iErrCode;      
+    TSifOperation iOperationType;
+    };
+
+
+/*
+ * This class provides the operation progress.
+ */
+NONSHARABLE_CLASS(CSifOperationProgressData) : public CBase
+    {
+    public:
+    /**
+        Creates a CSifOperationProgressData object from the stream.
+             
+        @param  aStream   The stream to read the CSifOperationProgressData object from.
+        @return A pointer to the newly allocated CSifOperationProgressData object, if creation is successful.
+     */          
+    IMPORT_C static CSifOperationProgressData* NewL(RReadStream& aStream);
+    
+    /**
+        Creates a CSifOperationProgressData object.
+        
+        @param  aGlobalComponentId  The global component id which uniquely identifies the operation           
+        @param  aPhase				The type of SIF operation
+        @param  aSubPhase			The current stage in the type of SIF operation
+        @param  aCurrentProgress    The amount of operation which is completed in current subphase
+        @param  aTotal				The total amount of operation required by this subphase operation
+                                                        
+        @return A pointer to the newly allocated CSifOperationProgressData object, if creation is successful.
+     */      
+    IMPORT_C static CSifOperationProgressData* NewL(const TDesC& aGlobalcomponentId, TSifOperationPhase aPhase, TSifOperationSubPhase aSubPhase, TInt aCurrentProgress, TInt aTotal);      
+
+    /**
+        Creates a CSifOperationProgressData object.
+        
+        @param  aGlobalComponentId  The global component id which uniquely identifies the operation           
+        @param  aPhase				The type of SIF operation
+        @param  aSubPhase			The current stage in the type of SIF operation
+        @param  aCurrentProgress    The amount of operation which is completed in current subphase
+        @param  aTotal				The total amount of operation required by this subphase operation
+                                                        
+        @return A pointer to the newly allocated CSifOperationProgressData object, if creation is successful.
+                The pointer is also put onto the cleanup stack. 
+     */     
+    IMPORT_C static CSifOperationProgressData* NewLC(const TDesC& aGlobalcomponentId, TSifOperationPhase aPhase, TSifOperationSubPhase aSubPhase, TInt aCurrentProgress, TInt aTotal);
+
+    /**
+     @return The global component id associated with the operation.
+     */ 
+    IMPORT_C const HBufC& GlobalComponentId() const;
+    
+    /**
+     @return The current phase of operation.
+     */     
+    IMPORT_C TSifOperationPhase Phase() const;
+    
+    /**
+     @return The current sub-phase of operation.
+     */    
+    IMPORT_C TSifOperationSubPhase SubPhase() const;
+    
+    /**
+     @return The current progress value.
+     */     
+    IMPORT_C TInt CurrentProgess() const;
+    
+    /**
+     @return The total value to achieve completion of the subphase.
+     */     
+    IMPORT_C TInt Total() const;  
+    
+    IMPORT_C ~CSifOperationProgressData();               
+
+    IMPORT_C void ExternalizeL(RWriteStream& aStream) const;
+
+private:
+    CSifOperationProgressData();
+    void ConstructL(const TDesC& aGlobalcomponentId, TSifOperationPhase aPhase, TSifOperationSubPhase aSubPhase, TInt aCurrentProgress, TInt aTotal);
+    void InternalizeL(RReadStream& aStream);
+
+private:   
+    HBufC* iGlobalComponentId;       
+    TSifOperationPhase iPhase;
+    TSifOperationSubPhase iSubPhase;
+    TInt iCurrentProgress;
+    TInt iTotal;
+    };
+
+/**
+ * This class will be used by installers to publish a single install/uninstall/update operation information.
+ * A scheduler needs to be in started when using this class.
+ */
+NONSHARABLE_CLASS(CPublishSifOperationInfo) : public CBase
+    {
+public:
+    
+    /**
+        Creates a CPublishSifOperationInfo object.
+                                                        
+        @return A pointer to the newly allocated CPublishSifOperationInfo object, if creation is successful.
+     */       
+    IMPORT_C static CPublishSifOperationInfo* NewL();
+  
+    /**
+        Creates a CPublishSifOperationInfo object.
+                             
+        @return A pointer to the newly allocated CPublishSifOperationInfo object, if creation is successful.
+                The pointer is also put onto the cleanup stack. 
+     */       
+    IMPORT_C static CPublishSifOperationInfo* NewLC();
+    
+    /**
+		Publish the start of an operation. The corresponding PublishCompletionL() method should be called later
+		else an opeartion place holder is always blocked for this operation which has started.       
+       
+		@capability WriteDeviceData
+		@param aStartData Start operation related information.
+		@leave KErrInUse No more slots are available to publish.
+     */
+    IMPORT_C void PublishStartL(CSifOperationStartData& aStartData);
+
+    /**
+		Publish the operation progress information
+       
+		@capability WriteDeviceData
+		@param aProgressData Progress operation related information.
+     */
+    IMPORT_C void PublishProgressL(CSifOperationProgressData& aProgressData);
+
+    /**
+		Publish the error status of the operation (at the end)
+       
+		@capability WriteDeviceData
+		@param aEndData End operation related information.
+     */
+    IMPORT_C void PublishCompletionL(CSifOperationEndData& aEndData);
+    
+    IMPORT_C ~CPublishSifOperationInfo(); 
+    
+private:
+    void SetKeyToDelete(TUint aStartEndKey);
+    void SetStartEndKey(TUint aStartEndKey);
+    CPublishSifOperationInfo();
+    void ConstructL();
+    TUint AvailableKeyL();
+    TUint KeyForGlobalComponentIdL(const TDesC& aGlobalComponentId);
+    
+private:
+    CDeleteKeyTimer* iDeleteTimer;
+    TInt iBufferSize;
+    TUint iStartEndKey;
+    };
+
+/**
+ * MSifOperationsHandler
+ * Clients must implement this class in order to receive notifications.
+ */
+class MSifOperationsHandler
+    {
+public:
+    /**
+       Called when a new operation is started. The client should use the SubscribeL() method 
+       (@see CSifOperationsNotifier) to register for progress and end notification for this operation.
+       This function should return quickly as this is run as part of an active object request completion handler.
+
+       @param aKey The Start End key of the operation.
+       @param aStartData Start operation related information.
+     */
+    virtual void StartOperationHandler(TUint aKey, const CSifOperationStartData& aStartData) = 0;
+    
+    /**
+       Called when an operation completes.
+       This function should return quickly as this is run as part of an active object request completion handler.
+
+       @param aEndData End operation related information.
+     */
+    virtual void EndOperationHandler(const CSifOperationEndData& aEndData) = 0;
+   
+    /**
+       Called whenever a progress update is available.
+       This function should return quickly as this is run as part of an active object request completion handler.
+
+       @param aProgressData Progress operation related information.
+     */   
+    virtual void ProgressOperationHandler(const CSifOperationProgressData& aProgressData) = 0;
+    virtual ~MSifOperationsHandler() {}
+    };
+
+/**
+ * CSifOperationsNotifier
+ *
+ * Clients must create a CSifOperationsNotifier object by passing in the handler object.
+ *
+ * For every new Sif Operation, the StartOperationHandler() method of the handler would be called along
+ * with some related information. The client can choose to subscribe to this operation by calling the 
+ * SubscribeL() method.
+ * 
+ * A scheduler needs to be started when using this class.
+ */
+NONSHARABLE_CLASS(CSifOperationsNotifier) : public CActive
+    {
+public:    
+    
+    /**
+        Creates a CSifOperationsNotifier object.
+        
+        @param  aHandler A handle to the implementation of the MSifOperationsHandler class.      
+                                        
+        @return A pointer to the newly allocated CSifOperationsNotifier object, if creation is successful.
+                The pointer is also put onto the cleanup stack. 
+     */         
+    IMPORT_C static CSifOperationsNotifier* NewL(MSifOperationsHandler& aHandler);
+    
+    /**
+        Creates a CSifOperationsNotifier object.
+        
+        @param  aHandler A handle to the implementation of the MSifOperationsHandler class.     
+                                                        
+        @return A pointer to the newly allocated CSifOperationsNotifier object, if creation is successful.
+                The pointer is also put onto the cleanup stack. 
+     */         
+    IMPORT_C static CSifOperationsNotifier* NewLC(MSifOperationsHandler& aHandler);
+    
+    /**
+       Subscribe for progress and end notifications or only end notification.
+       
+       @param aKey The StartEnd key assoicated with the operation.
+       @param aSubscribeForProgressNotifications Boolean to specify optional subscription to progreess information.
+     */
+    IMPORT_C void SubscribeL(TUint aKey, TBool aSubscribeForProgressNotifications = ETrue);
+    
+    /**
+       Cancel Subscription for a specific key.
+       
+       @param aKey The StartEnd key assoicated with the operation.
+     */    
+    IMPORT_C void CancelSubscribeL(TUint aKey);
+    
+    /**
+       Cancel all subscriptions.
+     */      
+    IMPORT_C void CancelSubscribeL();
+    
+    IMPORT_C ~CSifOperationsNotifier();
+
+private:
+    enum TNotifierState
+        {
+        EFirstStart,
+        EWaitForChange
+        };
+    CSifOperationsNotifier(MSifOperationsHandler& aHandler);
+    void GetKeysL(RArray<TUint>& aKeys);
+    void ActiveOperationsNotificationL();
+    void WaitForChangeL();
+    void ConstructL();
+    void RunL();
+    void DoCancel();
+    TInt RunError(TInt aError);
+
+private:
+    MSifOperationsHandler& iHandler;
+    TInt iBufferSize;   
+    RArray<TUint> iKeyArray;
+    RProperty iProperty;
+    RPointerArray<CSifNotifierBase> iNotifierArray;
+    TNotifierState iNotifierState;
+    };
+
+
+} // namespace
+
+#endif
--- a/installationservices/swinstallationfw/inc/tsif.iby	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/inc/tsif.iby	Fri May 14 15:58:48 2010 +0300
@@ -24,9 +24,6 @@
 define ZDRIVE \epoc32\data\Z
 define DATADRIVE \tusif\tsif\data
 
-//This is to be removed if SIFLauncher is added as part of production code
-#include "siflauncherconfig.iby"
-
 ECOM_PLUGIN(refnativeplugin.dll,10285BC3.rsc)
 ECOM_PLUGIN(testnonnativeplugin.dll,10285BD1.rsc)
 
@@ -36,6 +33,8 @@
 data=ZDRIVE\tusif\tsif\tsif.script								\tusif\tsif\tsif.script
 data=ZDRIVE\tusif\tsif\tsif_appuidgen.ini							\tusif\tsif\tsif_appuidgen.ini
 data=ZDRIVE\tusif\tsif\tsif_appuidgen.script							\tusif\tsif\tsif_appuidgen.script
+data=ZDRIVE\tusif\tsif\tnotifier.ini							\tusif\tsif\tnotifier.ini
+data=ZDRIVE\tusif\tsif\tnotifier.script							\tusif\tsif\tnotifier.script
 data=ZDRIVE\tusif\tsifintegration\tsifintegration.ini			\tusif\tsifintegration\tsifintegration.ini
 data=ZDRIVE\tusif\tsifintegration\tsifintegration.script		\tusif\tsifintegration\tsifintegration.script
 data=ZDRIVE\tusif\tsifintegration\data\compound.sifrefbinpkg	\tusif\tsifintegration\data\compound.sifrefbinpkg
@@ -84,6 +83,12 @@
 data=ZDRIVE\tusif\tswtype\data\sifswtypebase.sis				\tusif\tswtype\data\sifswtypebase.sis
 data=ZDRIVE\tusif\tswtype\data\sifswtypeupgrade.sis				\tusif\tswtype\data\sifswtypeupgrade.sis
 
+data=ZDRIVE\tusif\tsif\data\swiappregintegration_case05.sis		DATADRIVE\swiappregintegration_case05.sis
+data=ZDRIVE\tusif\tsif\data\swiappregintegration_case05_SU.sis		DATADRIVE\swiappregintegration_case05_SU.sis
+data=ZDRIVE\tusif\tsif\data\swiappregintegration_case06_base.sis	DATADRIVE\swiappregintegration_case06_base.sis
+data=ZDRIVE\tusif\tsif\data\swiappregintegration_case06_sa.sis		DATADRIVE\swiappregintegration_case06_sa.sis
+data=ZDRIVE\tusif\tsif\data\swiappregintegration_case08_sa1.sis		DATADRIVE\swiappregintegration_case08_sa1.sis
+data=ZDRIVE\tusif\tsif\data\swiappregintegration_case08_sa2.sis		DATADRIVE\swiappregintegration_case08_sa2.sis
 
 REM security tests
 file=ABI_DIR\BUILD_DIR\usifsecuritytests.dll					\sys\bin\usifsecuritytests.dll
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/inc_private/sifnotification_internal.h	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,149 @@
+/*
+* 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 the License "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: 
+* sifnotification_internal.h - Internal classes used by the Sif notifier.
+*
+*/
+
+/**
+ @file
+ @released
+ @internal
+*/
+
+#ifndef __SIFNOTIFICATION_INTERNAL_H__
+#define __SIFNOTIFICATION_INTERNAL_H__
+
+#include <e32std.h>
+#include <usif/sif/sifnotification.h>
+
+namespace Usif {
+
+const TUint KBufferSize = 100;
+const TInt KMaxNumberOfOperations = 11;//One more than the maximum number of operations that that could be tracked
+//The Global operation key, this property will contain the total number and list of all the ongoing operations.
+const TUint KSifOperationKey = 0x2002ED64; 
+//StartEnd and progress key for the first operation
+const TUint KSifFirstOperationStartEndKey = 0x2002ED65; 
+//StartEnd and progress key for the second operation
+const TUint KSifSecondOperationStartEndKey = 0x2002ED67;
+//StartEnd and progress key for the third operation
+const TUint KSifThirdOperationStartEndKey = 0x2002ED69;
+//StartEnd and progress key for the fourth operation
+const TUint KSifFourthOperationStartEndKey = 0x2002F7C4;
+//StartEnd and progress key for the fifth operation
+const TUint KSifFifthOperationStartEndKey = 0x2002F7C6;
+//StartEnd and progress key for the sixth operation
+const TUint KSifSixthOperationStartEndKey = 0x2002F7C8;
+//StartEnd and progress key for the seventh operation
+const TUint KSifSeventhOperationStartEndKey = 0x2002F7CA;
+//StartEnd and progress key for the eight operation
+const TUint KSifEightOperationStartEndKey = 0x2002F7CC;
+//StartEnd and progress key for the ninth operation
+const TUint KSifNinthOperationStartEndKey = 0x2002F7CE;
+//StartEnd and progress key for the tenth operation
+const TUint KSifTenthOperationStartEndKey = 0x2002F7D0;
+
+const TUint KSifPropertyTable [KMaxNumberOfOperations-1] = {KSifFirstOperationStartEndKey, KSifSecondOperationStartEndKey, KSifThirdOperationStartEndKey,
+                                                            KSifFourthOperationStartEndKey, KSifFifthOperationStartEndKey, KSifSixthOperationStartEndKey,
+                                                            KSifSeventhOperationStartEndKey, KSifEightOperationStartEndKey, KSifNinthOperationStartEndKey, KSifTenthOperationStartEndKey};
+
+const TInt KDeleteKeyDelay = 2000000; // 2 seconds
+
+const TInt KStartBufLength = 100;
+const TInt KProgressBufLength = 25;
+
+_LIT_SECURITY_POLICY_C1(KSecurityPolicyNone, ECapability_None);
+_LIT_SECURITY_POLICY_C1(KSecurityPolicyWDD, ECapabilityWriteDeviceData);
+
+/**
+ * This class will be used internally to start timer after publishing the completion data.
+ * The property which holds the Start-End and Progress data will be deleted after this timer.
+ */
+NONSHARABLE_CLASS(CDeleteKeyTimer) : public CTimer
+    {
+public:
+    static CDeleteKeyTimer* NewL(const TUint aKey);
+    CDeleteKeyTimer();
+    ~CDeleteKeyTimer();
+    void Start();
+private:
+    void ConstructL(const TUint aKey);
+    void RunL();
+    TInt RunError(TInt aError);
+    TUint iKey;//StartEnd key to be deleted
+    };
+
+
+NONSHARABLE_CLASS(CSifOperationKey) : public CBase
+    /**
+     * This class will be used internally to hold contents of KSIFOperationKey
+     */
+    {
+public:
+    IMPORT_C static CSifOperationKey* NewL();
+    IMPORT_C static CSifOperationKey* NewLC();    
+    static CSifOperationKey* NewL(RReadStream& aStream);
+    ~CSifOperationKey(); 
+    void AddKeyL(TUint aKey);
+    void DeleteKey(TUint aPos);
+    const RArray<TUint>& StartEndKeys() const;
+    IMPORT_C void ExternalizeL(RWriteStream& aStream) const;
+private:
+    void InternalizeL(RReadStream& aStream);
+    CSifOperationKey();
+    void ConstructL();
+
+private:
+    RArray<TUint> iStartEndKeyArray; 
+    };
+
+
+/**
+ * This class will be used internally to subscribe to changes in individual operations requested by the client.
+ */
+class CSifNotifierBase : public CActive
+    {
+public:
+	enum TNotifierType
+        {
+        EStartEndNotifier =1,
+        EProgressNotifier
+        };
+
+    IMPORT_C static CSifNotifierBase* NewL(MSifOperationsHandler& aHandler, TUint aKey, TNotifierType aType);
+    IMPORT_C static CSifNotifierBase* NewLC(MSifOperationsHandler& aHandler, TUint aKey, TNotifierType aType);
+    IMPORT_C TUint Key();
+    IMPORT_C ~CSifNotifierBase();
+    
+private:
+    CSifNotifierBase(MSifOperationsHandler& aHandler, TUint aKey, TNotifierType aType);
+    void WaitForChangeL();
+    void ConstructL();
+    void RunL();
+    TInt RunError(TInt aError);
+    void DoCancel();
+    
+private:
+    MSifOperationsHandler& iHandler; 
+    TUint iKey;
+    RProperty iProperty;
+    TInt iBufferSize;
+    TNotifierType iType;
+    };
+
+
+} //namespace 
+
+#endif //__SIFNOTIFICATION_INTERNAL_H__
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/source/sifnotification.cpp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,826 @@
+/*
+* 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 the License "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: 
+* This file implements the SifNotifier library
+*
+*/
+
+#include <usif/sif/sifnotification.h>
+#include <s32mem.h> 
+#include <scs/cleanuputils.h>
+#include <scs/streamingarray.h>
+#include "sifnotification_internal.h"
+#include <usif/sif/sif.h>
+#include "e32property.h" 
+#include "scrclient.inl"
+#include "usiflog.h"
+
+
+using namespace Usif;
+
+/**
+ * A global method which is used by both the publisher and subscriber code to retrieve data.
+ * 
+ */
+void GetDataL(TUint aKey, TInt& aBufferSize, RBuf8& aData)
+    {
+    aData.CreateL(aBufferSize);
+    aData.CleanupClosePushL();
+    TInt err = RProperty::Get(KUidSystemCategory, aKey, aData);
+    
+    // If the buffer size is too small.
+    while (err == KErrOverflow)
+        {
+        aBufferSize*=2;
+        aData.ReAllocL(aBufferSize);
+        err = RProperty::Get(KUidSystemCategory, aKey, aData);
+        }
+        
+    User::LeaveIfError(err);
+    CleanupStack::Pop();
+    }
+
+////////////////////////////
+// CPublishSifOperationInfo
+////////////////////////////
+
+CPublishSifOperationInfo::CPublishSifOperationInfo():
+    iBufferSize(KBufferSize)
+    {
+    // empty
+    }
+
+CPublishSifOperationInfo::~CPublishSifOperationInfo()
+    {
+    delete iDeleteTimer;
+    if (iStartEndKey != 0)
+        {
+        RProperty::Delete(KUidSystemCategory, iStartEndKey);
+        RProperty::Delete(KUidSystemCategory, (iStartEndKey+1));
+        }
+    }
+
+EXPORT_C CPublishSifOperationInfo* CPublishSifOperationInfo::NewL()
+    {
+    CPublishSifOperationInfo *self = CPublishSifOperationInfo::NewLC();
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+EXPORT_C CPublishSifOperationInfo* CPublishSifOperationInfo::NewLC()
+    {
+    CPublishSifOperationInfo *self = new(ELeave) CPublishSifOperationInfo();
+    CleanupStack::PushL(self);
+    self->ConstructL();
+    return self;
+    }
+
+void CPublishSifOperationInfo::ConstructL()
+    {
+    
+    }
+
+TUint CPublishSifOperationInfo::AvailableKeyL()
+    {
+    TBuf8<KMaxNumberOfOperations*sizeof(TInt)> buf;
+    for(TInt i=0; i< KMaxNumberOfOperations-1; ++i)
+        {
+        if(KErrNotFound == RProperty::Get(KUidSystemCategory, KSifPropertyTable[i], buf))
+            {
+            return KSifPropertyTable[i];
+            }
+        }
+
+	User::Leave(KErrInUse);
+    return KErrNone; // Keep compiler happy.
+    }
+
+TUint CPublishSifOperationInfo::KeyForGlobalComponentIdL(const TDesC& aGlobalComponentId)
+    {
+    TBuf8<KMaxNumberOfOperations*sizeof(TInt)> buf;
+    //Get all ongoing operations
+    User::LeaveIfError(RProperty::Get(KUidSystemCategory, KSifOperationKey, buf));
+   
+    RDesReadStream readStream(buf);
+    CleanupClosePushL(readStream);
+    CSifOperationKey* opKey = CSifOperationKey::NewL(readStream);
+    CleanupStack::PopAndDestroy(&readStream);
+    CleanupStack::PushL(opKey);
+    
+    RArray<TUint> startEndKeyArr = opKey->StartEndKeys();
+	// Get the data for all the ongoing operations and check for global component id
+    for (TInt i=0; i<startEndKeyArr.Count(); ++i)
+        {
+        RBuf8 startDatabuf;
+        startDatabuf.CleanupClosePushL();
+
+		GetDataL(startEndKeyArr[i], iBufferSize, startDatabuf);
+        RDesReadStream readStream(startDatabuf);
+        CleanupClosePushL(readStream);
+        
+        // Read the first 4 bytes
+        TSifOperation opType = static_cast<TSifOperation>(readStream.ReadInt32L());         
+        if(opType != ESifOperationStart)
+            {
+            CleanupStack::PopAndDestroy(2, &startDatabuf);
+            continue;
+            }
+                    
+        // Release the stream and reopen it.
+        readStream.Release();
+        readStream.Open(startDatabuf);
+                    
+        CSifOperationStartData* startObj = CSifOperationStartData::NewL(readStream);
+        CleanupStack::PushL(startObj);
+		// Check if the global component id is the same as what we are looking for
+        if( KErrNone == aGlobalComponentId.Compare(startObj->GlobalComponentId()))
+            {
+            TInt key = startEndKeyArr[i];
+            CleanupStack::PopAndDestroy(4, opKey);
+            return key;
+            }
+        CleanupStack::PopAndDestroy(3, &startDatabuf);
+        }
+    CleanupStack::PopAndDestroy(opKey);
+    
+    // Could not find corresponding key
+    User::Leave(KErrNotFound);
+    return KErrNone; // Keep compiler happy.
+    }
+    
+void CPublishSifOperationInfo::SetKeyToDelete(TUint aStartEndKey)
+    {
+    iStartEndKey = aStartEndKey;
+    }
+
+EXPORT_C void CPublishSifOperationInfo::PublishStartL(CSifOperationStartData& aSifOperationStartData)
+    {
+    // Get Property key from free pool which could be used for this operation.
+    TUint key = AvailableKeyL();    
+    
+    // Define key from free pool. Start data could be bigger than 512 bytes, hence using ELargeByteArray.
+    User::LeaveIfError(RProperty::Define(KUidSystemCategory, key, RProperty::ELargeByteArray,KSecurityPolicyWDD,KSecurityPolicyNone,KStartBufLength));
+        
+    // Store this key and delete it in case of any leaves
+    SetKeyToDelete(key);
+    
+    // Publish start info of operation in defined key.
+    RBuf8 bufStartData;
+    bufStartData.CleanupClosePushL();
+    ExternalizeRefObjectL(aSifOperationStartData, bufStartData);
+
+    User::LeaveIfError(RProperty::Set(KUidSystemCategory, key, bufStartData));
+    
+    CleanupStack::PopAndDestroy(&bufStartData);
+    
+    // Define key for progress data for this operation.
+    User::LeaveIfError(RProperty::Define(KUidSystemCategory, (key+1), RProperty::EByteArray,KSecurityPolicyWDD,KSecurityPolicyNone, KProgressBufLength));
+    
+    // Publish(append this key to existing info) the newly defined key in the global SIF key.
+    TBuf8<KMaxNumberOfOperations*sizeof(TUint)> buf;
+
+    User::LeaveIfError(RProperty::Get(KUidSystemCategory, KSifOperationKey, buf));
+
+    RDesReadStream stream(buf);
+    CleanupClosePushL(stream);      
+    
+    // Retrieve current keys.
+    CSifOperationKey* currentKeys = CSifOperationKey::NewL(stream);
+    CleanupStack::PopAndDestroy(&stream);
+    
+    CleanupStack::PushL(currentKeys);
+    
+    // Append the new key.
+    currentKeys->AddKeyL(key);
+    
+    RBuf8 bufOperationKeys;
+    bufOperationKeys.CleanupClosePushL();
+    ExternalizeRefObjectL(*currentKeys, bufOperationKeys);
+    
+    // Publish the new set of keys.
+    User::LeaveIfError(RProperty::Set(KUidSystemCategory, KSifOperationKey, bufOperationKeys));
+    
+    // Everything finished fine, we need not delete the keys defined above.
+    SetKeyToDelete(0);
+    
+    CleanupStack::PopAndDestroy(2, currentKeys);
+    }
+
+EXPORT_C void CPublishSifOperationInfo::PublishProgressL(CSifOperationProgressData& aSifOperationProgressData)
+    {
+    TUint startEndKey = 0;
+    
+    HBufC16 *compGlobalId = aSifOperationProgressData.GlobalComponentId().AllocLC();
+	//Get the key defined for this operation
+    startEndKey = KeyForGlobalComponentIdL(compGlobalId->Des());
+    CleanupStack::PopAndDestroy(compGlobalId);
+
+    //Publish progress info of operation in defined key
+    RBuf8 bufProgressData;
+    bufProgressData.CleanupClosePushL();
+    ExternalizeRefObjectL(aSifOperationProgressData, bufProgressData);
+    User::LeaveIfError(RProperty::Set(KUidSystemCategory, (startEndKey+1), bufProgressData));
+    CleanupStack::PopAndDestroy(&bufProgressData);
+    }
+
+EXPORT_C void CPublishSifOperationInfo::PublishCompletionL(CSifOperationEndData& aSifOperationEndData)
+    {
+    TUint endKey = 0;
+    HBufC *compGlobalId = aSifOperationEndData.GlobalComponentId().AllocLC();
+	//Get the key defined for this operation
+    endKey = KeyForGlobalComponentIdL(compGlobalId->Des());
+    CleanupStack::PopAndDestroy(compGlobalId);
+    
+    // Store this key and delete it in case of any leaves
+    SetKeyToDelete(endKey);
+    
+    //Publish end info of operation in defined key
+    RBuf8 bufEndData;
+    bufEndData.CleanupClosePushL();
+    ExternalizeRefObjectL(aSifOperationEndData, bufEndData);
+
+    User::LeaveIfError(RProperty::Set(KUidSystemCategory, endKey, bufEndData));
+    CleanupStack::PopAndDestroy(&bufEndData);
+    
+    // Wait for KDeleteKeyDelay seconds before deleting this key.
+    if(iDeleteTimer)
+        iDeleteTimer->Cancel();
+    delete iDeleteTimer;
+    iDeleteTimer = CDeleteKeyTimer::NewL(endKey);
+    
+    // Everything finished fine, we need not delete the keys defined for this operation
+    SetKeyToDelete(0);
+    
+    iDeleteTimer->Start();
+
+    }
+
+
+
+//////////////////////////
+// CSifOperationsNotifier
+//////////////////////////
+
+
+EXPORT_C CSifOperationsNotifier* CSifOperationsNotifier::NewL(MSifOperationsHandler& aHandler)
+    {
+    CSifOperationsNotifier* self = CSifOperationsNotifier::NewLC(aHandler);
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+
+EXPORT_C CSifOperationsNotifier* CSifOperationsNotifier::NewLC(MSifOperationsHandler& aHandler)
+    {
+    CSifOperationsNotifier* self = new (ELeave) CSifOperationsNotifier(aHandler);
+    CleanupStack::PushL(self);
+    self->ConstructL();
+    return self;
+    }
+
+CSifOperationsNotifier::CSifOperationsNotifier(MSifOperationsHandler& aHandler):
+    CActive(EPriorityNormal),
+    iHandler(aHandler),
+    iBufferSize(KBufferSize) 
+    {
+    //Empty
+    }
+
+
+void CSifOperationsNotifier::ConstructL()
+    {
+    CActiveScheduler::Add(this);
+    iProperty.Attach(KUidSystemCategory,KSifOperationKey,EOwnerThread);
+    
+    // On first start, the notifier looks for any active operations and 
+    // notifies the client.
+    iNotifierState = EFirstStart;
+    
+    TRequestStatus* status = &iStatus;
+    User::RequestComplete(status, KErrNone);
+    SetActive();
+    }
+
+
+void CSifOperationsNotifier::RunL()
+    {  
+    User::LeaveIfError(iStatus.Int());
+    
+    // Resubscribe for any changes to the global key.
+    WaitForChangeL();
+    
+    if( iNotifierState == EFirstStart)
+        {
+        // Notify the client of any active operation.
+        ActiveOperationsNotificationL();
+        iNotifierState = EWaitForChange;    
+        return;
+        }
+ 
+   // Global key change notification received.      
+    RArray<TUint> newKeyArray;
+    GetKeysL(newKeyArray);
+    CleanupClosePushL(newKeyArray);
+    
+    if(iKeyArray.Count() < newKeyArray.Count())
+        {
+        // New Keys added.
+        RBuf8 externalizedBuffer;
+        externalizedBuffer.CleanupClosePushL();
+        
+        // Retrieve the new keys and send the start operation notification to each.
+        for(TInt i = iKeyArray.Count(); i< newKeyArray.Count(); ++i)
+            {
+            externalizedBuffer.Close();
+            GetDataL(newKeyArray[i], iBufferSize, externalizedBuffer);
+            
+            RDesReadStream stream(externalizedBuffer);
+            CleanupClosePushL(stream);
+            // Read the first 4 bytes
+            TSifOperation opType = static_cast<TSifOperation>(stream.ReadInt32L());         
+            if(opType != ESifOperationStart)
+                {
+                CleanupStack::PopAndDestroy(&stream);
+                continue;
+                }
+            
+            // Release the stream and reopen it.
+            stream.Release();
+            stream.Open(externalizedBuffer);
+           
+            CSifOperationStartData* startData = CSifOperationStartData::NewL(stream);
+            CleanupStack::PushL(startData);
+            
+            //Update iKeyArray with the new key.
+            iKeyArray.AppendL(newKeyArray[i]);
+            
+            iHandler.StartOperationHandler(newKeyArray[i], *startData);
+            CleanupStack::PopAndDestroy(2, &stream);            
+            
+            }
+        CleanupStack::PopAndDestroy(&externalizedBuffer);
+        }
+    else if (iKeyArray.Count() > newKeyArray.Count())
+        {
+        // Keys removed.
+        for(TInt i = 0; i<iKeyArray.Count(); ++i)
+            {
+            // Key present in iKeyArray (the previous array of keys) is no longer
+            // present in the newKeyArray.
+            if(newKeyArray.Find(iKeyArray[i]) == KErrNotFound)
+                {
+                CancelSubscribeL(iKeyArray[i]);
+                iKeyArray.Remove(i);
+                }
+            }
+        }   
+    CleanupStack::PopAndDestroy(&newKeyArray);
+    }
+
+void CSifOperationsNotifier::ActiveOperationsNotificationL()
+    {
+    // Notify the caller of any operation currently in progress.
+    GetKeysL(iKeyArray);
+    
+    RBuf8 externalizedBuffer;
+    
+    for(TInt i=0; i<iKeyArray.Count(); ++i)
+        {
+        externalizedBuffer.Close();
+        GetDataL(iKeyArray[i], iBufferSize, externalizedBuffer);
+        CleanupClosePushL(externalizedBuffer);
+        
+        RDesReadStream stream(externalizedBuffer);
+        CleanupClosePushL(stream);
+        
+        //Read the first 4 bytes
+        TSifOperation opType = static_cast<TSifOperation>(stream.ReadUint32L());
+        if(opType != ESifOperationStart)
+            {
+            // Ignore this key and continue.
+            CleanupStack::PopAndDestroy(2, &externalizedBuffer);
+            continue;
+            }
+        // Release the stream and reopen it.
+        stream.Release();
+        stream.Open(externalizedBuffer);
+        
+        CSifOperationStartData* startData = CSifOperationStartData::NewL(stream);
+        CleanupStack::PushL(startData);
+        iHandler.StartOperationHandler(iKeyArray[i], *startData); 
+        CleanupStack::PopAndDestroy(startData);  
+           
+        CleanupStack::PopAndDestroy(2, &externalizedBuffer);  
+        }
+    
+    }
+void CSifOperationsNotifier::WaitForChangeL()
+    {   
+    iProperty.Subscribe(iStatus);
+    SetActive();
+    }
+
+
+void CSifOperationsNotifier::GetKeysL(RArray<TUint>& aKeys)
+    {
+    TBuf8<KMaxNumberOfOperations * sizeof(TInt)> keysBuffer;
+    User::LeaveIfError(iProperty.Get(keysBuffer));
+    
+    RDesReadStream stream(keysBuffer);
+    CleanupClosePushL(stream);
+    
+    // Construct the CSifOperationKey object from the buffer.
+    CSifOperationKey* opKey = CSifOperationKey::NewL(stream);
+    CleanupStack::PushL(opKey);
+    
+    for(TInt i=0; i<opKey->StartEndKeys().Count(); ++i)
+        {
+        aKeys.AppendL(opKey->StartEndKeys()[i]);
+        }
+    
+    CleanupStack::PopAndDestroy(2, &stream);
+    }
+
+
+EXPORT_C void CSifOperationsNotifier::SubscribeL(TUint aKey, TBool aSubscribeForProgressNotifications)
+    {
+    User::LeaveIfError(iKeyArray.Find(aKey));
+    
+    // Start End notifier.
+    CSifNotifierBase* startEndNotifier = CSifNotifierBase::NewLC(iHandler, aKey, CSifNotifierBase::EStartEndNotifier);
+    iNotifierArray.AppendL(startEndNotifier);
+    CleanupStack::Pop(startEndNotifier);
+    
+    if(aSubscribeForProgressNotifications)
+        {
+        // Progress Notifier.
+        CSifNotifierBase* progressNotifier = CSifNotifierBase::NewLC(iHandler, aKey+1, CSifNotifierBase::EProgressNotifier);
+        iNotifierArray.AppendL(progressNotifier);
+        CleanupStack::Pop(progressNotifier);
+        }
+    }
+
+
+EXPORT_C void CSifOperationsNotifier::CancelSubscribeL(TUint aKey)
+    {
+    TInt index = iKeyArray.Find(aKey);
+    
+    if(index == KErrNotFound)
+        {
+        // No need to leave.
+        return;
+        }
+    
+    for(TInt i=0; i< iNotifierArray.Count(); ++i)
+        {
+
+        if(iNotifierArray[i]->Key() == aKey)
+            {
+            delete iNotifierArray[i];
+            iNotifierArray.Remove(i);
+            
+            // Delete progress notification object also, if present.
+            // i now points to the next element
+            if( i <= iNotifierArray.Count()-1 && iNotifierArray[i]->Key() == aKey+1)
+                {
+                delete iNotifierArray[i];
+                iNotifierArray.Remove(i);
+                }
+            }
+        
+        }
+
+    }
+
+
+EXPORT_C void CSifOperationsNotifier::CancelSubscribeL()
+    {
+    //Destroy all the notifiers.
+    Cancel();
+    }
+
+
+void CSifOperationsNotifier::DoCancel()
+    {
+    iProperty.Cancel();
+    iNotifierArray.ResetAndDestroy();
+    }
+
+TInt CSifOperationsNotifier::RunError(TInt aError)
+    {
+    DEBUG_PRINTF2(_L8("CSifOperationsNotifier::RunError : Error code %d"), aError);
+    // If RunL() leaves due to ActiveOperationsNotificationL(), change the state.
+    if(iNotifierState == EFirstStart)
+        {
+        iNotifierState = EWaitForChange;
+        }
+    (void)aError;
+    return KErrNone;
+    }
+
+
+CSifOperationsNotifier::~CSifOperationsNotifier()
+    {
+    Cancel();
+    iProperty.Close();
+    iKeyArray.Close();
+    }
+
+
+
+//////////////////////////
+// CSifNotifierBase
+//////////////////////////
+
+
+EXPORT_C CSifNotifierBase* CSifNotifierBase::NewL(MSifOperationsHandler& aHandler, TUint aKey, TNotifierType aType)
+    {
+    CSifNotifierBase* self = CSifNotifierBase::NewLC(aHandler, aKey, aType);
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+
+EXPORT_C CSifNotifierBase* CSifNotifierBase::NewLC(MSifOperationsHandler& aHandler, TUint aKey, TNotifierType aType)
+    {
+    CSifNotifierBase* self = new (ELeave) CSifNotifierBase(aHandler, aKey, aType);
+    CleanupStack::PushL(self);
+    self->ConstructL();
+    return self;
+    }
+
+CSifNotifierBase::CSifNotifierBase(MSifOperationsHandler& aHandler, TUint aKey, TNotifierType aType):
+    CActive(EPriorityNormal),
+    iHandler(aHandler),
+    iKey(aKey),
+    iBufferSize(KBufferSize),
+    iType(aType)
+    {
+    //Empty
+    }
+
+
+void CSifNotifierBase::ConstructL()
+    {
+    CActiveScheduler::Add(this);
+    iProperty.Attach(KUidSystemCategory,iKey,EOwnerThread);
+    // Subscribe to the key and wait for a notification.
+    WaitForChangeL();
+    }
+
+
+void CSifNotifierBase::RunL()
+    {
+    User::LeaveIfError(iStatus.Int());
+    
+    //Resubscribe for any changes.
+    WaitForChangeL();
+    
+    RBuf8 externalizedBuffer;
+    GetDataL(iKey, iBufferSize, externalizedBuffer);  
+    externalizedBuffer.CleanupClosePushL();
+    
+    RDesReadStream stream(externalizedBuffer);
+    CleanupClosePushL(stream);
+    
+    switch (iType)
+        {
+        case EStartEndNotifier:
+            {
+            //Read the first 4 bytes
+            TSifOperation opType = static_cast<TSifOperation>(stream.ReadInt32L());
+            stream.Release();
+            stream.Open(externalizedBuffer);
+            switch(opType)
+                {
+                case ESifOperationEnd:
+                    {
+                    CSifOperationEndData* endData = CSifOperationEndData::NewL(stream);
+                    CleanupStack::PushL(endData);
+                    iHandler.EndOperationHandler(*endData);
+                    CleanupStack::PopAndDestroy(endData);
+                    break;
+                    }
+                    
+                default:
+                    // Cannot receive a start notification here !
+                    User::Leave(KErrNotSupported);
+                    break; 
+                }            
+            }
+            
+         break;
+            
+        case EProgressNotifier:
+            {
+            CSifOperationProgressData* progressData = CSifOperationProgressData::NewL(stream);
+            CleanupStack::PushL(progressData);
+            iHandler.ProgressOperationHandler(*progressData);
+            CleanupStack::PopAndDestroy(progressData);
+            }
+        }
+
+    
+    CleanupStack::PopAndDestroy(2, &externalizedBuffer);
+    }
+
+
+
+void CSifNotifierBase::WaitForChangeL()
+    {
+    iProperty.Subscribe(iStatus);
+    SetActive();
+    }
+
+
+TInt CSifNotifierBase::RunError(TInt aError)
+    {
+    DEBUG_PRINTF2(_L8("CSifNotifierBase::RunError : Error code %d"), aError);
+    (void)aError;
+    return KErrNone;
+    }
+
+TUint CSifNotifierBase::Key()
+    {
+    return iKey;
+    }
+
+void CSifNotifierBase::DoCancel()
+    {
+    iProperty.Cancel();
+    }
+
+
+CSifNotifierBase::~CSifNotifierBase()
+    {
+    Cancel();
+    }
+
+
+
+/////////////////////
+// CSifOperationKey
+/////////////////////
+
+CSifOperationKey::CSifOperationKey()
+    {
+    // empty
+    }
+
+CSifOperationKey::~CSifOperationKey()
+    {
+    iStartEndKeyArray.Close();
+    }
+
+EXPORT_C CSifOperationKey* CSifOperationKey::NewL()
+    {
+    CSifOperationKey *self = CSifOperationKey::NewLC();
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+CSifOperationKey* CSifOperationKey::NewLC()
+    {
+    CSifOperationKey *self = new(ELeave) CSifOperationKey();
+    CleanupStack::PushL(self);
+    return self;
+    }
+
+CSifOperationKey* CSifOperationKey::NewL(RReadStream& aStream)
+    {
+    CSifOperationKey *self = new(ELeave) CSifOperationKey();
+    CleanupStack::PushL(self);
+    self->InternalizeL(aStream);
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+EXPORT_C void CSifOperationKey::ExternalizeL(RWriteStream& aStream) const
+    {
+    TInt count = iStartEndKeyArray.Count();
+    aStream.WriteUint32L(count);
+    for(TInt i=0 ; i< count; ++i)
+        {
+        aStream.WriteUint32L(iStartEndKeyArray[i]);
+        }
+    }
+    
+void CSifOperationKey::InternalizeL(RReadStream& aStream)
+    {
+    TInt count = aStream.ReadUint32L();
+    for(TInt i=0 ; i< count; ++i)
+        {
+        iStartEndKeyArray.AppendL(aStream.ReadUint32L());
+        }
+    }
+
+const RArray<TUint>& CSifOperationKey::StartEndKeys() const
+    {
+    return iStartEndKeyArray;
+    }
+
+void CSifOperationKey::AddKeyL(TUint aKey)
+    {
+    iStartEndKeyArray.AppendL(aKey);
+    }
+
+void CSifOperationKey::DeleteKey(TUint aPos)
+    {
+    iStartEndKeyArray.Remove(aPos);
+    }
+
+
+/////////////////////
+// CDeleteKeyTimer
+/////////////////////
+
+
+CDeleteKeyTimer::CDeleteKeyTimer() : CTimer(EPriorityLow)
+    {
+    CActiveScheduler::Add(this);
+    }
+
+CDeleteKeyTimer::~CDeleteKeyTimer()
+    {
+    Cancel();
+    }
+
+CDeleteKeyTimer* CDeleteKeyTimer::NewL(const TUint aKey)
+    {
+    CDeleteKeyTimer* self = new(ELeave) CDeleteKeyTimer();
+    CleanupStack::PushL(self);
+    self->ConstructL(aKey);
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+void CDeleteKeyTimer::ConstructL(const TUint aKey)
+    {
+    CTimer::ConstructL();
+    iKey = aKey;
+    }
+
+void CDeleteKeyTimer::Start()
+    {
+    After(KDeleteKeyDelay);
+    }
+
+void CDeleteKeyTimer::RunL()
+    {
+    // Publish(remove this key from existing info) the remaining keys in the global SIF key.
+    TBuf8<KMaxNumberOfOperations * sizeof(TInt)> buf;
+	RProperty oprnProperty;
+	CleanupClosePushL(oprnProperty);
+	
+	oprnProperty.Attach(KUidSystemCategory, KSifOperationKey);
+    TInt err = oprnProperty.Get(buf);
+    User::LeaveIfError(err);
+    
+    RDesReadStream readStream(buf);
+    CleanupClosePushL(readStream);
+    CSifOperationKey* opKey = CSifOperationKey::NewL(readStream);
+    CleanupStack::PushL(opKey);
+
+    //Find the position of the key 
+    TInt pos = opKey->StartEndKeys().Find(iKey);
+    
+    // Delete key, externalize the updated CSifOperationKey object and publish it.
+    opKey->DeleteKey(pos);
+    
+    RBuf8 operationKeyData;
+    operationKeyData.CleanupClosePushL();
+    ExternalizeRefObjectL(*opKey, operationKeyData);
+    
+    User::LeaveIfError(oprnProperty.Set(operationKeyData));
+    
+    // StartEnd Key.
+    RProperty::Delete(KUidSystemCategory, iKey);
+    // Progress Key.
+    RProperty::Delete(KUidSystemCategory, (iKey+1));
+    
+    CleanupStack::PopAndDestroy(4, &oprnProperty);
+    }
+
+
+TInt CDeleteKeyTimer::RunError(TInt aError)
+    {
+    DEBUG_PRINTF2(_L8("CDeleteKeyTimer::RunError : Error code %d"), aError);
+    (void)aError;
+    
+    // StartEnd Key.
+    RProperty::Delete(KUidSystemCategory, iKey);
+    // Progress Key.
+    RProperty::Delete(KUidSystemCategory, (iKey+1));
+    return KErrNone;
+    }
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/source/sifnotifierdata.cpp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,370 @@
+/*
+* 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 the License "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: 
+* This file implements the data classes provided by the SifNotifier library
+*
+*/
+
+#include <usif/sif/sifnotification.h> 
+#include <scs/cleanuputils.h>
+#include <scs/streamingarray.h>
+#include "sifnotification_internal.h"
+#include <usif/sif/sif.h>
+
+
+using namespace Usif;
+
+//////////////////////////
+// CSifOperationStartData
+//////////////////////////
+
+CSifOperationStartData::CSifOperationStartData()
+    {
+    // empty
+    }
+
+EXPORT_C CSifOperationStartData::~CSifOperationStartData()
+    {
+    delete iGlobalComponentId;                                    
+    delete iComponentName;
+    delete iComponentIcon;
+    iApplicationNames.ResetAndDestroy();
+    iApplicationIcons.ResetAndDestroy();          
+    delete iIconPath;      
+    delete iSoftwareType;
+    }
+
+
+EXPORT_C CSifOperationStartData* CSifOperationStartData::NewL(RReadStream& aStream)
+    {
+    CSifOperationStartData *self = new(ELeave) CSifOperationStartData();
+    CleanupStack::PushL(self);
+    self->InternalizeL(aStream);
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+EXPORT_C CSifOperationStartData* CSifOperationStartData::NewL(const TDesC& aGlobalComponentId, const TDesC& aComponentName,
+                                        const RPointerArray<HBufC>& aApplicationNames, const RPointerArray<HBufC>& aApplicationIcons, 
+                                        TInt aComponentSize, const TDesC& aIconPath, const TDesC& aComponentIcon, const TDesC& aSoftwareType)
+    {
+    CSifOperationStartData *self = CSifOperationStartData::NewLC(aGlobalComponentId, aComponentName, 
+                                        aApplicationNames, aApplicationIcons, aComponentSize, aIconPath, aComponentIcon,aSoftwareType);
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+EXPORT_C CSifOperationStartData* CSifOperationStartData::NewLC(const TDesC& aGlobalComponentId, const TDesC& aComponentName,
+										const RPointerArray<HBufC>& aApplicationNames, const RPointerArray<HBufC>& aApplicationIcons, const TInt aComponentSize, 
+                                        const TDesC& aIconPath, const TDesC& aComponentIcon, const TDesC& aSoftwareType)
+    {
+    CSifOperationStartData *self = new(ELeave) CSifOperationStartData();
+    CleanupStack::PushL(self);
+    self->ConstructL(aGlobalComponentId, aComponentName, aApplicationNames, aApplicationIcons, aComponentSize, aIconPath, aComponentIcon, aSoftwareType);
+    return self;
+    }
+
+void CSifOperationStartData::ConstructL(const TDesC& aGlobalComponentId, const TDesC& aComponentName, const RPointerArray<HBufC>& aApplicationNames,
+                                        const RPointerArray<HBufC>& aApplicationIcons, TInt aComponentSize, const TDesC& aIconPath, const TDesC& aComponentIcon, const TDesC& aSoftwareType)
+    {
+	iGlobalComponentId = aGlobalComponentId.AllocL();
+    iComponentName = aComponentName.AllocL();
+    iComponentIcon = aComponentIcon.AllocL();
+
+    for(TInt i=0; i<aApplicationNames.Count();++i)
+        {
+        HBufC* applicationName = aApplicationNames[i]->AllocLC();
+        iApplicationNames.AppendL(applicationName);
+        CleanupStack::Pop(applicationName);
+        }
+
+    for(TInt i=0; i<aApplicationIcons.Count();++i)
+        {
+        HBufC* applicationIcon = aApplicationIcons[i]->AllocLC();
+        iApplicationIcons.AppendL(applicationIcon);
+        CleanupStack::Pop(applicationIcon);
+        }
+    
+    iComponentSize = aComponentSize;
+    iIconPath = aIconPath.AllocL();      
+    iSoftwareType = aSoftwareType.AllocL();
+    }
+
+EXPORT_C void CSifOperationStartData::ExternalizeL(RWriteStream& aStream) const
+	{
+	aStream.WriteUint32L(ESifOperationStart);
+	aStream << *iGlobalComponentId;
+	aStream << *iComponentName;
+	ExternalizePointersArrayL(iApplicationNames, aStream);
+	ExternalizePointersArrayL(iApplicationIcons, aStream);
+	aStream.WriteUint16L(iComponentSize);
+	aStream << *iIconPath;
+	aStream << *iComponentIcon;
+	aStream << *iSoftwareType;
+	}
+	
+void CSifOperationStartData::InternalizeL(RReadStream& aStream)
+    {
+    iOperationType = static_cast<TSifOperation>(aStream.ReadUint32L());
+    DeleteObjectZ(iGlobalComponentId);
+    iGlobalComponentId = HBufC::NewL(aStream, KMaxTInt);
+    DeleteObjectZ(iComponentName);
+    iComponentName = HBufC::NewL(aStream, KMaxTInt);
+    iApplicationNames.ResetAndDestroy();
+    InternalizePointersArrayL(iApplicationNames, aStream);
+    iApplicationIcons.ResetAndDestroy();
+    InternalizePointersArrayL(iApplicationIcons, aStream);
+    iComponentSize = aStream.ReadUint16L();
+    DeleteObjectZ(iIconPath);
+    iIconPath = HBufC::NewL(aStream, KMaxTInt);
+    DeleteObjectZ(iComponentIcon);
+    iComponentIcon = HBufC::NewL(aStream, KMaxTInt);
+    DeleteObjectZ(iSoftwareType);
+    iSoftwareType = HBufC::NewL(aStream, KMaxTInt);
+    }
+
+EXPORT_C const HBufC& CSifOperationStartData::GlobalComponentId() const
+    {
+    return *iGlobalComponentId;
+    }
+
+EXPORT_C const HBufC& CSifOperationStartData::ComponentName() const
+    {
+    return *iComponentName;
+    }
+
+EXPORT_C const RPointerArray<HBufC>& CSifOperationStartData::ApplicationNames() const
+    {
+    return iApplicationNames;
+    }
+
+EXPORT_C const RPointerArray<HBufC>& CSifOperationStartData::ApplicationIcons() const
+    {
+    return iApplicationIcons;
+    }
+
+EXPORT_C const HBufC& CSifOperationStartData::IconPath() const
+    {
+    return *iIconPath;
+    }
+
+EXPORT_C const HBufC& CSifOperationStartData::ComponentIcon() const
+    {
+    return *iComponentIcon;
+    }
+
+EXPORT_C const HBufC& CSifOperationStartData::SoftwareType() const
+    {
+    return *iSoftwareType;
+    }
+
+
+EXPORT_C TInt CSifOperationStartData::ComponentSize() const
+    {
+    return iComponentSize;
+    }
+
+////////////////////////
+// CSifOperationEndData
+////////////////////////
+
+CSifOperationEndData::CSifOperationEndData()
+    {
+    // empty
+    }
+
+EXPORT_C CSifOperationEndData::~CSifOperationEndData()
+    {
+    delete iGlobalComponentId;
+    delete iErrMsg;                                    
+    delete iErrMsgDetails;
+    }
+
+
+EXPORT_C CSifOperationEndData* CSifOperationEndData::NewL(RReadStream& aStream)
+    {
+    CSifOperationEndData *self = new(ELeave) CSifOperationEndData();
+    CleanupStack::PushL(self);
+    self->InternalizeL(aStream);
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+EXPORT_C CSifOperationEndData* CSifOperationEndData::NewL(const TDesC& aGlobalComponentId, TErrorCategory aErrCategory, TInt aErrCode, const TDesC& aErrMsg, const TDesC& aErrMsgDetails)
+    {
+    CSifOperationEndData *self = CSifOperationEndData::NewLC(aGlobalComponentId, aErrCategory, aErrCode, aErrMsg, aErrMsgDetails);
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+EXPORT_C CSifOperationEndData* CSifOperationEndData::NewLC(const TDesC& aGlobalComponentId, TErrorCategory aErrCategory, TInt aErrCode, const TDesC& aErrMsg, const TDesC& aErrMsgDetails)
+    {
+    CSifOperationEndData *self = new(ELeave) CSifOperationEndData();
+    CleanupStack::PushL(self);
+    self->ConstructL(aGlobalComponentId, aErrCategory, aErrCode, aErrMsg, aErrMsgDetails);
+    return self;
+    }
+
+void CSifOperationEndData::ConstructL(const TDesC& aGlobalComponentId, TErrorCategory aErrCategory, TInt aErrCode, const TDesC& aErrMsg, const TDesC& aErrMsgDetails)
+    {
+	iGlobalComponentId = aGlobalComponentId.AllocL();      
+    iErrCategory = aErrCategory;
+    iErrCode = aErrCode;
+    iErrMsg = aErrMsg.AllocL();
+    iErrMsgDetails = aErrMsgDetails.AllocL();
+    }
+
+EXPORT_C void CSifOperationEndData::ExternalizeL(RWriteStream& aStream) const
+    {
+	aStream.WriteUint32L(ESifOperationEnd);
+    aStream << *iGlobalComponentId;
+    aStream << TCardinality(iErrCategory);
+    aStream.WriteUint16L(iErrCode);
+    aStream << *iErrMsg;
+    aStream << *iErrMsgDetails;
+    }
+    
+void CSifOperationEndData::InternalizeL(RReadStream& aStream)
+    {
+    iOperationType = static_cast<TSifOperation>(aStream.ReadUint32L());
+    iGlobalComponentId = HBufC::NewL(aStream, KMaxTInt);
+    TCardinality c;
+    aStream >> c;
+	iErrCategory = static_cast<TErrorCategory>(static_cast<TInt>(c));
+    iErrCode = aStream.ReadUint16L();
+    DeleteObjectZ(iErrMsg);
+    iErrMsg = HBufC::NewL(aStream, KMaxTInt);
+    DeleteObjectZ(iErrMsgDetails);
+    iErrMsgDetails = HBufC::NewL(aStream, KMaxTInt);
+    }
+
+EXPORT_C const HBufC& CSifOperationEndData::GlobalComponentId() const
+    {
+    return *iGlobalComponentId;
+    }
+
+EXPORT_C TErrorCategory CSifOperationEndData::ErrorCategory() const
+    {
+    return iErrCategory;
+    }
+
+EXPORT_C TInt CSifOperationEndData::ErrorCode() const
+    {
+    return iErrCode;
+    }
+
+EXPORT_C const HBufC& CSifOperationEndData::ErrorMessage() const
+    {
+    return *iErrMsg;
+    }
+
+EXPORT_C const HBufC& CSifOperationEndData::ErrorMessageDetails() const
+    {
+    return *iErrMsgDetails;
+    }
+
+/////////////////////////////
+// CSifOperationProgressData
+/////////////////////////////
+
+CSifOperationProgressData::CSifOperationProgressData()
+    {
+    // empty
+    }
+
+
+EXPORT_C CSifOperationProgressData* CSifOperationProgressData::NewL(RReadStream& aStream)
+    {
+    CSifOperationProgressData *self = new(ELeave) CSifOperationProgressData();
+    CleanupStack::PushL(self);
+    self->InternalizeL(aStream);
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+EXPORT_C CSifOperationProgressData* CSifOperationProgressData::NewL(const TDesC& aGlobalComponentId, TSifOperationPhase aPhase, TSifOperationSubPhase aSubPhase, TInt aCurrentProgress, TInt aTotal)
+    {
+    CSifOperationProgressData *self = CSifOperationProgressData::NewLC(aGlobalComponentId, aPhase, aSubPhase, aCurrentProgress, aTotal);
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+EXPORT_C CSifOperationProgressData* CSifOperationProgressData::NewLC(const TDesC& aGlobalComponentId, TSifOperationPhase aPhase, TSifOperationSubPhase aSubPhase, TInt aCurrentProgress, TInt aTotal)
+    {
+    CSifOperationProgressData *self = new(ELeave) CSifOperationProgressData();
+    CleanupStack::PushL(self);
+    self->ConstructL(aGlobalComponentId, aPhase, aSubPhase, aCurrentProgress, aTotal);
+    return self;
+    }
+
+void CSifOperationProgressData::ConstructL(const TDesC& aGlobalComponentId, TSifOperationPhase aPhase, TSifOperationSubPhase aSubPhase, TInt aCurrentProgress, TInt aTotal)
+    {
+    iGlobalComponentId = aGlobalComponentId.AllocL();      
+    iPhase = aPhase;
+    iSubPhase = aSubPhase;
+    iCurrentProgress = aCurrentProgress;
+    iTotal = aTotal;
+    }
+
+EXPORT_C void CSifOperationProgressData::ExternalizeL(RWriteStream& aStream) const
+    {
+    aStream << *iGlobalComponentId;
+    aStream << TCardinality(iPhase);
+    aStream << TCardinality(iSubPhase);
+    aStream.WriteUint16L(iCurrentProgress);
+    aStream.WriteUint16L(iTotal);
+    }
+    
+void CSifOperationProgressData::InternalizeL(RReadStream& aStream)
+    {
+    iGlobalComponentId = HBufC::NewL(aStream, KMaxTInt);
+    TCardinality c;
+    aStream >> c;
+    iPhase = static_cast<TSifOperationPhase>(static_cast<TInt>(c));
+    aStream >> c;
+    iSubPhase = static_cast<TSifOperationSubPhase>(static_cast<TInt>(c));
+    iCurrentProgress = aStream.ReadUint16L();
+    iTotal = aStream.ReadUint16L();
+    }
+
+EXPORT_C const HBufC& CSifOperationProgressData::GlobalComponentId() const
+    {
+    return *iGlobalComponentId;
+    }
+
+EXPORT_C TSifOperationPhase CSifOperationProgressData::Phase() const
+    {
+    return iPhase;
+    }
+
+EXPORT_C TSifOperationSubPhase CSifOperationProgressData::SubPhase() const
+    {
+    return iSubPhase;
+    }
+
+EXPORT_C TInt CSifOperationProgressData::CurrentProgess() const
+    {
+    return iCurrentProgress;
+    }
+
+EXPORT_C TInt CSifOperationProgressData::Total() const
+    {
+    return iTotal;
+    }
+
+
+EXPORT_C CSifOperationProgressData::~CSifOperationProgressData()
+    {
+    delete iGlobalComponentId;
+    }
--- a/installationservices/swinstallationfw/source/sifservertask.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/source/sifservertask.cpp	Fri May 14 15:58:48 2010 +0300
@@ -27,6 +27,7 @@
 #include "siftransportcommon.h"
 #include "usiflog.h"
 #include "sifutils.h"
+#include "e32property.h" 
 
 using namespace Usif;
 
@@ -34,7 +35,7 @@
 	{
 	CSifServerTask* self = new (ELeave) CSifServerTask(aTaskType, aParams);
 	CleanupStack::PushL(self);
-
+   
 	// Query AppArc about the (MIME) type of the package to be processed and instantiate an appropriate SIF plug-in
 	self->SelectAndLoadPluginL();
 
@@ -50,7 +51,7 @@
 CSifServerTask::~CSifServerTask()
 	{
 	DEBUG_PRINTF2(_L8("CSifServerTask::~CSifServerTask() for aFunction = %d\n"),iTaskType);
-
+	                
 	// Clean up the plugin
 	delete iPlugin;
 	iPlugin = NULL;
--- a/installationservices/swinstallationfw/source/siftransportserver.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/source/siftransportserver.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2008 - 2010 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 "Eclipse Public License v1.0"
@@ -20,6 +20,8 @@
 #include "siftransportserver.h"
 #include "siftransportcommon.h"
 #include <e32property.h>
+#include "sifnotification_internal.h"
+#include "scrclient.inl"
 
 using namespace Usif;
 
@@ -53,8 +55,26 @@
 	starts the server.
  */
 	{
-	CScsServer::ConstructL(aShutdownPeriodUs);
+	// Define a key (KSifOperationKey) which would be used to notify the client of any new operations.
+    TInt ret = RProperty::Define(KUidSystemCategory, KSifOperationKey, RProperty::EByteArray, KSecurityPolicyWDD, KSecurityPolicyNone,(sizeof(TInt) * KMaxNumberOfOperations));
+    if (ret != KErrAlreadyExists && ret != KErrNone)
+        {
+        User::Leave(ret);
+        }
 
+    if(ret == KErrNone)
+        {
+        // Create a empty CSifOperationKey object and publish it.
+        CSifOperationKey* nullKey = CSifOperationKey::NewL();
+        CleanupStack::PushL(nullKey);
+        RBuf8 nullKeyBuffer;
+        nullKeyBuffer.CleanupClosePushL();
+        ExternalizeRefObjectL(*nullKey, nullKeyBuffer);
+        User::LeaveIfError(RProperty::Set(KUidSystemCategory, KSifOperationKey, nullKeyBuffer));
+		CleanupStack::PopAndDestroy(2, nullKey);
+        }
+    
+    CScsServer::ConstructL(aShutdownPeriodUs);
 	StartL(aServerName);
 	}
 
@@ -64,6 +84,7 @@
 	Cleanup the server, in particular close the RFs session.
  */
 	{
+	RProperty::Delete(Usif::KSifOperationKey);
 	}
 
 CScsSession* CSifTransportServer::DoNewSessionL(const RMessage2& /*aMessage*/)
--- a/installationservices/swinstallationfw/test/group/cleansiflauncher.bat	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/test/group/cleansiflauncher.bat	Fri May 14 15:58:48 2010 +0300
@@ -19,4 +19,12 @@
 set PLATFORM=%1
 set CFG=%2
 
-del /f /q %EPOCROOT%epoc32\release\%PLATFORM%\%CFG%\siflauncher.exe
\ No newline at end of file
+del /f /q %EPOCROOT%epoc32\release\%PLATFORM%\%CFG%\siflauncher.exe
+
+del /f /q %EPOCROOT%epoc32\release\%PLATFORM%\%CFG%\z\resource\apps\siflauncher.mbm
+del /f /q %EPOCROOT%epoc32\release\%PLATFORM%\%CFG%\z\resource\apps\siflauncher_loc.rsc
+del /f /q %EPOCROOT%epoc32\release\%PLATFORM%\%CFG%\z\private\10003a3f\apps\siflauncher_reg.rsc
+
+del /f /q %EPOCROOT%epoc32\data\z\resource\apps\siflauncher.mbm
+del /f /q %EPOCROOT%epoc32\data\z\resource\apps\siflauncher_loc.rsc
+del /f /q %EPOCROOT%epoc32\data\z\private\10003a3f\apps\siflauncher_reg.rsc
--- a/installationservices/swinstallationfw/test/group/tsiflauncher.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/test/group/tsiflauncher.mmp	Fri May 14 15:58:48 2010 +0300
@@ -23,7 +23,8 @@
 TARGETTYPE			exe
 TARGETPATH			/sys/bin
 
-CAPABILITY			TrustedUI
+// We need WriteDeviceData so that the installer data types can have priority EDataTypePrioritySystem
+CAPABILITY			TrustedUI WriteDeviceData
 
 VENDORID			0x70000001
 
--- a/installationservices/swinstallationfw/test/plugins/nonnativeplugin/group/testnonnativeplugin.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/test/plugins/nonnativeplugin/group/testnonnativeplugin.mmp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2008-2010 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 "Eclipse Public License v1.0"
@@ -27,7 +27,7 @@
 
 UID 0x10009D8D 0x10285BD1
 
-CAPABILITY			ProtServ TrustedUI ReadUserData
+CAPABILITY			ProtServ TrustedUI ReadUserData WriteDeviceData
 
 SOURCEPATH			../source
 SOURCE				testnonnativeplugin.cpp
--- a/installationservices/swinstallationfw/test/plugins/nonnativeplugin/group/testnonnativeplugin2.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/test/plugins/nonnativeplugin/group/testnonnativeplugin2.mmp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2008-2010 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 "Eclipse Public License v1.0"
@@ -31,7 +31,7 @@
 
 VENDORID	0x70000001
 
-CAPABILITY			ProtServ TrustedUI ReadUserData
+CAPABILITY			ProtServ TrustedUI ReadUserData WriteDeviceData
 
 SOURCEPATH			../source
 SOURCE				testnonnativeplugin.cpp
--- a/installationservices/swinstallationfw/test/siflauncherconfig/siflauncher_reg.rss	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/test/siflauncherconfig/siflauncher_reg.rss	Fri May 14 15:58:48 2010 +0300
@@ -33,7 +33,7 @@
 	newfile=KAppDoesNotSupportNewFile;
 	datatype_list=
 		{
-		DATATYPE { priority=EDataTypePriorityHigh; type="x-epoc/x-sisx-app"; },
-		DATATYPE { priority=EDataTypePriorityHigh; type="binary/sif-refpkg"; }
+		DATATYPE { priority=EDataTypePrioritySystem; type="x-epoc/x-sisx-app"; },
+		DATATYPE { priority=EDataTypePrioritySystem; type="binary/sif-refpkg"; }
 		};
 	}
--- a/installationservices/swinstallationfw/test/tusif/group/createleesisfiles.pl	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/test/tusif/group/createleesisfiles.pl	Fri May 14 15:58:48 2010 +0300
@@ -52,7 +52,16 @@
 my $SIFGETCOMAPPARCINFOTESTEMBEDDED = 'sifgetcompapparcinfotestembedded_innerwithdifficon';
 my $SIFGETCOMAPPARCINFOTESTNOLOCALE = 'sifgetcompapparcinfotest_nolocale';
 my $SIFGETCOMAPPARCINFOTESTLARGEANDSMALLEXTN = 'sifgetcompapparcinfotestmultifiles_largeandsmallextn';
-
+my $SWIAPPREGINTEGRATION_CASE05 = 'swiappregintegration_case05';
+my $SWIAPPREGINTEGRATION_CASE05_SU = 'swiappregintegration_case05_SU';
+my $SWIAPPREGINTEGRATION_CASE06_BASE = 'swiappregintegration_case06_base';
+my $SWIAPPREGINTEGRATION_CASE06_SP3 = 'swiappregintegration_case06_sp3';
+my $SWIAPPREGINTEGRATION_CASE06_SP2 = 'swiappregintegration_case06_sp2';
+my $SWIAPPREGINTEGRATION_CASE06_PU = 'swiappregintegration_case06_pu';
+my $SWIAPPREGINTEGRATION_CASE06_SP1 = 'swiappregintegration_case06_sp1';
+my $SWIAPPREGINTEGRATION_CASE06_SA = 'swiappregintegration_case06_sa';
+my $SWIAPPREGINTEGRATION_CASE08_SA1 = 'swiappregintegration_case08_sa1';
+my $SWIAPPREGINTEGRATION_CASE08_SA2 = 'swiappregintegration_case08_sa2';
 my $suffix = '_edited';
 
 # Replace <BUILDMIDPATH> and <ZDRIVEMIDPATH> in the PKG files with the current values
@@ -75,6 +84,17 @@
 EditFile("$PKGDIR\\$SIFGETCOMAPPARCINFOTESTEMBEDDED.pkg", "$PKGDIR\\$SIFGETCOMAPPARCINFOTESTEMBEDDED$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
 EditFile("$PKGDIR\\$SIFGETCOMAPPARCINFOTESTNOLOCALE.pkg", "$PKGDIR\\$SIFGETCOMAPPARCINFOTESTNOLOCALE$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
 EditFile("$PKGDIR\\$SIFGETCOMAPPARCINFOTESTLARGEANDSMALLEXTN.pkg", "$PKGDIR\\$SIFGETCOMAPPARCINFOTESTLARGEANDSMALLEXTN$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
+EditFile("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE05.pkg", "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE05$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
+EditFile("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE05_SU.pkg", "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE05_SU$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
+EditFile("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_BASE.pkg", "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_BASE$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
+EditFile("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP3.pkg", "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP3$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
+EditFile("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP2.pkg", "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP2$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
+EditFile("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_PU.pkg", "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_PU$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
+EditFile("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP1.pkg", "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP1$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
+EditFile("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SA.pkg", "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SA$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
+EditFile("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA1.pkg", "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA1$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
+EditFile("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA2.pkg", "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA2$suffix.pkg" , sub { s/<BUILDMIDPATH>/$BUILDMIDPATH/gm; s/<ZDRIVEMIDPATH>/$ZDRIVEMIDPATH/gm; });
+
 
 my $dir = getcwd;
 chdir $PKGDIR;
@@ -93,6 +113,16 @@
 `$CREATESISCMD $PKGDIR\\$SIFGETCOMAPPARCINFOTESTCORRUPTRSC$suffix.pkg`;
 `$CREATESISCMD $PKGDIR\\$SIFGETCOMAPPARCINFOTESTNOLOCALE$suffix.pkg`;
 `$CREATESISCMD $PKGDIR\\$SIFGETCOMAPPARCINFOTESTLARGEANDSMALLEXTN$suffix.pkg`;
+`$CREATESISCMD $PKGDIR\\$SWIAPPREGINTEGRATION_CASE05$suffix.pkg`;
+`$CREATESISCMD $PKGDIR\\$SWIAPPREGINTEGRATION_CASE05_SU$suffix.pkg`;
+`$CREATESISCMD $PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_BASE$suffix.pkg`;
+`$CREATESISCMD $PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP3$suffix.pkg`;
+`$CREATESISCMD $PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP2$suffix.pkg`;
+`$CREATESISCMD $PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_PU$suffix.pkg`;
+`$CREATESISCMD $PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP1$suffix.pkg`;
+`$CREATESISCMD $PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SA$suffix.pkg`;
+`$CREATESISCMD $PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA1$suffix.pkg`;
+`$CREATESISCMD $PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA2$suffix.pkg`;
 
 # Copy generated SIS files onto the Z drive
 if (lc($PLATFORM) ne "armv5")
@@ -121,7 +151,27 @@
 	move("$PKGDIR\\$SIFGETCOMAPPARCINFOTESTNOLOCALE$suffix.sis", "$DATADIR_TSIF\\$SIFGETCOMAPPARCINFOTESTNOLOCALE.sis");	
 	unlink "$DATADIR_TSIF\\$SIFGETCOMAPPARCINFOTESTLARGEANDSMALLEXTN.sis";
 	move("$PKGDIR\\$SIFGETCOMAPPARCINFOTESTLARGEANDSMALLEXTN$suffix.sis", "$DATADIR_TSIF\\$SIFGETCOMAPPARCINFOTESTLARGEANDSMALLEXTN.sis");
-	
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE05.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE05$suffix.sis", "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE05.sis");	
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE05_SU.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE05_SU$suffix.sis", "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE05_SU.sis");	
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_BASE.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_BASE$suffix.sis", "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_BASE.sis");	
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP3.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP3$suffix.sis", "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP3.sis");	
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP2.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP2$suffix.sis", "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP2.sis");	
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_PU.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_PU$suffix.sis", "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_PU.sis");	
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP1.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP1$suffix.sis", "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP1.sis");	
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SA.sis";	
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SA$suffix.sis", "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SA.sis");	
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE08_SA1.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA1$suffix.sis", "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE08_SA1.sis");	
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE08_SA2.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA2$suffix.sis", "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE08_SA2.sis");		
+
 	`$CREATESISCMD $PKGDIR\\$SIFGETCOMAPPARCINFOTESTEMBEDDED$suffix.pkg`;
 	unlink "$DATADIR_TSIF\\$SIFGETCOMAPPARCINFOTESTEMBEDDED.sis";
 	move("$PKGDIR\\$SIFGETCOMAPPARCINFOTESTEMBEDDED$suffix.sis", "$DATADIR_TSIF\\$SIFGETCOMAPPARCINFOTESTEMBEDDED.sis");	
@@ -154,6 +204,26 @@
 	move("$PKGDIR\\$SIFGETCOMAPPARCINFOTESTNOLOCAL$suffix.sis", "$ARMV5DATADIR_TSIF\\$SIFGETCOMAPPARCINFOTESTNOLOCAL.sis");	
 	unlink "$DATADIR_TSIF\\$SIFGETCOMAPPARCINFOTESTLARGEANDSMALLEXTN.sis";
 	move("$PKGDIR\\$SIFGETCOMAPPARCINFOTESTLARGEANDSMALLEXTN$suffix.sis", "$ARMV5DATADIR_TSIF\\$SIFGETCOMAPPARCINFOTESTLARGEANDSMALLEXTN.sis");
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE05.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE05$suffix.sis", "$ARMV5DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE05.sis");
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE05_SU.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE05_SU$suffix.sis", "$ARMV5DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE05_SU.sis");
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_BASE.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_BASE$suffix.sis", "$ARMV5DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_BASE.sis");
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP3.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP3$suffix.sis", "$ARMV5DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP3.sis");
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP2.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP2$suffix.sis", "$ARMV5DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP2.sis");
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_PU.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_PU$suffix.sis", "$ARMV5DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_PU.sis");
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP1.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP1$suffix.sis", "$ARMV5DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SP1.sis");
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SA.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SA$suffix.sis", "$ARMV5DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE06_SA.sis");
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE08_SA1.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA1$suffix.sis", "$ARMV5DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE08_SA1.sis");
+	unlink "$DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE08_SA2.sis";
+	move("$PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA2$suffix.sis", "$ARMV5DATADIR_TSIF\\$SWIAPPREGINTEGRATION_CASE08_SA2.sis");
 				
 	`$CREATESISCMD $PKGDIR\\$SIFGETCOMAPPARCINFOTESTEMBEDDED$suffix.pkg`;
 	unlink "$DATADIR_TSIF\\$SIFGETCOMAPPARCINFOTESTEMBEDDED.sis";
@@ -176,6 +246,16 @@
 unlink "$PKGDIR\\$SIFGETCOMAPPARCINFOTESTNOLOCALE$suffix.pkg";
 unlink "$PKGDIR\\$SIFGETCOMAPPARCINFOTESTEMBEDDED$suffix.pkg";
 unlink "$PKGDIR\\$SIFGETCOMAPPARCINFOTESTLARGEANDSMALLEXTN$suffix.pkg";
+unlink "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE05$suffix.pkg";
+unlink "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE05_SU$suffix.pkg";
+unlink "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_BASE$suffix.pkg";
+unlink "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP3$suffix.pkg";
+unlink "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP2$suffix.pkg";
+unlink "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_PU$suffix.pkg";
+unlink "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SP1$suffix.pkg";
+unlink "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE06_SA$suffix.pkg";
+unlink "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA1$suffix.pkg";
+unlink "$PKGDIR\\$SWIAPPREGINTEGRATION_CASE08_SA2$suffix.pkg";
 
 chdir $dir;
 
--- a/installationservices/swinstallationfw/test/tusif/group/tsif.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/test/tusif/group/tsif.mmp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2008-2010 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 "Eclipse Public License v1.0"
@@ -20,7 +20,7 @@
 TARGETTYPE		exe
 UID				0x1000007A 0x10285BCC
 
-CAPABILITY		ReadUserData TrustedUI
+CAPABILITY		ReadUserData TrustedUI writeDeviceData
 
 //Please add any change under here
 SOURCEPATH		../source
@@ -30,6 +30,7 @@
 SOURCE			tsifcommonverificationstep.cpp
 SOURCE			tsifgenericbrowserinstallstep.cpp
 SOURCE			tsifcommonunitteststep.cpp
+SOURCE			tsifnotifierteststep.cpp
 
 USERINCLUDE		../source
 USERINCLUDE		../../../../swcomponentregistry/inc_private
@@ -44,7 +45,7 @@
 LIBRARY			scsclient.lib
 
 //Please add your libraries under here. For example:
-LIBRARY			sif.lib estor.lib apgrfx.lib apparc.lib
+LIBRARY			sif.lib estor.lib apgrfx.lib apparc.lib sifnotification.lib
 
 LIBRARY			scrclient.lib sisregistryclient.lib scrdatabase.lib oomtestbase.lib
 SMPSAFE
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case05.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,34 @@
+;
+; 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 the License "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:
+; Base package containing complete resource files for English and French
+;
+
+;Languages
+&EN, FR
+
+#{"swiappregintegration_case5A_EN","swiappregintegration_case5A_FR"},(0x80010009),1,1,1
+
+;Localised Vendor name
+%{"Vendor_EN","Vendor_FR"}
+
+;Unique Vendor name
+:"Vendor"
+
+"\epoc32\<BUILDMIDPATH>\swiappregintegration_case05.exe" - "!:\sys\bin\swiappregintegration_case05.exe"
+
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_reg.rsc" - "!:\private\10003a3f\import\apps\swiappregintegration_case05_reg.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_loc.rsc" - "!:\resource\apps\swiappregintegration_case05_loc.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration01\swiappregintegration.mbm"  -"!:\resource\apps\swiappregintegration.mbm"
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case05_SU.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,32 @@
+;
+; 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 the License "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:
+; Base package containing complete resource files for English and French
+;
+
+;Languages
+&EN, FR
+
+#{"swiappregintegration_case5B_EN","swiappregintegration_case5B_FR"},(0x80010009),1,1,1,TYPE=SA
+
+;Localised Vendor name
+%{"Vendor_EN","Vendor_FR"}
+
+;Unique Vendor name
+:"Vendor"
+"\epoc32\<BUILDMIDPATH>\swiappregintegration_case05.exe" - "!:\sys\bin\swiappregintegration_case05.exe"
+
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_su_reg.rsc" - "!:\private\10003a3f\import\apps\swiappregintegration_case05_reg.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_loc.rsc" - "!:\resource\apps\swiappregintegration_case05_loc.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration01\swiappregintegration.mbm"  -"!:\resource\apps\swiappregintegration.mbm"
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_base.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,37 @@
+;
+; 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 the License "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:
+; 
+;
+
+;Languages
+&EN
+
+#{"swiappregintegration_case6_EN"},(0x80010099),1,1,1
+
+;Localised Vendor name
+%{"Vendor_EN"}
+
+;Unique Vendor name
+:"Vendor"
+
+
+
+
+"\epoc32\<BUILDMIDPATH>\swiappregintegration_case05.exe" - "!:\sys\bin\swiappregintegration_case05.exe"
+
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_reg.rsc" - "!:\private\10003a3f\import\apps\swiappregintegration_case05_reg.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_loc.rsc" - "!:\resource\apps\swiappregintegration_case05_loc.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration01\swiappregintegration.mbm"  -"!:\resource\apps\swiappregintegration.mbm"
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_pu.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,36 @@
+;
+; 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 the License "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:
+; 
+;
+
+;Languages
+&GE
+
+#{"swiappregintegration_case6_GR_PU"},(0x80010099),1,1,1, TYPE=PU
+
+;Localised Vendor name
+%{"Vendor_GR"}
+
+;Unique Vendor name
+:"Vendor"
+
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_loc.r03" - "!:\resource\apps\swiappregintegration_case05_loc.r03"
+
+"\epoc32\<BUILDMIDPATH>\swiappregintegration03.exe" - "!:\sys\bin\swiappregintegration03.exe"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration03\swiappregintegration03_reg.rsc" - "!:\private\10003a3f\import\apps\swiappregintegration03_reg.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration03\swiappregintegration03_loc.rsc" -"!:\resource\apps\swiappregintegration03_loc.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration01\swiappregintegration.mbm"  -"!:\resource\apps\swiappregintegration03_rsc.mbm"
+
+@"swiappregintegration_case06_sp2_edited.sis", (0x80010099)
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_sa.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,32 @@
+;
+; 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 the License "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:
+; 
+;
+
+;Languages
+&EN
+
+#{"swiappregintegration_case6_EN_SA"},(0x80010099),1,1,1, TYPE=SA
+
+;Localised Vendor name
+%{"Vendor_EN"}
+
+;Unique Vendor name
+:"Vendor"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_reg.rsc" - "!:\private\10003a3f\import\apps\swiappregintegration_case05_reg.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_loc.r01" - "!:\resource\apps\swiappregintegration_case05_loc.r01"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration01\swiappregintegration.mbm"  -"!:\resource\apps\swiappregintegration.mbm"
+
+@"swiappregintegration_case06_sp1_edited.sis", (0x80010099)
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_sp1.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,36 @@
+;
+; 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 the License "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:
+; 
+;
+
+;Languages
+&FR
+
+#{"swiappregintegration_case6_FR_SP1"},(0x80010099),1,1,1, TYPE=SP
+
+;Localised Vendor name
+%{"Vendor_FR"}
+
+;Unique Vendor name
+:"Vendor"
+
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_loc.r02" - "!:\resource\apps\swiappregintegration_case05_loc.r02"
+
+"\epoc32\<BUILDMIDPATH>\swiappregintegration02.exe" - "!:\sys\bin\swiappregintegration02.exe"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration02\swiappregintegration02_reg.rsc" - "!:\private\10003a3f\import\apps\swiappregintegration02_reg.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration02\swiappregintegration02_loc.rsc" -"!:\resource\apps\swiappregintegration02_loc.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration01\swiappregintegration.mbm"  -"!:\resource\apps\swiappregintegration02_rsc.mbm"
+
+@"swiappregintegration_case06_pu_edited.sis", (0x80010099)
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_sp2.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,33 @@
+;
+; 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 the License "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:
+; 
+;
+
+;Languages
+&EN
+
+#{"swiappregintegration_case6_EN_SP2"},(0x80010099),1,1,1, TYPE=SP
+
+;Localised Vendor name
+%{"Vendor_EN"}
+
+;Unique Vendor name
+:"Vendor"
+"\epoc32\<BUILDMIDPATH>\swiappregintegration_case06.exe" - "!:\sys\bin\swiappregintegration_case06.exe"
+
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case06\swiappregintegration_case06_reg.rsc" - "!:\private\10003a3f\import\apps\swiappregintegration_case06_reg.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case06\swiappregintegration_case06_loc.rsc" - "!:\resource\apps\swiappregintegration_case06_loc.rsc"
+
+@"swiappregintegration_case06_sp3_edited.sis", (0x80010099)
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case06_sp3.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,34 @@
+;
+; 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 the License "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:
+; 
+;
+
+;Languages
+&FR
+
+#{"swiappregintegration_case6_FR_SP3"},(0x80010099),1,1,1,TYPE=SP
+
+;Localised Vendor name
+%{"Vendor_FR"}
+
+;Unique Vendor name
+:"Vendor"
+
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_loc.r04" - "!:\resource\apps\swiappregintegration_case05_loc.r04"
+
+"\epoc32\<BUILDMIDPATH>\swiappregintegration_case07.exe" - "!:\sys\bin\swiappregintegration_case07.exe"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case07\swiappregintegration_case07_reg.rsc" - "!:\private\10003a3f\import\apps\swiappregintegration_case07_reg.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case07\swiappregintegration_case07_loc.rsc" - "!:\resource\apps\swiappregintegration_case07_loc.rsc"
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case08_sa1.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,27 @@
+;
+; 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 the License "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:
+; 
+;
+
+;Languages
+&EN
+
+#{"swiappregintegration_case8_EN_SA1"},(0x80010099),1,1,1, TYPE=SA
+
+;Localised Vendor name
+%{"Vendor_EN"}
+
+;Unique Vendor name
+:"Vendor"
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/data/swiappregintegration_case08_sa2.pkg	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,31 @@
+;
+; 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 the License "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:
+; 
+;
+
+;Languages
+&EN
+
+#{"swiappregintegration_case8_EN_SA2"},(0x80010099),1,1,1, TYPE=SA
+
+;Localised Vendor name
+%{"Vendor_EN"}
+
+;Unique Vendor name
+:"Vendor"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_reg.rsc" - "!:\private\10003a3f\import\apps\swiappregintegration_case05_reg.rsc"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration_case05\swiappregintegration_case05_loc.r01" - "!:\resource\apps\swiappregintegration_case05_loc.r01"
+"\epoc32\<ZDRIVEMIDPATH>\z\tswi\tuiscriptadaptors\data\swiappregintegration01\swiappregintegration.mbm"  -"!:\resource\apps\swiappregintegration.mbm"
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/tnotifier.ini	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,305 @@
+[Key1]
+SubscriberNumber=1
+StartCount=0
+ProgressCount=0
+EndCount=0
+
+
+
+[Key3]
+delay = 1
+SubscriberNumber=2
+KeyNumber1 = 537062757
+SubscribeKey1 = 537062757
+SubscribeForProgress1= ETrue
+GlobalCompId1=abc
+ProgressData1=abc
+ProgressData2=abc
+EndData1=abc
+StartCount=1
+ProgressCount=2
+EndCount=1
+
+
+[Key4]
+delay = 1
+SubscriberNumber=1
+KeyNumber1 = 537062757
+SubscribeKey1 = 537062757
+SubscribeForProgress1= EFalse
+GlobalCompId1=abc
+EndData1=abc
+StartCount=1
+ProgressCount=0
+EndCount=1
+
+
+
+[Key5]
+delay = 1
+SubscriberNumber=1
+KeyNumber1 = 537062757
+SubscribeKey1 = 537062757
+SubscribeForProgress1= ETrue
+GlobalCompId1=abc
+ProgressData1=abc
+ProgressData2=abc
+EndData1=abc
+StartCount=1
+ProgressCount=2
+EndCount=1
+
+
+
+[publish_one]
+OperationCount=7
+configsection0=startabc
+configsection1=delaystep
+configsection2=progressabc1
+configsection3=delaystep
+configsection4=progressabc2
+configsection5=delaystep
+configsection6=endabc
+
+[delaystep]
+Operation=delay
+PublisherDelay=1
+
+[publish_one_large]
+OperationCount=7
+configsection0=startabclarge
+configsection1=delaystep
+configsection2=progressabc1
+configsection3=delaystep
+configsection4=progressabc2
+configsection5=delaystep
+configsection6=endabc
+
+[startabc]
+Operation=start
+GlobalCompId=abc
+ComponentName=compName
+ComponentIcon=iconName
+AppNameCount=2
+AppName0=firstApp
+AppName1=secondApp
+AppIconCount=2
+AppIcon0=firstAppIcon
+AppIcon1=secondAppIcon
+ComponentSize=40
+IconPath=iconPath
+SoftwareType=Native
+
+
+[startabclarge]
+Operation=start
+GlobalCompId=abc
+ComponentName=ThisIsaVeryLargeComponentName
+ComponentIcon=ThisIsaVeryLargeComponentIcon
+AppNameCount=2
+AppName0=LargeNameforthefirstApp
+AppName1=LargeNameforthesecondApp
+AppIconCount=2
+AppIcon0=LargeNameforthefirstAppIcon
+AppIcon1=LargeNameforthesecondAppIcon
+ComponentSize=40
+IconPath=LargePathfortheicon
+SoftwareType=Native
+
+[progressabc1]
+Operation=progress
+GlobalCompId=abc
+Phase=1
+SubPhase=1
+CurrentProgress=1
+Total=10
+
+[progressabc2]
+Operation=progress
+GlobalCompId=abc
+Phase=1
+SubPhase=1
+CurrentProgress=9
+Total=10
+
+[endabc]
+Operation=end
+GlobalCompId=abc
+ErrMsg=errMsg
+ErrMsgDetails=errMsgDetails
+ErrCategory=0
+ErrCode=0
+
+[Key6]
+SubscriberNumber=1
+KeyNumber1 = 537062757
+KeyNumber2 = 537062759
+SubscribeKey1 = 537062757
+SubscribeForProgress1= ETrue
+SubscribeKey2 = 537062759
+SubscribeForProgress2= ETrue
+GlobalCompId1=abc
+GlobalCompId2=xyz
+ProgressData1=abc
+ProgressData2=abc
+ProgressData3=xyz
+EndData1=xyz
+EndData2=abc
+StartCount=2
+ProgressCount=3
+EndCount=2
+SubscribeShutdownTimer=18
+
+[Key7]
+SubscriberNumber=1
+KeyNumber1 = 537062757
+KeyNumber2 = 537062757
+SubscribeKey1 = 537062757
+SubscribeForProgress1= ETrue
+SubscribeKey2 = 537062757
+SubscribeForProgress2= ETrue
+GlobalCompId1=abc
+GlobalCompId2=xyz
+ProgressData1=abc
+ProgressData2=abc
+ProgressData3=xyz
+EndData1=abc
+EndData2=xyz
+StartCount=2
+ProgressCount=3
+EndCount=2
+SubscribeShutdownTimer=15
+
+[publish_twoconcurrentinstall]
+delay =1
+OperationCount=13
+configsection0=startabc
+configsection1=delaystep
+configsection2=progressabc1
+configsection3=delaystep
+configsection4=startxyz
+configsection5=delaystep
+configsection6=progressabc2
+configsection7=delaystep
+configsection8=progressxyz1
+configsection9=delaystep
+configsection10=endxyz
+configsection11=delaystep
+configsection12=endabc
+
+
+[publish_twoconsecutiveinstall]
+delay =1
+OperationCount=13
+configsection0=startabc
+configsection1=delaystep
+configsection2=progressabc1
+configsection3=delaystep
+configsection4=progressabc2
+configsection5=delaystep
+configsection6=endabc
+configsection7=delaystep
+configsection8=startxyz
+configsection9=delaystep
+configsection10=progressxyz1
+configsection11=delaystep
+configsection12=endxyz
+
+[startxyz]
+Operation=start
+GlobalCompId=xyz
+ComponentName=xyzcompName
+ComponentIcon=xyziconName
+AppNameCount=2
+AppName0=firstxyzApp
+AppName1=secondxyzApp
+AppIconCount=2
+AppIcon0=firstxyzAppIcon
+AppIcon1=secondxyzAppIcon
+ComponentSize=40
+IconPath=xyziconPath
+SoftwareType=NonNative
+
+[progressxyz1]
+Operation=progress
+GlobalCompId=xyz
+Phase=1
+SubPhase=1
+CurrentProgress=3
+Total=5
+
+[endxyz]
+Operation=end
+GlobalCompId=xyz
+ErrMsg=xyzerrMsg
+ErrMsgDetails=xyzerrMsgDetails
+ErrCategory=2
+ErrCode=0
+
+
+[Key8]
+SubscriberNumber=1
+KeyNumber1 = 537062757
+KeyNumber2 = 537062757
+SubscribeKey1 = 537062757
+SubscribeForProgress1= ETrue
+SubscribeKey2 = 537062757
+SubscribeForProgress2= EFalse
+GlobalCompId1=abc
+GlobalCompId2=xyz
+ProgressData1=abc
+ProgressData2=abc
+EndData1=abc
+EndData2=xyz
+StartCount=2
+ProgressCount=2
+EndCount=2
+SubscribeShutdownTimer=15
+
+
+
+
+[Key9]
+delay=2
+SubscriberNumber=2
+KeyNumber1 = 537062757
+KeyNumber2 = 537062757
+SubscribeKey1 = 537062757
+SubscribeForProgress1= ETrue
+SubscribeKey2 = 537062757
+SubscribeForProgress2= ETrue
+GlobalCompId1=abc
+GlobalCompId2=xyz
+ProgressData1=abc
+ProgressData2=abc
+ProgressData3=xyz
+EndData1=abc
+EndData2=xyz
+StartCount=2
+ProgressCount=3
+EndCount=2
+SubscribeShutdownTimer=15
+
+
+[publish_details]
+OperationCount=5
+configsection0=startabc
+configsection1=delaystep
+configsection2=progressabc1
+configsection3=delaystep
+configsection4=endabc
+
+[Key10]
+delay = 1
+SubscriberNumber=1
+KeyNumber1 = 537062757
+SubscribeKey1 = 537062757
+SubscribeForProgress1= ETrue
+GlobalCompId1=abc
+ProgressData1=abc
+EndData1=abc
+StartCount=1
+ProgressCount=1
+EndCount=1
+PrintDetails=ETrue
+SubscribeShutdownTimer=15
\ No newline at end of file
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/scripts/tnotifier.script	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,130 @@
+//
+// 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 the License "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: 
+//
+// Sif Notifier test cases.
+
+LOAD_SUITE tUsifSuite 
+
+//! @SYMTestCaseID 		API-SEC-USIF-NOTIFIER-0001
+//! @SYMTestCaseDesc 		Start only one subscriber.  
+//!					
+//! @SYMTestStatus 		3. Released
+
+START_TESTCASE API-SEC-USIF-NOTIFIER-0001
+RUN_TEST_STEP 100 tUsifSuite SifSubscribeStep z:\tusif\tsif\tnotifier.ini Key1
+END_TESTCASE API-SEC-USIF-NOTIFIER-0001
+
+
+
+//! @SYMTestCaseID 		API-SEC-USIF-NOTIFIER-0002
+//! @SYMTestCaseDesc 		Start one subscriber, publisher  
+//!					
+//! @SYMTestStatus 		3. Released
+
+START_TESTCASE API-SEC-USIF-NOTIFIER-0002
+CONCURRENT
+RUN_TEST_STEP 100 tUsifSuite SifSubscribeStep z:\tusif\tsif\tnotifier.ini Key3
+RUN_TEST_STEP 100 tUsifSuite SifPublishStep z:\tusif\tsif\tnotifier.ini publish_one
+END_TESTCASE API-SEC-USIF-NOTIFIER-0002
+
+
+
+//! @SYMTestCaseID 		API-SEC-USIF-NOTIFIER-0003
+//! @SYMTestCaseDesc 		Start one subscriber subscribed to start/end notification and one publisher
+//!					
+//! @SYMTestStatus 		3. Released
+
+START_TESTCASE API-SEC-USIF-NOTIFIER-0003
+CONCURRENT
+RUN_TEST_STEP 100 tUsifSuite SifSubscribeStep z:\tusif\tsif\tnotifier.ini Key4
+RUN_TEST_STEP 100 tUsifSuite SifPublishStep z:\tusif\tsif\tnotifier.ini publish_one
+END_TESTCASE API-SEC-USIF-NOTIFIER-0003
+
+
+
+//! @SYMTestCaseID 		API-SEC-USIF-NOTIFIER-0004
+//! @SYMTestCaseDesc 		One publisher, 2 subscribers .. 1st subscriber subscribes for progress, second does not
+//!					
+//! @SYMTestStatus 		3. Released
+
+START_TESTCASE API-SEC-USIF-NOTIFIER-0004
+CONCURRENT
+RUN_TEST_STEP 100 tUsifSuite SifSubscribeStep z:\tusif\tsif\tnotifier.ini Key5
+RUN_TEST_STEP 100 tUsifSuite SifSubscribeStep z:\tusif\tsif\tnotifier.ini Key4
+RUN_TEST_STEP 100 tUsifSuite SifPublishStep z:\tusif\tsif\tnotifier.ini publish_one
+END_TESTCASE API-SEC-USIF-NOTIFIER-0004
+
+
+
+//! @SYMTestCaseID 		API-SEC-USIF-NOTIFIER-0005
+//! @SYMTestCaseDesc 	      One subscriber 2 publishers
+//! @SYMTestStatus 		3. Released
+
+START_TESTCASE API-SEC-USIF-NOTIFIER-0005
+CONCURRENT
+RUN_TEST_STEP 100 tUsifSuite SifSubscribeStep z:\tusif\tsif\tnotifier.ini Key6
+RUN_TEST_STEP 100 tUsifSuite SifPublishStep z:\tusif\tsif\tnotifier.ini publish_twoconcurrentinstall
+END_TESTCASE API-SEC-USIF-NOTIFIER-0005
+
+
+
+//! @SYMTestCaseID 		API-SEC-USIF-NOTIFIER-0006
+//! @SYMTestCaseDesc 	      One subscriber, 2 publishers ... the second publisher starts after the first finishes.
+//! @SYMTestStatus 		3. Released
+
+START_TESTCASE API-SEC-USIF-NOTIFIER-0006
+CONCURRENT
+RUN_TEST_STEP 100 tUsifSuite SifSubscribeStep z:\tusif\tsif\tnotifier.ini Key7
+RUN_TEST_STEP 100 tUsifSuite SifPublishStep z:\tusif\tsif\tnotifier.ini publish_twoconsecutiveinstall
+END_TESTCASE API-SEC-USIF-NOTIFIER-0006
+
+
+
+//! @SYMTestCaseID 		API-SEC-USIF-NOTIFIER-0007
+//! @SYMTestCaseDesc 	      2 publishers, 2 subscribers
+//! @SYMTestStatus 		3. Released
+
+START_TESTCASE API-SEC-USIF-NOTIFIER-0007
+CONCURRENT
+RUN_TEST_STEP 100 tUsifSuite SifSubscribeStep z:\tusif\tsif\tnotifier.ini Key8
+RUN_TEST_STEP 100 tUsifSuite SifSubscribeStep z:\tusif\tsif\tnotifier.ini Key9
+RUN_TEST_STEP 100 tUsifSuite SifPublishStep z:\tusif\tsif\tnotifier.ini publish_twoconsecutiveinstall
+END_TESTCASE API-SEC-USIF-NOTIFIER-0007
+
+
+//! @SYMTestCaseID 		API-SEC-USIF-NOTIFIER-0008
+//! @SYMTestCaseDesc 		Start one subscriber, publisher with large start data.
+//!					
+//! @SYMTestStatus 		3. Released
+
+START_TESTCASE API-SEC-USIF-NOTIFIER-0008
+CONCURRENT
+RUN_TEST_STEP 100 tUsifSuite SifSubscribeStep z:\tusif\tsif\tnotifier.ini Key3
+RUN_TEST_STEP 100 tUsifSuite SifPublishStep z:\tusif\tsif\tnotifier.ini publish_one_large
+END_TESTCASE API-SEC-USIF-NOTIFIER-0008
+
+
+
+//! @SYMTestCaseID 		API-SEC-USIF-NOTIFIER-0009
+//! @SYMTestCaseDesc 		Start one subscriber, publisher. Print details
+//!					
+//! @SYMTestStatus 		3. Released
+
+START_TESTCASE API-SEC-USIF-NOTIFIER-0009
+CONCURRENT
+RUN_TEST_STEP 100 tUsifSuite SifSubscribeStep z:\tusif\tsif\tnotifier.ini Key10
+RUN_TEST_STEP 100 tUsifSuite SifPublishStep z:\tusif\tsif\tnotifier.ini publish_details
+END_TESTCASE API-SEC-USIF-NOTIFIER-0009
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/source/tsifnotifierteststep.cpp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,604 @@
+/*
+* 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 the License "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: 
+*
+*/
+
+
+/**
+ @file
+ @internalTechnology 
+*/
+
+#include "tsifnotifierteststep.h"
+#include "tsifsuitedefs.h"
+#include <usif/sif/sifcommon.h>
+#include <usif/sif/sif.h>
+#include <scs/cleanuputils.h>
+#include <ct/rcpointerarray.h>
+
+using namespace Usif;
+
+_LIT(KOperationCount, "OperationCount");
+_LIT(KOperation, "Operation");
+_LIT(KGlobalCompId, "GlobalCompId");
+_LIT(KComponentName, "ComponentName");
+_LIT(KComponentIcon, "ComponentIcon");
+_LIT(KAppNameCount, "AppNameCount");
+_LIT(KAppName, "AppName");
+_LIT(KAppIconCount, "AppIconCount");
+_LIT(KAppIcon, "AppIcon");
+_LIT(KComponentSize, "ComponentSize");
+_LIT(KIconPath, "IconPath");
+_LIT(KSoftwareType, "SoftwareType");
+_LIT(KErrMsg, "ErrMsg");
+_LIT(KErrMsgDetails, "ErrMsgDetails");
+_LIT(KErrCategory, "ErrCategory");
+_LIT(KErrCode, "ErrCode");
+_LIT(KPhase, "Phase");
+_LIT(KSubPhase, "SubPhase");
+_LIT(KCurrentProgress, "CurrentProgress");
+_LIT(KTotal, "Total");
+_LIT(KSubscriberNumber, "SubscriberNumber");
+_LIT(KKeyNumber, "KeyNumber");
+_LIT (KSubscribeKey, "SubscribeKey");
+_LIT (KSubscribeForProgress, "SubscribeForProgress");
+_LIT (KEndData, "EndData");
+_LIT (KProgressData, "ProgressData");
+_LIT (KDelay, "Delay");
+_LIT (KTotalStartCount, "StartCount");
+_LIT (KTotalProgressCount, "ProgressCount");
+_LIT (KTotalEndCount, "EndCount");
+_LIT (KSubscribeShutdownTimer, "SubscribeShutdownTimer");
+_LIT (KPublisherDelay, "PublisherDelay");
+_LIT (KPrintDetails, "PrintDetails");
+CSifSubscribeTestStep::~CSifSubscribeTestStep()
+/**
+* Destructor
+*/
+    {
+    INFO_PRINTF1(_L("Cleanup in CSifSubscribeTestStep::~CSifSubscribeTestStep()"));
+    }
+
+CSifSubscribeTestStep::CSifSubscribeTestStep()
+/**
+* Constructor
+*/
+    {
+    SetTestStepName(KSifSubscribeTestStep);
+    }
+
+void CSifSubscribeTestStep::ImplTestStepPreambleL()
+/**
+* @return - TVerdict code
+* Override of base class virtual
+*/
+    {
+    INFO_PRINTF1(_L("I am in CSifSubscribeTestStep::ImplTestStepPreambleL()."));
+    iSched=new(ELeave) CActiveScheduler;
+    CActiveScheduler::Install(iSched);
+    SetTestStepResult(EPass);
+    }
+
+
+void CSifSubscribeTestStep::ImplTestStepL()
+/**
+* @return - TVerdict code
+* Override of base class pure virtual
+* Our implementation only gets called if the base class doTestStepPreambleL() did
+* not leave. That being the case, the current test result value will be EPass.
+*/
+    {   
+    //Get the  Subscriber number
+    GetIntFromConfig(ConfigSection(),KSubscriberNumber, iSubscriberNum);
+    
+    // Delay the Startup ?
+    TInt delay(0);
+    //Get the  delay value if present
+    GetIntFromConfig(ConfigSection(),KDelay, delay);
+    if(delay !=0)
+        {
+        User::After(delay * 1000000);
+        }
+    
+    
+    iNotifier = CSifOperationsNotifier::NewL(*this);
+    TInt shutdownTimer(0);
+    GetIntFromConfig(ConfigSection(), KSubscribeShutdownTimer, shutdownTimer);
+    if(shutdownTimer ==0)
+        {
+        shutdownTimer = 10; //default value
+        }
+    iTimer = CStopTimer::NewL(iNotifier, shutdownTimer* 1000000);
+    CActiveScheduler::Start();
+
+    //Verify Counts
+    TInt startCount(0);
+    GetIntFromConfig(ConfigSection(), KTotalStartCount, startCount);
+    
+    if(startCount != iStartMessageCounter)
+        {
+        INFO_PRINTF1(_L("Total number of start handler notifications received does not match expected value"));
+        SetTestStepResult(EFail);
+        }
+
+    TInt progressCount(0);
+    GetIntFromConfig(ConfigSection(), KTotalProgressCount, progressCount);
+    
+    if(progressCount != iProgressMessageCounter)
+        {
+        INFO_PRINTF1(_L("Total number of progress handler notifications received does not match expected value"));
+        SetTestStepResult(EFail);
+        }
+    
+    TInt endCount(0);
+    GetIntFromConfig(ConfigSection(), KTotalEndCount, endCount);
+    
+    if(endCount != iEndMessageCounter)
+        {
+        INFO_PRINTF1(_L("Total number of end handler notifications received does not match expected value"));
+        SetTestStepResult(EFail);
+        }    
+    
+    }
+
+void CSifSubscribeTestStep::ImplTestStepPostambleL()
+/**
+* @return - TVerdict code
+* Override of base class virtual
+*/
+    {   
+    INFO_PRINTF1(_L("I am in CSifPublishTestStep::ImplTestStepPostambleL()."));
+    delete iNotifier;
+    delete iSched;
+    delete iTimer;
+    }
+
+void CSifSubscribeTestStep::StartOperationHandler(TUint aKey, const CSifOperationStartData& aStartData)
+    { 
+    TBuf<20> Key;
+    Key = KKeyNumber;
+    GenerateIndexedAttributeNameL(Key, ++iStartMessageCounter);
+    TPtrC keyFromIni;
+    GetStringFromConfig(ConfigSection(), Key, keyFromIni);
+    HBufC* retrievedKeyFromIni = keyFromIni.AllocLC();
+    
+    //Received Key
+    HBufC* receivedKey = HBufC::NewLC(20);
+    receivedKey->Des().Format(_L("%d"), aKey );
+    
+    if(*receivedKey != *retrievedKeyFromIni)
+        {
+        INFO_PRINTF1(_L("Key Mismatch !") );
+        SetTestStepResult(EFail);
+        }
+    else
+        {
+        INFO_PRINTF1(_L("Received Correct Key!") );
+        }
+    
+    
+    //Subscribe to key ?
+    TBuf<20> SubscribeKey;
+    SubscribeKey = KSubscribeKey;
+    GenerateIndexedAttributeNameL(SubscribeKey, ++iSubscribeCounter);
+    
+    TPtrC SubscribeKeyFromIni;
+    if(GetStringFromConfig(ConfigSection(),SubscribeKey, SubscribeKeyFromIni))
+        {
+        HBufC* retrievedSubscribeKeyFromIni = SubscribeKeyFromIni.AllocLC();
+        
+        
+        if(*retrievedSubscribeKeyFromIni == *receivedKey)
+            {
+            INFO_PRINTF3(_L("Subscribing to Key %d from Subscriber%d ."), aKey, iSubscriberNum);
+            
+            TBuf<35> progressNotifier;
+            progressNotifier = KSubscribeForProgress;
+            GenerateIndexedAttributeNameL(progressNotifier, iSubscribeCounter);
+            
+            TBool progressNotifierVal;
+            GetBoolFromConfig(ConfigSection(),progressNotifier, progressNotifierVal);
+            iNotifier->SubscribeL(aKey, progressNotifierVal);
+            }
+ 
+        CleanupStack::PopAndDestroy(retrievedSubscribeKeyFromIni);
+        }   
+    
+    CleanupStack::PopAndDestroy(2, retrievedKeyFromIni);
+    //Global Component Id check
+    TBuf<20> GlobalId;
+    GlobalId = KGlobalCompId;
+    GenerateIndexedAttributeNameL(GlobalId, iStartMessageCounter);
+    
+    TPtrC globalIdFromIni;
+    GetStringFromConfig(ConfigSection(),GlobalId, globalIdFromIni);
+    
+    HBufC* retrievedGlobalIdFromIni = globalIdFromIni.AllocLC();
+    
+    
+    if(*retrievedGlobalIdFromIni != aStartData.GlobalComponentId())
+        {       
+        INFO_PRINTF1(_L("Global Component Id mismatch !") );
+        SetTestStepResult(EFail); 
+        }
+    else
+        {
+        INFO_PRINTF1(_L("Received Correct Global Component Id !") );     
+        }   
+    CleanupStack::PopAndDestroy(retrievedGlobalIdFromIni);
+    
+    //Print received data ?
+    TBool print;
+    if(GetBoolFromConfig(ConfigSection(),KPrintDetails, print))
+        {
+        INFO_PRINTF2(_L("Global Component Id : %S"),  &aStartData.GlobalComponentId());
+        INFO_PRINTF2(_L("Component Name: %S"),  &aStartData.ComponentName());
+        
+        for(TInt i=0; i<aStartData.ApplicationNames().Count(); ++i)
+            {
+            INFO_PRINTF3(_L("Application name %d : %S"), i,  aStartData.ApplicationNames()[i]);
+            }
+        for(TInt i=0; i<aStartData.ApplicationIcons().Count(); ++i)
+            {
+            INFO_PRINTF3(_L("Application icons %d : %S"), i,  aStartData.ApplicationIcons()[i]);
+            }       
+        INFO_PRINTF2(_L("Component Size : %d"),  aStartData.ComponentSize());
+        INFO_PRINTF2(_L("Icon Path : %S"),  &aStartData.IconPath());
+        INFO_PRINTF2(_L("Component Icon : %S"),  &aStartData.ComponentIcon());
+        INFO_PRINTF2(_L("Software Type: %S"),  &aStartData.SoftwareType());
+        
+        
+        }
+    }
+
+
+void CSifSubscribeTestStep::EndOperationHandler(const CSifOperationEndData& aEndData)
+    {
+    TBuf<20> endData;
+    endData = KEndData;
+    GenerateIndexedAttributeNameL(endData, ++iEndMessageCounter);
+    
+    TPtrC endDataFromIni;
+    if(GetStringFromConfig(ConfigSection(),endData, endDataFromIni))
+        {
+        HBufC* retrievedEndDataFromIni = endDataFromIni.AllocLC();
+        
+        if(*retrievedEndDataFromIni != aEndData.GlobalComponentId())
+            {
+            SetTestStepResult(EFail);
+            INFO_PRINTF1(_L("End Data Mismatch !") );
+            }
+        else
+            {
+            INFO_PRINTF1(_L("Correct end data received !") );
+            }     
+        CleanupStack::PopAndDestroy(retrievedEndDataFromIni);
+        }
+    else
+        {
+        SetTestStepResult(EFail);
+        INFO_PRINTF1(_L("End Data Mismatch !") );
+        }
+    
+    //Print received data ?
+    TBool print;
+    if(GetBoolFromConfig(ConfigSection(),KPrintDetails, print))
+        {
+        INFO_PRINTF2(_L("Global Component Id : %S"),  &aEndData.GlobalComponentId());
+        INFO_PRINTF2(_L("Error Category : %d"),  (TInt)aEndData.ErrorCategory());
+        INFO_PRINTF2(_L("Error code : %d"),  aEndData.ErrorCode());
+        INFO_PRINTF2(_L("Error message : %S"),  &aEndData.ErrorMessage());
+        INFO_PRINTF2(_L("Error message details : %S"),  &aEndData.ErrorMessageDetails());
+        }
+    }
+
+void CSifSubscribeTestStep::ProgressOperationHandler(const CSifOperationProgressData& aProgressData)
+    {
+    TBuf<20> progressData;
+    progressData = KProgressData;
+    GenerateIndexedAttributeNameL(progressData, ++iProgressMessageCounter);
+    
+    TPtrC progressDataFromIni;
+    if(GetStringFromConfig(ConfigSection(),progressData, progressDataFromIni))
+        {
+        HBufC* retrievedprogressDataFromIni = progressDataFromIni.AllocLC();
+        
+        if(*retrievedprogressDataFromIni != aProgressData.GlobalComponentId())
+            {
+            SetTestStepResult(EFail);
+            INFO_PRINTF1(_L("Progress Data Mismatch !") );
+            }
+        else
+            {
+            INFO_PRINTF1(_L("Correct progress data received !") );
+            }
+        
+        CleanupStack::PopAndDestroy(retrievedprogressDataFromIni);       
+        }
+    else
+        {
+        SetTestStepResult(EFail);
+        INFO_PRINTF1(_L("Progress Data Mismatch !") );
+        }   
+    
+    //Print received data ?
+    TBool print;
+    if(GetBoolFromConfig(ConfigSection(),KPrintDetails, print))
+        {
+        INFO_PRINTF2(_L("Global Component Id : %S"),  &aProgressData.GlobalComponentId());
+        INFO_PRINTF2(_L("Phase : %d"),  (TInt)aProgressData.Phase());
+        INFO_PRINTF2(_L("Sub Phase : %d"),  (TInt)aProgressData.SubPhase());
+        INFO_PRINTF2(_L("Current Progress : %d"),  aProgressData.CurrentProgess());
+        INFO_PRINTF2(_L("Total Value : %d"),  aProgressData.Total());
+        
+        }
+    }
+
+void CSifSubscribeTestStep::GenerateIndexedAttributeNameL(TDes& aInitialAttributeName, TInt aIndex)
+    {
+    const TInt MAX_INT_STR_LEN = 8;
+    TBuf<MAX_INT_STR_LEN> integerAppendStr;
+    integerAppendStr.Format(_L("%d"), aIndex);
+    aInitialAttributeName.Append(integerAppendStr);
+    }
+
+CSifPublishTestStep::~CSifPublishTestStep()
+/**
+* Destructor
+*/
+    {
+    INFO_PRINTF1(_L("Cleanup in CSifPublishTestStep::~CSifPublishTestStep()"));
+    delete iTimer;
+    delete iPublisher;
+    delete iSched;
+    }
+
+CSifPublishTestStep::CSifPublishTestStep()
+/**
+* Constructor
+*/
+    {
+    SetTestStepName(KSifPublishTestStep);
+    }
+
+void CSifPublishTestStep::ImplTestStepPreambleL()
+/**
+* @return - TVerdict code
+* Override of base class virtual
+*/
+    {
+    INFO_PRINTF1(_L("I am in CSifPublishTestStep::ImplTestStepPreambleL()."));
+    
+    TInt delay(0);
+    //Get the  delay value if present
+    GetIntFromConfig(ConfigSection(),KDelay, delay);
+    if(delay !=0)
+        {
+        User::After(delay * 1000000);
+        }
+   
+    iSched=new(ELeave) CActiveScheduler;
+    CActiveScheduler::Install(iSched);
+    iPublisher = CPublishSifOperationInfo::NewL();
+    }
+
+void CSifPublishTestStep::GenerateIndexedAttributeNameL(TDes& aInitialAttributeName, TInt aIndex)
+    {
+    const TInt MAX_INT_STR_LEN = 8;
+    TBuf<MAX_INT_STR_LEN> integerAppendStr;
+    integerAppendStr.Format(_L("%d"), aIndex);
+    aInitialAttributeName.Append(integerAppendStr);
+    }
+
+void CSifPublishTestStep::PublishDataL(HBufC* aConfigSection)
+    {
+    HBufC* configsection;
+    if(aConfigSection == NULL)
+       configsection = ConfigSection().AllocLC();
+    else
+       configsection = aConfigSection->AllocLC();
+        
+	TPtrC op;
+	GetStringFromConfig(*configsection,KOperation, op);
+    if(op.Compare(_L("start")) == 0)
+		{
+		TPtrC globalCompId, compName, compIcon, appName, appIcon, iconPath, softwareType;
+		TInt appNameCount =0;
+		TInt appIconCount =0;
+		TInt compSize = 0;
+		GetStringFromConfig(*configsection,KGlobalCompId, globalCompId);
+		GetStringFromConfig(*configsection,KComponentName, compName);
+		GetStringFromConfig(*configsection,KComponentIcon, compIcon);
+		GetIntFromConfig(*configsection, KAppNameCount, appNameCount);
+		RPointerArray<HBufC> appNameArray;
+		CleanupResetAndDestroyPushL(appNameArray);
+		for (TUint i = 0; i < appNameCount; ++i)
+			{
+			TPtrC tAppName;
+			TBuf<20> appName;
+			appName = KAppName;
+			GenerateIndexedAttributeNameL(appName, i);
+			GetStringFromConfig(*configsection, appName, tAppName);
+			HBufC* applicationName = tAppName.AllocLC();
+			appNameArray.AppendL(applicationName);
+			CleanupStack::Pop(applicationName);
+			}
+		GetIntFromConfig(*configsection, KAppIconCount, appIconCount);
+		RPointerArray<HBufC> appIconArray;
+		CleanupResetAndDestroyPushL(appIconArray);
+		for (TUint i = 0; i < appIconCount; ++i)
+			{
+			TPtrC tAppIcon;
+			TBuf<20> appIcon;
+			appIcon = KAppIcon;
+			GenerateIndexedAttributeNameL(appIcon, i);
+			GetStringFromConfig(*configsection, appIcon, tAppIcon);
+			HBufC* applicationIcon = tAppIcon.AllocLC();
+			appIconArray.AppendL(applicationIcon);
+			CleanupStack::Pop(applicationIcon);
+			}
+       
+		GetIntFromConfig(*configsection, KComponentSize, compSize);
+		GetStringFromConfig(*configsection, KIconPath, iconPath);
+		GetStringFromConfig(*configsection, KSoftwareType, softwareType);
+
+        CSifOperationStartData* startdata = CSifOperationStartData::NewLC(globalCompId, compName, appNameArray, appIconArray, compSize, iconPath, compIcon, softwareType);
+        iPublisher->PublishStartL(*startdata);   
+        CleanupStack::PopAndDestroy(3, &appNameArray);
+        }
+    else if(op.Compare(_L("progress")) == 0)
+        {
+		TInt phase=0, subPhase=0, curProgress=0, total=0;
+		TPtrC globalCompIdProgress;
+		GetStringFromConfig(*configsection,KGlobalCompId, globalCompIdProgress);
+		GetIntFromConfig(*configsection, KPhase, phase);
+		GetIntFromConfig(*configsection, KSubPhase, subPhase);
+		GetIntFromConfig(*configsection, KCurrentProgress, curProgress);
+		GetIntFromConfig(*configsection, KTotal, total);
+
+		TSifOperationPhase enumPhase = static_cast<TSifOperationPhase>(phase);
+		TSifOperationSubPhase enumSubPhase = static_cast<TSifOperationSubPhase>(subPhase);
+        CSifOperationProgressData* progressdata = CSifOperationProgressData::NewLC(globalCompIdProgress, enumPhase, enumSubPhase, curProgress, total);
+        iPublisher->PublishProgressL(*progressdata);    
+        CleanupStack::PopAndDestroy(progressdata);
+        }
+    else if(op.Compare(_L("end")) == 0)
+        {
+		TPtrC errMsg, errMsgDetails;
+		TInt errCat, errCode;
+		TPtrC globalCompIdEnd;
+		GetStringFromConfig(*configsection,KGlobalCompId, globalCompIdEnd);
+		GetStringFromConfig(*configsection, KErrMsg, errMsg);
+		GetStringFromConfig(*configsection, KErrMsgDetails, errMsgDetails);
+		GetIntFromConfig(*configsection, KErrCategory, errCat);
+		GetIntFromConfig(*configsection, KErrCode, errCode);
+
+		TErrorCategory enumErrCat = static_cast<TErrorCategory>(errCat);
+		CSifOperationEndData* enddata = CSifOperationEndData::NewLC(globalCompIdEnd, enumErrCat, errCode, errMsg, errMsgDetails);
+        iPublisher->PublishCompletionL(*enddata);
+        CStopTimer* timer = CStopTimer::NewL(NULL, 5000000);
+        CleanupStack::PushL(timer);
+        CActiveScheduler::Start();    
+        CleanupStack::PopAndDestroy(2, enddata);
+        }   
+    else if (op.Compare(_L("delay")) == 0)
+        {
+        TInt delay(0);
+        GetIntFromConfig(*configsection, KPublisherDelay, delay);
+        User::After(delay*1000000);
+        }
+        
+        
+    CleanupStack::PopAndDestroy(configsection);
+    }
+
+void CSifPublishTestStep::ImplTestStepL()
+/**
+* @return - TVerdict code
+* Override of base class pure virtual
+* Our implementation only gets called if the base class doTestStepPreambleL() did
+* not leave. That being the case, the current test result value will be EPass.
+*/
+    {
+    RSoftwareInstall sif;
+    User::LeaveIfError(sif.Connect());
+    CleanupClosePushL(sif);
+    
+    TInt operationCount = 0;
+    TPtrC configSectionName(ConfigSection());
+    HBufC* cnfSecName = NULL;
+        
+    GetIntFromConfig(ConfigSection(), KOperationCount, operationCount);
+    for (TUint i = 0; i < operationCount; ++i)
+        {
+        TBuf<20> configSection = _L("configsection");
+        GenerateIndexedAttributeNameL(configSection, i);
+        GetStringFromConfig(ConfigSection(),configSection, configSectionName);
+        cnfSecName = configSectionName.AllocLC();
+        PublishDataL(cnfSecName);
+        CleanupStack::PopAndDestroy(cnfSecName);
+        }
+    CStopTimer* timer = CStopTimer::NewL(NULL, 5000000);
+    CleanupStack::PushL(timer);
+    CActiveScheduler::Start();
+    CleanupStack::PopAndDestroy(2, &sif);
+    }
+
+void CSifPublishTestStep::ImplTestStepPostambleL()
+/**
+* @return - TVerdict code
+* Override of base class virtual
+*/
+    {   
+    delete iPublisher;
+    iPublisher=0;
+    delete iSched;
+    iSched=0;
+    }
+
+
+
+
+CStopTimer::CStopTimer(CSifOperationsNotifier* aNotifier) : 
+    CTimer(-1),
+    iNotifier(aNotifier)
+    {
+    CActiveScheduler::Add(this);
+    }
+
+CStopTimer::~CStopTimer()
+    {
+    Cancel();
+    }
+
+void CStopTimer::ConstructL(TInt aSeconds)
+    {
+    CTimer::ConstructL();
+    iSeconds = aSeconds;
+    Start();
+    }
+
+void CStopTimer::Start()
+    {
+    After(iSeconds);
+    }
+CStopTimer* CStopTimer::NewL(CSifOperationsNotifier* aNotifier, TInt aSeconds)
+    {
+    CStopTimer* self = new(ELeave) CStopTimer(aNotifier);
+    CleanupStack::PushL(self);
+    self->ConstructL(aSeconds);
+    CleanupStack::Pop(self);
+    return self;
+    }
+
+void CStopTimer::RunL()
+    {
+    if(iNotifier)
+        {
+        //To improve coverage, call cancel subscribe on a non existent key.
+        iNotifier->CancelSubscribeL(123);
+        
+        //cancel all subscriptions.
+        iNotifier->CancelSubscribeL();           
+        }
+    CActiveScheduler::Stop();
+    }
+
+
+TInt CStopTimer::RunError(TInt aError)
+    {
+    (void)aError;
+    return KErrNone;
+    }
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/installationservices/swinstallationfw/test/tusif/source/tsifnotifierteststep.h	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,102 @@
+/*
+* 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 the License "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: 
+*
+*/
+
+
+/**
+ @file
+ @internalTechnology 
+*/
+
+#ifndef TSIFNOTIFIERTESTSTEP_H
+#define TSIFNOTIFIERTESTSTEP_H
+
+#include <test/testexecutestepbase.h>
+#include <usif/sif/sifnotification.h>
+#include "tsifsuitestepbase.h"
+
+namespace Usif
+	{
+	
+    class CStopTimer : public CTimer
+        {
+    public:
+        static CStopTimer* NewL(CSifOperationsNotifier* aNotifier, TInt aSeconds);
+        CStopTimer(CSifOperationsNotifier* aNotifier);
+        ~CStopTimer();
+        void ConstructL(TInt aSeconds);
+        void Start();
+    private:
+        void RunL();
+        TInt RunError(TInt aError);
+        TInt iSeconds;
+        CSifOperationsNotifier* iNotifier;
+        };  	
+
+	class CSifSubscribeTestStep : public CSifSuiteStepBase, public MSifOperationsHandler
+		{
+	public:
+		virtual ~CSifSubscribeTestStep();
+		CSifSubscribeTestStep();
+		virtual void ImplTestStepPreambleL();
+		virtual void ImplTestStepL();
+		virtual void ImplTestStepPostambleL();
+		
+		//Implementing MSifOperationsHandler
+		void StartOperationHandler(TUint aKey, const CSifOperationStartData& aStartData);
+		void EndOperationHandler(const CSifOperationEndData& aEndData);
+		void ProgressOperationHandler(const CSifOperationProgressData& aProgressData);
+		
+	private:
+	    void GenerateIndexedAttributeNameL(TDes& aInitialAttributeName, TInt aIndex);
+	private:
+	    CActiveScheduler* iSched;
+	    CSifOperationsNotifier* iNotifier;
+	    TInt iKey;
+	    TInt iStartMessageCounter;
+	    TInt iProgressMessageCounter;
+	    TInt iEndMessageCounter;
+	    TInt iSubscribeCounter;
+	    TInt iSubscriberNum;
+	    CStopTimer * iTimer;
+		};
+	
+	_LIT(KSifSubscribeTestStep,"SifSubscribeStep");
+		
+
+	class CSifPublishTestStep : public CSifSuiteStepBase
+	    {
+	public:
+	    virtual ~CSifPublishTestStep();
+	    CSifPublishTestStep();
+	    virtual void ImplTestStepPreambleL();
+	    virtual void ImplTestStepL();
+	    virtual void ImplTestStepPostambleL();
+	    
+	    void GenerateIndexedAttributeNameL(TDes& aInitialAttributeName, TInt aIndex);
+	    void PublishDataL(HBufC* aConfigSection);    
+	private:
+	    CActiveScheduler* iSched;
+	    CPublishSifOperationInfo* iPublisher;
+	    CStopTimer* iTimer;
+	    };
+
+	_LIT(KSifPublishTestStep,"SifPublishStep");
+	
+	    
+	} // namespace Sif
+
+#endif // TSIFNOTIFIERTESTSTEP_H
--- a/installationservices/swinstallationfw/test/tusif/source/tsifsuitedefs.h	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/test/tusif/source/tsifsuitedefs.h	Fri May 14 15:58:48 2010 +0300
@@ -72,7 +72,7 @@
 	_LIT(KTe_CompInfoRootNodePrefix,"root");
 	_LIT(KTe_CompInfoChildNodePrefix,".child");
 	_LIT(KTe_CompInfoNumChildren,"numChildren");
-
+	_LIT(KTe_OperationType,"operation");
 	// For test step panics
 	_LIT(KTe_SifSuitePanic,"Te_SifSuite");
 
--- a/installationservices/swinstallationfw/test/tusif/source/tsifsuiteserver.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/swinstallationfw/test/tusif/source/tsifsuiteserver.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2008-2010 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 "Eclipse Public License v1.0"
@@ -26,6 +26,7 @@
 #include "tsifgenericbrowserinstallstep.h"
 #include "tsifcommonverificationstep.h"
 #include "tsifcommonunitteststep.h"
+#include "tsifnotifierteststep.h"
 
 using namespace Usif;
 
@@ -124,6 +125,10 @@
 		testStep = new CSifMultipleInstallStep();
 	else if(aStepName == KSifCommonUnitTestStep)
 		testStep = new CSifCommonUnitTestStep();
+    else if(aStepName == KSifSubscribeTestStep)
+        testStep = new CSifSubscribeTestStep();
+	else if(aStepName == KSifPublishTestStep)
+        testStep = new CSifPublishTestStep();
 
 	return testStep;
 	}
--- a/installationservices/switestfw/test/autotesting/hosts	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/switestfw/test/autotesting/hosts	Fri May 14 15:58:48 2010 +0300
@@ -1,2 +1,2 @@
-10.253.27.175  cam-ocsptest01.intra
-10.253.27.175  cam-OCSPTEST01.prod.ad.symbian.intra
+10.225.90.30  cam-ocsptest01.intra
+10.225.90.30  cam-OCSPTEST01.prod.ad.symbian.intra
--- a/installationservices/switestfw/test/autotesting/runusiftests.bat	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/switestfw/test/autotesting/runusiftests.bat	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 @rem
-@rem Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
+@rem Copyright (c) 2009-2010 Nokia Corporation and/or its subsidiary(-ies).
 @rem All rights reserved.
 @rem This component and the accompanying materials are made available
 @rem under the terms of the License "Eclipse Public License v1.0"
@@ -34,6 +34,11 @@
 testexecute z:\tusif\tswtype\tsifswtypeintegration.script
 move c:\logs\testexecute\tsifswtypeintegration.htm e:\testresults\tsifswtypeintegration.htm
 
+REM Sif notifier tests
+testexecute z:\tusif\tsif\tnotifier.script
+move c:\logs\testexecute\tnotifier.htm e:\testresults\tnotifier.htm
+
+
 REM run SCR tests
 testexecute z:\tusif\tscr\tscr.script
 move c:\logs\testexecute\tscr.htm e:\testresults\tscr.htm
--- a/installationservices/switestfw/test/autotesting/test_spec_apr_9.5.txt	Mon May 03 12:38:03 2010 +0300
+++ b/installationservices/switestfw/test/autotesting/test_spec_apr_9.5.txt	Fri May 14 15:58:48 2010 +0300
@@ -361,6 +361,7 @@
 TESTEXECUTE, \logs\testexecute\tsifintegration.htm,,z:\tusif\tsifintegration\tsifintegration.script, 500, UDEB#UREL,,
 TESTEXECUTE, \logs\testexecute\tsif.htm,,z:\tusif\tsif\tsif.script, 300, UDEB#UREL,,
 TESTEXECUTE, \logs\testexecute\tsifoom.htm,,z:\tusif\tsif\tsifoom.script, 300, UDEB,,
+TESTEXECUTE, \logs\testexecute\tnotifier.htm,,z:\tusif\tsif\tnotifier.script, 1000, UDEB#UREL,,
 TESTEXECUTE, \logs\testexecute\tscr.htm,,z:\tusif\tscr\tscr.script, 100000, UDEB#UREL,,
 TESTEXECUTE, \logs\testexecute\tscr_oom.htm,,z:\tusif\tscr\tscr_oom.script, 100000, UDEB,,
 TESTEXECUTE, \logs\testexecute\tsts_bootuptimerecovery.htm,,z:\tusif\tsts\tsts_bootuptimerecovery.script, 300, UDEB#UREL, \epoc32\data\z\tusif\tsts\batchfiles\tsts_bootuptimerecovery.bat,
--- a/ncdengine/engine/group/catalogsserver.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/ncdengine/engine/group/catalogsserver.mmp	Fri May 14 15:58:48 2010 +0300
@@ -443,7 +443,6 @@
 LIBRARY         gsmu.lib    // SMS
 LIBRARY         smcm.lib    // SMS
 LIBRARY         msgs.lib    // SMS
-LIBRARY         apengine.lib
 
 #ifndef __SERIES60_31__
 LIBRARY         cmmanager.lib // CMManager and other SNAP/APN classes
--- a/package_definition.xml	Mon May 03 12:38:03 2010 +0300
+++ b/package_definition.xml	Fri May 14 15:58:48 2010 +0300
@@ -43,6 +43,21 @@
       <component id="swidevicetools" name="Secure Software Install Device Tools" introduced="8.1" purpose="development">
         <unit bldFile="installationservices/swidevicetools/group" mrp="installationservices/swidevicetools/group/security_switools_device.mrp"/>
       </component>
+      <component id="swcomponentregistry" name="Software Component Registry" introduced="^4" purpose="mandatory">
+        <unit bldFile="installationservices/swcomponentregistry/group" mrp="installationservices/swcomponentregistry/group/security_softwarecomponentregistry.mrp"/>
+      </component>
+      <component id="swinstallationfw" name="Software Installation Framework" introduced="^4" purpose="optional">
+        <unit bldFile="installationservices/swinstallationfw/group" mrp="installationservices/swinstallationfw/group/security_softwareinstallframework.mrp"/>
+      </component>
+      <component id="swtransactionservices" name="Software Transaction Services" introduced="^4" purpose="optional">
+        <unit bldFile="installationservices/swtransactionservices/group" mrp="installationservices/swtransactionservices/group/security_softwaretransactionservices.mrp"/>
+      </component>
+      <component id="refswinstallationplugin" name="Reference Software Installation Plugin" introduced="^4" purpose="development" class="plugin">
+        <unit bldFile="installationservices/refswinstallationplugin/group" mrp="installationservices/refswinstallationplugin/group/security_sifrefplugin.mrp"/>
+      </component>
+      <component id="refsoftwareappmgr" name="Reference Software Application Manager" introduced="^4" purpose="development">
+        <unit bldFile="installationservices/refsoftwareappmgr/group" mrp="installationservices/refsoftwareappmgr/group/security_referenceapplicationmanager.mrp"/>
+      </component>
       <component id="switestfw" name="Software Install Test Framework" deprecated="^3" introduced="7.0" purpose="development" filter="test">
         <unit mrp="installationservices/switestfw/group/install_testframework.mrp" bldFile="installationservices/switestfw/group"/>
       </component>
--- a/secureswitools/swisistools/group/interpretsislib.mmp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/group/interpretsislib.mmp	Fri May 14 15:58:48 2010 +0300
@@ -80,6 +80,7 @@
 SOURCEPATH		../source/rscparser
 SOURCE			barsc2.cpp
 SOURCE			barscimpl.cpp
+SOURCE			dictionarycompression.cpp
 SOURCE			commontypes.cpp
 SOURCE			barsread2.cpp
 SOURCE			barsreadimpl.cpp
--- a/secureswitools/swisistools/source/dbmanager/dblayer.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/dbmanager/dblayer.cpp	Fri May 14 15:58:48 2010 +0300
@@ -887,9 +887,7 @@
 
 		if(appPropertyIter->iIsStr8Bit)
 			{
-			std::string str = Util::wstring2string(appPropertyIter->iStrValue);
-			std::string decodedString = Util::Base64Decode(str);
-			stmtAppProperty->BindBinary(6, str);
+			stmtAppProperty->BindBinary(6, appPropertyIter->iStrValue);
 			}
 		else
 			{
--- a/secureswitools/swisistools/source/dbmanager/dbprocessor.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/dbmanager/dbprocessor.cpp	Fri May 14 15:58:48 2010 +0300
@@ -376,6 +376,13 @@
 	CheckSqlErrCode(err);
 	}
 
+void CStatement::BindBinary(TInt aParameterIndex, const std::wstring &aParameterStr)
+	{
+	TInt err = iLibraryHandler.sqlite3_bind_blob(iStmtHandle, aParameterIndex, aParameterStr.c_str(), aParameterStr.size()*2, SQLITE_TRANSIENT);
+	// The fifth argument has the value SQLITE_TRANSIENT, it means that SQLite makes its own private copy of the data immediately
+	CheckSqlErrCode(err);
+	}
+
 void CStatement::Reset()
 	{
 	TInt err = iLibraryHandler.sqlite3_reset(iStmtHandle);
--- a/secureswitools/swisistools/source/dbmanager/dbprocessor.h	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/dbmanager/dbprocessor.h	Fri May 14 15:58:48 2010 +0300
@@ -188,6 +188,8 @@
 		
 		void BindBinary(int aParameterIndex, const std::string &aParameterStr);
 
+		void BindBinary(int aParameterIndex, const std::wstring &aParameterStr);
+
 		/**
 			Resets this SQL statement object to its initial state and makes it ready to be executed again.
 			Any SQL statement parameters that had values bound to them, retain their values.
--- a/secureswitools/swisistools/source/interpretsis/main.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/interpretsis/main.cpp	Fri May 14 15:58:48 2010 +0300
@@ -67,26 +67,30 @@
 		CInterpretSIS interpretSis(paramList);
 		
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK
-		if ( paramPtr->IsFlagSet(CParameterList::EFlagsResourceFilePathSet)) 
+		//Parsing Preprovisioned Resource file in not done if RegistryVersionExists
+		if(!paramPtr->RegistryVersionExists())
 		{
-			ParseResourceDir(paramPtr, interpretSis);
-
-			if (NULL != logFile)
+			if ( paramPtr->IsFlagSet(CParameterList::EFlagsResourceFilePathSet)) 
 			{
-				bool val = logFile->is_open();
-				logFile->close();
-				delete logFile;
+				ParseResourceDir(paramPtr, interpretSis);
+
+				if (NULL != logFile)
+				{
+					bool val = logFile->is_open();
+					logFile->close();
+					delete logFile;
+				}
+				return result;
 			}
-			return result;
-		}
-		else
-		{
-			ParseResourceDir(paramPtr, interpretSis);
+			else
+			{
+				ParseResourceDir(paramPtr, interpretSis);
+			}
 		}
 #endif //SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK		
 	
 		result = interpretSis.Install();
-		
+
 		// Uninstall the sis files
 		interpretSis.Uninstall();
 #ifdef SYMBIAN_UNIVERSAL_INSTALL_FRAMEWORK	
--- a/secureswitools/swisistools/source/interpretsislib/installer.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/interpretsislib/installer.cpp	Fri May 14 15:58:48 2010 +0300
@@ -305,23 +305,19 @@
 
 		UpdateRegistry(file, installable, aInstallSISFile, aInstallSISFile.iSUFlag);
 	}
+	catch  (InterpretSisError& e)
+	{
+		RestoreAll(file, installable, iBackupFlag);
+
+		LERROR(L"\t" << Utf8ToUcs2(e.what()));
+		int result =  e.GetErrorCode();
+		return result;
+	
+	}
 	catch  (...)
 	{//Update Registry Failed. UnInstall the files.
-		InstallableFiles::const_iterator filedesIter; 
-		std::wstring itargetLocalFile;
 
-		for(filedesIter = installable.begin() ; filedesIter != installable.end(); ++filedesIter)
-		{
-		    itargetLocalFile = (*filedesIter)->GetLocalTarget();
-			
-			if (FileExists(itargetLocalFile))
-			{
-				RemoveFile(itargetLocalFile);
-				RemoveHashForFile(itargetLocalFile, iParamList.SystemDriveLetter(), iParamList.SystemDrivePath());
-			}
-		}
-		Restore(file, installable, iBackupFlag);
-		FreeInstallableFiles(installable);
+		RestoreAll(file, installable, iBackupFlag);
 		return RSC_PARSING_ERROR;
 	}
 
@@ -594,6 +590,26 @@
 		}
 	}
 }
+
+void Installer::RestoreAll(const SisFile& aFile, InstallableFiles& aInstallable, TBool& aBackupFlag)
+{
+	InstallableFiles::const_iterator filedesIter; 
+	std::wstring itargetLocalFile;
+
+	for(filedesIter = aInstallable.begin() ; filedesIter != aInstallable.end(); ++filedesIter)
+	{
+		itargetLocalFile = (*filedesIter)->GetLocalTarget();
+		
+		if (FileExists(itargetLocalFile))
+		{
+			RemoveFile(itargetLocalFile);
+			RemoveHashForFile(itargetLocalFile, iParamList.SystemDriveLetter(), iParamList.SystemDrivePath());
+		}
+	}
+	Restore(aFile, aInstallable, aBackupFlag);
+	FreeInstallableFiles(aInstallable);
+}
+
 #endif
 
 struct CheckDependencyMet
--- a/secureswitools/swisistools/source/interpretsislib/installer.h	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/interpretsislib/installer.h	Fri May 14 15:58:48 2010 +0300
@@ -72,6 +72,7 @@
 	void Backup(const SisFile& aFile, InstallableFiles& aInstallable, TBool& aBackupFlag);
 	void RemoveBackup(const SisFile& aFile, InstallableFiles& aInstallable);
 	void Restore(const SisFile& aFile, InstallableFiles& aInstallable, TBool& aBackupFlag);
+	void RestoreAll(const SisFile& aFile, InstallableFiles& aInstallable, TBool& aBackupFlag);
 #endif
 	bool DependenciesOk(const SisFile& aFile);			// Check to see if the sis file
 														// meets it's dependencies
--- a/secureswitools/swisistools/source/interpretsislib/sisregistry.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/interpretsislib/sisregistry.cpp	Fri May 14 15:58:48 2010 +0300
@@ -2090,13 +2090,16 @@
 			RegistrationFileName = iRomPath + localpath;
 		}
 
+		size_t found=RegistrationFileName.rfind(".rsc");
+		if(found==string::npos)
+			continue;
+
 		//Return 0 for Registration file else 1
 		TInt err = FindRegistrationResourceFileL(RegistrationFileName);
 
 		if(err)
 			continue;
 
-		size_t found;
 		std::string folder;
 		found=RegistrationFileName.find("private\\10003a3f\\");
 
--- a/secureswitools/swisistools/source/rscparser/aplappinforeader.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/rscparser/aplappinforeader.cpp	Fri May 14 15:58:48 2010 +0300
@@ -476,9 +476,11 @@
 				std::string Locale;
 				int iLocale = 0;
 		
-				found=fName.find_last_of(".");
-				if(found)
-				   	Locale = fName.substr(found+2);
+				found=fName.rfind(".r");
+				if(found!=string::npos)
+					Locale = fName.substr(found+2);
+				else
+					continue;
 
 				iLocale = atoi(Locale.c_str()); 
 			    if(!iLocale)
--- a/secureswitools/swisistools/source/rscparser/barscimpl.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/rscparser/barscimpl.cpp	Fri May 14 15:58:48 2010 +0300
@@ -25,25 +25,71 @@
 #include <sstream>
 #include "barsc2.h"
 #include "barscimpl.h"
+#include "dictionarycompression.h"
 #include "ucmp.h"
+#include "util.h"
+#include "parse.h"
 
+#define REINTERPRET_CAST(type,exp) (reinterpret_cast<type>(exp))
+#define CONST_CAST(type,exp) (const_cast<type>(exp))
+#define STATIC_CAST(type,exp) (static_cast<type>(exp))
+
+inline TUint8* MemCopy(TAny* aTrg, const TAny* aSrc, TInt aLength)
+{ return (TUint8*)memmove(aTrg, aSrc, aLength) + aLength; }
+
+
+/** Cleanup function.
+@internalComponent
+@param aArrayOfDictionaryCompressionBitStreams Pointer to an vector of 
+RDictionaryCompressionBitStream objects which have to be closed. */
+void CloseArrayOfDictionaryCompressionBitStreams(TAny* aArray)
+{
+	typedef std::vector<RDictionaryCompressionBitStream> RDictComprBitStream;
+	RDictComprBitStream* array = static_cast <RDictComprBitStream*> (aArray);
+	for (TInt i=array->size()-1;i>=0;--i)
+		{
+		array[i].clear();
+		}
+	array->clear();
+}
 
 RResourceFileImpl::TExtra::TExtra():
 	iBitArrayOfResourcesContainingCompressedUnicode(NULL),
 	iFileOffset(0),
 	iFileSize(0)
-	{
-	}
+{
+}
 
 
 RResourceFileImpl::TExtra::~TExtra()
-	{
+{
+	delete [] iDictionaryCompressionData.iCachedResourceBuffer;
+	iDictionaryCompressionData.iCachedResourceBuffer = NULL;
+	delete [] iDictionaryCompressionData.iCachedDictionaryIndex;
+	iDictionaryCompressionData.iCachedDictionaryIndex = 0;
+
 	delete iBitArrayOfResourcesContainingCompressedUnicode;
-	}
+}
 
 
-TInt32 RResourceFileImpl::TExtra::ContainsCompressedUnicode(const TInt& aRscIdx) const
+TInt32 RResourceFileImpl::TExtra::ContainsCompressedUnicode(TInt& aRscIdx, TBool aFirstRscIsGen) const
+{
+	
+	if (aFirstRscIsGen)
 	{
+		// dictionary-compressed resource files can have an automatically generated 
+		//resource which is the bit-array of resources containing compressed Unicode 
+		//(this automatically generated resource does not have a corresponding bit 
+		//for itself in the bit-array as it would be self-referring...)
+		--aRscIdx; 
+		if (aRscIdx<0)
+		{
+			//aRscIdx is referring to the automatically generated resource 
+			//(which is the bit-array of resources containing compressed Unicode)
+			return EFalse; 
+			}
+	}
+	
 	assert(aRscIdx>=0);
 	
 	if (iBitArrayOfResourcesContainingCompressedUnicode==NULL)
@@ -52,19 +98,19 @@
 		}
 	
 	TInt index = aRscIdx/8;
-	
-	return (iBitArrayOfResourcesContainingCompressedUnicode)[index]&(1<<(aRscIdx%8));
-	}
+	assert(index < iBitArrayOfResourcesContainingCompressedUnicode->GetLength());
+	return (*iBitArrayOfResourcesContainingCompressedUnicode)[index]&(1<<(aRscIdx%8));
+}
 
 
 RResourceFileImpl::RResourceFileImpl() :
 	iResourceContents(NULL),
 	iSizeOfLargestResourceWhenCompletelyUncompressed(0),
-	iIndex(0),
+	iIndex(NULL),
 	iOffset(0),
 	iExtra(NULL),
 	iFlagsAndNumberOfResources(0)
-	{
+{
 	// Fixed class size - because of the BC reasons.
 	// RResourceFileImpl size must be the same as CResourceFile size.
 	enum
@@ -75,7 +121,7 @@
 
 	//Fixed "iOffset" position - because of the BC reasons.
 	assert(offsetof(RResourceFileImpl, iOffset)==12);
-	}
+}
 
 
 RResourceFileImpl::~RResourceFileImpl()
@@ -101,7 +147,15 @@
 	iOffset=0;
 }
 
-
+/** Opens the resource file reader.
+The resource file reader must be opened before reading resources or
+checking the signature of the resource file. 
+@internalComponent
+@param aName File to open as a resource file.
+@param aFileOffset The resource file section offset from the beginning of the file.
+@param aFileSize The resource file section size.
+@leave - The file is corrupted.
+*/
 void RResourceFileImpl::OpenL(
 						  const std::string& aName, 
 						  TUint32 aFileOffset, 
@@ -156,29 +210,49 @@
 }
 
 
-Ptr8* RResourceFileImpl::GetDecompressedResourceDataL(
-													const TInt& aResourceIndex,			
-													const TUint32& aFlags) 
-	{
-	const TInt positionOfResourceData= iIndex[aResourceIndex];
-	const TInt numberOfBytes= iIndex[aResourceIndex+1]-positionOfResourceData;
-	
-	assert(numberOfBytes >= 0);
-	
-	Ptr8* outputResourceData=new Ptr8(numberOfBytes);
-	ReadL(aFlags, positionOfResourceData, outputResourceData->GetPtr(), numberOfBytes);
-	outputResourceData->UpdateLength(numberOfBytes);
-	
-	return outputResourceData;
-	}
+/** 
+Retrieve the UID tuple of the opened resource file.
+
+@internalComponent
+@pre OpenL() has been called successfully.
+@return The UIDs of the loaded resource file.
+*/
+TUidType RResourceFileImpl::UidType() const
+{
+	assert(iExtra!=NULL);
+	return iExtra->iUidType;
+}
+
+/** Reads a resource into a heap buffer, returns a pointer to that
+buffer.
 
+A heap buffer of appropriate length is allocated for the resource.
+Ownership of the heap buffer passes to the caller who must destroy
+it. The search for the resource uses the following algorithm:A
+resource id in the range 1 to 4095 is looked up in this resource file.
+The function leaves if there is no matching resource.If the resource
+id is greater than 4095, then the most significant 20 bits of the
+resource id is treated as an offset and the least significant 12 bits
+is treated as the real resource id. If the offset matches the offset
+value defined for this file, then the resource is looked up in this
+resource file using the real resource id (i.e. the least significant
+12 bits). If the offset does not match, then the function leaves.Note,
+do not call this function until a call to
+ConfirmSignatureL() has completed successfully.
 
+@internalComponent
+@pre OpenL() is called.
+@param aResourceId The numeric id of the resource to be read.
+@return Pointer to a heap buffer containing the resource.
+@panic Some BAFL panic codes, if the file is corrupted.
+@leave - The file is corrupted.
+@leave - There is no resource with aResourceId in the file.
+*/
 Ptr8* RResourceFileImpl::AllocReadL(const TInt& aResourceId) 
-	{
-	
+{
 	// Check if the resource id is present in the RSC file
 	if (!OwnsResourceId(aResourceId))
-		{
+	{
 		std::ostringstream errDispStream;
 		
 		errDispStream<<"Resource ID:";
@@ -186,44 +260,105 @@
 		errDispStream<<" is not present in the RSC file";
 		
 		throw CResourceFileException(errDispStream.str());
-		}
+	}
 	
 	//"-1" because the first resource has ID 0x*****001 (not 0x*****000)
 	TInt resourceIndex= (aResourceId & EIdBits)-1; 
-	assert(resourceIndex>=0);
 	
-	Ptr8* decompressedResourceData= 
-		GetDecompressedResourceDataL(
-								resourceIndex,
-								iFlagsAndNumberOfResources & static_cast<TUint32>(EAllFlags));
-	
-	// Return the resource data if its not unicode compressed.
-	if (!iExtra->ContainsCompressedUnicode(resourceIndex))
+	if (iFlagsAndNumberOfResources & EFlagGenerate_RSS_SIGNATURE_ForFirstUserResource)
+	{
+		assert(iFlagsAndNumberOfResources & EFlagDictionaryCompressed);
+		assert(iFlagsAndNumberOfResources & EFlagThirdUidIsOffset);
+		
+		if (resourceIndex>0)
+		{
+			--resourceIndex;
+		}
+		else
 		{
-		return decompressedResourceData;
+			assert(resourceIndex==0);
+
+			Ptr8* resourceDataFor_RSS_SIGNATURE = new Ptr8(8);
+			if(NULL==resourceDataFor_RSS_SIGNATURE || NULL==resourceDataFor_RSS_SIGNATURE->GetPtr())
+			{
+				std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+				throw CResourceFileException(errMsg);
+			}
+
+			resourceDataFor_RSS_SIGNATURE->SetLength(8);
+			TUint* wordPointer=REINTERPRET_CAST(TUint*,CONST_CAST(TUint8*,resourceDataFor_RSS_SIGNATURE->GetPtr()));
+
+			wordPointer[0]=4;
+			wordPointer[1]=((iExtra->iUidType[2].iUid << 12) | 1);
+			return resourceDataFor_RSS_SIGNATURE;
 		}
+	}
 	
-	// Get the decompressed unicode data.
-	Ptr8* finalResourceData= DecompressUnicodeL(decompressedResourceData);	
+
+	const TBool firstResourceIsGenerated=
+		(iFlagsAndNumberOfResources & 
+		EFlagFirstResourceIsGeneratedBitArrayOfResourcesContainingCompressedUnicode);
+	if (firstResourceIsGenerated)
+	{
+		assert(iFlagsAndNumberOfResources & EFlagDictionaryCompressed);
+		//dictionary-compressed resource files can have an automatically generated 
+		//resource which is the bit-array of resources containing compressed Unicode 
+		//(this automatically generated resource does not have a corresponding bit for 
+		//itself in the bit-array as it would be self-referring...)
+		++resourceIndex; 
+	}
 	
-	delete decompressedResourceData;	
-	return finalResourceData;	
+	assert(resourceIndex>=0);
+
+	Ptr8* const dictionaryDecompressedResourceData = DictionaryDecompressedResourceDataL(resourceIndex,
+						iFlagsAndNumberOfResources & static_cast<TUint>(EAllFlags),	
+						iExtra->iDictionaryCompressionData,	
+						iIndex);
+
+	// Return the resource data if its not unicode compressed.
+	if (!iExtra->ContainsCompressedUnicode(resourceIndex,firstResourceIsGenerated))
+	{
+		return dictionaryDecompressedResourceData;
 	}
+		
+	Ptr8* const finalResourceData=DecompressUnicodeL(dictionaryDecompressedResourceData);
 
+	delete dictionaryDecompressedResourceData;
+	return finalResourceData;
+	
+}
 
+/** The method will decompress the unicode data (aInputResourceData argument), allocate enough
+memory from the heap for the decompressed data, copy the data there and return a buffer
+to the decompressed data.
+
+The method doesn't own the allocated heap memory for the decompressed data. It's a caller
+responsibility to deallocate the allocated memory.
+
+@internalComponent
+@param aInputResourceData Compressed data.
+@pre OpenL() is called.
+@leave - The file is corrupted.
+@leave - There is not enough memory for the decompressed data.
+*/
 Ptr8* RResourceFileImpl::DecompressUnicodeL(const Ptr8* aInputResourceData) const
-	{
+{
 	const TInt numberOfBytesInInput= aInputResourceData->GetLength();
 	assert(iSizeOfLargestResourceWhenCompletelyUncompressed>0);
 							
 	Ptr8* outputResourceData= new Ptr8(iSizeOfLargestResourceWhenCompletelyUncompressed);
+	if(NULL==outputResourceData || NULL==outputResourceData->GetPtr())
+	{
+		std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+		throw CResourceFileException(errMsg);
+	}
 	
 	const TUint8* input= aInputResourceData->GetPtr();
 	TInt index=0;
 	
 	TBool decompressRun=ETrue;
 	while (1)
-		{
+	{
 		assert(index<numberOfBytesInInput);
 		
 		TInt runLength=input[index];
@@ -233,63 +368,59 @@
 		// with the most significant bit of the first byte set to non-zero 
 		//to indicate that the run-length occupies two bytes.
 		if (runLength & 0x80)
-			{
+		{
 			++index;
 			if (index>=numberOfBytesInInput)
-				{
+			{
 				std::string errMsg="Invalid Rsc File";
 				throw CResourceFileException(errMsg);
-				}
+			}
 			runLength &= ~0x80;
 			runLength <<= 8;
 			runLength |= input[index];
-			}
+		}
 		++index;
 		if (runLength>0)
-			{			
+		{			
 			if (decompressRun)
-				{
+			{
 				AppendDecompressedUnicodeL(
 										outputResourceData,				
 										const_cast<unsigned char *>(input+index),
 										runLength);
-				}
+			}
 			else
-				{
+			{
 				assert(
 					(outputResourceData->GetLength() + runLength) <= 
 					iSizeOfLargestResourceWhenCompletelyUncompressed);
 				
 				memcpy((char*)(outputResourceData->GetPtr()+outputResourceData->GetLength()),(char*)(input+index),runLength);				
 				outputResourceData->UpdateLength(runLength);
-				}
+			}
 			index+=runLength;
-			}
+		}
 		if (index>numberOfBytesInInput)
-			{
+		{
 			std::string errMsg="Invalid Rsc File";
 			throw CResourceFileException(errMsg);
-			}
+		}
 		if (index>=numberOfBytesInInput)
-			{
+		{
 			break;
-			}
+		}
 			decompressRun=!decompressRun;
-		}	
+	}	
 	return outputResourceData;
-	}
-
+}
 
 
 /** @internalComponent
 @return The first resource record.
-@panic Some BAFL panic codes, if the file is corrupted.
-@leave KErrCorrupt The file is corrupted.
-Some other error codes are possible too.
-The method could panic or leave depending on the state of
-iAssertObj member of RResourceFileImpl::TExtra class. */
+@leave - The file is corrupted.
+*/
 RResourceFileImpl::SSigRecord RResourceFileImpl::FirstRecordL() const
-	{
+{
 	// Added to support reading of rel 6.x resource files.
 	// rel 6.x files do not have signatures!
 	Ptr8* const firstResource=AllocReadL(1);
@@ -312,19 +443,13 @@
 two 32-bit integers. The first integer contains the version number and
 the second is a self-referencing link whose value is the offset for
 the resources in the file, plus 1.This function must be called before
-calling Offset(), AllocReadL(), AllocReadLC() or ReadL().
+calling Offset(), AllocReadL() or ReadL().
 
-@see Offset()
-@see AllocReadL()
-@see AllocReadLC() 
-@see ReadL()
 @internalComponent
 @pre OpenL() is called.
-@panic Some BAFL panic codes, if the file is corrupted.
-@leave KErrCorrupt The file is corrupted.
+@leave if the file is corrupted.
 Some other error codes are possible too.
-The method could panic or leave depending on the state of
-iAssertObj member of RResourceFileImpl::TExtra class. */
+*/
 void RResourceFileImpl::ConfirmSignatureL()
 {
 	// Added to support reading of rel 6.x resource files.
@@ -340,23 +465,33 @@
 	iOffset=(firstRecord.offset & EOffsetBits);
 }
 
+/** The method will decomress the unicode data (aCompressedUnicode argument) and append
+the decompressed data to the end of aBuffer (aBuffer argument).
+
+@internalComponent
+@pre OpenL() is called.
+@param aBuffer Destination buffer.
+@param aCompressedUnicode Compressed unicode buffer.
+@leave - The file is corrupted.
+*/
+
 void RResourceFileImpl::AppendDecompressedUnicodeL(
 												   Ptr8* aBuffer,
 												   const TUint8*  aCompressedUnicode,
 												   const TInt& aLengthOfCompressedUnicode) const
+{
+
+	if (aLengthOfCompressedUnicode>0)
 	{
-	
-	if (aLengthOfCompressedUnicode>0)
-		{
 		TUint8* startOfDecompressedUnicode= aBuffer->GetPtr() + aBuffer->GetLength();
 		
 		if (reinterpret_cast<TUint32>(startOfDecompressedUnicode) & 0x01)
-			{			
+		{			
 			TUint8 padChar = 0xab;
 			memcpy(startOfDecompressedUnicode,&padChar,1);
 			++startOfDecompressedUnicode;
 			aBuffer->UpdateLength(1);
-			}
+		}
 		
 		const TInt maximumOutputLength= (
 			iSizeOfLargestResourceWhenCompletelyUncompressed - (aBuffer->GetLength()))/2; 
@@ -379,15 +514,28 @@
 		aBuffer->UpdateLength(lengthOfDecompressedUnicode*2);
 		
 		assert(numberOfInputBytesConsumed == aLengthOfCompressedUnicode);		
-		}
 	}
+}
 
+/** Tests whether the resource file owns the specified resource id.
+
+The resource file owns the resource id if the most significant 20 bits
+of the resource id are zero or match the offset value as returned from
+a call to the Offset() member function or if the resource id is not out of range.
+
+@internalComponent
+@pre OpenL() is called.
+@param aResourceId The resource id to test.
+@return True, if the resource file owns the id, false otherwise.
+@leave - The file is corrupted.
+*/
 
 TBool RResourceFileImpl::OwnsResourceId(const TInt& aResourceId) const
-	{ 
+{ 
 	// Checks whether Rsc file owns the resource:
 	// does so if offset is 0, or matches that given, 
 	// and id is in index.
+
 	const TInt offset=(aResourceId & EOffsetBits);
 //	if ((offset!=0) && (offset!=iOffset))
 //		{
@@ -396,17 +544,27 @@
 	
 	const TInt resourceIndex=(aResourceId & EIdBits)-1;
 	TInt numberOfResources=(iFlagsAndNumberOfResources & ~EAllFlags);
-	
-	return (resourceIndex >= 0) && (resourceIndex < numberOfResources);
+	if (iFlagsAndNumberOfResources & EFlagGenerate_RSS_SIGNATURE_ForFirstUserResource)
+	{
+		assert(iFlagsAndNumberOfResources & EFlagDictionaryCompressed);
+		assert(iFlagsAndNumberOfResources & EFlagThirdUidIsOffset);
+		++numberOfResources;
 	}
-
+	if (iFlagsAndNumberOfResources & 
+		EFlagFirstResourceIsGeneratedBitArrayOfResourcesContainingCompressedUnicode)
+	{
+		assert(iFlagsAndNumberOfResources & EFlagDictionaryCompressed);
+		--numberOfResources;
+	}
+	return (resourceIndex >= 0) && (resourceIndex < numberOfResources);
+}
 
-void RResourceFileImpl::ReadL(
+TInt RResourceFileImpl::ReadL(
 							const TUint32& aFlags, 
 							TInt aPos,
 							TUint8* aData,
 							const TInt& aLength) 
-	{
+{
 	aPos += iExtra->iFileOffset;
 	
 	assert(aPos >= iExtra->iFileOffset);
@@ -415,125 +573,557 @@
 	
 	// Seek to the offset specified by "aPos"
 	iResourceContents->seekg(aPos, std::ios_base::beg);
-	iResourceContents->read((char*)aData, aLength);		
-	}
+	iResourceContents->read((char*)aData, aLength);	
+	return iResourceContents->gcount();
+}
 
 
-void RResourceFileImpl::ReadL(TInt aPos, TUint8* aData, const TInt& aLength) 
-	{
-	ReadL(iFlagsAndNumberOfResources & static_cast<TUint32>(EAllFlags),aPos,aData,aLength);
-	}
+TInt RResourceFileImpl::ReadL(TInt aPos, TUint8* aData, const TInt& aLength) 
+{
+	return ReadL(iFlagsAndNumberOfResources & static_cast<TUint32>(EAllFlags),aPos,aData,aLength);
+}
 
 
 TInt RResourceFileImpl::LittleEndianTwoByteInteger(
-													TUint8* aBuffer,
-													const TInt& aIndexOfFirstByte) const
-	{
+													const TUint8* aBuffer,
+													const TInt& aIndexOfFirstByte, TInt aLength) const
+{
+	assert((aIndexOfFirstByte + 1) < aLength);
 	return aBuffer[aIndexOfFirstByte] | (aBuffer[aIndexOfFirstByte+1]<<8);
-	}
+}
 
 
-void RResourceFileImpl::ReadHeaderAndResourceIndexL()
-	{
+/** Function to retrieve the header information of the rsc file and all the
+	resource index information in the rsc file. This function is created to
+	handle the common functionality in the two OpenL() method.
+@internalComponent
+@pre OpenL() is called.
+*/
 	
-	// Unicode compressed RSC file will have 19 bytes header.
-	const TUint8 kHeaderSize= 19;
-	TUint8 header[kHeaderSize];
-			
-	sTUid uid;
-	
-	// Verify the header of the RSC file.
-	if(iExtra->iFileSize >= kHeaderSize)
-		{
+void RResourceFileImpl::ReadHeaderAndResourceIndexL()
+{
+	SDictionaryCompressionData dictionaryCompressionData;
 		
-		// Get the RSC header
-		ReadL(0,0,header,kHeaderSize);
-		// Get the first UID
-		memcpy((TUint8*)&uid.iUid1,header,4);
-		
-		// First uid of unicode compressed RSC is "0x101f4a6b"
-		TUint32 unicodeCompressedFirstUid = 0x101f4a6b;
-		
-		if (uid.iUid1 == unicodeCompressedFirstUid)
+	TUidType uidType;
+	TInt length =0;
+	//dictionary-compressed resource files have a 21-byte header, 
+	//16 bytes of checked UIDs followed by a 1-byte field and two 2-byte fields
+	TUint8 header[21];
+	if(iExtra->iFileSize >= 16)
+	{
+		length = ReadL(0,header,Min((sizeof(header)/sizeof(header[0])),iExtra->iFileSize));
+		uidType=TCheckedUid(header, 16).UidType();
+
+		if (uidType[0].iUid==0x101f4a6b)
+		{
+			iFlagsAndNumberOfResources |= EFlagPotentiallyContainsCompressedUnicode;
+			assert(length >= 18);
+			iSizeOfLargestResourceWhenCompletelyUncompressed = LittleEndianTwoByteInteger(header,16+1,length);
+		}
+		else if (uidType[0].iUid==0x101f5010)
+		{
+			iFlagsAndNumberOfResources |=
+					EFlagPotentiallyContainsCompressedUnicode | EFlagDictionaryCompressed;
+			assert(length >= 18);
+			iSizeOfLargestResourceWhenCompletelyUncompressed = LittleEndianTwoByteInteger(header,16+1,length);
+		}
+		else if (uidType[0]!=TUid::Null())
+		{
+			std::string errMsg="Failed : Not Supported. Invalid Registration File.";
+			throw CResourceFileException(errMsg);
+		}
+		//the "signature" of Calypso's resource files
+		else if (LittleEndianTwoByteInteger(header,0,length)==4) 
+		{
+			iFlagsAndNumberOfResources |= EFlagDictionaryCompressed | EFlagCalypsoFileFormat;
+			iSizeOfLargestResourceWhenCompletelyUncompressed = LittleEndianTwoByteInteger(header,8,length);
+		}
+	}
+	
+	//It seems that the following AssertDebL() call never fails, 
+	//because LittleEndianTwoByteIntegerL always 
+	//returns zero or positive value.
+	assert(iSizeOfLargestResourceWhenCompletelyUncompressed>=0);
+	TInt numberOfResources=0;
+	Ptr8* bitArrayOfResourcesContainingCompressedUnicode=NULL;
+	if (iFlagsAndNumberOfResources & EFlagDictionaryCompressed)
+	{
+		if (iFlagsAndNumberOfResources & EFlagCalypsoFileFormat)
+		{
+			assert(length > 10);
+			numberOfResources=LittleEndianTwoByteInteger(header,2,length);
+			const TInt numberOfBitsUsedForDictionaryTokens = header[10];
+			const TInt numberOfDictionaryEntries =
+					(1 << numberOfBitsUsedForDictionaryTokens) - header[5];
+			assert(numberOfDictionaryEntries >= 0);
+			// "+2" because the first entry in the dictionary-index in this file format 
+			//is the number of bits from the start of the dictionary data to the start 
+			//of the first dictionary entry which is always zero, and thus unnecessary
+			const TInt startOfDictionaryData=4+7+2; 
+			// "+2" because the first entry in the resource-index in this file format is 
+			//the number of bits from the start of the resource data to the start of the 
+			//first resource which is always zero, and thus unnecessary
+			const TInt startOfResourceIndex=LittleEndianTwoByteInteger(header,6,length)+2; 
+			assert(startOfResourceIndex >= 0);
+			dictionaryCompressionData.iStartOfDictionaryData=
+							startOfDictionaryData+(numberOfDictionaryEntries*2);
+			dictionaryCompressionData.iStartOfDictionaryIndex=startOfDictionaryData;
+			dictionaryCompressionData.iNumberOfDictionaryEntries=numberOfDictionaryEntries;
+			dictionaryCompressionData.iStartOfResourceData=
+							startOfResourceIndex+(numberOfResources*2);
+			dictionaryCompressionData.iStartOfResourceIndex=startOfResourceIndex;
+			dictionaryCompressionData.iNumberOfBitsUsedForDictionaryTokens=
+							numberOfBitsUsedForDictionaryTokens;
+			
+			if ((iFlagsAndNumberOfResources & static_cast<TUint>(EFlagIsRomFile)) == 0)
 			{
-			iFlagsAndNumberOfResources |= EFlagPotentiallyContainsCompressedUnicode;
-			iSizeOfLargestResourceWhenCompletelyUncompressed=	LittleEndianTwoByteInteger(header,16+1);
+				// attempt to cache dictionary index
+				// allocate and populate the dictionary index buffer
+				dictionaryCompressionData.iCachedDictionaryIndex = new TUint16[numberOfDictionaryEntries];
+				if (dictionaryCompressionData.iCachedDictionaryIndex != 0)
+				{
+					TInt len = numberOfDictionaryEntries * 2;
+
+					Ptr8* ptr8 = new Ptr8(numberOfDictionaryEntries * 2);
+					if(NULL==ptr8 || NULL==ptr8->GetPtr())
+					{
+						std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+						throw CResourceFileException(errMsg);
+					}
+					ptr8->UpdateLength(numberOfDictionaryEntries * 2);
+					ReadL(
+						iFlagsAndNumberOfResources & static_cast<TUint>(EAllFlags), 	// aFlags
+						startOfDictionaryData,											// aPos
+						(TUint8*)ptr8->GetPtr(),
+						len);															// aLength
+
+					memcpy((TUint8*)dictionaryCompressionData.iCachedDictionaryIndex, ptr8->GetPtr(), len);
+					if(NULL != ptr8)
+					{
+						delete ptr8;
+					}
+				}
+			}	// if (iFlagsAndNumberOfResources & EFlagIsRomFile)
+		}
+		else
+		{
+			assert(length==16+1+2+2);
+			const TUint firstByteAfterUids=header[16];
+			if (firstByteAfterUids & 0x80)
+			{
+				// this flag is only set if the resource file is dictionary-compressed
+				iFlagsAndNumberOfResources |= EFlagThirdUidIsOffset; 
 			}
-		else
+			if (firstByteAfterUids & 0x40)
+			{
+				// this flag is only set if the resource file is dictionary-compressed
+				iFlagsAndNumberOfResources |= EFlagGenerate_RSS_SIGNATURE_ForFirstUserResource; 
+			}
+			if (firstByteAfterUids & 0x20)
 			{
-				if (iResourceContents->is_open())
-						iResourceContents->close();
-			std::string errMsg="Failed : Unsupported RSC file type";
-			throw CResourceFileException(errMsg);
+				iFlagsAndNumberOfResources |=
+					EFlagFirstResourceIsGeneratedBitArrayOfResourcesContainingCompressedUnicode;
+			}
+			dictionaryCompressionData.iStartOfResourceData =	LittleEndianTwoByteInteger(header,16+1+2,length);
+			TUint8 temp[2];
+			length = ReadL((iExtra->iFileSize)-2,temp,2);
+	
+			const TInt numberOfBitsOfResourceData = LittleEndianTwoByteInteger(temp,0,length);
+			dictionaryCompressionData.iStartOfResourceIndex=
+						dictionaryCompressionData.iStartOfResourceData+
+						((numberOfBitsOfResourceData+7)/8);
+			numberOfResources=(iExtra->iFileSize-dictionaryCompressionData.iStartOfResourceIndex)/2;
+			dictionaryCompressionData.iStartOfDictionaryData=16+5;
+			if ((numberOfResources>0) && 
+				!(iFlagsAndNumberOfResources &
+				EFlagFirstResourceIsGeneratedBitArrayOfResourcesContainingCompressedUnicode))
+			{
+				const TInt lengthOfBitArrayInBytes=(numberOfResources+7)/8;
+				bitArrayOfResourcesContainingCompressedUnicode=	new Ptr8(lengthOfBitArrayInBytes);
+				if(NULL==bitArrayOfResourcesContainingCompressedUnicode || NULL==bitArrayOfResourcesContainingCompressedUnicode->GetPtr())
+				{
+					std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+					throw CResourceFileException(errMsg);
+				}
+				bitArrayOfResourcesContainingCompressedUnicode->UpdateLength(lengthOfBitArrayInBytes);
+				TUint8* asWritable = bitArrayOfResourcesContainingCompressedUnicode->GetPtr();
+				ReadL(16+5,asWritable,lengthOfBitArrayInBytes);
+				dictionaryCompressionData.iStartOfDictionaryData+=lengthOfBitArrayInBytes;
+			}
+			length = ReadL(dictionaryCompressionData.iStartOfResourceData-2,temp,2);
+			const TInt numberOfBitsOfDictionaryData=LittleEndianTwoByteInteger(temp,0,length);
+			dictionaryCompressionData.iStartOfDictionaryIndex=
+						dictionaryCompressionData.iStartOfDictionaryData+
+						((numberOfBitsOfDictionaryData+7)/8);
+			dictionaryCompressionData.iNumberOfDictionaryEntries=
+						(dictionaryCompressionData.iStartOfResourceData-
+						dictionaryCompressionData.iStartOfDictionaryIndex)/2;
+			//the bottom 3 bits of firstByteAfterUids stores the number of bits used for 
+			//dictionary tokens as an offset from 3, e.g. if 2 is stored in these three bits 
+			//then the number of bits per dictionary token would be 3+2=5 - this allows a 
+			//range of 3-11 bits per dictionary token (the maximum number of dictionary 
+			//tokens therefore ranging from 8-2048) - the spec currently only supports 5-9
+			//bits per dictionary token, however
+			dictionaryCompressionData.iNumberOfBitsUsedForDictionaryTokens=
+						3 + (firstByteAfterUids & 0x07); 
+			if ((numberOfResources>0) && 
+				(iFlagsAndNumberOfResources &
+				EFlagFirstResourceIsGeneratedBitArrayOfResourcesContainingCompressedUnicode))
+			{
+				Ptr16* nulldesc = new Ptr16(1);
+				if(NULL==nulldesc || NULL==nulldesc->GetPtr())
+				{
+					std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+					throw CResourceFileException(errMsg);
+				}
+				*(nulldesc->GetPtr()) = 0;
+				nulldesc->UpdateLength(0);
+				
+				bitArrayOfResourcesContainingCompressedUnicode=
+				DictionaryDecompressedResourceDataL(
+											0,
+											iFlagsAndNumberOfResources & static_cast<TUint>(EAllFlags),
+											dictionaryCompressionData,
+											nulldesc);
+				if(NULL != nulldesc)
+				{
+					delete nulldesc;
+				}
 			}
 		}
-		
-		TInt numberOfResources= 0;
-		TUint8* bitArrayOfResourcesContainingCompressedUnicode= NULL;
-		
-		if (iFlagsAndNumberOfResources & EFlagPotentiallyContainsCompressedUnicode)
+	}
+	else
+	{
+		assert((iExtra->iFileSize + iExtra->iFileOffset) > 2);
+		// This format of resource file is likely to be used for non-ROM resource files, 
+		//so cache the resource-index (in iIndex) to minimize disk access.
+		// Ignore the flags in non-dictionary-compressed resource files - they are to 
+		//be used only by a dictionary-compressing program. 
+		const TInt KMaximumNumberOfBytesCached=256;
+		TUint8 cache[KMaximumNumberOfBytesCached];
+		const TInt numberOfBytesCached=Min(iExtra->iFileSize,KMaximumNumberOfBytesCached);
+		TInt len = ReadL(iExtra->iFileSize-numberOfBytesCached,cache,numberOfBytesCached);
+		assert(len==numberOfBytesCached);
+		const TInt positionOfStartOfIndex=
+					((cache[numberOfBytesCached-1]<<8) | cache[numberOfBytesCached-2]);
+		const TInt numberOfBytesOfIndex=iExtra->iFileSize-positionOfStartOfIndex;
+		assert(numberOfBytesOfIndex%2==0);
+		assert(numberOfBytesOfIndex>=0);
+		const TInt numberOfBytesOfIndexStillToRetrieve=
+					numberOfBytesOfIndex-numberOfBytesCached;
+		if (numberOfBytesOfIndexStillToRetrieve<=0)
 		{
-			// Cache the resource-index (in iIndex) to minimize disk access.		
-			const TInt KMaximumNumberOfBytesCached= 256;
-			TUint8 cache[KMaximumNumberOfBytesCached];
-			const TInt numberOfBytesCached=
-				((iExtra->iFileSize>KMaximumNumberOfBytesCached) ? KMaximumNumberOfBytesCached : iExtra->iFileSize);
-			
-			ReadL(iExtra->iFileSize-numberOfBytesCached, cache, numberOfBytesCached);
-			
-			const TInt positionOfStartOfIndex=
-				((cache[numberOfBytesCached-1]<<8) | cache[numberOfBytesCached-2]);
-			const TInt numberOfBytesOfIndex=iExtra->iFileSize-positionOfStartOfIndex;
-			
-			assert(numberOfBytesOfIndex%2==0);
-			assert(numberOfBytesOfIndex>=0);
-			
-			const TInt numberOfBytesOfIndexStillToRetrieve = numberOfBytesOfIndex-numberOfBytesCached;
+			Ptr8* indexAsBinaryBuffer = new Ptr8(numberOfBytesOfIndex); 
+			if(NULL==indexAsBinaryBuffer || NULL==indexAsBinaryBuffer->GetPtr())
+			{
+				std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+				throw CResourceFileException(errMsg);
+			}
+
+			indexAsBinaryBuffer->UpdateLength(numberOfBytesOfIndex);
+			BufCpy8(indexAsBinaryBuffer->GetPtr(), cache+(numberOfBytesCached - numberOfBytesOfIndex) , numberOfBytesOfIndex);
+
+			iIndex = new Ptr16(numberOfBytesOfIndex/2); 
+			if(NULL==iIndex || NULL==iIndex->GetPtr())
+			{
+				std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+				throw CResourceFileException(errMsg);
+			}
+
+			MemCopy(CONST_CAST(TUint16*,(TUint16*)iIndex->GetPtr()),indexAsBinaryBuffer->GetPtr(),numberOfBytesOfIndex); 
+			iIndex->UpdateLength(numberOfBytesOfIndex/2);
+
+			if(NULL != indexAsBinaryBuffer)
+			{
+				delete indexAsBinaryBuffer;
+			}
+		}
+		else
+		{
+			Ptr16* const index=new Ptr16(numberOfBytesOfIndex/2);
+			if(NULL==index || NULL==index->GetPtr())
+			{
+				std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+				throw CResourceFileException(errMsg);
+			}
+			index->UpdateLength(numberOfBytesOfIndex/2);
+				
+			Ptr8* indexAsWritableBinaryBuffer = new Ptr8(numberOfBytesOfIndex);
+			if(NULL==indexAsWritableBinaryBuffer || NULL==indexAsWritableBinaryBuffer->GetPtr())
+			{
+				std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+				throw CResourceFileException(errMsg);
+			}
+			indexAsWritableBinaryBuffer->UpdateLength(numberOfBytesOfIndexStillToRetrieve);
+				
+			ReadL(positionOfStartOfIndex,indexAsWritableBinaryBuffer->GetPtr(),
+											numberOfBytesOfIndexStillToRetrieve);
+			assert(indexAsWritableBinaryBuffer->GetLength()==numberOfBytesOfIndexStillToRetrieve);
+			indexAsWritableBinaryBuffer->Append(cache, len);
+			indexAsWritableBinaryBuffer->UpdateLength(len);
+			assert(indexAsWritableBinaryBuffer->GetLength()==numberOfBytesOfIndex);
+			assert(indexAsWritableBinaryBuffer->GetLength()==index->GetLength()*2);
+			memcpy((TUint8*)index->GetPtr(), indexAsWritableBinaryBuffer->GetPtr() , numberOfBytesOfIndex);
+	
+			iIndex=index;
+			if(NULL != indexAsWritableBinaryBuffer)
+			{
+				delete indexAsWritableBinaryBuffer;
+			}
+		}
 			
-			if (numberOfBytesOfIndexStillToRetrieve<=0)
-				{
-				iIndex= new TUint16[numberOfBytesOfIndex/2];
-				memcpy(iIndex, cache+(numberOfBytesCached-numberOfBytesOfIndex), numberOfBytesOfIndex);
-				}
-			else
-				{
-				TUint16* index= new TUint16(numberOfBytesOfIndex/2);			
-				ReadL(positionOfStartOfIndex, reinterpret_cast<TUint8*>(index), numberOfBytesOfIndexStillToRetrieve);
-				memcpy((index+numberOfBytesOfIndexStillToRetrieve),cache,numberOfBytesCached); 		
-
-				iIndex=index;			
-				}
-
-			//"-1" because the last thing in the index (which is in fact the last thing in the 
-			//file itself) is the position of the start of the index which is therefore not 
-			//pointing to a resource
-			numberOfResources=(numberOfBytesOfIndex/2) - 1; 
-			
-			if (numberOfResources <= 0)
-				{
-				if (iResourceContents->is_open())
-						iResourceContents->close();
-				std::string errMsg="Failed : Invalid RSC file.";
+		//"-1" because the last thing in the index (which is in fact the last thing in the 
+		//file itself) is the position of the start of the index which is therefore not 
+		//pointing to a resource
+		numberOfResources=(numberOfBytesOfIndex/2) - 1; 
+		if ((numberOfResources>0) && 
+			(iFlagsAndNumberOfResources & EFlagPotentiallyContainsCompressedUnicode))
+		{
+			const TInt lengthOfBitArrayInBytes=(numberOfResources+7)/8;
+			bitArrayOfResourcesContainingCompressedUnicode= new Ptr8(lengthOfBitArrayInBytes);
+			if(NULL==bitArrayOfResourcesContainingCompressedUnicode || NULL==bitArrayOfResourcesContainingCompressedUnicode->GetPtr())
+			{
+				std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
 				throw CResourceFileException(errMsg);
-				}
-				
-			const TInt lengthOfBitArrayInBytes=(numberOfResources+7)/8;
-			bitArrayOfResourcesContainingCompressedUnicode=
-								new TUint8(lengthOfBitArrayInBytes);
-			
+			}
+			bitArrayOfResourcesContainingCompressedUnicode->UpdateLength(lengthOfBitArrayInBytes);
+			TUint8* bitArray = bitArrayOfResourcesContainingCompressedUnicode->GetPtr();
 			//"16+1+2": 16 bytes of checked-UID + 1 byte of flags (these flags are for a 
 			//dictionary-compressing program's use rather than directly for Bafl's use, 
 			//so we ignore them) + 2 bytes containing the size of the largest resource when 
 			//uncompressed
-			ReadL(16+1+2,bitArrayOfResourcesContainingCompressedUnicode,lengthOfBitArrayInBytes); 
+			ReadL(16+1+2,bitArray,lengthOfBitArrayInBytes); 
+		}
+	}
+	assert((numberOfResources & EAllFlags)==0);
+	assert((iFlagsAndNumberOfResources & ~EAllFlags)==0);
+	iFlagsAndNumberOfResources |= (numberOfResources & ~EAllFlags);
+	iExtra->iUidType = uidType;
+	iExtra->iBitArrayOfResourcesContainingCompressedUnicode = bitArrayOfResourcesContainingCompressedUnicode;
+	iExtra->iBitArrayOfResourcesContainingCompressedUnicode->SetLength(bitArrayOfResourcesContainingCompressedUnicode->GetLength());
+	iExtra->iDictionaryCompressionData = dictionaryCompressionData;
+	//iOffset is set by calling ConfirmSignatureL
+	assert(iOffset==0);
+}
+
+
+/** @internalComponent
+@pre OpenL() is called.
+@leave KErrCorrupt The file is corrupted.
+@leave KErrNoMemory There is not enough memory for the decompressed data.
+Some other error codes are possible too.
+*/
+Ptr8* RResourceFileImpl::DictionaryDecompressedResourceDataL(
+			TInt aResourceIndex,
+			TUint aFlags,
+			const SDictionaryCompressionData& aDictionaryCompressionData,
+			const Ptr16* aIndex) const
+{
+	if (aFlags & EFlagDictionaryCompressed)
+	{
+		assert(iSizeOfLargestResourceWhenCompletelyUncompressed>0);
+		Ptr8* const outputResourceData = new Ptr8(iSizeOfLargestResourceWhenCompletelyUncompressed);
+		if(NULL==outputResourceData || NULL==outputResourceData->GetPtr())
+		{
+			std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+			throw CResourceFileException(errMsg);
+		}
+
+		Ptr8* asWritable = outputResourceData;
+		std::vector<RDictionaryCompressionBitStream> stackOfDictionaryCompressionBitStreams;
+		AppendDictionaryCompressionBitStreamL(
+						stackOfDictionaryCompressionBitStreams,
+						aFlags,
+						aDictionaryCompressionData,
+						aDictionaryCompressionData.iStartOfResourceData,
+						aDictionaryCompressionData.iStartOfResourceIndex,
+						aResourceIndex);
+		const TBool calypsoFileFormat=(aFlags & EFlagCalypsoFileFormat);
+		while(1)
+		{
+			const TInt indexOfTopBitStream=stackOfDictionaryCompressionBitStreams.size()-1;
+			assert(indexOfTopBitStream>=-1);
+			if (indexOfTopBitStream<0)
+			{
+				break;
+			}
+			RDictionaryCompressionBitStream& dictionaryCompressionBitStream=
+							stackOfDictionaryCompressionBitStreams[indexOfTopBitStream];
+
+			while(1)
+			{
+				if (dictionaryCompressionBitStream.EndOfStreamL())
+				{
+					dictionaryCompressionBitStream.Close();
+					stackOfDictionaryCompressionBitStreams.erase(indexOfTopBitStream);
+					break;
+				}
+				const TInt indexOfDictionaryEntry=
+								dictionaryCompressionBitStream.IndexOfDictionaryEntryL();
+				if (indexOfDictionaryEntry<0)
+				{
+					dictionaryCompressionBitStream.ReadL(asWritable,calypsoFileFormat);
+				}
+				else
+				{
+					AppendDictionaryCompressionBitStreamL(
+											stackOfDictionaryCompressionBitStreams,
+											aFlags,
+											aDictionaryCompressionData,
+											aDictionaryCompressionData.iStartOfDictionaryData,
+											aDictionaryCompressionData.iStartOfDictionaryIndex,
+											indexOfDictionaryEntry);
+					break;
+				}
+			}
+		}
+		stackOfDictionaryCompressionBitStreams.clear();
+		return outputResourceData;
+	}
+
+	assert(aResourceIndex < aIndex->GetLength());
+
+	const TInt positionOfResourceData=(*aIndex)[aResourceIndex];
+	const TInt numberOfBytes=(*aIndex)[aResourceIndex+1]-positionOfResourceData;
+
+	assert(numberOfBytes >= 0);
+	Ptr8* const outputResourceData= new Ptr8(numberOfBytes);
+	if(NULL==outputResourceData || NULL==outputResourceData->GetPtr())
+	{
+		std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+		throw CResourceFileException(errMsg);
+	}
+
+	TUint8* asWritable = outputResourceData->GetPtr();
+	ReadL(aFlags,positionOfResourceData,asWritable,numberOfBytes);
+	outputResourceData->UpdateLength(numberOfBytes);
 		
-		}
+	return outputResourceData;
 		
-		assert((numberOfResources & EAllFlags)==0);
-		assert((iFlagsAndNumberOfResources & ~EAllFlags)==0);
-		
-		iFlagsAndNumberOfResources |= (numberOfResources & ~EAllFlags);
-		iExtra->iUid = uid;
-		iExtra->iBitArrayOfResourcesContainingCompressedUnicode = bitArrayOfResourcesContainingCompressedUnicode;
+}
+	
+
+void RResourceFileImpl::AppendDictionaryCompressionBitStreamL(
+			std::vector<RDictionaryCompressionBitStream>& aStackOfDictionaryCompressionBitStreams,
+			TUint aFlags,
+			const SDictionaryCompressionData& aDictionaryCompressionData,
+			TInt aStartOfBitData,
+			TInt aStartOfIndex,
+			TInt aIndexEntry) const
+{
+	const TBool isRomFile=(aFlags & static_cast<TUint>(EFlagIsRomFile));
+	TUint8 temp[4];
+	TInt length = 0;
+	assert(aIndexEntry>=0);
+	TInt offsetToFirstBit;
+	TInt offsetOnePastLastBit;
+	if (	aDictionaryCompressionData.iStartOfDictionaryIndex == aStartOfIndex
+		&&	aDictionaryCompressionData.iCachedDictionaryIndex != 0)
+	{
+		assert(!isRomFile);
+		// indices start at 1
+		offsetToFirstBit = (aIndexEntry <= 0)
+			?	0
+			:	aDictionaryCompressionData.iCachedDictionaryIndex[aIndexEntry-1];
+		offsetOnePastLastBit = aDictionaryCompressionData.iCachedDictionaryIndex[aIndexEntry];
+	}
+	else
+	{
+		TInt len = ReadL(aFlags,aStartOfIndex+((aIndexEntry-1)*2),temp,4);
+		offsetToFirstBit=(aIndexEntry > 0) ? LittleEndianTwoByteInteger(temp,0,len) : 0;
+		offsetOnePastLastBit=LittleEndianTwoByteInteger(temp,2,len);
+	}
+	TInt rsc_file_size = iExtra->iFileOffset + iExtra->iFileSize;
+	TInt offset_first = offsetToFirstBit / 8 + iExtra->iFileOffset;
+	assert(offset_first < rsc_file_size);
+	TInt offset_last = offsetOnePastLastBit / 8 + iExtra->iFileOffset;
+	assert(offset_last <= rsc_file_size);
+	TUint8* buffer = NULL;
+	TInt start_pos = 0;
+	if (isRomFile)
+	{
+		TInt startOfBitData = aStartOfBitData + iExtra->iFileOffset;
+		assert(startOfBitData < rsc_file_size);
+		buffer = startOfBitData; 
+	}
+	else
+	{
+		const TInt offsetToByteContainingFirstBit=offsetToFirstBit/8;
+		const TInt offsetToOnePastByteContainingLastBit=((offsetOnePastLastBit-1)/8)+1;
+		const TInt numberOfBytesToLoad=
+							offsetToOnePastByteContainingLastBit-offsetToByteContainingFirstBit;
+		assert(numberOfBytesToLoad >= 0);
+		buffer=new TUint8[numberOfBytesToLoad];
+		if(NULL==buffer)
+		{	
+			std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+			throw CResourceFileException(errMsg);
+		}
+
+		if( iExtra->iDictionaryCompressionData.iCachedResourceBuffer == 0)
+		{
+			iExtra->iDictionaryCompressionData.iCachedResourceBuffer=new TUint8[rsc_file_size]; // reserver buffer for whole file
+			if(NULL==iExtra->iDictionaryCompressionData.iCachedResourceBuffer)
+			{	
+			 	delete buffer; // buffer deleted in RDictionaryCompressionBitStream::close
+				std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+				throw CResourceFileException(errMsg);
+			}
 			
+			Ptr8* JKasWritable = new Ptr8(rsc_file_size); 
+			if(NULL==JKasWritable || NULL == JKasWritable->GetPtr())
+			{	
+			 	delete buffer; // buffer deleted in RDictionaryCompressionBitStream::close
+				std::string errMsg= "Failed : Error in Reading File. Memory Allocation Failed";
+				throw CResourceFileException(errMsg);
+			}
+			JKasWritable->UpdateLength(rsc_file_size);
+
+			try {
+				length = ReadL(0,(TUint8*)JKasWritable->GetPtr(),	rsc_file_size);
+			}
+			catch(...)
+			{
+			 	delete buffer; // buffer deleted in RDictionaryCompressionBitStream::close
+				std::string errMsg= "Failed : Error in Reading File.";
+				throw CResourceFileException(errMsg);
+			}
+
+			BufCpy8(iExtra->iDictionaryCompressionData.iCachedResourceBuffer, JKasWritable->GetPtr(), length);
+			if(NULL != JKasWritable)
+			{
+				delete JKasWritable;
+			}
+		}
+		start_pos = aStartOfBitData + offsetToByteContainingFirstBit + iExtra->iFileOffset;
+		assert(start_pos < rsc_file_size);
+		assert((start_pos + numberOfBytesToLoad) <= rsc_file_size);
+		const TInt numberOfBitsFromStartOfBitDataToFirstLoadedByte=
+											offsetToByteContainingFirstBit*8;
+		offsetToFirstBit-=numberOfBitsFromStartOfBitDataToFirstLoadedByte;
+		offsetOnePastLastBit-=numberOfBitsFromStartOfBitDataToFirstLoadedByte;
+	
+		MemCopy( buffer, iExtra->iDictionaryCompressionData.iCachedResourceBuffer + start_pos,  numberOfBytesToLoad);
 	}
+	RDictionaryCompressionBitStream stream;
+	stream.OpenL(
+				aDictionaryCompressionData.iNumberOfBitsUsedForDictionaryTokens,
+				offsetToFirstBit,
+				offsetOnePastLastBit,
+				!isRomFile,
+				buffer);
+	try {
+		aStackOfDictionaryCompressionBitStreams.push_back(stream);
+	}
+	catch(...)
+	{
+	 	delete buffer; // buffer deleted in RDictionaryCompressionBitStream::close
+		std::string errMsg= "Failed : Error in Reading File.";
+		throw CResourceFileException(errMsg);
+	}
+	if (!isRomFile)
+	{
+		 delete buffer; // buffer deleted in RDictionaryCompressionBitStream::close
+	}
+}
+
--- a/secureswitools/swisistools/source/rscparser/barscimpl.h	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/rscparser/barscimpl.h	Fri May 14 15:58:48 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2009 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"
@@ -26,6 +26,9 @@
 #include <string>
 #include "commontypes.h"
 
+//Forward declarations
+struct SDictionaryCompressionData;
+class RDictionaryCompressionBitStream;
 /** 
 Accesses a resource file and reads the resource data into a buffer.
 It is the implementation class for CResourceFile class.
@@ -76,8 +79,11 @@
 	@param aPos Offset from where to begin reading
 	@param aData Buffer to store read values
 	@param aLength Length of the bytes to be read.
+	@return Length of the bytes to be read.
 	*/
-	void ReadL(TInt aPos,TUint8* aData,const TInt& aLength) ;
+	TInt ReadL(TInt aPos,TUint8* aData,const TInt& aLength);
+
+	TUidType UidType() const;
 
 
 private:
@@ -114,8 +120,9 @@
 	@param aPos Offset from where to begin reading
 	@param aData Buffer to store read values
 	@param aLength Length of the bytes to be read.
+	@return Length of the bytes to be read.
 	*/
-	void ReadL(const TUint32& aFlags, TInt aPos, TUint8* aData, const TInt& aLength);
+	TInt ReadL(const TUint32& aFlags, TInt aPos, TUint8* aData, const TInt& aLength);
 
 	/** @internalComponent
 	@return The first resource record.
@@ -155,6 +162,38 @@
 	@return Pointer to decompressed data 
 	*/
 	Ptr8* DecompressUnicodeL(const Ptr8* aInputResourceData) const;
+
+
+	/**
+	The method will decompress the dictionary compressed data, allocate enough
+	memory from the heap for the decompressed data, copy the data there and return a pointer
+	to the decompressed data.
+	The method doesn't own the allocated heap memory for the decompressed data. It's a caller
+	responsibility to deallocate the allocated memory.
+	@pre OpenL() is called.
+	@leave KErrCorrupt The file is corrupted.
+	@leave KErrNoMemory There is not enough memory for the decompressed data.
+	Some other error codes are possible too.
+	*/
+	Ptr8* DictionaryDecompressedResourceDataL(
+								TInt aResourceIndex,
+								TUint aFlags,
+								const SDictionaryCompressionData& aDictionaryCompressionData,
+								const Ptr16* aIndex) const;
+
+
+	/** 
+	The method will decomress the dictionary compressed data (aDictionaryCompressionData argument) and append
+	the decompressed data to the end of std::vector<RDictionaryCompressionBitStream> 
+	(aStackOfDictionaryCompressionBitStreams argument).
+	*/
+	void AppendDictionaryCompressionBitStreamL(
+								std::vector<RDictionaryCompressionBitStream>& aStackOfDictionaryCompressionBitStreams,
+								TUint aFlags,
+								const SDictionaryCompressionData& aDictionaryCompressionData,
+								TInt aStartOfBitData,
+								TInt aStartOfIndex,
+								TInt aIndexEntry) const;
 	
 	/**
 	Get the two bytes(in Little Endian format) from the specified buffer
@@ -163,22 +202,52 @@
            buffer.
 	@return 2-bytes read from the buffer.
 	*/
-	TInt LittleEndianTwoByteInteger(TUint8* aBuffer,const TInt& aIndexOfFirstByte) const;
-	Ptr8* GetDecompressedResourceDataL(
-									const TInt& aResourceIndex,			
-									const TUint32& aFlags);
+	
+	TInt LittleEndianTwoByteInteger(const TUint8* aBuffer,const TInt& aIndexOfFirstByte,TInt aLength) const;
+
 
 private:
 	std::ifstream* iResourceContents;	
 	TInt iSizeOfLargestResourceWhenCompletelyUncompressed;
-	// An array of (unsigned) 16-bit file-positions
-	TUint16* iIndex; 
+	//basically an array of (unsigned) 16-bit file-positions - 
+	//this is only used for non-dictionary-compressed resource files
+	Ptr16* iIndex; 
+
+	//the position of this member in the class is exposed because RResourceFile::Offset() is 
+	//an inline function accessing "iOffset". RResourceFileImpl is an implementation class for
+	//RResourceFile class. The "iOffset" offset from the beginning of the class must be exactly
+	//12 bytes.
 	TInt iOffset; 
 	TExtra* iExtra;
 	TUint32 iFlagsAndNumberOfResources;
 	};
 
 
+struct SDictionaryCompressionData
+	{
+ 	inline SDictionaryCompressionData() :
+		iStartOfDictionaryData(0),
+		iStartOfDictionaryIndex(0),
+		iNumberOfDictionaryEntries(0),
+		iStartOfResourceData(0),
+		iStartOfResourceIndex(0),
+		iNumberOfBitsUsedForDictionaryTokens(0), 
+		iCachedDictionaryIndex(0),
+		iCachedResourceBuffer(0)// = NULL;
+		{
+		}
+	TInt iStartOfDictionaryData;
+	TInt iStartOfDictionaryIndex;
+	TInt iNumberOfDictionaryEntries;
+	TInt iStartOfResourceData;
+	TInt iStartOfResourceIndex;
+	TInt iNumberOfBitsUsedForDictionaryTokens;
+	TUint16* iCachedDictionaryIndex;
+	TUint8* iCachedResourceBuffer;
+	
+	};
+
+
 /** 
 Stores the RSC filesize, offset and the bit-array 
 representing resources containing compressed unicode.
@@ -194,7 +263,7 @@
 	@param aRscIdx Resource Index
 	@return Status of whether the resource is actually present or not.
 	*/
-	TInt32 ContainsCompressedUnicode(const TInt& aRscIdx) const;
+	TInt32 ContainsCompressedUnicode(TInt& aRscIdx, TBool aFirstRscIsGen) const;
 
 private:
 	// Prevent default copy constructor
@@ -204,13 +273,15 @@
 
 public:
 	// RSC file UID
-	sTUid iUid;
+	TUidType iUidType;
 	// An array of bits, one for each resource in the resource file
-	TUint8* iBitArrayOfResourcesContainingCompressedUnicode; 
+	Ptr8* iBitArrayOfResourcesContainingCompressedUnicode;
+	SDictionaryCompressionData iDictionaryCompressionData;
 	// Offset of RSC chunk
 	TInt iFileOffset;	
 	// RSC file size 
 	TUint32 iFileSize;		
 	};
 
+
 #endif//__BARSCIMPL_H__
--- a/secureswitools/swisistools/source/rscparser/barsreadimpl.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/rscparser/barsreadimpl.cpp	Fri May 14 15:58:48 2010 +0300
@@ -251,7 +251,7 @@
 			// to ensure the alignment of Unicode strings within each resource.
 				if(*currentPtr!=0xab)
 				{
-					std::string errMsg= "Failed : Trying to access invalid registrationFile";
+					std::string errMsg= "Failed : Improper alignment of Unicode strings (0xab) within each resource.";
 					throw CResourceFileException(errMsg);
 				}
 			++currentPtr;
--- a/secureswitools/swisistools/source/rscparser/commontypes.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/rscparser/commontypes.cpp	Fri May 14 15:58:48 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2009 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"
@@ -20,6 +20,7 @@
 */
 #include "commontypes.h"
 #include "barsc2.h"
+#include <cassert>
 
 /** 
  Implementation of Class Ptr8
@@ -32,15 +33,23 @@
 }
 
 Ptr8::~Ptr8()
-	{
+{
 	delete iPtr;
 	iPtr=0;
-	}
+}
+
+
+TUint8 Ptr8::operator[](TInt aIndex) const
+{
+	assert(aIndex>=0);
+	return(iPtr[aIndex]);
+
+}
 
 TUint8* Ptr8::GetPtr() const 
-	{
+{
 	return iPtr;
-	}
+}
 
 void Ptr8::SetPtr(TUint8* aPtr)
 {
@@ -55,36 +64,54 @@
 void Ptr8::SetLength(const TUint32& aLength)
 {
 	if ((iLength+aLength) <= iMaxLength)
-		{
+	{
 		iLength = aLength;
 		return 0;
-		}
+	}
 	else
-		{
+	{
 		return 1;	
-		}
+	}
 }
 	
 TBool Ptr8::UpdateLength(const TUint32& aLength) 
-	{
+{
 	// Current length should not increase the 
 	// Max length.
 	if ((iLength+aLength) <= iMaxLength)
-		{
+	{
 		iLength+= aLength;
 		return 0;
-		}
+	}
 	else
-		{
+	{
 		return 1;	
-		}
 	}
+}
 
 TUint32 Ptr8::GetLength() const 
-	{
+{
 	return iLength;
+}
+
+TUint32 Ptr8::GetMaxLength() const 
+{
+	return iMaxLength;
+}
+
+void Ptr8::Append(TUint8* aBuffer, TInt aLen)
+{
+	if ((iLength+aLen) <= iMaxLength)
+	{
+		memcpy(iPtr+iLength,aBuffer, aLen);
+		iLength+= aLen;
 	}
-
+	else
+	{
+		std::string errMsg= "Failed : Cannot Append Beyond Maximum Length";
+		throw CResourceFileException(errMsg);	
+	}
+}
 
 /** 
  Implementation of Class Ptr16
@@ -92,40 +119,51 @@
 
 Ptr16::Ptr16(const TUint32& aSize)
 		:iLength(0), iMaxLength(aSize)		
-	{
-		iPtr= new TUint16[aSize];
-	}
+{
+	iPtr= new TUint16[aSize];
+}
 
 Ptr16::~Ptr16()
-	{
+{
 	delete iPtr;
 	iPtr=0;
-	}
+}
 
 TUint16* Ptr16::GetPtr() const 
-	{
+{
 	return iPtr;
-	}
+}
+
+void Ptr16::SetPtr(TUint16* aPtr)
+{
+	iPtr=aPtr;
+}
+
+TUint16 Ptr16::operator[](TInt aIndex) const
+{
+	assert(aIndex>=0);
+	return(iPtr[aIndex]);
+}
 
 TBool Ptr16::UpdateLength(const TUint32& aLength) 
-	{
+{
 	// Current length should not increase the 
 	// Max length.
 	if ((iLength+aLength) <= iMaxLength)
-		{
+	{
 		iLength+= aLength;
 		return 0;
-		}
+	}
 	else
-		{
+	{
 		return 1;	
-		}
 	}
+}
 
 TUint32 Ptr16::GetLength() const 
-	{
+{
 	return iLength;
-	}
+}
 
 /**
 Implementation of Sructure PtrC8
--- a/secureswitools/swisistools/source/rscparser/commontypes.h	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/rscparser/commontypes.h	Fri May 14 15:58:48 2010 +0300
@@ -1,4 +1,4 @@
-// Copyright (c) 2009 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"
@@ -26,6 +26,57 @@
 #include <vector>
 using namespace std;
 using namespace rscparser;
+
+/** 
+Returns the smaller of two values.
+ 
+@param aLeft  The first value to be compared.
+@param aRight The second value to be compared.
+
+@return The smaller value.
+*/
+template <class T>
+inline T Min(T aLeft,T aRight)
+    {return(aLeft<aRight ? aLeft : aRight);}
+
+/**
+Returns the smaller of two objects, where the right hand object is a treated
+as a TInt for the  purpose of comparison.
+
+@param aLeft  The first value to be compared.
+@param aRight The second value to be compared.
+
+@return The smaller value.
+*/
+template <class T>
+inline T Min(T aLeft,TUint aRight)
+    {return(aLeft<(TInt)aRight ? aLeft : (T)aRight);}
+
+/** 
+Returns the larger of two values.
+
+@param aLeft  The first value to be compared.
+@param aRight The second value to be compared.
+
+@return The larger value.
+*/
+template <class T>
+inline T Max(T aLeft,T aRight)
+    {return(aLeft<aRight ? aRight : aLeft);}
+
+/**
+Returns the larger of two objects, where the right hand object is a treated
+as a TInt for the  purpose of comparison.
+
+@param aLeft  The first value to be compared.
+@param aRight The second value to be compared.
+
+@return The larger value.
+ */
+template <class T>
+inline T Max(T aLeft,TUint aRight)
+    {return(aLeft<(TInt)aRight ? (TInt)aRight : aLeft);}
+
 /**
 Class to allocate heap memory and store a pointer to it 
 for unicode data.
@@ -75,6 +126,15 @@
 	*/
 	TUint32 GetLength() const;
 
+	/**
+	To fetch the Max length
+	*/
+	TUint32 GetMaxLength() const;
+
+ 	TUint8 operator[](TInt anIndex) const;
+
+	void Append(TUint8* aBuffer, TInt aLen);
+
 private:
 	TUint8* iPtr;
 	TUint32 iLength;
@@ -110,6 +170,11 @@
 	TUint16* GetPtr() const;
 
 	/**
+	Set the pointer
+	*/
+	void SetPtr(TUint16* aPtr);
+
+	/**
 	Update the length of the current pointer
 	with the length provided
 	@param aLength Length to be updated
@@ -121,6 +186,8 @@
 	*/
 	TUint32 GetLength() const;
 
+ 	TUint16 operator[](TInt anIndex) const;
+
 private:
 	TUint16* iPtr;
 	TUint32 iLength;
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/secureswitools/swisistools/source/rscparser/dictionarycompression.cpp	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,170 @@
+// 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:
+// dictionarycompression.cpp
+//
+/** 
+* @file dictionarycompression.cpp
+*
+* @internalComponent
+* @released
+*/
+
+#include "dictionarycompression.h"
+
+RDictionaryCompressionBitStream::RDictionaryCompressionBitStream() :
+	iNumberOfBitsUsedForDictionaryTokens(0),
+	iOffsetToFirstBit(-1),
+	iOffsetToCurrentBit(-1),
+	iOffsetOnePastLastBit(-1),
+	iOwnsBitBuffer(false),
+	iBuffer(NULL)
+	{
+	}
+
+void RDictionaryCompressionBitStream::OpenL(
+				TInt aNumberOfBitsUsedForDictionaryTokens,
+				TInt aOffsetToFirstBit,
+				TInt aOffsetOnePastLastBit,
+				TBool aTransferringOwnershipOfBuffer,
+				TUint8* aBuffer)
+	{
+	iNumberOfBitsUsedForDictionaryTokens = aNumberOfBitsUsedForDictionaryTokens;
+	iOffsetToFirstBit = aOffsetToFirstBit;
+	iOffsetToCurrentBit = aOffsetToFirstBit;
+	iOffsetOnePastLastBit = aOffsetOnePastLastBit;
+	iOwnsBitBuffer = aTransferringOwnershipOfBuffer;
+	iBuffer = aBuffer;
+
+	assert(aBuffer!=NULL);
+	assert(aOffsetToFirstBit >= 0);
+	assert(aOffsetToFirstBit<=aOffsetOnePastLastBit);
+	}
+
+void RDictionaryCompressionBitStream::Close()
+	{
+	if (iOwnsBitBuffer)
+		{
+		iOwnsBitBuffer=EFalse;
+		delete [] iBuffer;
+		}
+	iBuffer=NULL;
+	}
+
+TBool RDictionaryCompressionBitStream::EndOfStreamL() const
+	{
+	assert(iBuffer!=NULL);
+	assert(iOffsetToFirstBit >= 0);
+	assert(iOffsetToCurrentBit>=iOffsetToFirstBit);
+	assert(iOffsetToCurrentBit<=iOffsetOnePastLastBit);
+	return iOffsetToCurrentBit>=iOffsetOnePastLastBit;
+	}
+
+TInt RDictionaryCompressionBitStream::IndexOfDictionaryEntryL()
+	{
+	// increments the current bit-position if it returns a value >=0; returns KErrNotFound if the next thing in the stream is plain data rather than the index of a dictionary entry
+	assert(iBuffer!=NULL);
+	assert(!EndOfStreamL());
+	if (!CurrentBitIsOn())
+		{
+		++iOffsetToCurrentBit;
+		return ReadIntegerL(iNumberOfBitsUsedForDictionaryTokens);
+		}
+	return KErrNotFound;
+	}
+
+void RDictionaryCompressionBitStream::ReadL(Ptr8 aBufferToAppendTo,TBool aCalypsoFileFormat)
+	{
+	// can only be called if IndexOfDictionaryEntry returned a negative value
+	assert(iBuffer!=NULL);
+	assert(!EndOfStreamL());
+	TInt numberOfConsecutivePrefixBits=0;
+	TInt i;
+	for (i=0; i<4; ++i)
+		{
+		const TBool currentBitIsOn=CurrentBitIsOn();
+		++iOffsetToCurrentBit; // increment this regardless whether the current bit is on
+		if (!currentBitIsOn)
+			{
+			break;
+			}
+		++numberOfConsecutivePrefixBits;
+		}
+	assert(numberOfConsecutivePrefixBits>0);
+	assert(numberOfConsecutivePrefixBits<=4);
+	TInt numberOfBytesToRead = numberOfConsecutivePrefixBits;
+	if (numberOfConsecutivePrefixBits==3)
+		{
+		numberOfBytesToRead=3+ReadIntegerL(3);
+		}
+	else if (numberOfConsecutivePrefixBits==4)
+		{
+		numberOfBytesToRead=ReadIntegerL(8);
+		if (!aCalypsoFileFormat)
+			{
+			numberOfBytesToRead+=3+(1<<3);
+			}
+		}
+
+	const TInt numberOfBitsOffByteBoundary=iOffsetToCurrentBit%8;
+	const TUint8* currentByte=iBuffer+(iOffsetToCurrentBit/8);
+	assert((numberOfBytesToRead + aBufferToAppendTo.GetLength()) <= aBufferToAppendTo.GetMaxLength());
+	for (i=0; i<numberOfBytesToRead; ++i, ++currentByte)
+		{
+		TUint byte=*currentByte;
+		assert(numberOfBitsOffByteBoundary>=0);
+		if (numberOfBitsOffByteBoundary>0)
+			{
+			byte>>=numberOfBitsOffByteBoundary;
+			byte|=(*(currentByte+1)<<(8-numberOfBitsOffByteBoundary));
+			byte&=0xff;
+			}
+		aBufferToAppendTo.Append(byte,1);
+		}
+	iOffsetToCurrentBit+=numberOfBytesToRead*8;
+	assert(numberOfBitsOffByteBoundary==iOffsetToCurrentBit%8);
+	}
+
+TBool RDictionaryCompressionBitStream::CurrentBitIsOn() const
+	{
+	// does not increment the current bit-position
+	assert(iBuffer!=NULL);
+	return iBuffer[iOffsetToCurrentBit/8]&(1<<(iOffsetToCurrentBit%8));
+	}
+
+TUint RDictionaryCompressionBitStream::ReadIntegerL(TInt aNumberOfBits)
+	{
+	// increments the current bit-position
+	assert(iBuffer!=NULL);
+	TInt integer=0;
+	TInt numberOfBitsLeftToRead=aNumberOfBits;
+//	FOREVER
+	while(1)
+		{
+		const TInt offsetToFirstBitToReadInCurrentByte=iOffsetToCurrentBit%8;
+		const TInt offsetOnePastLastBitToReadInCurrentByte=Min(8,offsetToFirstBitToReadInCurrentByte+numberOfBitsLeftToRead);
+		const TInt numberOfBitsReadFromCurrentByte=offsetOnePastLastBitToReadInCurrentByte-offsetToFirstBitToReadInCurrentByte;
+		assert(numberOfBitsReadFromCurrentByte>0);
+		const TUint bitsReadFromCurrentByte=((iBuffer[iOffsetToCurrentBit/8]>>offsetToFirstBitToReadInCurrentByte)&((1<<numberOfBitsReadFromCurrentByte)-1));
+		integer|=(bitsReadFromCurrentByte<<(aNumberOfBits-numberOfBitsLeftToRead));
+		iOffsetToCurrentBit+=numberOfBitsReadFromCurrentByte;
+		numberOfBitsLeftToRead-=numberOfBitsReadFromCurrentByte;
+		assert(numberOfBitsLeftToRead>=0);
+		if (numberOfBitsLeftToRead<=0)
+			{
+			break;
+			}
+		}
+	return integer;
+	}
+
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/secureswitools/swisistools/source/rscparser/dictionarycompression.h	Fri May 14 15:58:48 2010 +0300
@@ -0,0 +1,60 @@
+// 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:
+// dictionarycompression.h
+//
+/** 
+* @file dictionarycompression.h
+*
+* @internalComponent
+* @released
+*/
+#if !defined(__DICTIONARYCOMPRESSION_H__)
+#define __DICTIONARYCOMPRESSION_H__
+
+#include <string>
+#include "commontypes.h"
+#include <cassert>
+
+/**
+This class implements a stream of bits (least significant bit first) as used by the code reading dictionary-compressed resource-files
+@internalComponent
+*/
+class RDictionaryCompressionBitStream
+	{
+public:
+	RDictionaryCompressionBitStream();
+	void OpenL(
+		TInt aNumberOfBitsUsedForDictionaryTokens,
+		TInt aOffsetToFirstBit,
+		TInt aOffsetOnePastLastBit,
+		TBool aTransferringOwnershipOfBuffer,
+		TUint8* aBuffer);
+	void Close();
+	TBool EndOfStreamL() const;
+	TInt IndexOfDictionaryEntryL(); // increments the current bit-position if it returns a value >=0; returns a negative value if the next thing in the stream is plain data rather than the index of a dictionary entry
+ 	void ReadL(Ptr8 aBufferToAppendTo,TBool aCalypsoFileFormat); // can only be called if IndexOfDictionaryEntry returned a negative value
+private:
+	TBool CurrentBitIsOn() const; // does not increment the current bit-position
+	TUint ReadIntegerL(TInt aNumberOfBits); // increments the current bit-position
+private:
+	TInt iNumberOfBitsUsedForDictionaryTokens;
+	TInt iOffsetToFirstBit;
+	TInt iOffsetToCurrentBit;
+	TInt iOffsetOnePastLastBit;
+	TBool iOwnsBitBuffer;
+	TUint8* iBuffer;
+	};
+
+#endif
+
--- a/secureswitools/swisistools/source/rscparser/dirparse.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/rscparser/dirparse.cpp	Fri May 14 15:58:48 2010 +0300
@@ -619,13 +619,6 @@
 	std::list<std::wstring>::iterator curr = regDirs.begin();
 	for( curr = regDirs.begin(); curr != regDirs.end(); ++curr )
 	{
-	
-		if(aParamList->RegistryVersionExists())
-		{
-			std::string errMsg= "Database not updated. SIS Registry version file present.\n Remove file RomDrive\\system\\data\\sisregistry_*.txt";
-			throw CResourceFileException(errMsg);
-		}
-
 		try
 		{
 			if (curr->find(AppResourceFileExtension,0) != std::wstring::npos)
--- a/secureswitools/swisistools/source/rscparser/uidtype.cpp	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/rscparser/uidtype.cpp	Fri May 14 15:58:48 2010 +0300
@@ -122,4 +122,47 @@
     return(iUid[0]==aUidType.iUid[0] &&
            iUid[1]==aUidType.iUid[1] &&
            iUid[2]==aUidType.iUid[2]);
-    }
\ No newline at end of file
+    }
+
+TCheckedUid::TCheckedUid()
+//
+// Constructor
+//
+	{
+
+	memset(this,0,sizeof(TCheckedUid));
+	}
+
+TCheckedUid::TCheckedUid(const TUidType& aUidType)
+//
+// Constructor
+//
+	{
+
+	Set(aUidType);
+	}
+
+void TCheckedUid::Set(const TUidType& aUidType)
+//
+// Set from a aUidType
+//
+	{
+	iType=aUidType;
+	}
+
+const TUidType&  TCheckedUid::UidType() const
+{
+	return (iType);
+}
+
+void TCheckedUid::Set(const TUint8* aDes, TInt aLen)
+    {
+   	assert(aLen == sizeof(TCheckedUid));
+    memcpy(this,aDes,aLen);
+    }
+
+TCheckedUid::TCheckedUid(const TUint8* aDes, TInt aLen)
+    {
+    memset(this,0,sizeof(TCheckedUid));
+    Set(aDes, aLen);
+    }
--- a/secureswitools/swisistools/source/rscparser/uidtype.h	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/source/rscparser/uidtype.h	Fri May 14 15:58:48 2010 +0300
@@ -30,31 +30,16 @@
 namespace rscparser
 {
 /**
-@internalComponent
-@released
-
 Defines a Null UID value.
-
-@see TUid
 */
 const TInt KNullUidValue=0;
 
 /**
-@publishedAll
-@released
-
 Defines the number of TUids that form a TUidType.
-
-@see TUid
-@see TUidType
 */
 const TInt KMaxCheckedUid=3;
 
-
 /**
-@publishedAll
-@released
-
 A globally unique 32-bit number.
 */
 class TUid
@@ -75,9 +60,6 @@
 
 
 /**
-@publishedAll
-@released
-
 Defines a null UID
 */
 #define NullUid TUid::Null()
@@ -102,9 +84,6 @@
 	{TUid uid={aUid};return uid;}
 	
 /**
-@publishedAll
-@released
-
 Encapsulates a set of three unique identifiers (UIDs) which, in combination, 
 identify a system object such as a GUI application or a DLL. The three
 component UIDs are referred to as UID1, UID2 and UID3.
@@ -123,5 +102,22 @@
 private:
 	TUid iUid[KMaxCheckedUid];
 	};
+
+/**
+Packages a Uid type together with a checksum.
+*/
+class TCheckedUid
+     {
+ public:
+     TCheckedUid();
+     TCheckedUid(const TUidType& aUidType);
+	 TCheckedUid(const TUint8* aDes, TInt aLen);
+     void Set(const TUidType& aUidType);
+	 void Set(const TUint8* aDes, TInt aLen);
+     const TUidType&  UidType() const;
+private:
+    TUidType iType;
+	TUint32 iCheck;
+    };
 }
 #endif
\ No newline at end of file
--- a/secureswitools/swisistools/test/tinterpretsisinteg/data/regfiles/tstapp_reg.rss	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/test/tinterpretsisinteg/data/regfiles/tstapp_reg.rss	Fri May 14 15:58:48 2010 +0300
@@ -59,8 +59,7 @@
 			},
 		SERVICE_INFO { uid = 0x02345000; opaque_data = r_second_service_specific_data;},
 		SERVICE_INFO { uid = 0x05678000; opaque_data = r_first_service_specific_data;},
-		SERVICE_INFO { uid = 0x01020305; opaque_data = R_SERVICE_SPECIFIC_DATA_LOC; },
-		SERVICE_INFO { uid = 0x01020304; opaque_data = 0;}
+		SERVICE_INFO { uid = 0x01020305; opaque_data = R_SERVICE_SPECIFIC_DATA_LOC; }
 		};
 
 	}
--- a/secureswitools/swisistools/test/tinterpretsisinteg/int_nr_option-01_db.bat	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/test/tinterpretsisinteg/int_nr_option-01_db.bat	Fri May 14 15:58:48 2010 +0300
@@ -24,6 +24,7 @@
 if not exist .\cdrive\Documents mkdir .\cdrive\Documents > NUL
 if not exist .\romdrive\system\ mkdir .\romdrive\system\ > NUL
 if not exist .\romdrive\system\install\ mkdir .\romdrive\system\install\ > NUL
+if exist .\backup\romdrive\sys\install\scr\provisioned\scr.db del .\backup\romdrive\sys\install\scr\provisioned\scr.db > NUL
 REM Remove installation files from any previous tests
 if exist  .\cdrive\Documents\InstTest\Equivalent*.txt  del .\cdrive\Documents\InstTest\Equivalent*.txt  > NUL
 
--- a/secureswitools/swisistools/test/tinterpretsisinteg/scripts/ini.ini	Mon May 03 12:38:03 2010 +0300
+++ b/secureswitools/swisistools/test/tinterpretsisinteg/scripts/ini.ini	Fri May 14 15:58:48 2010 +0300
@@ -994,7 +994,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-OpaqueData=Non-localised_resource
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 OwnedFileCount=2
 FileName0=z:\temp\AppNameTempFile.txt
 FileName1=z:\temp\AppName.txt
@@ -1008,7 +1010,9 @@
 ServiceDataType1=image/gif1
 
 ServiceUid1=0ffb3bf3
-ServiceOpaqueData1=Non-localised_service_uid_01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
@@ -1016,7 +1020,9 @@
 ServiceDataType3=image/gif2
 
 ServiceUid2=0ffb3bf4
-ServiceOpaqueData2=Non-localised_service_uid_02030405
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg3
@@ -1053,7 +1059,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-OpaqueData=Non-localised_resource
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 PropertiesCount=0
 OwnedFileCount=2
 FileName0=z:\temp\AppNameTempFile.txt
@@ -1067,7 +1075,9 @@
 ServiceDataType1=image/gif1
 
 ServiceUid1=268123123
-ServiceOpaqueData1=Non-localised_service_uid_01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
@@ -1075,7 +1085,9 @@
 ServiceDataType3=image/gif2
 
 ServiceUid2=268123124
-ServiceOpaqueData2=Non-localised_service_uid_02030405
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg3
@@ -1094,7 +1106,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-OpaqueData=Non-localised_resource
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 PropertiesCount=0
 OwnedFileCount=2
 FileName0=z:\temp\AppNameTempFile.txt
@@ -1115,7 +1129,9 @@
 ServiceDataType1=image/gif2
 
 ServiceUid1=268123123
-ServiceOpaqueData1=Non-localised_service_uid_01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
@@ -1123,7 +1139,9 @@
 ServiceDataType3=image/gif2
 
 ServiceUid2=268123124
-ServiceOpaqueData2=Non-localised_service_uid_02030405
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg2
@@ -1142,7 +1160,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-OpaqueData=Non-localised_resource
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 PropertiesCount=0
 OwnedFileCount=2
 FileName0=z:\temp\AppNameTempFile.txt
@@ -1163,7 +1183,9 @@
 ServiceDataType1=image/gif2
 
 ServiceUid1=268123123
-ServiceOpaqueData1=Non-localised_service_uid_01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
@@ -1171,7 +1193,9 @@
 ServiceDataType3=image/gif2
 
 ServiceUid2=268123124
-ServiceOpaqueData2=Non-localised_service_uid_02030405
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg2
@@ -1190,7 +1214,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-OpaqueData=Non-localised_resource
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 OwnedFileCount=2
 FileName0=z:\temp\AppNameTempFile.txt
 FileName1=z:\temp\AppName.txt
@@ -1210,7 +1236,9 @@
 ServiceDataType1=image/gif2
 
 ServiceUid1=268123123
-ServiceOpaqueData1=Non-localised_service_uid_01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
@@ -1218,7 +1246,9 @@
 ServiceDataType3=image/gif2
 
 ServiceUid2=268123124
-ServiceOpaqueData2=Non-localised_service_uid_02030405
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg2
@@ -1237,7 +1267,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-OpaqueData=Non-localised_resource
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 PropertiesCount=0
 OwnedFileCount=2
 FileName0=z:\temp\AppNameTempFile.txt
@@ -1251,7 +1283,9 @@
 ServiceDataType1=image/gif1
 
 ServiceUid1=0ffb3bf3
-ServiceOpaqueData1=Non-localised_service_uid_01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
@@ -1259,7 +1293,9 @@
 ServiceDataType3=image/gif2
 
 ServiceUid2=0ffb3bf4
-ServiceOpaqueData2=Non-localised_service_uid_02030405
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg3
@@ -1493,7 +1529,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-OpaqueData=Non-localised_resource
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 PropertiesCount=0
 OwnedFileCount=2
 FileName0=z:\temp\AppNameTempFile.txt
@@ -1507,7 +1545,9 @@
 ServiceDataType1=image/gif1
 
 ServiceUid1=0ffb3bf3
-ServiceOpaqueData1=Non-localised_service_uid_01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
@@ -1515,7 +1555,9 @@
 ServiceDataType3=image/gif2
 
 ServiceUid2=0ffb3bf4
-ServiceOpaqueData2=Non-localised_service_uid_02030405
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg3
@@ -1739,7 +1781,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-OpaqueData=Non-localised_resource
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 PropertiesCount=0
 OwnedFileCount=2
 FileName0=z:\temp\AppNameTempFile.txt
@@ -1753,7 +1797,9 @@
 ServiceDataType1=image/gif1
 
 ServiceUid1=0ffb3bf3
-ServiceOpaqueData1=Non-localised_service_uid_01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
@@ -1761,7 +1807,9 @@
 ServiceDataType3=image/gif2
 
 ServiceUid2=0ffb3bf4
-ServiceOpaqueData2=Non-localised_service_uid_02030405
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg3
@@ -1987,7 +2035,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-OpaqueData=Non-localised_resource
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 PropertiesCount=0
 OwnedFileCount=2
 FileName0=z:\temp\AppNameTempFile.txt
@@ -2001,7 +2051,9 @@
 ServiceDataType1=image/gif1
 
 ServiceUid1=0ffb3bf3
-ServiceOpaqueData1=Non-localised_service_uid_01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
@@ -2009,7 +2061,9 @@
 ServiceDataType3=image/gif2
 
 ServiceUid2=0ffb3bf4
-ServiceOpaqueData2=Non-localised_service_uid_02030405
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg3
@@ -2046,7 +2100,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-OpaqueData=Non-localised_resource
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 PropertiesCount=0
 OwnedFileCount=2
 FileName0=z:\temp\AppNameTempFile.txt
@@ -2060,7 +2116,9 @@
 ServiceDataType1=image/gif1
 
 ServiceUid1=0ffb3bf3
-ServiceOpaqueData1=Non-localised_service_uid_01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
@@ -2068,7 +2126,9 @@
 ServiceDataType3=image/gif2
 
 ServiceUid2=0ffb3bf4
-ServiceOpaqueData2=Non-localised_service_uid_02030405
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg3
@@ -2114,33 +2174,39 @@
 NewFile=0
 Launch=0
 GroupName=Games
+PropertiesCount=0
 OwnedFileCount=1
 FileName0=C:\System\file2
-ServiceInfoCount=6
-ServiceUid0=269488144
+ServiceInfoCount=5
+ServiceUid0=10101010
 ServiceDataTypeCount0=0
 
-ServiceUid1=16909060
-ServiceOpaqueData1=Non-localised_text_for_service_uid_0x01020304
+ServiceUid1=01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_text_for_service_uid_0x01020304
 ServiceDataTypeCount1=1
 ServiceDataTypePriority0=0
 ServiceDataType0=text/custom1
 
-ServiceUid2=36982784
-ServiceOpaqueData2=Non-localised_text_for_service_uid_0x02345000
+ServiceUid2=02345000
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_text_for_service_uid_0x02345000
 ServiceDataTypeCount2=0
 
-ServiceUid3=90669056
-ServiceOpaqueData3=Non-localised_text_for_service_uid_0x01020304
+ServiceUid3=05678000
+ServiceOpaqueDataInfoCount3=1
+ServiceOpaqueLocale2=0
+ServiceOpaqueData2=Non-localised_text_for_service_uid_0x01020304
 ServiceDataTypeCount3=0
 
-ServiceUid4=16909061
-ServiceOpaqueData4=Non-localised_text_for_service_uid_0x02345000
+ServiceUid4=01020305
+ServiceOpaqueDataInfoCount4=1
+ServiceOpaqueLocale3=1
+ServiceOpaqueData3=Localised_text_for_service_UID_0x01020305
 ServiceDataTypeCount4=0
 
-ServiceUid5=16909060
-ServiceDataTypeCount5=0
-
 LocalizableAppInfoCount=1
 
 LocShortCaption0=TCUK
@@ -2191,7 +2257,9 @@
 Launch=0
 GroupName=AppNameGroup
 DefaultScreenNumber=2
-OpaqueData=Non-localised_resource
+AppOpaqueDataInfoCount= 1
+AppOpaqueLocale0=0
+AppOpaqueData0=Non-localised_resource
 PropertiesCount=0
 OwnedFileCount=2
 FileName0=z:\temp\AppNameTempFile.txt
@@ -2205,7 +2273,9 @@
 ServiceDataType1=image/gif1
 
 ServiceUid1=0ffb3bf3
-ServiceOpaqueData1=Non-localised_service_uid_01020304
+ServiceOpaqueDataInfoCount1=1
+ServiceOpaqueLocale0=0
+ServiceOpaqueData0=Non-localised_service_uid_01020304
 ServiceDataTypeCount1=2
 ServiceDataTypePriority2=0
 ServiceDataType2=image/jpeg2
@@ -2213,7 +2283,9 @@
 ServiceDataType3=image/gif2
 
 ServiceUid2=0ffb3bf4
-ServiceOpaqueData2=Non-localised_service_uid_02030405
+ServiceOpaqueDataInfoCount2=1
+ServiceOpaqueLocale1=0
+ServiceOpaqueData1=Non-localised_service_uid_02030405
 ServiceDataTypeCount2=2
 ServiceDataTypePriority4=0
 ServiceDataType4=image/jpeg3
Binary file secureswitools/swisistools/test/tscrtool/data/preprovision.dtd has changed
Binary file secureswitools/swisistools/test/tscrtool/data/preprovision_appreginfo.xml has changed
Binary file secureswitools/swisistools/test/tscrtool/data/preprovision_nocaptioniconinfo.xml has changed
Binary file secureswitools/swisistools/test/tscrtool/data/preprovision_nullappfile.xml has changed
Binary file secureswitools/swisistools/test/tscrtool/data/preprovision_nullappuid.xml has changed
--- a/tsrc/group/bld.inf	Mon May 03 12:38:03 2010 +0300
+++ b/tsrc/group/bld.inf	Fri May 14 15:58:48 2010 +0300
@@ -1,5 +1,5 @@
 /*
-* Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
+* Copyright (c) 2008-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"
@@ -21,7 +21,5 @@
 
 PRJ_TESTEXPORTS
 
+PRJ_TESTMMPFILES
 
-PRJ_TESTMMPFILES
-#include "../../appinstall_plat/appmngr2runtimeapi/tsrc/group/bld.inf"
-