phoneapp/phoneuiutils/inc/cphonelangsettingmonitor.h
branchGCC_SURGE
changeset 51 f39ed5e045e0
parent 40 bab96b7ed1a4
parent 46 bc5a64e5bc3c
equal deleted inserted replaced
40:bab96b7ed1a4 51:f39ed5e045e0
     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:  Monitor for input language setting
       
    15 *
       
    16 */
       
    17 
       
    18 #ifndef CPHONELANGSETTINGMONITOR_H
       
    19 #define CPHONELANGSETTINGMONITOR_H
       
    20 
       
    21 //  INCLUDES
       
    22 #include    <e32base.h>
       
    23 #include    "mphonecenrepobserver.h" 
       
    24 
       
    25 // CLASS DECLARATION
       
    26 // FORWARD DECLARATIONS
       
    27 class MPhoneLangSettingObserver;
       
    28 
       
    29 /**
       
    30 *  Monitor for call theme settings.
       
    31 *
       
    32 */
       
    33 class CPhoneLangSettingMonitor : public CBase, private MPhoneCenRepObserver
       
    34     {
       
    35     public:
       
    36 
       
    37         /**
       
    38         * Two-phased constructor.
       
    39         */
       
    40         static CPhoneLangSettingMonitor* NewL();
       
    41         
       
    42         /**
       
    43         * Destructor.
       
    44         */
       
    45         virtual ~CPhoneLangSettingMonitor();
       
    46 
       
    47     public: // New functions
       
    48         
       
    49         /**
       
    50         * Get input language id.
       
    51         * @since Series 60 3.1
       
    52         * @return Language id.
       
    53         */
       
    54         TInt InputLanguage() const;
       
    55         
       
    56         /**
       
    57         * Add observer.
       
    58         * @since Series 60 3.1
       
    59         * @param aObserver Observer.
       
    60         */
       
    61         void AddObserverL( MPhoneLangSettingObserver& aObserver );
       
    62 
       
    63         /**
       
    64         * Remove observer.
       
    65         * @since Series 60 3.1
       
    66         * @param aObserver Observer.
       
    67         */
       
    68         void RemoveObserver( MPhoneLangSettingObserver& aObserver );
       
    69 
       
    70     protected:  // Functions from base classes
       
    71 
       
    72         /**
       
    73         * Handle the change of the setting from Central Repository
       
    74         * @param aUid identifing the central repository UID.
       
    75         * @param aId central repository ID.
       
    76         */
       
    77         virtual void HandleCenRepChangeL( 
       
    78             const TUid& aUid,
       
    79             const TUint aId );
       
    80             
       
    81     private:
       
    82 
       
    83         /**
       
    84         * C++ default constructor.
       
    85         */
       
    86         CPhoneLangSettingMonitor();
       
    87 
       
    88         /**
       
    89         * By default Symbian 2nd phase constructor is private.
       
    90         */
       
    91         void ConstructL();
       
    92 
       
    93     private:    // Data                
       
    94         // AI Setting Change Observer array.
       
    95         RPointerArray< MPhoneLangSettingObserver > iObserverArray;
       
    96         // Language Setting.
       
    97         TInt  iInputLanguageSetting;
       
    98     };
       
    99 
       
   100 #endif      // CPHONELANGSETTINGMONITOR_H   
       
   101             
       
   102 // End of File