--- a/startupservices/Startup/src/StartupAppUi.cpp Mon May 03 12:40:23 2010 +0300
+++ b/startupservices/Startup/src/StartupAppUi.cpp Fri May 14 16:01:13 2010 +0300
@@ -18,14 +18,7 @@
// SYSTEM INCLUDES
#include <StringLoader.h>
-#include <AknGlobalNote.h> //used for Selftest failed note
-#include <aknPopup.h>
-#include <aknlists.h>
-#include <aknSDData.h>
-#include <badesca.h>
-#include <tzlocalizationdatatypes.h>
-#include <tzlocalizer.h>
-#include <tz.h>
+
#include <featmgr.h> // Feature Manager
#include <centralrepository.h>
#include <startup.rsg>
@@ -33,54 +26,22 @@
#include "startupappprivatepskeys.h"
#include <startupdomainpskeys.h>
#include <startupdomaincrkeys.h>
-#include <coreapplicationuissdkcrkeys.h>
+#include <CoreApplicationUIsSDKCRKeys.h>
#include <starterclient.h>
-
-#ifdef RD_UI_TRANSITION_EFFECTS_PHASE2
-// Transition effects
-#include <gfxtranseffect/gfxtranseffect.h>
-#include <akntranseffect.h>
-#endif
-
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
- #include "sanimstartupctrl.h"
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- #include <akndef.h> // For layout change event definitions
- #include <AknSoundSystem.h>
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+#include <hbdevicemessageboxsymbian.h>
+#include "sanimstartupctrl.h"
// USER INCLUDES
#include "StartupAppUi.h"
#include "StartupApplication.h"
-#include "StartupUserWelcomeNote.h"
-#include "StartupQueryDialog.h" //used for Startup own Time and Date queries
-#include "StartupPopupList.h" //used for Startup own City and Country queries
-#include "StartupMediatorObserver.h"
+
#include "StartupPubSubObserver.h"
-
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
- #include "startupanimationwrapper.h"
- #include "startupview.h"
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- #include "StartupDocument.h"
- #include "StartupOperatorAnimation.h"
- #include "StartupTone.h"
- #include "StartupWelcomeAnimation.h"
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+#include "startupanimationwrapper.h"
+#include "startupview.h"
+
+#include <eikenv.h>
-// CONSTANTS
-const TInt KUserWelcomeNoteShowPeriodTime = 3000000; // 3 sec
-
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- const TInt KOneMilliSecondInMicroSeconds = 1000;
- const TInt KMaxToneInitWait = 200; // 200 ms
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
-
-static const TInt KMaxCityLength(120);
-static const TInt KMaxCountryLength(120);
-
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
static const CSAnimStartupCtrl::TAnimationParams KStartupAnimationParams =
{
KCRUidStartupConf,
@@ -90,15 +51,7 @@
KStartupTonePath,
KStartupToneVolume
};
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
-_LIT(KEmpty, " ");
-
-// Default date and time value is used if cenrep string is not valid
-// Default date is 01.01.2007 and default time is 09:00 AM
-_LIT( KDefaultDateTimeValue, "20070000:090000" ); // YYYYMMDD:HHMMSS
-
-static const TInt KTimeFormatLength(16); // "20070000:090000."
_LIT_SECURITY_POLICY_C1(KReadDeviceDataPolicy, ECapabilityReadDeviceData);
_LIT_SECURITY_POLICY_C1(KWriteDeviceDataPolicy, ECapabilityWriteDeviceData);
@@ -106,7 +59,6 @@
// ======== LOCAL FUNCTIONS ==================================================
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
namespace
{
TInt AnimationFinishedFunc( TAny* aPtr )
@@ -115,7 +67,7 @@
return KErrNone;
}
}
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
// ================= MEMBER FUNCTIONS ========================================
@@ -124,17 +76,8 @@
// CStartupAppUi::CStartupAppUi()
// ---------------------------------------------------------------------------
CStartupAppUi::CStartupAppUi() :
- iUserWelcomeNote( NULL ),
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iStartupTone( NULL ),
- iOpStartupTone( NULL ),
- iToneInitWaitTime( 0 ),
- iAnimation( EFalse ),
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
- iInternalState( EStartupStartingUp ),
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iSplashScreenShouldBeRemoved( EFalse ),
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+ iInternalState( EStartupStartingUp ),
+
iStartupFirstBootAndRTCCheckAlreadyCalled( EFalse ),
iChargingOrAlarmBoot( EFalse ),
iFirstBoot( ETrue ),
@@ -144,15 +87,8 @@
iCriticalBlockEnded( EFalse ),
iSwStateFatalStartupError( EFalse ),
iStartupWaitingShowStartupAnimation( EFalse ),
- iSimSupported( ETrue ),
- iStartupMediatorObserver( NULL ),
- iCoverUISupported( EFalse ),
- iCounryListIndex( 0 )
- , iTime( 0 )
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- , iTouchScreenCalibSupport( EFalse )
- , iTouchScreenCalibrationDone( EFalse )
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+ iSimSupported( ETrue )
+
{
TRACES("CStartupAppUi::CStartupAppUi");
}
@@ -163,17 +99,14 @@
void CStartupAppUi::ConstructL()
{
TRACES("CStartupAppUi::ConstructL()");
- TInt flags = EStandardApp|EAknEnableSkin|EAknEnableMSK ;
-
- BaseConstructL(flags);
+ TInt flags = EStandardApp;
+ BaseConstructL( flags );
+
+ iMainView = CStartupView::NewL( ApplicationRect() );
+
+
+ iAnimation = CStartupAnimationWrapper::NewL( *iMainView );
- iAvkonAppUi->SetKeyEventFlags( CAknAppUiBase::EDisableSendKeyShort |
- CAknAppUiBase::EDisableSendKeyLong );
-
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iMainView = CStartupView::NewL( ApplicationRect() );
- iAnimation = CStartupAnimationWrapper::NewL( *iMainView );
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
TInt err = RProperty::Define( KPSUidStartupApp,
KPSStartupAppState,
@@ -198,42 +131,9 @@
iStartupPubSubObserver = CStartupPubSubObserver::NewL( this );
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- err = RProperty::Define( KPSUidStartup,
- KStartupBootIntoOffline,
- RProperty::EInt,
- KReadDeviceDataPolicy,
- KWriteDeviceDataPolicy );
- if( KErrNone != err &&
- KErrAlreadyExists != err )
- {
- TRACES1("CStartupAppUi::ConstructL(): KStartupBootIntoOffline define err %d", err);
- }
- err = RProperty::Define( KPSUidStartup,
- KStartupSecurityCodeQueryStatus,
- RProperty::EInt,
- KReadDeviceDataPolicy,
- KWriteDeviceDataPolicy );
- if( KErrNone != err &&
- KErrAlreadyExists != err )
- {
- TRACES1("CStartupAppUi::ConstructL(): KStartupSecurityCodeQueryStatus define err %d", err);
- }
- err = RProperty::Define( KPSUidStartup,
- KStartupCleanBoot,
- RProperty::EInt,
- KReadDeviceDataPolicy,
- KWriteDeviceDataPolicy );
- if( KErrNone != err &&
- KErrAlreadyExists != err )
- {
- TRACES1("CStartupAppUi::ConstructL(): KStartupCleanBoot define err %d", err);
- }
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
err = RProperty::Define( KPSUidStartup,
KPSStartupUiPhase,
RProperty::EInt,
@@ -247,7 +147,7 @@
}
UpdateStartupUiPhase( EStartupUiPhaseUninitialized );
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
FeatureManager::InitializeLibL();
if ( FeatureManager::FeatureSupported( KFeatureIdOfflineMode ) )
@@ -258,60 +158,30 @@
{
iSimSupported = EFalse;
}
- if ( FeatureManager::FeatureSupported( KFeatureIdCoverDisplay ) )
- {
- iCoverUISupported = ETrue;
- }
+
TRACES1("CStartupAppUi::ConstructL(): Offline mode supported: %d", iOfflineModeSupported );
TRACES1("CStartupAppUi::ConstructL(): SIM card supported: %d", iSimSupported );
- TRACES1("CStartupAppUi::ConstructL(): CoverUI supported: %d", iCoverUISupported );
-
-#if defined (RD_SCALABLE_UI_V2) && !defined(RD_STARTUP_ANIMATION_CUSTOMIZATION)
- if ( FeatureManager::FeatureSupported(KFeatureIdPenSupport) &&
- FeatureManager::FeatureSupported(KFeatureIdPenSupportCalibration) )
- {
- iTouchScreenCalibSupport = ETrue;
- }
-#endif // RD_SCALABLE_UI_V2 && !RD_STARTUP_ANIMATION_CUSTOMIZATION
-
- if (iCoverUISupported)
- {
- iStartupMediatorObserver = CStartupMediatorObserver::NewL( this );
- }
+
iFirstBoot = FirstBoot();
TRACES1("CStartupAppUi::ConstructL(): First boot: %d", iFirstBoot );
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iWelcomeAnimation = CStartupWelcomeAnimation::NewL( this, ClientRect());
- AddToStackL( iWelcomeAnimation );
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
+ CEikonEnv* eikEnv = CEikonEnv::Static();
// Set Startup application to be system application
- iEikonEnv->SetSystem( ETrue );
+ eikEnv->SetSystem( ETrue );
- iEikonEnv->RootWin().SetOrdinalPosition(0,0);
+ eikEnv->RootWin().SetOrdinalPosition(0,0);
// Disable priority changes of window server
- iEikonEnv->WsSession().ComputeMode(
+ eikEnv->WsSession().ComputeMode(
RWsSession::EPriorityControlDisabled );
+ iNoteTimer = CPeriodic::NewL( EPriorityNormal );
- iNoteTimer = CPeriodic::NewL( EPriorityNormal );
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iAnimTimer = CPeriodic::NewL( EPriorityNormal );
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
iExitTimer = CPeriodic::NewL( EPriorityNormal );
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- TRACES("CStartupAppUi::ConstructL(): StartupTone: Initialising");
- iStartupTone = CStartupTone::NewL( this, EStartupTone );
- TRACES("CStartupAppUi::ConstructL(): StartupTone: Initialised");
-
- TRACES("CStartupAppUi::ConstructL(): Operator StartupTone: Initialising");
- iOpStartupTone = CStartupTone::NewL( this, EStartupOpTone );
- TRACES("CStartupAppUi::ConstructL(): Operator StartupTone: Initialised");
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
if ( iSwStateFatalStartupError )
{
@@ -333,43 +203,6 @@
{
TRACES("CStartupAppUi::~CStartupAppUi()");
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- if (iWelcomeAnimation)
- {
- RemoveFromStack( iWelcomeAnimation );
- delete iWelcomeAnimation;
- }
-
- if (iOperatorAnimation)
- {
- RemoveFromStack( iOperatorAnimation);
- delete iOperatorAnimation;
- }
-
- if (iUserWelcomeNote)
- {
- RemoveFromStack( iUserWelcomeNote );
- delete iUserWelcomeNote;
- iUserWelcomeNote = NULL;
- }
-
- if (iStartupPubSubObserver)
- {
- delete iStartupPubSubObserver;
- }
- if (iStartupMediatorObserver)
- {
- delete iStartupMediatorObserver;
- }
- if (iStartupTone)
- {
- delete iStartupTone;
- }
- if (iOpStartupTone)
- {
- delete iOpStartupTone;
- }
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
if( iExitTimer )
{
@@ -377,13 +210,7 @@
delete iExitTimer;
}
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- if( iAnimTimer )
- {
- iAnimTimer->Cancel();
- delete iAnimTimer;
- }
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
if( iNoteTimer )
{
@@ -391,13 +218,13 @@
delete iNoteTimer;
}
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
- delete iUserWelcomeNote;
+
+
delete iAnimation;
delete iStartupPubSubObserver;
- delete iStartupMediatorObserver;
+
delete iMainView;
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
FeatureManager::UnInitializeLib();
@@ -411,26 +238,11 @@
{
TRACES("CStartupAppUi::PrepareToExit()");
-#ifdef RD_UI_TRANSITION_EFFECTS_PHASE2
- // Start the custom exit effect at boot time.
- // Note: Not allowed to call GfxTransEffect::EndFullScreen() as AVKON takes care of that when
- // EApplicationExit context is used!
+
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
- if ( !( iAnimation->WasCancelled() ) )
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- if( !iWelcomeAnimation->IsAnimationCancelled() )
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
- {
- TRACES("CStartupAppUi::PrepareToExit(): Starting transition effect");
+
+ CEikAppUi::PrepareToExit();
- GfxTransEffect::BeginFullScreen( AknTransEffect::EApplicationExit, TRect(),
- AknTransEffect::EParameterType,
- AknTransEffect::GfxTransParam( KUidStartUp, AknTransEffect::TParameter::EAllowAtBoot ) );
- }
-#endif
-
- CEikAppUi::PrepareToExit();
#ifndef RD_BOOT_CUSTOMIZABLE_AI
if( !iChargingOrAlarmBoot )
{
@@ -474,6 +286,7 @@
return KErrNone;
}
+
// ---------------------------------------------------------------------------
// CStartupAppUi::HandleKeyEventL
// ---------------------------------------------------------------------------
@@ -512,13 +325,7 @@
iOfflineModeQueryShown = EFalse;
response = EKeyWasConsumed;
}
- else if ( iUserWelcomeNote )
- {
- TRACES("CStartupAppUi::HandleKeyEventL(): This key event is used to stop UserWelcomeAnimation");
- //this is used to stop User Welcome note showing
- StopTimingL();
- response = EKeyWasConsumed;
- }
+
else if ( ( iInternalState == EStartupShowingWelcomeAnimation ||
iInternalState == EStartupShowingOperatorAnimation ) &&
!( iAnimation->WasCancelled() ) )
@@ -534,7 +341,8 @@
return response;
}
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+/*
+ * Qt Support Not available..
// ---------------------------------------------------------------------------
// CStartupAppUi::HandleResourceChangeL
//
@@ -544,17 +352,20 @@
{
TRACES("CStartupAppUi::HandleResourceChangeL()");
TRACES1("CStartupAppUi::HandleResourceChangeL Type: %d", aType);
-
+
+
+ * No equivalent in Qt.
CAknAppUi::HandleResourceChangeL( aType );
if ( aType == KEikDynamicLayoutVariantSwitch )
{
iMainView->SetRect( ApplicationRect() );
}
-
+
TRACES("CStartupAppUi::HandleResourceChangeL(): End");
}
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
+*/
// ---------------------------------------------------------------------------
@@ -568,7 +379,8 @@
case EEikCmdExit:
{
TRACES("CStartupAppUi::HandleCommandL(): EEikCmdExit");
- Exit();
+
+ Exit();
}
break;
default:
@@ -583,14 +395,13 @@
void CStartupAppUi::DoStartupStartPartL()
{
TRACES("CStartupAppUi::DoStartupStartPartL()");
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
TryPreLoadAnimation();
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
DoNextStartupPhaseL( EStartupWaitingCriticalBlock );
TRACES("CStartupAppUi::DoStartupStartPartL(): End");
}
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
// ---------------------------------------------------------------------------
// CStartupAppUi::TryPreLoadAnimation()
// ---------------------------------------------------------------------------
@@ -621,7 +432,7 @@
{
iAnimation->PreLoad(
ClientRect(),
- *iMainView,
+ *iMainView,
KStartupAnimationParams,
ETrue,
SecondaryDisplay::EStartWelcomeAnimation );
@@ -629,7 +440,7 @@
TRACES("CStartupAppUi::TryPreLoadAnimation(): End");
}
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
// ---------------------------------------------------------------------------
@@ -644,44 +455,24 @@
//the same way like in the end of ShowUserWelcomeNoteL()
TRACES("CStartupAppUi::DoStartupShowWelcomeAnimationL(): Skip the animation and UWN because it's hidden reset");
TRACES("CStartupAppUi::DoStartupShowWelcomeAnimationL(): and change internal state directly to EStartupFirstBootAndRTCCheck");
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iWelcomeAnimation->RemoveSplashScreen();
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
DoNextStartupPhaseL( EStartupFirstBootAndRTCCheck );
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- return;
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
}
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
else
{
TRACES("CStartupAppUi::DoStartupShowWelcomeAnimationL(): Show animation");
iAnimation->Play(
ClientRect(),
- *iMainView,
+ *iMainView,
KStartupAnimationParams,
ETrue,
SecondaryDisplay::EStartWelcomeAnimation,
TCallBack( AnimationFinishedFunc, this ) );
}
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- TRACES("CStartupAppUi::DoStartupShowWelcomeAnimationL(): Play startup tone.");
-
- // Play startup tone
- if (iStartupTone->Play() != KErrNone)
- {
- // Play startup beep.
- TRACES("CStartupAppUi::DoStartupShowWelcomeAnimationL(): Play startup beep");
- static_cast<CAknAppUi*>(iEikonEnv->
- EikAppUi())->
- KeySounds()->
- PlaySound( EAvkonSIDPowerOnTone );
- }
- iWelcomeAnimation->SetAnimationShowing(ETrue);
- ShowWelcomeAnimationL();
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
TRACES("CStartupAppUi::DoStartupShowWelcomeAnimationL(): End");
}
@@ -699,11 +490,9 @@
TRACES("CStartupAppUi::DoStartupShowOperatorAnimationL(): Skip the animation and UWN because it's hidden reset");
TRACES("CStartupAppUi::DoStartupShowOperatorAnimationL(): and change internal state directly to EStartupFirstBootAndRTCCheck");
DoNextStartupPhaseL( EStartupFirstBootAndRTCCheck );
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- return;
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
}
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
else
{
TRACES("CStartupAppUi::DoStartupShowOperatorAnimationL(): Show animation");
@@ -717,61 +506,18 @@
params.iVolumeKey = KStartupOperatorToneVolume;
iAnimation->Play(
ClientRect(),
+
*iMainView,
params,
EFalse,
SecondaryDisplay::EStartOperatorAnimation,
TCallBack( AnimationFinishedFunc, this ) );
}
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- if ( iOperatorAnimation->ShowingTime() )
- {
- TRACES("CStartupAppUi::DoStartupShowOperatorAnimationL(): Operator animation time defined properly");
- iOperatorAnimation->SetAnimationShowing(ETrue);
- iOpStartupTone->Play();
- ShowOperatorAnimationL();
- }
- else
- {
- TRACES("CStartupAppUi::DoStartupShowOperatorAnimationL(): Operator animation not defined. Skip it.");
- iOperatorAnimation->SetAnimationShowing(EFalse);
- DoNextStartupPhaseL( EStartupShowingUserWelcomeNote );
- }
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
TRACES("CStartupAppUi::DoStartupShowOperatorAnimationL(): End");
}
-// ---------------------------------------------------------------------------
-// CStartupAppUi::DoStartupShowUserWelcomeNoteL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::DoStartupShowUserWelcomeNoteL()
- {
- TRACES("CStartupAppUi::DoStartupShowUserWelcomeNoteL()");
- ShowUserWelcomeNoteL();
- TRACES("CStartupAppUi::DoStartupShowUserWelcomeNoteL(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::StartupQueriesEnabled()
-// ---------------------------------------------------------------------------
-TBool CStartupAppUi::StartupQueriesEnabled()
- {
- TRACES("CStartupAppUi::StartupQueriesEnabled()");
-
- TInt value( EStartupQueriesEnabled );
- CRepository* repository(NULL);
-
- TRAPD( err, repository = CRepository::NewL( KCRUidStartupConf ) );
- if ( err == KErrNone )
- {
- err = repository->Get( KStartupQueries, value );
- }
- delete repository;
-
- TRACES1("CStartupAppUi::StartupQueriesEnabled(): returns %d", value);
- return value;
- }
// ---------------------------------------------------------------------------
// CStartupAppUi::PredictiveTimeEnabled()
@@ -801,64 +547,30 @@
{
TRACES("CStartupAppUi::DoStartupFirstBootAndRTCCheckL()");
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
RProperty::Set( KPSUidStartup, KStartupCleanBoot, iCleanBoot );
RProperty::Set( KPSUidStartup, KPSSplashShutdown, ESplashShutdown );
- delete iUserWelcomeNote;
- iUserWelcomeNote = NULL;
iMainView->DrawDeferred();
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
// When Predictive Time and Country Selection is enabled, no queries are
// shown to user during first boot. Instead, Clock application gets the
// time and location from the network and marks the first boot as done.
if( !PredictiveTimeEnabled() )
{
- if( iFirstBoot && !HiddenReset() && StartupQueriesEnabled() )
+ if( iFirstBoot && !HiddenReset() ) //&& StartupQueriesEnabled() )
{
TRACES("CStartupAppUi::DoStartupFirstBootAndRTCCheckL(): First boot. Show city, time and date queries.");
-
-
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iWelcomeAnimation->UpdateDrawInfo( EStartupDICityTimeDateQueries );
- iWelcomeAnimation->DrawNow();
-
- if (iOperatorAnimation)
- {
- RemoveFromStack( iOperatorAnimation );
- delete iOperatorAnimation;
- iOperatorAnimation = NULL;
- }
- if (iUserWelcomeNote)
- {
- RemoveFromStack( iUserWelcomeNote );
- delete iUserWelcomeNote;
- iUserWelcomeNote = NULL;
- }
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
-
- ShowStartupQueriesL();
- TRACES("CStartupAppUi::DoStartupFirstBootAndRTCCheckL(): Mark first boot");
+ TRACES("CStartupAppUi::DoStartupFirstBootAndRTCCheckL(): Mark first boot");
MarkFirstBoot();
}
- else if( !RTCStatus() && !HiddenReset() && StartupQueriesEnabled())
+ else if( !RTCStatus() && !HiddenReset() ) // && StartupQueriesEnabled())
{
TRACES("CStartupAppUi::DoStartupFirstBootAndRTCCheckL(): No first boot but RTCStatus is corrupted. Ask time and date");
- #ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iWelcomeAnimation->UpdateDrawInfo( EStartupDICityTimeDateQueries );
- if (iUserWelcomeNote)
- {
- RemoveFromStack( iUserWelcomeNote );
- delete iUserWelcomeNote;
- iUserWelcomeNote = NULL;
- }
- #endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
-
- ShowStartupQueriesL(); // Not first boot, so skips Country/City query
- }
- if( iFirstBoot && !StartupQueriesEnabled() )
+ }
+ if( iFirstBoot ) // && !StartupQueriesEnabled() )
{
TRACES("CStartupAppUi::DoStartupFirstBootAndRTCCheckL(): First boot ongoing and queries are disabled.");
MarkFirstBoot();
@@ -875,6 +587,7 @@
}
// End of temporary fix.
}
+
TRACES("CStartupAppUi::DoStartupFirstBootAndRTCCheckL(): Setting KPSStartupAppState = EStartupAppStateFinished");
TInt err = RProperty::Set( KPSUidStartupApp, KPSStartupAppState, EStartupAppStateFinished );
if( KErrNone != err )
@@ -883,58 +596,11 @@
, err);
}
- DoNextStartupPhaseL( EStartupWaitingCUIStartupReady );
+ DoNextStartupPhaseL( EStartupStartupOK );
}
-// ---------------------------------------------------------------------------
-// CStartupAppUi::ShowStartupQueriesL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::ShowStartupQueriesL()
- {
- TRACES("CStartupAppUi::ShowStartupQueriesL()");
-
- TBool citysaved(EFalse);
- TBool timesaved(EFalse);
- TBool datesaved(EFalse);
-
- // Get default time ( to be used only in date query )
- GetDefaultTimeAndDate( iTime );
-
- // Show Country, Date and Time queries ( with possibility to go back ).
- // Country query is shown only in the first boot.
- while (!timesaved)
- {
- while (!datesaved)
- {
- while (!citysaved && iFirstBoot)
- {
- // 1. Select time zone
- ShowCountryAndCityListsL();
- citysaved = ETrue;
- TRACES1("CStartupAppUi::ShowStartupQueriesL(): citysaved = %d", citysaved );
- }
- // 2. Set date
- datesaved = ShowDateQueryL();
- TRACES1("CStartupAppUi::ShowStartupQueriesL(): datesaved = %d", datesaved );
- if (!datesaved)
- {
- citysaved = EFalse;
- }
- }
- // 3. Set time
- timesaved = ShowTimeQueryL();
- TRACES1("CStartupAppUi::ShowStartupQueriesL(): timesaved = %d", timesaved );
- if (!timesaved)
- {
- datesaved = EFalse;
- }
- }
- // All the queries completed.
-
- TRACES("CStartupAppUi::ShowStartupQueriesL() - END");
- }
// ---------------------------------------------------------------------------
// CStartupAppUi::DoStartupEndPart()
@@ -944,13 +610,11 @@
TRACES("CStartupAppUi::DoStartupEndPart()");
TRACES("CStartupAppUi::DoStartupEndPart(): STARTUP OK");
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- RProperty::Set( KPSUidStartup, KStartupCleanBoot, iCleanBoot );
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
UpdateStartupUiPhase( EStartupUiPhaseAllDone );
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
TRACES("CStartupAppUi::DoStartupEndPart(): Exit application.");
iExitTimer->Start( 100000, 100000, TCallBack( DoExitApplication, this ) );
@@ -958,62 +622,6 @@
TRACES("CStartupAppUi::DoStartupEndPart(): End");
}
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
-// ---------------------------------------------------------------------------
-// CStartupAppUi::ContinueStartupAfterToneL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::ContinueStartupAfterToneL(TToneType aToneType)
- {
- TRACES("CStartupAppUi::ContinueStartupAfterToneL()");
-
- if (aToneType == EStartupTone)
- {
- TRACES("CStartupAppUi::ContinueStartupAfterToneL(): Tone type EStartupTone");
- DoNextStartupPhaseL( EStartupWaitingCUIOperatorAnim );
- }
- else if (aToneType == EStartupOpTone)
- {
- TRACES("CStartupAppUi::ContinueStartupAfterToneL(): Tone type EStartupOpTone");
- DoNextStartupPhaseL( EStartupShowingUserWelcomeNote );
- }
- else
- {
- TRACES("CStartupAppUi::ContinueStartupAfterToneL(): Tone interrupted");
- DoNextStartupPhaseL( EStartupFirstBootAndRTCCheck );
- }
- TRACES("CStartupAppUi::ContinueStartupAfterToneL(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::BringToForeground()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::BringToForeground()
- {
- TRACES("CStartupAppUi::BringToForeground()");
- if ((iInternalState != EStartupWaitingTouchScreenCalib) ||
- (iTouchScreenCalibrationDone))
- {
- TRACES("CStartupAppUi::BringToForeground(): Bring to foreground");
- TApaTask self(iCoeEnv->WsSession());
- self.SetWgId(iCoeEnv->RootWin().Identifier());
- self.BringToForeground();
- }
- TRACES("CStartupAppUi::BringToForeground(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::SendToBackground()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::SendToBackground()
- {
- TRACES("CStartupAppUi::SendToBackground()");
- TApaTask self(iCoeEnv->WsSession());
- self.SetWgId(iCoeEnv->RootWin().Identifier());
- self.SendToBackground();
- TRACES("CStartupAppUi::SendToBackground(): End");
- }
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
-
// ---------------------------------------------------------------------------
// CStartupAppUi::StopTimingL()
// ---------------------------------------------------------------------------
@@ -1029,87 +637,10 @@
TRACES("CStartupAppUi::StopTimingL(): Stopping UWN");
iStartupFirstBootAndRTCCheckAlreadyCalled = ETrue;
iNoteTimer->Cancel();
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
UpdateStartupUiPhase( EStartupUiPhaseUserWelcomeDone );
DoNextStartupPhaseL( EStartupFirstBootAndRTCCheck );
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- iUserWelcomeNote->CancelNoteCancelTimer();
- iWelcomeAnimation->UpdateDrawInfo( EStartupDIWelcomeNoteEnd );
- iWelcomeAnimation->DrawNow();
- iUserWelcomeNote->SetUserWelcomeNoteShowing(EFalse);
- TRACES("CStartupAppUi::StopTimingL(): UWN stopped");
- if (iStartupTone->Playing())
- {
- TRACES("CStartupAppUi::StopTimingL(): Startup tone playing. Cannot continue to next phase");
- iStartupTone->StartupWaiting(ETrue);
- }
- else
- {
- DoNextStartupPhaseL( EStartupFirstBootAndRTCCheck );
- }
- }
- else if (iInternalState == EStartupShowingOperatorAnimation) // EStartupShowingOperatorAnimation
- {
- TRACES("CStartupAppUi::StopTimingL(): Stopping animation");
- iAnimTimer->Cancel();
- iWelcomeAnimation->CancelAnimCancelTimer();
- iOperatorAnimation->UpdateDrawInfo( EStartupDIOperatorAnimEnd );
- iOperatorAnimation->SetAnimationShowing(EFalse);
- TRACES("CStartupAppUi::StopTimingL(): operator animation showing stopped");
- if ( iOperatorAnimation->IsAnimationCancelled())
- {
- TRACES("CStartupAppUi::StopTimingL(): Animation is cancelled by user and therefore UWN is not shown");
- StopOperatorTone();
- iStartupFirstBootAndRTCCheckAlreadyCalled = ETrue;
- DoNextStartupPhaseL( EStartupFirstBootAndRTCCheck );
- }
- else
- {
- // If tone is still playing wait until it completes.
- if (iOpStartupTone->Playing())
- {
- TRACES("CStartupAppUi::StopTimingL(): Operator startup tone is still playing. Wait until it completes.");
- iOpStartupTone->StartupWaiting(ETrue);
- }
- else
- {
- TRACES("CStartupAppUi::StopTimingL(): Lets display UWN");
- DoNextStartupPhaseL( EStartupShowingUserWelcomeNote );
- }
- }
- TRACES("CStartupAppUi::StopTimingL(): Operator Animation stopped");
- }
- else // EStartupShowingWelcomeAnimation
- {
- TRACES("CStartupAppUi::StopTimingL(): Stopping animation");
- iAnimTimer->Cancel();
- iWelcomeAnimation->CancelAnimCancelTimer();
- iWelcomeAnimation->UpdateDrawInfo( EStartupDIWelcomeAnimEnd );
- iWelcomeAnimation->SetAnimationShowing(EFalse);
- TRACES("CStartupAppUi::StopTimingL(): Welcome animation showing stopped");
-
- if ( iWelcomeAnimation->IsAnimationCancelled())
- {
- TRACES("CStartupAppUi::StopTimingL(): Animation is cancelled by user and therefore operator animation and UWN is not shown");
- StopStartupTone();
- iStartupFirstBootAndRTCCheckAlreadyCalled = ETrue;
- DoNextStartupPhaseL( EStartupFirstBootAndRTCCheck );
- }
- else
- {
- if (iStartupTone->Playing())
- {
- // If tone is still playing wait until it completes.
- iStartupTone->StartupWaiting(ETrue);
- }
- else
- {
- DoNextStartupPhaseL( EStartupWaitingCUIOperatorAnim );
- }
- }
- TRACES("CStartupAppUi::StopTimingL(): Animation stopped");
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
}
}
@@ -1127,331 +658,6 @@
TRACES("CStartupAppUi::ExitApplication(): End");
}
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
-// ---------------------------------------------------------------------------
-// CStartupAppUi::ShowWelcomeAnimationL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::ShowWelcomeAnimationL()
- {
- TRACES("CStartupAppUi::ShowWelcomeAnimationL()");
- __ASSERT_DEBUG( iWelcomeAnimation , PANIC( EStartupPanicClassMemberVariableIsNull ) );
- TInt showtime = iWelcomeAnimation->ShowingTime();
- iAnimation = ETrue;
- TRACES("CStartupAppUi::ShowWelcomeAnimationL(): Animation timer started");
- iAnimTimer->Start(
- showtime*KOneMilliSecondInMicroSeconds,
- showtime*KOneMilliSecondInMicroSeconds,
- TCallBack( DoStopTimingL, this ) );
- iWelcomeAnimation->StartL();
- TRACES("CStartupAppUi::ShowWelcomeAnimationL(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::ShowOperatorAnimationL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::ShowOperatorAnimationL()
- {
- TRACES("CStartupAppUi::ShowOperatorAnimationL()");
- __ASSERT_DEBUG( iOperatorAnimation , PANIC( EStartupPanicClassMemberVariableIsNull ) );
- TInt showtime = iOperatorAnimation->ShowingTime();
- iAnimation = ETrue;
- TRACES("CStartupAppUi::ShowWelcomeAnimationL(): Operator Animation timer started");
- iAnimTimer->Start(
- showtime*KOneMilliSecondInMicroSeconds,
- showtime*KOneMilliSecondInMicroSeconds,
- TCallBack( DoStopTimingL, this ) );
- iOperatorAnimation->StartL();
- TRACES("CStartupAppUi::ShowOperatorAnimationL(): End");
- }
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::ShowUserWelcomeNoteL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::ShowUserWelcomeNoteL()
- {
- TRACES("CStartupAppUi::ShowUserWelcomeNoteL()");
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iUserWelcomeNote = CStartupUserWelcomeNote::NewL( *this, ClientRect(), *iMainView );
- TStartupNoteTypeInformation type = iUserWelcomeNote->NoteTypeInformation();
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- __ASSERT_DEBUG( iUserWelcomeNote , PANIC( EStartupPanicClassMemberVariableIsNull ) );
- TStartupNoteTypeInformation type;
- type = iUserWelcomeNote->NoteTypeInformation();
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
- if( type == EStartupImage )
- {
- // UserWelcomeNote type is EStartupImage
- // This type of note is shown fixed (KUserWelcomeNoteShowPeriodTime) time
- TRACES("CStartupAppUi::ShowUserWelcomeNoteL(): UWNTimer started (graphic)");
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iAnimation = EFalse;
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
- iNoteTimer->Start(
- KUserWelcomeNoteShowPeriodTime,
- KUserWelcomeNoteShowPeriodTime,
- TCallBack( DoStopTimingL, this ) );
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iUserWelcomeNote->StartL();
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
- }
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
- else if ( type == EStartupText )
- {
- TRACES("CStartupAppUi::ShowUserWelcomeNoteL(): Text UWN");
-
- iUserWelcomeNote->StartL();
-
- UpdateStartupUiPhase( EStartupUiPhaseUserWelcomeDone );
-
- DoNextStartupPhaseL( EStartupFirstBootAndRTCCheck );
- }
- else
- {
- TRACES("CStartupAppUi::ShowUserWelcomeNoteL(): No UWN");
-
- DoNextStartupPhaseL( EStartupFirstBootAndRTCCheck );
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- else
- {
- //if User Welcome Note type is ETextWelcomeNote nothing to do here,
- //because it is implemented with Avkon globalnote
- //or if type is EDefaultWelcomeNote no User Welcome Note is shown.
- TRACES("CStartupAppUi::ShowUserWelcomeNoteL(): No UWN to show or UWN is text");
- }
- //invoke welcome note container to show note
- iUserWelcomeNote->StartL();
-
- if( type == EStartupText || type == EStartupNoNote)
- {
- //this is called already here because timer not activated in text uwn case
- //and so DoStopTimingL() is never called and should be called here.
- StopTimingL();
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
- }
-
- TRACES("CStartupAppUi::ShowUserWelcomeNoteL(): End");
- }
-
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
-// ---------------------------------------------------------------------------
-// CStartupAppUi::WaitingTouchScreenCalibL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::WaitingTouchScreenCalibL()
- {
- TRACES("CStartupAppUi::WaitingTouchScreenCalibL()");
-#ifdef RD_SCALABLE_UI_V2
-
- if( iFirstBoot && iTouchScreenCalibSupport )
- {
- if (iTouchScreenCalibrationDone)
- {
- TRACES("CStartupAppUi::WaitingTouchScreenCalibL(): Calibration already done. Continue boot up");
- DoNextStartupPhaseL( EStartupOfflineModeQuery );
- }
- else
- {
- SendToBackground();
-
- iWelcomeAnimation->UpdateDrawInfo( EStartupDITouchScreenCalib );
- iWelcomeAnimation->DrawNow();
- TRACES("CStartupAppUi::WaitingTouchScreenCalibL(): Startup sequence halted until Touch Screen Calibration is done");
- }
- }
- else
- {
- TRACES("CStartupAppUi::WaitingTouchScreenCalibL(): Not first boot or calibration not supported. Continue boot up");
- DoNextStartupPhaseL( EStartupOfflineModeQuery );
- }
-
-#else // !RD_SCALABLE_UI_V2
- TRACES("CStartupAppUi::WaitingTouchScreenCalibL(): Calibration not supported. Continue boot up");
- DoNextStartupPhaseL( EStartupOfflineModeQuery );
-
-#endif // RD_SCALABLE_UI_V2
- TRACES("CStartupAppUi::WaitingTouchScreenCalibL(): End");
- }
-
-#ifdef RD_SCALABLE_UI_V2
-// ---------------------------------------------------------------------------
-// CStartupAppUi::TouchScreenCalibrationDoneL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::TouchScreenCalibrationDoneL()
- {
- TRACES("CStartupAppUi::TouchScreenCalibrationDoneL()");
- if (iInternalState == EStartupWaitingTouchScreenCalib)
- {
- iTouchScreenCalibrationDone = ETrue;
- BringToForeground();
- DoNextStartupPhaseL( EStartupOfflineModeQuery );
- }
- else
- {
- iTouchScreenCalibrationDone = ETrue;
- }
- TRACES("CStartupAppUi::TouchScreenCalibrationDoneL(): End");
- }
-#endif // RD_SCALABLE_UI_V2
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
-
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
-// ---------------------------------------------------------------------------
-// CStartupAppUi::CoverUIWelcomeAnimationSyncOKL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::CoverUIWelcomeAnimationSyncOKL()
- {
- TRACES("CStartupAppUi::CoverUIWelcomeAnimationSyncOKL()");
- DoNextStartupPhaseL( EStartupWaitingStartupTone );
- TRACES("CStartupAppUi::CoverUIWelcomeAnimationSyncOKL(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::WaitingCoverUIWelcomeAnimationSyncL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::WaitingCoverUIWelcomeAnimationSyncL()
- {
- TRACES("CStartupAppUi::WaitingCoverUIWelcomeAnimationSyncL()");
- if (iCoverUISupported)
- {
- iStartupMediatorObserver->IssueCommand(SecondaryDisplay::ECmdStartupSync,
- SecondaryDisplay::EStartWelcomeAnimation);
- }
- else
- {
- DoNextStartupPhaseL( EStartupWaitingStartupTone );
- }
- TRACES("CStartupAppUi::WaitingCoverUIWelcomeAnimationSyncL(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::CoverUIOperatorAnimationSyncOKL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::CoverUIOperatorAnimationSyncOKL()
- {
- TRACES("CStartupAppUi::CoverUIOperatorAnimationSyncOKL()");
- DoNextStartupPhaseL( EStartupShowingOperatorAnimation );
- TRACES("CStartupAppUi::CoverUIOperatorAnimationSyncOKL(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::WaitingCoverUIOperatorAnimationSyncL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::WaitingCoverUIOperatorAnimationSyncL()
- {
- TRACES("CStartupAppUi::WaitingCoverUIOperatorAnimationSyncL()");
- if (iCoverUISupported)
- {
- if (iOperatorAnimation->ShowingTime())
- {
- iStartupMediatorObserver->IssueCommand(SecondaryDisplay::ECmdStartupSync,
- SecondaryDisplay::EStartOperatorAnimation );
- }
- else
- {
- DoNextStartupPhaseL( EStartupShowingOperatorAnimation );
- }
- }
- else
- {
- DoNextStartupPhaseL( EStartupShowingOperatorAnimation );
- }
- TRACES("CStartupAppUi::WaitingCoverUIOperatorAnimationSyncL(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::WaitingStartupToneL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::WaitingStartupToneL()
- {
- if( iStartupTone->ToneFound() && !iStartupTone->AudioReady() )
- {
- TRACES("CStartupAppUi::WaitingStartupToneL(): Startup tone found but not ready. Waiting tone to init");
- iToneInitTimer = CPeriodic::NewL( EPriorityNormal );
- iToneInitTimer->Start( KOneMilliSecondInMicroSeconds,
- KOneMilliSecondInMicroSeconds,
- TCallBack( ToneInitTimerTimeoutL, this ) );
- }
- else
- {
- TRACES("CStartupAppUi::WaitingStartupToneL(): Audio ready");
- DoNextStartupPhaseL( EStartupShowingWelcomeAnimation );
- }
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::ToneInitTimerTimeoutL()
-// ---------------------------------------------------------------------------
-TInt CStartupAppUi::ToneInitTimerTimeoutL(TAny* aObject)
- {
- STATIC_CAST( CStartupAppUi*, aObject )->StartupToneWaitStatusL(); // cast, and call non-static function
- return KErrNone;
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::StartupToneWaitStatusL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::StartupToneWaitStatusL()
- {
- iToneInitWaitTime++;
- TRACES1("CStartupAppUi::StartupToneWaitStatusL(): Total tone init wait time = %d ms", iToneInitWaitTime );
- TBool audioReady = iStartupTone->AudioReady();
- if ( audioReady || (iToneInitWaitTime>=KMaxToneInitWait) )
- {
- iToneInitTimer->Cancel();
- delete iToneInitTimer;
- iToneInitTimer = NULL;
-
- TRACES1("CStartupAppUi::StartupToneWaitStatusL(): AudioReady: %d, proceed", audioReady );
- DoNextStartupPhaseL( EStartupShowingWelcomeAnimation );
- }
- }
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::CoverUIStartupReadySyncOKL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::CoverUIStartupReadySyncOKL()
- {
- TRACES("CStartupAppUi::CoverUIStartupReadySyncOKL()");
- DoNextStartupPhaseL( EStartupStartupOK );
- TRACES("CStartupAppUi::CoverUIStartupReadySyncOKL(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::WaitingCoverUIStartupReadySyncL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::WaitingCoverUIStartupReadySyncL()
- {
- TRACES("CStartupAppUi::WaitingCoverUIStartupReadySyncL()");
- if (iCoverUISupported)
- {
- iStartupMediatorObserver->IssueCommand(SecondaryDisplay::ECmdStartupSync,
- SecondaryDisplay::EStartStartupReady);
- }
- else
- {
- DoNextStartupPhaseL( EStartupStartupOK );
- }
- TRACES("CStartupAppUi::WaitingCoverUIStartupReadySyncL(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::RaiseCoverUIEvent()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::RaiseCoverUIEvent( TUid aCategory,
- TInt aEventId,
- const TDesC8& aData )
- {
- TRACES("CStartupAppUi::RaiseCoverUIEvent()");
- if (iCoverUISupported)
- {
- iStartupMediatorObserver->RaiseEvent( aCategory,
- aEventId,
- aData );
- }
- TRACES("CStartupAppUi::RaiseCoverUIEvent(): End");
- }
-
// ---------------------------------------------------------------------------
// CStartupAppUi::SetCriticalBlockEndedL()
// ---------------------------------------------------------------------------
@@ -1476,11 +682,8 @@
if( iCriticalBlockEnded )
{
TRACES("CStartupAppUi::WaitingCriticalBlockEndingL(): CriticalBlock has ended. Continue.");
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
DoNextStartupPhaseL( EStartupOfflineModeQuery );
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- DoNextStartupPhaseL( EStartupWaitingTouchScreenCalib );
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
}
TRACES("CStartupAppUi::WaitingCriticalBlockEndingL(): End");
}
@@ -1525,7 +728,7 @@
{
TRACES("CStartupAppUi::SetEmergencyCallsOnlyL(): Entered emergency calls only state.");
- DoNextStartupPhaseL( EStartupWaitingCUIStartupReady );
+ DoNextStartupPhaseL( EStartupStartupOK );
}
TRACES("CStartupAppUi::SetEmergencyCallsOnlyL(): End");
}
@@ -1547,28 +750,6 @@
TRACES("CStartupAppUi::SwStateFatalStartupErrorL(): End");
}
-
-
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
-// ---------------------------------------------------------------------------
-// CStartupAppUi::GetOfflineModeQueryShown()
-// ---------------------------------------------------------------------------
-TBool CStartupAppUi::GetOfflineModeQueryShown()
- {
- TRACES1("CStartupAppUi::GetOfflineModeQueryShown(): iOfflineModeQueryShown == %d ", iOfflineModeQueryShown );
- return iOfflineModeQueryShown;
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::SetOfflineModeQueryShown()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::SetOfflineModeQueryShown(TBool aValue)
- {
- TRACES1("CStartupAppUi::SetOfflineModeQueryShown(): iOfflineModeQueryShown == %d ", iOfflineModeQueryShown );
- iOfflineModeQueryShown = aValue;
- }
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
-
// ----------------------------------------------------------------------------
// CStartAppUi::DosInOfflineModeL()
// ----------------------------------------------------------------------------
@@ -1651,20 +832,23 @@
else if ( iOfflineModeSupported && DosInOfflineModeL() )
{
TRACES("CStartupAppUi::ShowOfflineModeQueryL(): Offline mode query needed");
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
RProperty::Set( KPSUidStartup, KPSSplashShutdown, ESplashShutdown );
iAnimation->BringToForeground();
iMainView->DrawDeferred();
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- iWelcomeAnimation->UpdateDrawInfo( EStartupDIQueriesOn );
- iWelcomeAnimation->DrawNow();
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
iOfflineModeQueryShown = ETrue;
- CAknQueryDialog* dlg = new (ELeave) CAknQueryDialog( CAknQueryDialog::ENoTone );
- TRACES("CStartupAppUi::ShowOfflineModeQueryL(): Publish dialog for Secondary UI");
- dlg->PublishDialogL(SecondaryDisplay::ECmdShowOfflineQuery,
- SecondaryDisplay::KCatStartup);
- if ( dlg->ExecuteLD( R_STARTUP_OFFLINE_MODE_QUERY ) )
+ CHbDeviceMessageBoxSymbian *aMessageBox = NULL;
+ aMessageBox = CHbDeviceMessageBoxSymbian::NewL(CHbDeviceMessageBoxSymbian::EQuestion);
+ _LIT(KText, "Continue using phone in Offline mode?");
+ aMessageBox->SetTextL(KText);
+ _LIT(KAcceptText, "Yes");
+ aMessageBox->SetButtonTextL(CHbDeviceMessageBoxSymbian::EAcceptButton, KAcceptText);
+ _LIT(KRejectText, "No");
+ aMessageBox->SetButtonTextL(CHbDeviceMessageBoxSymbian::ERejectButton, KRejectText);
+ //aMessageBox->SetDismissPolicy(HbPopup::NoDismiss);
+ //define the selection button to hold user's option choice
+ CHbDeviceMessageBoxSymbian::TButtonId selection;
+ selection = aMessageBox->ExecL();
+ if ( selection == CHbDeviceMessageBoxSymbian::EAcceptButton )
{
TRACES("CStartupAppUi::ShowOfflineModeQueryL(): Offline Mode query: YES -> Boot to Offline");
reply = 1;
@@ -1698,7 +882,7 @@
{
TRACES1("CStartupAppUi::ShowOfflineModeQueryL(): KStartupBootIntoOffline set err %d", err);
}
-
+
TRACES("CStartupAppUi::ShowOfflineModeQueryL(): End");
}
@@ -1708,395 +892,13 @@
void CStartupAppUi::CancelAnimation()
{
TRACES("CStartupAppUi::CancelAnimation()");
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
iAnimation->Cancel();
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- iWelcomeAnimation->CancelAnimation();
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
TRACES("CStartupAppUi::CancelAnimation(): End");
}
-// ---------------------------------------------------------------------------
-// CStartupAppUi::ShowCountryAndCityListsL()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::ShowCountryAndCityListsL()
- {
- TRACES("CStartupAppUi::ShowCountryAndCityListsL()");
- TInt cityselected( EFalse );
- while ( !cityselected )
- {
- TRACES1("CStartupAppUi::ShowCountryAndCityListsL(): City item to focus: %d", iCounryListIndex);
- TInt cityGroupId = ShowCountryListL();
- TRACES1("CStartupAppUi::ShowCountryAndCityListsL(): City group id: %d", cityGroupId);
- if ( cityGroupId != KErrCancel )
- {
- cityselected = ShowCityListL(cityGroupId);
- }
- else
- {
- cityselected = ETrue;
- }
- }
- TRACES("CStartupAppUi::ShowCountryAndCityListsL(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::ShowCountryListL()
-// ---------------------------------------------------------------------------
-TInt CStartupAppUi::ShowCountryListL()
- {
- TRACES("CStartupAppUi::ShowCountryListL()");
-
- CAknSinglePopupMenuStyleListBox* listBox =
- new(ELeave) CAknSinglePopupMenuStyleListBox;
- CleanupStack::PushL(listBox);
-
- CStartupPopupList* popupList = CStartupPopupList::NewL(listBox, R_AVKON_SOFTKEYS_SELECT_CANCEL__SELECT,
- AknPopupLayouts::EMenuGraphicHeadingWindow );
-
- CleanupStack::PushL(popupList);
-
- listBox->ConstructL(popupList, EAknListBoxSelectionList | EAknListBoxScrollBarSizeExcluded);
- listBox->CreateScrollBarFrameL( ETrue );
- listBox->ScrollBarFrame()->SetScrollBarVisibilityL( CEikScrollBarFrame::EOff,
- CEikScrollBarFrame::EAuto );
-
- listBox->ItemDrawer()->FormattedCellData()->EnableMarqueeL( ETrue );
-
- CDesCArrayFlat *items = new(ELeave)CDesCArrayFlat(1);
-
- CleanupStack::PushL(items);
-
- CTzLocalizer* tzLocalizer = CTzLocalizer::NewL();
- CleanupStack::PushL(tzLocalizer);
-
- CTzLocalizedCityGroupArray* countryList;
- countryList = tzLocalizer->GetAllCityGroupsL(CTzLocalizer::ETzAlphaNameAscending);
- CleanupStack::PushL(countryList);
-
- TRACES("CStartupAppUi::ShowCountryListL(): Create list of cities");
- for(TInt i = 0; i <countryList->Count(); i++)
- {
- CTzLocalizedCityGroup& cityGroup = countryList->At(i);
-
- // Check if the country name is blank.
- // If it is blank, ignore it. Empty name shouldn't be shown in the list.
- if(cityGroup.Name().Compare(KEmpty) != 0)
- {
- TBuf<KMaxCountryLength> countryitem;
- countryitem.Insert(0,cityGroup.Name());
- TRACES1("CStartupAppUi::ShowCountryListL(): Create country to list: %S", &countryitem);
- items->AppendL(countryitem);
- }
- }
-
- CleanupStack::PopAndDestroy( countryList );
-
- CTextListBoxModel* model=listBox->Model();
- model->SetItemTextArray(items);
- model->SetOwnershipType(ELbmOwnsItemArray);
-
- TRACES("CStartupAppUi::ShowCountryListL(): Set title");
- // Set title
- HBufC* title = StringLoader::LoadLC( R_QTN_SU_SELECT_COUNTRY );
- popupList->SetTitleL(title->Des());
- CleanupStack::PopAndDestroy( title );
-
- popupList->EnableAdaptiveFind();
- listBox->SetCurrentItemIndex(iCounryListIndex);
-
- TInt cityGroupId;
-
- if (iCoverUISupported)
- {
- TRACES("CStartupAppUi::ShowCountryListL(): Publish country list for Secondary UI");
- TPckgBuf<TInt> data( SecondaryDisplay::EShowCountryQuery );
- iStartupMediatorObserver->RaiseEvent( SecondaryDisplay::KCatStartup,
- SecondaryDisplay::EMsgStartupEvent,
- data );
- }
-
- TRACES("CStartupAppUi::ShowCountryListL(): Show the list");
- if (popupList->ExecuteLD())
- {
- iCounryListIndex = listBox->CurrentItemIndex();
- TRACES1("CStartupAppUi::ShowCountryListL(): CurrentItemIndex: %d", iCounryListIndex);
- TPtrC countryName = listBox->Model()->ItemText(iCounryListIndex);
-
- CTzLocalizedCityGroup* tzLocalizedCityGroup = tzLocalizer->FindCityGroupByNameL(countryName);
- CleanupStack::PushL(tzLocalizedCityGroup);
-
- cityGroupId = tzLocalizedCityGroup->Id();
- CleanupStack::PopAndDestroy( tzLocalizedCityGroup );
-
- TRACES1("CStartupAppUi::ShowCountryListL(): Selected country %S", &countryName);
- }
- else
- {
- TRACES("CStartupAppUi::ShowCountryListL(): Country list cancelled");
- cityGroupId = KErrCancel;
- }
-
- CleanupStack::PopAndDestroy( tzLocalizer );
- CleanupStack::Pop( items );
- CleanupStack::Pop( popupList );
- CleanupStack::PopAndDestroy( listBox );
-
- TRACES1("CStartupAppUi::ShowCountryListL(): End. Return city group id: %d", cityGroupId);
- return cityGroupId;
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::ShowCityListL()
-// ---------------------------------------------------------------------------
-TBool CStartupAppUi::ShowCityListL(TUint8 cityGroupId)
- {
- TRACES("CStartupAppUi::ShowCityListL()");
-
- TBool retval( ETrue );
-
- CTzLocalizer* tzLocalizer = CTzLocalizer::NewL();
- CleanupStack::PushL(tzLocalizer);
-
- CTzLocalizedCityArray* cityList;
-
- TRACES1("CStartupAppUi::ShowCityListL(): Create list of cities in group %d", cityGroupId);
-
- cityList = tzLocalizer->GetCitiesInGroupL(cityGroupId,//cityGroup.Id(),
- CTzLocalizer::ETzAlphaNameAscending );
- CleanupStack::PushL(cityList);
-
- if ( cityList->Count() == 1 )
- {
- TRACES("CStartupAppUi::ShowCityListL(): Only one city in citygroup. This can be selected automatically.");
-
- CTzLocalizedCity& city = cityList->At(0);
-
- CTzLocalizedCity* tzLocalizedCity = tzLocalizer->FindCityByNameL(city.Name());
- CleanupStack::PushL(tzLocalizedCity);
-
- TInt timeZoneId = tzLocalizedCity->TimeZoneId();
-
- tzLocalizer->SetTimeZoneL(timeZoneId);
- tzLocalizer->SetFrequentlyUsedZoneL(*tzLocalizedCity, CTzLocalizedTimeZone::ECurrentZone);
-
- CleanupStack::PopAndDestroy( tzLocalizedCity );
- CleanupStack::PopAndDestroy( cityList );
- CleanupStack::PopAndDestroy( tzLocalizer );
-
- TRACES1("CStartupAppUi::ShowCityListL(): End, returns %d", retval);
- return retval;
- }
-
- CAknSinglePopupMenuStyleListBox* listBox =
- new(ELeave) CAknSinglePopupMenuStyleListBox;
- CleanupStack::PushL(listBox);
-
- CStartupPopupList* popupList = CStartupPopupList::NewL(listBox, R_AVKON_SOFTKEYS_SELECT_CANCEL__SELECT,
- AknPopupLayouts::EMenuGraphicHeadingWindow );
-
- CleanupStack::PushL(popupList);
-
- CDesCArrayFlat *items = new(ELeave)CDesCArrayFlat(1);
-
- CleanupStack::PushL(items);
-
- for(TInt j = 0; j < cityList->Count(); j++)
- {
- CTzLocalizedCity& city = cityList->At(j);
-
- // Check if the city name is blank.
- // If it is blank, ignore it. Empty name shouldn't be shown in the list.
- if(city.Name().Compare(KEmpty) != 0)
- {
- TBuf<KMaxCityLength> homecityitem;
- homecityitem.Insert(0,city.Name());
- TRACES1("CStartupAppUi::ShowCityListL(): Create to list: %S", &homecityitem);
- items->AppendL(homecityitem);
- }
- }
-
- listBox->ConstructL(popupList, EAknListBoxSelectionList | EAknListBoxScrollBarSizeExcluded);
- listBox->CreateScrollBarFrameL( ETrue );
- listBox->ScrollBarFrame()->SetScrollBarVisibilityL( CEikScrollBarFrame::EOff,
- CEikScrollBarFrame::EAuto );
-
- listBox->ItemDrawer()->FormattedCellData()->EnableMarqueeL( ETrue );
-
- CTextListBoxModel* model=listBox->Model();
- model->SetItemTextArray(items);
- model->SetOwnershipType(ELbmOwnsItemArray);
-
- TRACES("CStartupAppUi::ShowCityListL(): Set title");
- // Set title
- HBufC* title = StringLoader::LoadLC( R_QTN_SU_SELECT_CITY );
- popupList->SetTitleL(title->Des());
- CleanupStack::PopAndDestroy(title);
-
- popupList->EnableAdaptiveFind();
-
- if (iCoverUISupported)
- {
- TRACES("CStartupAppUi::ShowCountryListL(): Publish city list for Secondary UI");
- TPckgBuf<TInt> data( SecondaryDisplay::EShowCityQuery );
- iStartupMediatorObserver->RaiseEvent( SecondaryDisplay::KCatStartup,
- SecondaryDisplay::EMsgStartupEvent,
- data );
- }
-
- TRACES("CStartupAppUi::ShowCityListL(): Show the list");
- if (popupList->ExecuteLD())
- {
- TInt index(listBox->CurrentItemIndex());
- TRACES1("CStartupAppUi::ShowCityListL(): CurrentItemIndex: %d", index);
- TPtrC cityName = listBox->Model()->ItemText(index);
-
- CTzLocalizedCity* tzLocalizedCity = tzLocalizer->FindCityByNameL(cityName);
- CleanupStack::PushL(tzLocalizedCity);
-
- TInt timeZoneId = tzLocalizedCity->TimeZoneId();
-
- tzLocalizer->SetTimeZoneL(timeZoneId);
- tzLocalizer->SetFrequentlyUsedZoneL(*tzLocalizedCity, CTzLocalizedTimeZone::ECurrentZone);
-
- CleanupStack::PopAndDestroy(tzLocalizedCity);
-
- TRACES1("CStartupAppUi::ShowCityListL(): Selected city %S", &cityName);
- }
- else
- {
- TRACES("CStartupAppUi::ShowCityListL(): City list cancelled");
- retval = EFalse;
- }
-
- CleanupStack::Pop(items);
- CleanupStack::Pop(popupList);
- CleanupStack::PopAndDestroy(listBox);
- CleanupStack::PopAndDestroy(cityList);
- CleanupStack::PopAndDestroy(tzLocalizer);
-
-
- TRACES("CStartupAppUi::ShowCityListL(): Home city selected");
- TRACES1("CStartupAppUi::ShowCityListL(): End, return %d", retval);
- return retval;
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::ShowTimeQueryL()
-// ---------------------------------------------------------------------------
-TBool CStartupAppUi::ShowTimeQueryL()
- {
- TRACES("CStartupAppUi::ShowTimeQueryL()");
-
- TTime time;
- GetDefaultTimeAndDate( time );
-
- CStartupQueryDialog* dlg = new (ELeave) CStartupQueryDialog(time, CAknQueryDialog::ENoTone);
- TRACES("CStartupAppUi::ShowTimeQueryL(): Publish dialog for Secondary UI");
- dlg->PublishDialogL(SecondaryDisplay::ECmdShowTimeQuery, SecondaryDisplay::KCatStartup);
- if( dlg->ExecuteLD( R_STARTUP_TIME_SETTING_QUERY ) )
- {
- TTime current;
- current.HomeTime();
- TDateTime cTime = current.DateTime();
- TDateTime atime = time.DateTime();
- atime.SetYear(cTime.Year());
- atime.SetMonth(cTime.Month());
- atime.SetDay(cTime.Day());
- time = atime;
-
- RTz rtz;
- User::LeaveIfError(rtz.Connect());
- User::LeaveIfError(rtz.SetHomeTime(time));
- rtz.Close();
-
- TRACES("CStartupAppUi::ShowTimeQueryL(): End, return ETrue");
- return ETrue;
- }
- else
- {
- //in case of poweroff key was pressed and shutdown is occuring
- TRACES("CStartupAppUi::ShowTimeQueryL(): End, return EFalse");
- return EFalse;
- }
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::ShowDateQueryL()
-// ---------------------------------------------------------------------------
-TBool CStartupAppUi::ShowDateQueryL()
- {
- TRACES("CStartupAppUi::ShowDateQueryL()");
-
-
- CStartupQueryDialog* dlg = new (ELeave) CStartupQueryDialog(iTime, CAknQueryDialog::ENoTone);
- TRACES("CStartupAppUi::ShowDateQueryL(): Publish dialog for Secondary UI");
- dlg->PublishDialogL(SecondaryDisplay::ECmdShowDateQuery, SecondaryDisplay::KCatStartup);
-
- TInt query( R_STARTUP_DATE_SETTING_QUERY_NOBACK );
- if ( iFirstBoot )
- {
- query = R_STARTUP_DATE_SETTING_QUERY;
- }
-
- if( dlg->ExecuteLD( query ) )
- {
- TTime current;
- current.HomeTime();
- TDateTime cTime = current.DateTime();
- TDateTime atime = iTime.DateTime();
- atime.SetHour(cTime.Hour());
- atime.SetMinute(cTime.Minute());
- atime.SetSecond(cTime.Second());
- atime.SetMicroSecond(cTime.MicroSecond());
- iTime = atime;
-
- RTz rtz;
- User::LeaveIfError(rtz.Connect());
- User::LeaveIfError(rtz.SetHomeTime(iTime));
- rtz.Close();
-
- TRACES("CStartupAppUi::ShowDateQueryL(): End, return ETrue");
- return ETrue;
- }
- else
- {
- // Back key pressed. ( Or poweroff key was pressed and shutdown is occuring )
- TRACES("CStartupAppUi::ShowDateQueryL(): End, return EFalse");
- return EFalse;
- }
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::GetDefaultTimeAndDate()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::GetDefaultTimeAndDate( TTime& aTime )
- {
- TRACES("CStartupAppUi::GetDefaultTimeAndDate(): Get Time and Date from CenRep");
-
- CRepository* repository(NULL);
-
- TRAPD( err, repository = CRepository::NewL( KCRUidStartupConf ) );
- if ( !err )
- {
- TBuf<KTimeFormatLength> buf;
- err = repository->Get( KStartupDefaultTime, buf );
- if( !err )
- {
- err = aTime.Set(buf); // returns error if cenrep time format not valid
- }
- }
-
- if ( err )
- {
- TRACES("CStartupAppUi::GetDefaultTimeAndDate(): Failed to get valid data from CenRep. Using default");
- aTime.Set(KDefaultDateTimeValue);
- }
-
- delete repository;
- TRACES("CStartupAppUi::GetDefaultTimeAndDate(): End");
- }
// ---------------------------------------------------------------------------
// CStartupAppUi::FirstBoot()
@@ -2198,7 +1000,7 @@
}
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
// ---------------------------------------------------------------------------
// CStartupAppUi::AnimationFinished()
// ---------------------------------------------------------------------------
@@ -2240,7 +1042,7 @@
}
else if ( iInternalState == EStartupShowingOperatorAnimation )
{
- TRAP(err, DoNextStartupPhaseL( EStartupShowingUserWelcomeNote ));
+ TRAP(err, DoNextStartupPhaseL( EStartupFirstBootAndRTCCheck));
}
if ( err != KErrNone )
@@ -2250,51 +1052,6 @@
TRACES("CStartupAppUi::AnimationFinished(): End");
}
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
-// ---------------------------------------------------------------------------
-// CStartupAppUi::StopStartupTone()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::StopStartupTone()
- {
- TRACES("CStartupAppUi::StopStartupTone()");
- if ((iStartupTone) && (iStartupTone->Playing()))
- {
- iStartupTone->Stop();
- }
- TRACES("CStartupAppUi::StopStartupTone(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::StopOperatorTone()
-// ---------------------------------------------------------------------------
-void CStartupAppUi::StopOperatorTone()
- {
- TRACES("CStartupAppUi::StopOperatorTone()");
- if ((iOpStartupTone) && (iOpStartupTone->Playing()))
- {
- iOpStartupTone->Stop();
- }
- TRACES("CStartupAppUi::StopOperatorTone(): End");
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::StartupTonePlaying()
-// ---------------------------------------------------------------------------
-TBool CStartupAppUi::StartupTonePlaying()
- {
- TRACES("CStartupAppUi::StartupTonePlaying()");
- return iStartupTone->Playing();
- }
-
-// ---------------------------------------------------------------------------
-// CStartupAppUi::OperatorTonePlaying()
-// ---------------------------------------------------------------------------
-TBool CStartupAppUi::OperatorTonePlaying()
- {
- TRACES("CStartupAppUi::OperatorTonePlaying()");
- return iOpStartupTone->Playing();
- }
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
// ---------------------------------------------------------------------------
// CStartupAppUi::SetCleanBoot()
@@ -2315,14 +1072,7 @@
return iSimSupported;
}
-// ----------------------------------------------------------------------------
-// CStartupAppUi::CoverUISupported()
-// ----------------------------------------------------------------------------
-TBool CStartupAppUi::CoverUISupported()
- {
- TRACES("CStartupAppUi::CoverUISupported()");
- return iCoverUISupported;
- }
+
// ---------------------------------------------------------------------------
// CStartupAppUi::DoNextStartupPhaseL( TStartupInternalState toState )
@@ -2334,14 +1084,14 @@
// 5 EStartupWaitingTouchScreenCalib
// 6 EStartupWaitingPhoneLightIdle 8, 18
// 8 EStartupOfflineModeQuery 9, 18
-// 9 EStartupWaitingCUIWelcomeAnim 10, 18
+// 9 EStartupWaitingCUIWelcomeAnim 10, 18 Removed
// 10 EStartupWaitingStartupTone 11, 18
// 11 EStartupShowingWelcomeAnimation 12, 14, 18
// 12 EStartupWaitingCUIOperatorAnim 13, 18
// 13 EStartupShowingOperatorAnimation 14, 14, 18
-// 14 EStartupShowingUserWelcomeNote 15, 18
+// 14 EStartupShowingUserWelcomeNote 15, 18 Removed
// 15 EStartupFirstBootAndRTCCheck 16, 18
-// 16 EStartupWaitingCUIStartupReady 17, 18
+// 16 EStartupWaitingCUIStartupReady 17, 18 Removed
// 17 EStartupStartupOK -
// 18 EStartupSystemFatalError -
@@ -2377,42 +1127,18 @@
{
switch( toState )
{
- case EStartupWaitingCUIStartupReady:
- iInternalState = EStartupWaitingCUIStartupReady;
- TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupWaitingCUIStartupReady");
- WaitingCoverUIStartupReadySyncL();
- break;
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- case EStartupWaitingTouchScreenCalib:
- iInternalState = EStartupWaitingTouchScreenCalib;
- TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupWaitingTouchScreenCalib");
- WaitingTouchScreenCalibL();
- break;
- case EStartupSystemFatalError:
- SystemFatalErrorL();
+ case EStartupStartupOK:
+ iInternalState = EStartupStartupOK;
+ TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupStartupOK");
+ DoStartupEndPart();
break;
- default:
- __ASSERT_DEBUG(
- EFalse,
- PANIC( EStartupInvalidInternalStateChange ) );
- break;
- }
- }
- break;
- case EStartupWaitingTouchScreenCalib:
- {
- switch( toState )
- {
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
case EStartupOfflineModeQuery:
iInternalState = EStartupOfflineModeQuery;
TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupOfflineModeQuery");
ShowOfflineModeQueryL();
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
DoNextStartupPhaseL( EStartupWaitingShowStartupAnimation );
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- DoNextStartupPhaseL( EStartupWaitingCUIWelcomeAnim );
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
break;
case EStartupSystemFatalError:
SystemFatalErrorL();
@@ -2429,20 +1155,13 @@
{
switch( toState )
{
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
case EStartupWaitingShowStartupAnimation:
iInternalState = EStartupWaitingShowStartupAnimation;
TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupWaitingShowStartupAnimation");
WaitingStartupAnimationStartL();
break;
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- case EStartupWaitingCUIWelcomeAnim:
- iInternalState = EStartupWaitingCUIWelcomeAnim;
- TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupWaitingCUIWelcomeAnim");
- WaitingCoverUIWelcomeAnimationSyncL();
- break;
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
- case EStartupSystemFatalError:
+ case EStartupSystemFatalError:
SystemFatalErrorL();
break;
default:
@@ -2453,50 +1172,6 @@
}
}
break;
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- case EStartupWaitingCUIWelcomeAnim:
- {
- switch( toState )
- {
- case EStartupWaitingStartupTone:
- iInternalState = EStartupWaitingStartupTone;
- TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupWaitingStartupTone");
- WaitingStartupToneL();
- break;
- case EStartupSystemFatalError:
- SystemFatalErrorL();
- break;
- default:
- __ASSERT_DEBUG( EFalse,
- PANIC( EStartupInvalidInternalStateChange ) );
- break;
- }
- }
- break;
- case EStartupWaitingStartupTone:
- {
- switch( toState )
- {
- case EStartupShowingWelcomeAnimation:
- iInternalState = EStartupShowingWelcomeAnimation;
- TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupShowingWelcomeAnimation");
- iWelcomeAnimation->UpdateDrawInfo( EStartupDIWelcomeAnimStart );
- iWelcomeAnimation->DrawNow();
- DoStartupShowWelcomeAnimationL();
- iWelcomeAnimation->UpdateDrawInfo( EStartupDIWelcomeAnimEnd );
- iWelcomeAnimation->DrawNow();
- break;
- case EStartupSystemFatalError:
- SystemFatalErrorL();
- break;
- default:
- __ASSERT_DEBUG( EFalse,
- PANIC( EStartupInvalidInternalStateChange ) );
- break;
- }
- }
- break;
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
case EStartupWaitingShowStartupAnimation:
{
switch( toState )
@@ -2521,19 +1196,11 @@
{
switch( toState )
{
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
case EStartupShowingOperatorAnimation:
iInternalState = EStartupShowingOperatorAnimation;
TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState: EStartupShowingOperatorAnimation");
DoStartupShowOperatorAnimationL();
-#else // RD_STARTUP_ANIMATION_CUSTOMIZATION
- case EStartupWaitingCUIOperatorAnim:
- iOperatorAnimation = CStartupOperatorAnimation::NewL( this, ClientRect());
- AddToStackL( iOperatorAnimation);
- iInternalState = EStartupWaitingCUIOperatorAnim;
- TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState: EStartupWaitingCUIOperatorAnim");
- WaitingCoverUIOperatorAnimationSyncL();
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
break;
case EStartupFirstBootAndRTCCheck:
iInternalState = EStartupFirstBootAndRTCCheck;
@@ -2550,45 +1217,12 @@
}
}
break;
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- case EStartupWaitingCUIOperatorAnim:
- {
- switch( toState )
- {
- case EStartupShowingOperatorAnimation:
- iInternalState = EStartupShowingOperatorAnimation;
- TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState: EStartupShowingOperatorAnimation");
- iOperatorAnimation->UpdateDrawInfo( EStartupDIOperatorAnimStart );
- DoStartupShowOperatorAnimationL();
- break;
- case EStartupSystemFatalError:
- SystemFatalErrorL();
- break;
- default:
- __ASSERT_DEBUG( EFalse,
- PANIC( EStartupInvalidInternalStateChange ) );
- break;
- }
- }
- break;
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
case EStartupShowingOperatorAnimation:
{
switch( toState )
{
- case EStartupShowingUserWelcomeNote:
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iUserWelcomeNote = CStartupUserWelcomeNote::NewL( *this, ClientRect());
- AddToStackL( iUserWelcomeNote );
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
- iInternalState = EStartupShowingUserWelcomeNote;
- TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState: EStartupShowingUserWelcomeNote");
-#ifndef RD_STARTUP_ANIMATION_CUSTOMIZATION
- iWelcomeAnimation->UpdateDrawInfo( EStartupDIWelcomeNoteStart );
- iUserWelcomeNote->SetUserWelcomeNoteShowing(ETrue);
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
- DoStartupShowUserWelcomeNoteL();
- break;
+
+
case EStartupFirstBootAndRTCCheck:
iInternalState = EStartupFirstBootAndRTCCheck;
TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupFirstBootAndRTCCheck");
@@ -2604,48 +1238,11 @@
}
}
break;
- case EStartupShowingUserWelcomeNote:
- {
- switch( toState )
- {
- case EStartupFirstBootAndRTCCheck:
- iInternalState = EStartupFirstBootAndRTCCheck;
- TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupFirstBootAndRTCCheck");
- DoStartupFirstBootAndRTCCheckL();
- break;
- case EStartupSystemFatalError:
- SystemFatalErrorL();
- break;
- default:
- __ASSERT_DEBUG( EFalse,
- PANIC( EStartupInvalidInternalStateChange ) );
- break;
- }
- }
- break;
+
case EStartupFirstBootAndRTCCheck:
{
switch( toState )
{
- case EStartupWaitingCUIStartupReady:
- iInternalState = EStartupWaitingCUIStartupReady;
- TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupWaitingCUIStartupReady");
- WaitingCoverUIStartupReadySyncL();
- break;
- case EStartupSystemFatalError:
- SystemFatalErrorL();
- break;
- default:
- __ASSERT_DEBUG( EFalse,
- PANIC( EStartupInvalidInternalStateChange ) );
- break;
- }
- }
- break;
- case EStartupWaitingCUIStartupReady:
- {
- switch( toState )
- {
case EStartupStartupOK:
iInternalState = EStartupStartupOK;
TRACES("CStartupAppUi::DoNextStartupPhaseL(): InternalState : EStartupStartupOK");
@@ -2669,7 +1266,6 @@
case EStartupOfflineModeQuery:
case EStartupShowingWelcomeAnimation:
case EStartupShowingOperatorAnimation:
- case EStartupShowingUserWelcomeNote:
case EStartupFirstBootAndRTCCheck:
case EStartupWaitingCUIStartupReady:
case EStartupStartupOK:
@@ -2725,7 +1321,7 @@
return ret_val;
}
-#ifdef RD_STARTUP_ANIMATION_CUSTOMIZATION
+
// ---------------------------------------------------------------------------
// CStartupAppUi::UpdateStartupUiPhase()
// ---------------------------------------------------------------------------
@@ -2740,5 +1336,5 @@
TRACES1("CStartupAppUi::UpdateStartupUiPhase(): KPSStartupUiPhase set err %d", err);
}
}
-#endif // RD_STARTUP_ANIMATION_CUSTOMIZATION
+
// End of file