securitysettings/cpwlansecurityuiplugins/cpwpacmnui/inc/cpwpacmnui.h
branchGCC_SURGE
changeset 40 60f08993dad0
parent 29 77618ad58aba
parent 39 fe6b6762fccd
equal deleted inserted replaced
29:77618ad58aba 40:60f08993dad0
     1 /*
       
     2  * Copyright (c) 2010 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: 
       
    15  *    Control Panel QT UI for WPA/WPA2/802_Dot_1x configuration
       
    16  *
       
    17  */
       
    18 
       
    19 /*
       
    20  * %version: 9 %
       
    21  */
       
    22 
       
    23 #ifndef CPWPACMNUI_H
       
    24 #define CPWPACMNUI_H
       
    25 
       
    26 // System includes
       
    27 #include <cpsettingformitemdata.h>
       
    28 #include <cpsettingformentryitemdata.h>
       
    29 #include <eapqtconfiginterface.h>
       
    30 #include <eapqtplugininfo.h>
       
    31 #include <cpitemdatahelper.h>
       
    32 #include <cpbasesettingview.h>
       
    33 
       
    34 // User includes
       
    35 #include "cpwpacmnui_global.h"
       
    36 #include "cpwlansecurityplugininterface.h"
       
    37 
       
    38 // Forward declarations
       
    39 class EapPluginInformation;
       
    40 class PluginInformation;
       
    41 class CpBaseSettingView;
       
    42 class EapQtConfigInterface;
       
    43 class EapEntyItemData;
       
    44 class CmConnectionMethodShim;
       
    45 
       
    46 /*! 
       
    47  * Implements the Ui for WPA/WPA2/802.1x Security Mode  
       
    48  */
       
    49 
       
    50 // Class declaration
       
    51 class WPAUI_EXPORT CpWpaCmnUi : public QObject
       
    52 {
       
    53     Q_OBJECT
       
    54     
       
    55     
       
    56     public:
       
    57     
       
    58         CpWpaCmnUi(CMManagerShim::WlanSecMode securityMode, CpItemDataHelper &dataHelpper);
       
    59         ~CpWpaCmnUi();
       
    60         CpSettingFormItemData* createUi(
       
    61                 EapQtConfigInterface *mEapQtConfigInterface,
       
    62                 CmConnectionMethodShim *cmCM);
       
    63         //CpBaseSettingView *eapUiInstance();
       
    64         
       
    65         void reset();
       
    66 
       
    67     signals:
       
    68     
       
    69         void keyChanged(QString& key);
       
    70         void pskEapModeToggled(int pskEnable);
       
    71         void eapPluginChanged(int eapPlugin);
       
    72         void connectionStateChanged(int state);
       
    73         
       
    74     
       
    75     private:
       
    76     
       
    77         //void loadWPAPskView();
       
    78         //void loadWPAEapView();
       
    79         //void removePskView();
       
    80         //void removeEapView();
       
    81         void loadUi();
       
    82         void readValues();
       
    83         void loadWPA_WPA2Fields();
       
    84         //void load802Dot1xFields();
       
    85     
       
    86     private slots:
       
    87     
       
    88         //void wpaTypeChanged(int pskEnable);
       
    89         void pskKeyChanged();
       
    90         //void eapTypeChanged(int eapPlugin);
       
    91         //void unencryptConnStateChanged(int state);
       
    92     
       
    93     private:
       
    94         
       
    95         Q_DISABLE_COPY(CpWpaCmnUi)
       
    96         CpSettingFormItemData* mCmnUi;
       
    97         CpItemDataHelper &mDataHelper;
       
    98         CpSettingFormItemData* mPskKeyText;
       
    99         CpSettingFormItemData* mEapPlugins;
       
   100         CpSettingFormItemData* mUnencryptedConnection;
       
   101         CpSettingFormItemData *mWpaEapItem;
       
   102         QString mKeyData;
       
   103         //QList<EapQtPluginInfo> mPlugins;
       
   104         EapEntyItemData* mEapEntry;
       
   105         EapQtConfigInterface *mEapQtConfigInterface;
       
   106         int mPluginCurrent;
       
   107         CMManagerShim::WlanSecMode mSecurityMode;
       
   108         bool mEnablePskMode;
       
   109         int mcurrentEapPlugin;
       
   110         CmConnectionMethodShim* mConnMethod;
       
   111         int unencryptStateChanged;
       
   112 };
       
   113 
       
   114 
       
   115 
       
   116 #endif//CPWPACMNUI_H