messagingappbase/mcesettings/mcesettingsgsplugin/inc/MceSettingsGSPluginContainer.h
changeset 0 72b543305e3a
equal deleted inserted replaced
-1:000000000000 0:72b543305e3a
       
     1 /*
       
     2 * Copyright (c) 2006-2007 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:   Messaging settings plugin container 
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #ifndef MCESETTINGSGSPLUGINGCONTAINER_H
       
    21 #define MCESETTINGSGSPLUGINGCONTAINER_H
       
    22 
       
    23 // INCLUDES
       
    24 // System includes
       
    25 #include <gsbasecontainer.h>    // CGSBaseContainer
       
    26 #include <msvapi.h>             // TMsvSessionEvent
       
    27 
       
    28 // FORWARD DECLARATIONS
       
    29 class CMceSettingsSessionObserver;
       
    30 class CMtmStore;
       
    31 class CMceUidNameArray;
       
    32 class CMsvSession;
       
    33 class CMtmUiDataRegistry;
       
    34 class CUidNameArray;
       
    35 class CGSBaseContainer;
       
    36 
       
    37 // CLASS DECLARATION
       
    38 
       
    39 /**
       
    40 *  CMceSettingsGSPluginContainer class 
       
    41 *  @since Series60_5.0
       
    42 */
       
    43 class CMceSettingsGSPluginContainer : 
       
    44     public CGSBaseContainer,
       
    45     public MMsvSessionObserver
       
    46     {
       
    47     public: // Constructors and destructor
       
    48         
       
    49         /**
       
    50         * Default C++ constructor
       
    51         */        
       
    52         CMceSettingsGSPluginContainer();
       
    53 
       
    54         /**
       
    55         * Destructor.
       
    56         */
       
    57         ~CMceSettingsGSPluginContainer();
       
    58     
       
    59     private: // Functions from base classes
       
    60 
       
    61 
       
    62 TBool IsSettingsInUse();
       
    63         
       
    64         /**
       
    65         * From CGSBaseContainer
       
    66         * See base class.        
       
    67         */    
       
    68         void ConstructListBoxL( TInt aResLbxId );
       
    69 
       
    70         /**
       
    71         * From CGSBaseContainer
       
    72         * See base class.        
       
    73         */    
       
    74         TKeyResponse OfferKeyEventL( 
       
    75             const TKeyEvent& aKeyEvent,
       
    76             TEventCode aType );        
       
    77 
       
    78         /**
       
    79         * From CCoeControl
       
    80         * See base class.        
       
    81         */ 
       
    82         void GetHelpContext( TCoeHelpContext& aContext ) const;
       
    83         
       
    84     public:
       
    85         /**
       
    86         * From MMsvSessionObserver
       
    87         */
       
    88         virtual void HandleSessionEventL(
       
    89             TMsvSessionEvent aEvent,
       
    90             TAny* aArg1,
       
    91             TAny* aArg2,
       
    92             TAny* aArg3);
       
    93                 
       
    94    public: // new functions
       
    95 
       
    96         /**
       
    97         *
       
    98         */
       
    99         void EditSubSettingsL();
       
   100         
       
   101         
       
   102     private: // Constructor
       
   103     
       
   104         /**
       
   105         * Symbian OS constructor.
       
   106         *
       
   107         * @param aRect Listbox's rect.
       
   108         */
       
   109         void ConstructL( const TRect& aRect );
       
   110         
       
   111         
       
   112     private: // New functions
       
   113         /**
       
   114         *
       
   115         */
       
   116         void UpdateSettingItemsL();
       
   117         
       
   118         /**
       
   119         * Loads mtm
       
   120         * @param aMtmType: mtm type
       
   121         * @param aMtmStore: mtm store 
       
   122         */
       
   123         void LoadMtmL( const TUid aMtmType, CMtmStore& aMtmStore );
       
   124 
       
   125         /**
       
   126         * Changes array order: sms, mms, email, others...
       
   127         */
       
   128         void SortAndChangeSmsMmsEmailFirstL();
       
   129 
       
   130         /**
       
   131         * Places given mtm first in the array.
       
   132         * @param aArray: reference to array
       
   133         * @param aMsgType: mtm to changed to the first.
       
   134         */
       
   135         void ChangeMsgTypeTopL( CUidNameArray& aArray, TUid aMsgType ) const;
       
   136         
       
   137         /**
       
   138         * Checks CSP Cell Broadcast bit from SIM      
       
   139         */
       
   140         TBool CheckCspBitL() const;
       
   141         
       
   142     private: // Data
       
   143         CMsvSession*                    iMsvSession; // not owed by this class.        
       
   144         CMceUidNameArray*               iMsgTypesSettings;
       
   145         CMceSettingsSessionObserver*    iAccountManager;
       
   146         TBool														iEmailFramework;
       
   147         TBool                           iCbs;
       
   148         TBool							iDialogOpen; // To verify dialog is already open
       
   149 
       
   150     };
       
   151 
       
   152 #endif // MCESETTINGSGSPLUGINCONTAINER_H
       
   153 
       
   154 // End of File