mpxplugins/viewplugins/views/waitnotedialog/src/mpxopeningdialog.cpp
changeset 0 ff3acec5bc43
equal deleted inserted replaced
-1:000000000000 0:ff3acec5bc43
       
     1 /*
       
     2 * Copyright (c) 2006 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:  Wait note dialog for Opening
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 #include <e32base.h>
       
    20 #include <StringLoader.h>
       
    21 #include <avkon.rsg>
       
    22 #include <avkon.mbg>
       
    23 #include <aknconsts.h>
       
    24 #include <mpxcollectionmessage.h>
       
    25 #include <mpxwaitnotedialog.rsg>
       
    26 #include <mpxcollectionframeworkdefs.h>
       
    27 #include <mpxlog.h>
       
    28 #include <mpxcollectionutility.h>
       
    29 #include "mpxopeningdialog.h"
       
    30 
       
    31 // ---------------------------------------------------------------------------
       
    32 // Constructor
       
    33 // ---------------------------------------------------------------------------
       
    34 //
       
    35 CMPXOpeningWaitDialog::CMPXOpeningWaitDialog( MMPXWaitNoteObserver* aObs, TBool aVisibilityDelayOff )
       
    36                                      : CMPXWaitNoteDialog ( aObs,
       
    37                                                            EMPXOpeningNote,
       
    38                                                            aVisibilityDelayOff )
       
    39     {
       
    40 	// CMPXWaitNoteDialog constructor should have 3rd parameter (=aVisibilityDelayOff) set to ETrue 
       
    41 	// when the length of the process is AWLAYS over 1.5 seconds. (e.g. opening all songs)
       
    42     }
       
    43 
       
    44 
       
    45 // ---------------------------------------------------------------------------
       
    46 // 2nd Phased constructor
       
    47 // ---------------------------------------------------------------------------
       
    48 //
       
    49 void CMPXOpeningWaitDialog::ConstructL()
       
    50     {
       
    51     BaseConstructL();
       
    52     }
       
    53 
       
    54 
       
    55 // ---------------------------------------------------------------------------
       
    56 // Two-Phased Constructor
       
    57 // ---------------------------------------------------------------------------
       
    58 //
       
    59 CMPXOpeningWaitDialog* CMPXOpeningWaitDialog::NewL( MMPXWaitNoteObserver* aObs, TBool aVisibilityDelayOff )
       
    60     {
       
    61     CMPXOpeningWaitDialog* self = new(ELeave) CMPXOpeningWaitDialog( aObs, aVisibilityDelayOff );
       
    62     CleanupStack::PushL( self );
       
    63     self->ConstructL();
       
    64     CleanupStack::Pop( self );
       
    65     return self;
       
    66     }
       
    67 
       
    68 
       
    69 // ---------------------------------------------------------------------------
       
    70 // Destructor
       
    71 // ---------------------------------------------------------------------------
       
    72 //
       
    73 CMPXOpeningWaitDialog::~CMPXOpeningWaitDialog()
       
    74     {
       
    75     }
       
    76 
       
    77 
       
    78 // ---------------------------------------------------------------------------
       
    79 // Setup Wait Notes
       
    80 // ---------------------------------------------------------------------------
       
    81 //
       
    82 void CMPXOpeningWaitDialog::PreNoteDisplayHandleL()
       
    83     {
       
    84     // CBA
       
    85     SetCBAL( R_AVKON_SOFTKEYS_EMPTY );
       
    86 
       
    87     // Text
       
    88     HBufC* text = StringLoader::LoadLC( R_MPX_OPENING_TXT );
       
    89     SetTextL( *text );
       
    90     CleanupStack::PopAndDestroy( text );
       
    91 
       
    92     // Icon
       
    93     TNoteIconInfo icon( (TInt)EMbmAvkonQgn_note_progress,
       
    94                         (TInt)EMbmAvkonQgn_note_progress_mask,
       
    95                         TFileName(KAvkonBitmapFile) );
       
    96     SetIconL( icon );
       
    97 
       
    98     //HandleDatabaseOpenL();
       
    99     }
       
   100 
       
   101 
       
   102 // End of File