mediasettings/mediasettingsapp/inc/MPSettingsAdvancedBwSettingItemList.h
changeset 71 60b4b6493d7b
equal deleted inserted replaced
-1:000000000000 71:60b4b6493d7b
       
     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 the License "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:   Setting item list class for Advanced bandwidth setting list view.*
       
    15 */
       
    16 
       
    17 
       
    18 // Version : %version: 3 %
       
    19 
       
    20 
       
    21 
       
    22 
       
    23 #ifndef MPSETTINGSADVANCEDBWSETTINGITEMLIST_H
       
    24 #define MPSETTINGSADVANCEDBWSETTINGITEMLIST_H
       
    25 
       
    26 //  INCLUDES
       
    27 #include    <aknsettingitemlist.h>
       
    28 
       
    29 // FORWARD DECLARATIONS
       
    30 class CMPSettingsModelForROP;
       
    31 
       
    32 // CLASS DECLARATION
       
    33 
       
    34 /**
       
    35 *  CMPSettingsAdvancedBwSettingItemList
       
    36 *  Setting item list class for Advanced bandwidth setting list view.
       
    37 *
       
    38 *  @lib MediaSettings.app
       
    39 *  @since 2.1
       
    40 */
       
    41 class CMPSettingsAdvancedBwSettingItemList : public CAknSettingItemList
       
    42     {
       
    43     public:  // Constructors and destructor
       
    44         
       
    45         /**
       
    46         * C++ default constructor.
       
    47         */
       
    48         CMPSettingsAdvancedBwSettingItemList(CMPSettingsModelForROP* aModel);
       
    49 
       
    50 	    /**
       
    51 	    * 2nd-stage construction from resource id
       
    52 	    */
       
    53 	    void ConstructFromResourceL(TInt aResourceId);
       
    54 
       
    55         /**
       
    56         * From CCoeControl, 2nd-stage construction from constructed resource reader
       
    57         */
       
    58         void ConstructFromResourceL(TResourceReader& aReader);
       
    59         
       
    60         /**
       
    61         * Destructor.
       
    62         */
       
    63         virtual ~CMPSettingsAdvancedBwSettingItemList();
       
    64 
       
    65     public:     // Functions from base classes
       
    66 
       
    67         /**
       
    68         * From CAknSettingItemList
       
    69         * @param aIndex Current item's (Visible) index in the list
       
    70         * @param aCalledFromMenu True if function was called from Options menu.
       
    71         */
       
    72         void EditItemL(TInt aIndex, TBool aCalledFromMenu);
       
    73 
       
    74     protected:  // Functions from base classes
       
    75         
       
    76         /**
       
    77         * From CAknSettingItemList
       
    78         * Framework method to create a setting item based upon the user id aSettingId. The 
       
    79         * client code decides what type to contruct.  new (ELeave) must then be used and the resulting 
       
    80         * pointer returned. Ownership is thereafter base class's responsiblity.
       
    81         *
       
    82         * @param aSettingId ID to use to determine the type of the setting item
       
    83         * @return a constructed (not 2nd-stage constructed) setting item.
       
    84         */
       
    85         CAknSettingItem* CreateSettingItemL(TInt aSettingId);
       
    86 
       
    87     private: //New
       
    88 
       
    89         /**
       
    90         * Loads all setting values.
       
    91         * @since 2.1
       
    92         */
       
    93         void LoadAllL();       
       
    94 
       
    95         /**
       
    96         * Loads a specific setting value.
       
    97         * @since 2.1
       
    98         * @param aSettingId ID of the setting to be loaded.
       
    99         */
       
   100         void LoadSettingL(TInt aSettingId);
       
   101 
       
   102         /**
       
   103         * Stores a specific setting value.
       
   104         * @since 2.1
       
   105         * @param aSettingId ID of the setting to be stored.
       
   106         */
       
   107         void StoreSettingL(TInt aSettingId);
       
   108 
       
   109         /**
       
   110         * Searches aValue from aArray. If aValue is found, aListValue is its index
       
   111         * in aArray. Otherwise aListValue is aArray's count.
       
   112         */
       
   113         void CalculateListPosition(TInt aValue, TInt& aListValue, RArray<TInt>& aArray);
       
   114 
       
   115     private:
       
   116         CMPSettingsModelForROP* iModel;
       
   117 
       
   118         RArray<TInt> iGRPSSustainPresets;
       
   119         RArray<TInt> iEGRPSSustainPresets;
       
   120         RArray<TInt> iWCDMASustainPresets;
       
   121         RArray<TInt> iWLANSustainPresets;
       
   122         RArray<TInt> iHSDPASustainPresets;
       
   123         
       
   124         RArray<TInt> iGRPSMaxPresets;
       
   125         RArray<TInt> iEGRPSMaxPresets;
       
   126         RArray<TInt> iWCDMAMaxPresets;
       
   127         RArray<TInt> iWLANMaxPresets;
       
   128         RArray<TInt> iHSDPAMaxPresets;
       
   129         
       
   130         TInt iGPRSListValue;
       
   131         TInt iGPRSBw;
       
   132         TInt iEGPRSListValue;
       
   133         TInt iEGPRSBw;
       
   134         TInt iWCDMAListValue;
       
   135         TInt iWCDMABw;
       
   136         TInt iWLANListValue;
       
   137         TInt iWLANBw;
       
   138         TInt iHSDPAListValue;
       
   139         TInt iHSDPABw;
       
   140         
       
   141     };
       
   142 
       
   143 #endif      // MPSETTINGSADVANCEDBWSETTINGITEMLIST_H   
       
   144             
       
   145 // End of File