1 /* |
1 /* |
2 * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). |
2 * Copyright (c) 2010 Nokia Corporation and/or its subsidiary(-ies). |
3 * All rights reserved. |
3 * All rights reserved. |
4 * This component and the accompanying materials are made available |
4 * This component and the accompanying materials are made available |
5 * under the terms of the License "Eclipse Public License v1.0" |
5 * under the terms of the "Eclipse Public License v1.0" |
6 * which accompanies this distribution, and is available |
6 * which accompanies this distribution, and is available |
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
8 * |
8 * |
9 * Initial Contributors: |
9 * Initial Contributors: |
10 * Nokia Corporation - initial contribution. |
10 * Nokia Corporation - initial contribution. |
14 * Description: |
14 * Description: |
15 * WPS Wizard: API implementation. |
15 * WPS Wizard: API implementation. |
16 * |
16 * |
17 */ |
17 */ |
18 |
18 |
19 |
|
20 // System includes |
19 // System includes |
21 #include <hbdocumentloader.h> |
20 #include <QApplication> |
22 #include <qgraphicswidget> |
|
23 #include <hbmainwindow.h> |
|
24 #include <hbview.h> |
|
25 #include <hbstackedwidget.h> |
|
26 #include <hblabel.h> |
|
27 #include <hbaction.h> |
|
28 #include <qapplication.h> |
|
29 |
|
30 // Trace includes |
|
31 #include "OstTraceDefinitions.h" |
|
32 #ifdef OST_TRACE_COMPILER_IN_USE |
|
33 #include "wpswizardTraces.h" |
|
34 #endif |
|
35 |
21 |
36 // User includes |
22 // User includes |
37 // WLAN Wizard |
23 // WLAN Wizard |
38 #include "wlanwizardhelpper.h" |
24 #include "wlanwizardhelper.h" |
39 |
25 |
40 // Wizard |
26 // WPS Wizard |
41 #include "wpswizard.h" |
27 #include "wpswizard.h" |
42 #include "wpswizard_p.h" |
28 #include "wpswizard_p.h" |
43 |
29 |
44 // Wizard Pages |
30 // Wizard Pages |
45 #include "wpswizardsteptwo.h" |
31 #include "wpswizardsteptwo.h" |
46 #include "wpswizardstepthreebutton.h" |
32 #include "wpswizardstepthreebutton.h" |
47 #include "wpswizardstepthreenumber.h" |
33 #include "wpswizardstepthreenumber.h" |
48 #include "wpswizardstepfour.h" |
34 #include "wpswizardstepfour.h" |
49 #include "wpswizardstepfive.h" |
35 #include "wpswizardstepfive.h" |
50 |
36 |
|
37 // Trace includes |
|
38 #include "OstTraceDefinitions.h" |
|
39 #ifdef OST_TRACE_COMPILER_IN_USE |
|
40 #include "wpswizardTraces.h" |
|
41 #endif |
51 |
42 |
52 class WlanWizardHelpper; |
43 //Forward Declarations |
|
44 class WlanWizardHelper; |
|
45 |
|
46 // External function prototypes |
|
47 |
|
48 //Local Constants |
53 |
49 |
54 /*! |
50 /*! |
55 * Creates the WpsWizard object |
51 \class WpsWizard |
56 * |
52 \brief Provides the WPS wizard implementation |
57 * \param WlanWizardHelpper* Helper class to from the framework |
53 */ |
58 * \param BearerType Indicates the bearer type Eg. Wlan |
|
59 * |
|
60 */ |
|
61 |
54 |
62 WpsWizard::WpsWizard(WlanWizardHelpper *wizardHelpper, BearerType bearerType, |
55 // ======== LOCAL FUNCTIONS ======== |
63 int referenceId) : |
56 |
64 d_ptr(new WpsWizardPrivate(this, wizardHelpper, bearerType, referenceId)) |
57 // ======== MEMBER FUNCTIONS ======== |
65 { |
|
66 OstTraceFunctionEntry1(WPSWIZARD_WPSWIZARD_ENTRY, this) |
|
67 OstTraceFunctionExit1(WPSWIZARD_WPSWIZARD_EXIT, this) |
|
68 } |
|
69 |
58 |
70 /*! |
59 /*! |
71 * Destructor |
60 Creates the WpsWizard object |
72 * |
61 |
73 */ |
62 @param [in] wizardHelper WlanWizardHelper* Helper class to from the framework |
|
63 */ |
74 |
64 |
75 WpsWizard::~WpsWizard() |
65 WpsWizard::WpsWizard(WlanWizardHelper *wizardHelper) : |
76 { |
66 d_ptr(NULL) |
77 OstTraceFunctionEntry1(WPSWIZARD_WPSWIZARD_ENTRY, this); |
67 { |
78 delete d_ptr; |
68 OstTraceFunctionEntry1(WPSWIZARD_WPSWIZARD_ENTRY, this); |
|
69 d_ptr.reset(new WpsWizardPrivate(this, wizardHelper)); |
79 OstTraceFunctionExit1(WPSWIZARD_WPSWIZARD_EXIT, this); |
70 OstTraceFunctionExit1(WPSWIZARD_WPSWIZARD_EXIT, this); |
80 } |
71 } |
81 |
72 |
82 /*! |
73 /*! |
83 * StoreSettings: Stores the settings in the commsdat database |
74 Destructor |
84 * |
75 |
85 */ |
76 */ |
|
77 WpsWizard::~WpsWizard() |
|
78 { |
|
79 OstTraceFunctionEntry1(WPSWIZARD_WPSWIZARD_DESTRUCTOR_ENTRY, this); |
|
80 OstTraceFunctionExit1(WPSWIZARD_WPSWIZARD_DESTRUCTOR_EXIT, this); |
|
81 } |
86 |
82 |
87 void WpsWizard::storeSettings() |
|
88 { |
|
89 OstTraceFunctionEntry1(WPSWIZARD_STORESETTINGS_ENTRY, this); |
|
90 OstTraceFunctionExit1(WPSWIZARD_STORESETTINGS_EXIT, this); |
|
91 } |
|
92 |
|
93 /*! |
|
94 * Creates the summary page, valid only for EAP usecase |
|
95 * |
|
96 * \param WlanWizardPlugin::Summary indicates the type of summary item |
|
97 * \param QString &item item name |
|
98 * \param QString &value item value |
|
99 * |
|
100 * \return the status of the summary operation |
|
101 */ |
|
102 |
|
103 bool WpsWizard::summary(WlanWizardPlugin::Summary sum, QString &item, |
|
104 QString &value) |
|
105 { |
|
106 OstTraceFunctionEntry1(WPSWIZARD_SUMMARY_ENTRY, this); |
|
107 OstTraceFunctionExit1(WPSWIZARD_SUMMARY_EXIT, this); |
|
108 return true; |
|
109 } |
|