messagingappbase/mcesettings/inc/MceSettingsMtmServicesDialog.h
changeset 0 72b543305e3a
equal deleted inserted replaced
-1:000000000000 0:72b543305e3a
       
     1 /*
       
     2 * Copyright (c) 2002 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:  
       
    15 *     Dialog for handling services of certain mtm (if possible to create services).
       
    16 *
       
    17 */
       
    18 
       
    19 
       
    20 
       
    21 #ifndef __MCESETTINGSMTMSERVICESDIALOG_H__
       
    22 #define __MCESETTINGSMTMSERVICESDIALOG_H__
       
    23 
       
    24 //  INCLUDES
       
    25 
       
    26 #include "MceSettingsTitlePaneHandlerDialog.h"
       
    27 #include <ImumInternalApi.h>
       
    28 #include <ImumInHealthServices.h>
       
    29 class CMceSettingsMultipleServicesDialog;
       
    30 
       
    31 // CONSTANTS
       
    32 const TInt KMceMaxNumberOfMailboxes = 6;
       
    33 
       
    34 // FORWARD DECLARATIONS
       
    35 
       
    36 class MMceSettingsAccountManager;
       
    37 class CMceUidNameArray;
       
    38 
       
    39 // CLASS DECLARATION
       
    40 
       
    41 class CMceSettingsMtmServicesDialog :
       
    42     public CMceSettingsTitlePaneHandlerDialog,
       
    43     public MMsvSessionObserver
       
    44     {
       
    45     public:
       
    46 
       
    47         /**
       
    48         * Constructor.
       
    49         */
       
    50         CMceSettingsMtmServicesDialog (
       
    51             TUid aMessageType,
       
    52             MMceSettingsAccountManager& aManager,
       
    53             CMsvSession* aSession,
       
    54             CMceSettingsMultipleServicesDialog& aParent );
       
    55 
       
    56         /**
       
    57         * Destructor.
       
    58         */
       
    59         virtual ~CMceSettingsMtmServicesDialog();
       
    60 
       
    61         /**
       
    62         * From CEikDialog
       
    63         */
       
    64         virtual TBool OkToExitL(TInt aButtonId);
       
    65 
       
    66         /**
       
    67         * From MEikListBoxObserver
       
    68         */
       
    69         virtual void HandleListBoxEventL(
       
    70             CEikListBox* aListBox,
       
    71             TListBoxEvent aEventType );
       
    72 
       
    73         /**
       
    74         * From CAknDialog
       
    75         */
       
    76         void ProcessCommandL( TInt aCommandId );
       
    77 
       
    78         /**
       
    79         * From CAknDialog
       
    80         */
       
    81         void DynInitMenuPaneL( TInt aResourceId, CEikMenuPane* aMenuPane );               
       
    82 
       
    83         /**
       
    84         * From CEikDialog
       
    85         */
       
    86         TKeyResponse OfferKeyEventL( const TKeyEvent& aKeyEvent,TEventCode aType );
       
    87 
       
    88         /**
       
    89         * MMsvSessionObserver
       
    90         */
       
    91         void HandleSessionEventL( TMsvSessionEvent aEvent, TAny* aArg1, TAny* aArg2, TAny* aArg3 );
       
    92 
       
    93         /**
       
    94         * From CoeControl
       
    95         */
       
    96         void GetHelpContext( TCoeHelpContext& aContext ) const;        
       
    97 
       
    98         /**
       
    99         * Updates services array
       
   100         */
       
   101         virtual void UpdateServicesArrayL(); 
       
   102 
       
   103     protected:
       
   104 
       
   105         /**
       
   106         * From CEikDialog
       
   107         */
       
   108         virtual void PreLayoutDynInitL();
       
   109 
       
   110     private:
       
   111 
       
   112         /** 
       
   113         * Launches help application
       
   114         */
       
   115         void LaunchHelpL() const;
       
   116 
       
   117         /**
       
   118         * Set special MSK button
       
   119         * @since S60 3.2
       
   120         */
       
   121         void SetSpecialMSKButtonL(TInt aResourceId);        
       
   122   
       
   123         /**
       
   124          * Updates the internal mailbox data information
       
   125          *
       
   126          * @since S60 v3.2
       
   127          * @leave KErrNoMemory
       
   128          */
       
   129         void UpdateMailboxDataL(); 
       
   130         
       
   131     private: // Data
       
   132         TUid                    iMtmType;     
       
   133         MMceSettingsAccountManager& iAccountManager;
       
   134         CMsvSession*            iSession;       
       
   135 
       
   136         CMceUidNameArray*       iAccountArray;
       
   137         TBool                   iSelectionKeyPressedToOpenOptionMenu;
       
   138         TBool                   iSessionObserverAdded;
       
   139         // Owned: Pointer to email API object
       
   140         CImumInternalApi*       iEmailApi;
       
   141         // Array of mailbox id's
       
   142         MImumInHealthServices::RMailboxIdArray iMailboxArray;      
       
   143         TBool                   iMailboxCreationOn;
       
   144         TInt                    iNumberOfMailboxes;
       
   145         
       
   146         // Not owned: Only to call that we are closed
       
   147         CMceSettingsMultipleServicesDialog&  iParentDialog;
       
   148         TMsvId                  iCurrentMailAccountId;
       
   149     };
       
   150 
       
   151 #endif      // MCESETTINGSMTMSERVICESDIALOG_H
       
   152 
       
   153 // End of File