author | Pat Downey <patd@symbian.org> |
Wed, 01 Sep 2010 12:23:51 +0100 | |
branch | RCL_3 |
changeset 58 | 83ca720e2b9a |
parent 57 | 05bc53fe583b |
permissions | -rw-r--r-- |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
1 |
/* |
58 | 2 |
* Copyright (c) 2002-2010 Nokia Corporation and/or its subsidiary(-ies). |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
3 |
* All rights reserved. |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
4 |
* This component and the accompanying materials are made available |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
5 |
* under the terms of "Eclipse Public License v1.0" |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
6 |
* which accompanies this distribution, and is available |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
7 |
* at the URL "http://www.eclipse.org/legal/epl-v10.html". |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
8 |
* |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
9 |
* Initial Contributors: |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
10 |
* Nokia Corporation - initial contribution. |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
11 |
* |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
12 |
* Contributors: |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
13 |
* |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
14 |
* Description: Implementation of plugins (base & all derived). |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
15 |
* |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
16 |
*/ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
17 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
18 |
// INCLUDE FILES |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
19 |
#include "ConnDlgPlugin.h" |
58 | 20 |
#include "AuthenticationDialog.h" |
21 |
#include "ReconnectDialog.h" |
|
22 |
#include "QosDialog.h" |
|
23 |
#include "NewIapDialog.h" |
|
24 |
#include "ActiveIapPlugin.h" |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
25 |
|
58 | 26 |
#include "ActiveSelectConnectionPlugin.h" |
27 |
#include "CConnDlgPrivateCRKeys.h" |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
28 |
#include <centralrepository.h> |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
29 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
30 |
#include "ConnectionDialogsUidDefs.h" |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
31 |
#include "ConnectionDialogsLogger.h" |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
32 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
33 |
#include <eikenv.h> |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
34 |
#include <bautils.h> |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
35 |
#include <e32property.h> |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
36 |
#include <rmpm.h> |
58 | 37 |
#include <startupdomainpskeys.h> |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
38 |
|
58 | 39 |
#include <CConnDlgPlugin.rsg> |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
40 |
#include <data_caging_path_literals.hrh> |
58 | 41 |
#include <vpnapi.h> |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
42 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
43 |
using namespace CommsDat; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
44 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
45 |
// CONSTANTS |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
46 |
|
58 | 47 |
// RSC file name. |
48 |
_LIT( KResourceFileName, "CConnDlgPlugin.rsc" ); |
|
49 |
||
50 |
// Panic string |
|
51 |
_LIT( KConnDlgPluginPanic, "CConnDlgPlugin" ); |
|
52 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
53 |
LOCAL_D const TInt KPluginGranularity = 4; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
54 |
|
58 | 55 |
#if defined(_DEBUG) |
56 |
_LIT( KErrActiveObjectNull, "iActivePlugin not NULL" ); |
|
57 |
#endif |
|
58 |
||
59 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
60 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
61 |
LOCAL_C void CreateNotifiersL( |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
62 |
CArrayPtrFlat<MEikSrvNotifierBase2>* aNotifiers ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
63 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
64 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
65 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
66 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
67 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
68 |
// NotifierArray() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
69 |
// Lib main entry point |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
70 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
71 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
72 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
73 |
EXPORT_C CArrayPtr<MEikSrvNotifierBase2>* NotifierArray() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
74 |
{ |
58 | 75 |
CArrayPtrFlat<MEikSrvNotifierBase2>* array = new (ELeave) |
76 |
CArrayPtrFlat<MEikSrvNotifierBase2>( KPluginGranularity ); |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
77 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
78 |
if ( array ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
79 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
80 |
TRAPD( err, CreateNotifiersL( array ) ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
81 |
if( err ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
82 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
83 |
TInt count = array->Count(); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
84 |
while( count-- ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
85 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
86 |
(*array)[count]->Release(); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
87 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
88 |
delete array; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
89 |
array = NULL; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
90 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
91 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
92 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
93 |
return( array ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
94 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
95 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
96 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
97 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
98 |
// CreateNotifiersL |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
99 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
100 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
101 |
LOCAL_C void CreateNotifiersL( |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
102 |
CArrayPtrFlat<MEikSrvNotifierBase2>* aNotifiers ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
103 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
104 |
MEikSrvNotifierBase2 *serNotify; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
105 |
TBool resourceFileResponsible = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
106 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
107 |
serNotify = CConnDlgIapPlugin::NewL( resourceFileResponsible ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
108 |
CleanupStack::PushL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
109 |
aNotifiers->AppendL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
110 |
CleanupStack::Pop( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
111 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
112 |
resourceFileResponsible = EFalse; // Only the first has to load resources |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
113 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
114 |
serNotify = CConnDlgAuthenticationPlugin::NewL( resourceFileResponsible ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
115 |
CleanupStack::PushL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
116 |
aNotifiers->AppendL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
117 |
CleanupStack::Pop( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
118 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
119 |
serNotify = CConnDlgReconnectPlugin::NewL( resourceFileResponsible ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
120 |
CleanupStack::PushL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
121 |
aNotifiers->AppendL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
122 |
CleanupStack::Pop( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
123 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
124 |
serNotify = CConnDlgNewIapPlugin::NewL( resourceFileResponsible ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
125 |
CleanupStack::PushL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
126 |
aNotifiers->AppendL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
127 |
CleanupStack::Pop( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
128 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
129 |
serNotify = CConnDlgQosPlugin::NewL( resourceFileResponsible ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
130 |
CleanupStack::PushL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
131 |
aNotifiers->AppendL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
132 |
CleanupStack::Pop( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
133 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
134 |
serNotify = CConnDlgSelectConnectionPlugin::NewL( |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
135 |
resourceFileResponsible ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
136 |
CleanupStack::PushL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
137 |
aNotifiers->AppendL( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
138 |
CleanupStack::Pop( serNotify ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
139 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
140 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
141 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
142 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
143 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
144 |
// CConnDlgIapPlugin::TNotifierInfo CConnDlgIapPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
145 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
146 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
147 |
CConnDlgIapPlugin::TNotifierInfo CConnDlgIapPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
148 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
149 |
iInfo.iUid = KUidCConnDlgIap; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
150 |
iInfo.iPriority = ENotifierPriorityHigh; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
151 |
iInfo.iChannel = KUidCConnDlgIap; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
152 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
153 |
return iInfo; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
154 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
155 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
156 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
157 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
158 |
// void CConnDlgIapPlugin::StartL |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
159 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
160 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
161 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
162 |
void CConnDlgIapPlugin::StartL( const TDesC8& aBuffer, TInt aReplySlot, |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
163 |
const RMessagePtr2& aMessage ) |
58 | 164 |
{ |
165 |
if ( ScreenSaverOn() || AutolockOn() ) |
|
166 |
{ |
|
167 |
// Screen saver or Autolock is active. Cancel the dialog. |
|
168 |
CLOG_WRITE( "CConnDlgAuthenticationPlugin::StartL: Screen saver or Autolock is active." ); |
|
169 |
aMessage.Complete( KErrCancel ); |
|
170 |
return; |
|
171 |
} |
|
172 |
||
173 |
iPrefs.Copy( (TPtrC8) aBuffer ); |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
174 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
175 |
iCancelled = EFalse; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
176 |
iReplySlot = aReplySlot; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
177 |
iMessage = aMessage; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
178 |
|
58 | 179 |
// Check if there is a suitable active connection |
180 |
TInt iap( 0 ); |
|
181 |
TInt bearer( ECommDbBearerWLAN ); // User conn. is always WLAN in 9.1 |
|
182 |
||
183 |
// Is there active User connection |
|
184 |
TInt err = GetUserConnection( iap ); |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
185 |
|
58 | 186 |
if ( err != KErrNone || iap == 0 ) |
187 |
{ |
|
188 |
// Is there any active connection |
|
189 |
err = GetActiveConnection( iap, bearer ); |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
190 |
} |
58 | 191 |
|
192 |
if ( ( err == KErrNone ) && |
|
193 |
( iap != 0 ) && |
|
194 |
( iPrefs().iBearerSet & bearer ) ) |
|
195 |
{ |
|
196 |
// a suitable connection is already active |
|
197 |
iIAP = iap; |
|
198 |
CompleteL( KErrNone ); |
|
199 |
} |
|
200 |
else |
|
201 |
{ |
|
202 |
// display a dialog |
|
203 |
__ASSERT_DEBUG( !iActivePlugin, |
|
204 |
User::Panic( KErrActiveObjectNull, KErrNone ) ); |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
205 |
|
58 | 206 |
iActivePlugin = CActiveCConnDlgIapPlugin::NewL( this, iPrefs() ); |
207 |
iActivePlugin->StartSearchIAPsL(); |
|
208 |
} |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
209 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
210 |
|
58 | 211 |
|
212 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
213 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
214 |
// void CConnDlgIapPlugin::Cancel() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
215 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
216 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
217 |
void CConnDlgIapPlugin::Cancel() |
58 | 218 |
{ |
219 |
delete iActivePlugin; |
|
220 |
iActivePlugin = NULL; |
|
221 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
222 |
if ( !iCancelled ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
223 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
224 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
225 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
226 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
227 |
iMessage.Complete( KErrCancel ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
228 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
229 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
230 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
231 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
232 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
233 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
234 |
// void CConnDlgIapPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
235 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
236 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
237 |
void CConnDlgIapPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
238 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
239 |
CLOG_ENTERFN( "CConnDlgIapPlugin::CompleteL" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
240 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
241 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
242 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
243 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
244 |
if ( aStatus == KErrNone ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
245 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
246 |
iMessage.WriteL( iReplySlot, TPckg<TUint32>( iIAP ) ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
247 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
248 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
249 |
CLOG_WRITEF( _L( "CConnDlgIapPlugin::CompleteL iIAP : %d" ), iIAP ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
250 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
251 |
iMessage.Complete( aStatus ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
252 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
253 |
Cancel(); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
254 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
255 |
CLOG_LEAVEFN( "CConnDlgIapPlugin::CompleteL" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
256 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
257 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
258 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
259 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
260 |
// CConnDlgIapPlugin* CConnDlgIapPlugin::NewL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
261 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
262 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
263 |
CConnDlgIapPlugin* CConnDlgIapPlugin::NewL( |
58 | 264 |
const TBool aResourceFileResponsible ) |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
265 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
266 |
CConnDlgIapPlugin* self = new (ELeave) CConnDlgIapPlugin(); |
58 | 267 |
CleanupStack::PushL( self ); |
268 |
self->ConstructL( KResourceFileName, aResourceFileResponsible ); |
|
269 |
CleanupStack::Pop(); |
|
270 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
271 |
return self; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
272 |
} |
58 | 273 |
|
274 |
// --------------------------------------------------------- |
|
275 |
// CConnDlgIapPlugin::SetPreferredIapIdL |
|
276 |
// --------------------------------------------------------- |
|
277 |
// |
|
278 |
void CConnDlgIapPlugin::SetPreferredIapIdL( TUint32 aIAPId ) |
|
279 |
{ |
|
280 |
CLOG_ENTERFN( "CConnDlgIapPlugin::SetPreferredIapIdL " ); |
|
281 |
||
282 |
iIAP = aIAPId; |
|
283 |
||
284 |
CLOG_LEAVEFN( "CConnDlgIapPlugin::SetPreferredIapIdL " ); |
|
285 |
} |
|
286 |
||
287 |
||
288 |
// --------------------------------------------------------- |
|
289 |
// CConnDlgIapPlugin::GetActiveConnection |
|
290 |
// --------------------------------------------------------- |
|
291 |
// |
|
292 |
TInt CConnDlgIapPlugin::GetActiveConnection( TInt& aIapId, |
|
293 |
TInt& aBearer ) |
|
294 |
{ |
|
295 |
aIapId = 0; |
|
296 |
aBearer = 0; |
|
297 |
||
298 |
TInt err = RProperty::Get( KMPMActiveConnectionCategory, |
|
299 |
KMPMPSKeyActiveConnectionIap, |
|
300 |
aIapId ); |
|
301 |
||
302 |
CLOG_WRITEF( _L( "KMPMPSKeyActiveConnectionIap : %d" ), aIapId ); |
|
303 |
CLOG_WRITEF( _L( "err : %d" ), err ); |
|
304 |
||
305 |
if ( err == KErrNone ) |
|
306 |
{ |
|
307 |
err = RProperty::Get( KMPMActiveConnectionCategory, |
|
308 |
KMPMPSKeyActiveConnectionBearer, |
|
309 |
aBearer ); |
|
310 |
} |
|
311 |
||
312 |
CLOG_WRITEF( _L( "KMPMPSKeyActiveConnectionBearer : %d" ), aBearer ); |
|
313 |
CLOG_WRITEF( _L( "err : %d" ), err ); |
|
314 |
CLOG_WRITEF( _L( "iPrefs().iBearerSet : %d" ), iPrefs().iBearerSet ); |
|
315 |
||
316 |
return err; |
|
317 |
} |
|
318 |
||
319 |
||
320 |
// --------------------------------------------------------- |
|
321 |
// CConnDlgIapPlugin::GetUserConnection |
|
322 |
// --------------------------------------------------------- |
|
323 |
// |
|
324 |
TInt CConnDlgIapPlugin::GetUserConnection( TInt& aIapId ) |
|
325 |
{ |
|
326 |
aIapId = 0; |
|
327 |
||
328 |
TInt err = RProperty::Get( KMPMUserConnectionCategory, |
|
329 |
KMPMPSKeyUserConnectionIap, |
|
330 |
aIapId ); |
|
331 |
||
332 |
CLOG_WRITEF( _L( "KMPMPSKeyUserConnectionIap : %d" ), aIapId ); |
|
333 |
CLOG_WRITEF( _L( "err : %d" ), err ); |
|
334 |
||
335 |
return err; |
|
336 |
} |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
337 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
338 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
339 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
340 |
// CConnDlgAuthenticationPlugin::TNotifierInfo |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
341 |
// CConnDlgAuthenticationPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
342 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
343 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
344 |
CConnDlgAuthenticationPlugin::TNotifierInfo |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
345 |
CConnDlgAuthenticationPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
346 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
347 |
iInfo.iUid = KUidCConnDlgAuthentication; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
348 |
iInfo.iPriority = ENotifierPriorityHigh; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
349 |
iInfo.iChannel = KUidCConnDlgAuthentication; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
350 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
351 |
return iInfo; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
352 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
353 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
354 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
355 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
356 |
// void CConnDlgAuthenticationPlugin::StartL |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
357 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
358 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
359 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
360 |
void CConnDlgAuthenticationPlugin::StartL( const TDesC8& aBuffer, |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
361 |
TInt aReplySlot, |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
362 |
const RMessagePtr2& aMessage ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
363 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
364 |
CLOG_ENTERFN( "CConnDlgAuthenticationPlugin::StartL" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
365 |
|
58 | 366 |
if ( ScreenSaverOn() || AutolockOn() ) |
367 |
{ |
|
368 |
// Screen saver or Autolock is active. Cancel the dialog. |
|
369 |
CLOG_WRITE( "CConnDlgAuthenticationPlugin::StartL: Screen saver or Autolock is active." ); |
|
370 |
aMessage.Complete( KErrCancel ); |
|
371 |
return; |
|
372 |
} |
|
373 |
||
374 |
if ( aBuffer.Length() > iAuthPairBuff.Length() ) |
|
375 |
{ |
|
376 |
CLOG_WRITE( "User::Panic, EConnDlgIllegalRequest" ); |
|
377 |
User::Panic( KConnDlgPluginPanic, EConnDlgIllegalRequest ); |
|
378 |
} |
|
379 |
||
380 |
iAuthPairBuff.Copy( aBuffer ); |
|
381 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
382 |
iReplySlot = aReplySlot; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
383 |
iMessage = aMessage; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
384 |
iCancelled = EFalse; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
385 |
|
58 | 386 |
GetAuthenticationL(); |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
387 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
388 |
CLOG_LEAVEFN( "CConnDlgAuthenticationPlugin::StartL" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
389 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
390 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
391 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
392 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
393 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
394 |
// void CConnDlgAuthenticationPlugin::Cancel() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
395 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
396 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
397 |
void CConnDlgAuthenticationPlugin::Cancel() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
398 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
399 |
CLOG_ENTERFN( "CConnDlgAuthenticationPlugin::Cancel" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
400 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
401 |
if ( !iCancelled ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
402 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
403 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
404 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
405 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
406 |
iMessage.Complete( KErrCancel ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
407 |
} |
58 | 408 |
delete iDialog; |
409 |
iDialog = NULL; |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
410 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
411 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
412 |
CLOG_LEAVEFN( "CConnDlgAuthenticationPlugin::Cancel" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
413 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
414 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
415 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
416 |
// --------------------------------------------------------- |
58 | 417 |
// void CConnDlgAuthenticationPlugin::GetAuthenticationL() |
418 |
// --------------------------------------------------------- |
|
419 |
// |
|
420 |
void CConnDlgAuthenticationPlugin::GetAuthenticationL() |
|
421 |
{ |
|
422 |
CLOG_ENTERFN( "CConnDlgAuthenticationPlugin::GetAuthenticationL" ); |
|
423 |
||
424 |
iDialog = CAuthenticationDialog::NewL( this, iAuthPairBuff().iUsername, |
|
425 |
iAuthPairBuff().iPassword ); |
|
426 |
||
427 |
||
428 |
iDialog->ExecuteLD( R_CONNDLG_AUTHENTICATION ); |
|
429 |
||
430 |
CLOG_LEAVEFN( "CConnDlgAuthenticationPlugin::GetAuthenticationL" ); |
|
431 |
} |
|
432 |
||
433 |
||
434 |
// --------------------------------------------------------- |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
435 |
// void CConnDlgAuthenticationPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
436 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
437 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
438 |
void CConnDlgAuthenticationPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
439 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
440 |
CLOG_ENTERFN( "CConnDlgAuthenticationPlugin::CompleteL" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
441 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
442 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
443 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
444 |
{ |
58 | 445 |
if ( aStatus == KErrNone ) |
446 |
{ |
|
447 |
iMessage.WriteL( iReplySlot, iAuthPairBuff ); |
|
448 |
} |
|
449 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
450 |
iMessage.Complete( aStatus ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
451 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
452 |
Cancel(); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
453 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
454 |
CLOG_LEAVEFN( "CConnDlgAuthenticationPlugin::CompleteL" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
455 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
456 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
457 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
458 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
459 |
// CConnDlgAuthenticationPlugin* CConnDlgAuthenticationPlugin::NewL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
460 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
461 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
462 |
CConnDlgAuthenticationPlugin* CConnDlgAuthenticationPlugin::NewL( |
58 | 463 |
const TBool aResourceFileResponsible ) |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
464 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
465 |
CConnDlgAuthenticationPlugin* self = new (ELeave) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
466 |
CConnDlgAuthenticationPlugin(); |
58 | 467 |
CleanupStack::PushL( self ); |
468 |
self->ConstructL( KResourceFileName, aResourceFileResponsible ); |
|
469 |
CleanupStack::Pop(); |
|
470 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
471 |
return self; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
472 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
473 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
474 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
475 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
476 |
// CConnDlgAuthenticationPlugin::CConnDlgAuthenticationPlugin() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
477 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
478 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
479 |
CConnDlgAuthenticationPlugin::CConnDlgAuthenticationPlugin() |
58 | 480 |
: iAuthPair( TAuthenticationPair() ) |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
481 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
482 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
483 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
484 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
485 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
486 |
// CConnDlgQosPlugin::TNotifierInfo CConnDlgQosPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
487 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
488 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
489 |
CConnDlgQosPlugin::TNotifierInfo CConnDlgQosPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
490 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
491 |
iInfo.iUid = KUidCConnDlgQos; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
492 |
iInfo.iPriority = ENotifierPriorityHigh; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
493 |
iInfo.iChannel = KUidCConnDlgQos; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
494 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
495 |
return iInfo; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
496 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
497 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
498 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
499 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
500 |
// void CConnDlgQosPlugin::StartL |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
501 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
502 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
503 |
void CConnDlgQosPlugin::StartL( const TDesC8& /*aBuffer*/, TInt aReplySlot, |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
504 |
const RMessagePtr2& aMessage ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
505 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
506 |
iReplySlot = aReplySlot; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
507 |
iMessage = aMessage; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
508 |
iCancelled = EFalse; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
509 |
|
58 | 510 |
GetReconnectL(); |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
511 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
512 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
513 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
514 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
515 |
// void CConnDlgQosPlugin::Cancel() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
516 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
517 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
518 |
void CConnDlgQosPlugin::Cancel() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
519 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
520 |
if ( !iCancelled ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
521 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
522 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
523 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
524 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
525 |
iMessage.Complete( KErrCancel ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
526 |
} |
58 | 527 |
delete iDialog; |
528 |
iDialog = NULL; |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
529 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
530 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
531 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
532 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
533 |
// --------------------------------------------------------- |
58 | 534 |
// void CConnDlgQosPlugin::GetReconnectL() |
535 |
// --------------------------------------------------------- |
|
536 |
// |
|
537 |
void CConnDlgQosPlugin::GetReconnectL() |
|
538 |
{ |
|
539 |
iDialog = new (ELeave) CQosDialog( this, iBool ); |
|
540 |
iDialog->ExecuteLD( R_CONNDLG_QOS ); |
|
541 |
} |
|
542 |
||
543 |
||
544 |
// --------------------------------------------------------- |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
545 |
// void CConnDlgQosPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
546 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
547 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
548 |
void CConnDlgQosPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
549 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
550 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
551 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
552 |
{ |
58 | 553 |
if ( aStatus == KErrNone ) |
554 |
{ |
|
555 |
TRAP_IGNORE( iMessage.WriteL( iReplySlot, TPckg<TBool>( iBool ) ) ); |
|
556 |
} |
|
557 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
558 |
iMessage.Complete( aStatus ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
559 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
560 |
Cancel(); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
561 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
562 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
563 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
564 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
565 |
// CConnDlgQosPlugin* CConnDlgQosPlugin::NewL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
566 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
567 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
568 |
CConnDlgQosPlugin* CConnDlgQosPlugin::NewL( |
58 | 569 |
const TBool aResourceFileResponsible ) |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
570 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
571 |
CConnDlgQosPlugin* self = new (ELeave) CConnDlgQosPlugin(); |
58 | 572 |
CleanupStack::PushL( self ); |
573 |
self->ConstructL( KResourceFileName, aResourceFileResponsible ); |
|
574 |
CleanupStack::Pop(); |
|
575 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
576 |
return self; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
577 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
578 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
579 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
580 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
581 |
// CConnDlgReconnectPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
582 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
583 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
584 |
CConnDlgReconnectPlugin::TNotifierInfo CConnDlgReconnectPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
585 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
586 |
iInfo.iUid = KUidCConnDlgReconnect; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
587 |
iInfo.iPriority = ENotifierPriorityHigh; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
588 |
iInfo.iChannel = KUidCConnDlgReconnect; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
589 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
590 |
return iInfo; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
591 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
592 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
593 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
594 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
595 |
// void CConnDlgReconnectPlugin::StartL |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
596 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
597 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
598 |
void CConnDlgReconnectPlugin::StartL( const TDesC8& /*aBuffer*/, |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
599 |
TInt aReplySlot, |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
600 |
const RMessagePtr2& aMessage ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
601 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
602 |
iReplySlot = aReplySlot; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
603 |
iMessage = aMessage; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
604 |
iCancelled = EFalse; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
605 |
|
58 | 606 |
GetReconnectL(); |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
607 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
608 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
609 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
610 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
611 |
// void CConnDlgReconnectPlugin::Cancel() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
612 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
613 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
614 |
void CConnDlgReconnectPlugin::Cancel() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
615 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
616 |
if ( !iCancelled ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
617 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
618 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
619 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
620 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
621 |
iMessage.Complete( KErrCancel ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
622 |
} |
58 | 623 |
delete iDialog; |
624 |
iDialog = NULL; |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
625 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
626 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
627 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
628 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
629 |
// --------------------------------------------------------- |
58 | 630 |
// void CConnDlgReconnectPlugin::GetReconnectL() |
631 |
// --------------------------------------------------------- |
|
632 |
// |
|
633 |
void CConnDlgReconnectPlugin::GetReconnectL() |
|
634 |
{ |
|
635 |
iDialog = new (ELeave) CReconnectDialog( this, iBool ); |
|
636 |
iDialog->ExecuteLD( R_CONNDLG_RECONNECT ); |
|
637 |
} |
|
638 |
||
639 |
||
640 |
// --------------------------------------------------------- |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
641 |
// void CConnDlgReconnectPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
642 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
643 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
644 |
void CConnDlgReconnectPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
645 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
646 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
647 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
648 |
{ |
58 | 649 |
if ( aStatus == KErrNone ) |
650 |
{ |
|
651 |
iMessage.WriteL( iReplySlot, TPckg<TBool>( iBool ) ); |
|
652 |
} |
|
653 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
654 |
iMessage.Complete( aStatus ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
655 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
656 |
Cancel(); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
657 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
658 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
659 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
660 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
661 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
662 |
// CConnDlgReconnectPlugin* CConnDlgReconnectPlugin::NewL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
663 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
664 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
665 |
CConnDlgReconnectPlugin* CConnDlgReconnectPlugin::NewL( |
58 | 666 |
const TBool aResourceFileResponsible ) |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
667 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
668 |
CConnDlgReconnectPlugin* self = new (ELeave) CConnDlgReconnectPlugin(); |
58 | 669 |
CleanupStack::PushL( self ); |
670 |
self->ConstructL( KResourceFileName, aResourceFileResponsible ); |
|
671 |
CleanupStack::Pop(); |
|
672 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
673 |
return self; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
674 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
675 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
676 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
677 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
678 |
// CConnDlgNewIapPlugin::TNotifierInfo CConnDlgNewIapPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
679 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
680 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
681 |
CConnDlgNewIapPlugin::TNotifierInfo CConnDlgNewIapPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
682 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
683 |
iInfo.iUid = KUidCConnDlgNewIap; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
684 |
iInfo.iPriority = ENotifierPriorityHigh; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
685 |
iInfo.iChannel = KUidCConnDlgNewIap; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
686 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
687 |
return iInfo; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
688 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
689 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
690 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
691 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
692 |
// void CConnDlgNewIapPlugin::StartL |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
693 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
694 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
695 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
696 |
void CConnDlgNewIapPlugin::StartL( const TDesC8& aBuffer, TInt aReplySlot, |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
697 |
const RMessagePtr2& aMessage ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
698 |
{ |
58 | 699 |
if ( aBuffer.Length() > iPrefs.Length() ) |
700 |
{ |
|
701 |
User::Panic( KConnDlgPluginPanic, EConnDlgIllegalRequest ); |
|
702 |
} |
|
703 |
||
704 |
iPrefs.Copy( aBuffer ); |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
705 |
iReplySlot = aReplySlot; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
706 |
iMessage = aMessage; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
707 |
iCancelled = EFalse; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
708 |
|
58 | 709 |
GetNewIapL(); |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
710 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
711 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
712 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
713 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
714 |
// void CConnDlgNewIapPlugin::Cancel() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
715 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
716 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
717 |
void CConnDlgNewIapPlugin::Cancel() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
718 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
719 |
if ( !iCancelled ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
720 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
721 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
722 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
723 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
724 |
iMessage.Complete( KErrCancel ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
725 |
} |
58 | 726 |
delete iDialog; |
727 |
iDialog = NULL; |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
728 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
729 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
730 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
731 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
732 |
// --------------------------------------------------------- |
58 | 733 |
// void CConnDlgNewIapPlugin::GetNewIapL() |
734 |
// --------------------------------------------------------- |
|
735 |
// |
|
736 |
void CConnDlgNewIapPlugin::GetNewIapL() |
|
737 |
{ |
|
738 |
iDialog = new (ELeave) CNewIapDialog( this, iConnect, iPrefs() ); |
|
739 |
iDialog->ExecuteLD( R_CONNDLG_NEW_IAP ); |
|
740 |
} |
|
741 |
||
742 |
||
743 |
// --------------------------------------------------------- |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
744 |
// void CConnDlgNewIapPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
745 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
746 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
747 |
void CConnDlgNewIapPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
748 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
749 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
750 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
751 |
{ |
58 | 752 |
if ( aStatus == KErrNone ) |
753 |
{ |
|
754 |
iMessage.WriteL( iReplySlot, TPckg<TBool>( iConnect ) ); |
|
755 |
} |
|
756 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
757 |
iMessage.Complete( aStatus ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
758 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
759 |
Cancel(); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
760 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
761 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
762 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
763 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
764 |
// CConnDlgNewIapPlugin* CConnDlgNewIapPlugin::NewL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
765 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
766 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
767 |
CConnDlgNewIapPlugin* CConnDlgNewIapPlugin::NewL( |
58 | 768 |
const TBool aResourceFileResponsible ) |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
769 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
770 |
CConnDlgNewIapPlugin* self = new (ELeave) CConnDlgNewIapPlugin(); |
58 | 771 |
CleanupStack::PushL( self ); |
772 |
self->ConstructL( KResourceFileName, aResourceFileResponsible ); |
|
773 |
CleanupStack::Pop(); |
|
774 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
775 |
return self; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
776 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
777 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
778 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
779 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
780 |
// CConnDlgSelectConnectionPlugin::TNotifierInfo |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
781 |
// CConnDlgSelectConnectionPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
782 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
783 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
784 |
CConnDlgSelectConnectionPlugin::TNotifierInfo |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
785 |
CConnDlgSelectConnectionPlugin::RegisterL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
786 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
787 |
iInfo.iUid = KUidCConnDlgSelectConn; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
788 |
iInfo.iPriority = ENotifierPriorityHigh; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
789 |
iInfo.iChannel = KUidCConnDlgSelectConn; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
790 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
791 |
return iInfo; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
792 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
793 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
794 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
795 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
796 |
// void CConnDlgSelectConnectionPlugin::StartL |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
797 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
798 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
799 |
|
58 | 800 |
void CConnDlgSelectConnectionPlugin::StartL( const TDesC8& aBuffer, |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
801 |
TInt aReplySlot, |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
802 |
const RMessagePtr2& aMessage ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
803 |
{ |
58 | 804 |
CLOG_ENTERFN( "CConnDlgSelectConnectionPlugin::StartL" ); |
805 |
||
806 |
if ( iActivePlugin ) |
|
807 |
{ |
|
808 |
aMessage.Complete( KErrServerBusy ); |
|
809 |
return; |
|
810 |
} |
|
811 |
||
812 |
TInt iStartUpPhaseValue( EStartupUiPhaseUninitialized ); |
|
813 |
RProperty::Get( KPSUidStartup, KPSStartupUiPhase, iStartUpPhaseValue ); |
|
814 |
CLOG_WRITEF( _L( "CConnDlgSelectConnectionPlugin::Phone start up phase: %d" ), |
|
815 |
iStartUpPhaseValue ); |
|
816 |
// Don't show the dialog if phone boot up isn't complete or screen saver or Autolock is on. |
|
817 |
if ( iStartUpPhaseValue != EStartupUiPhaseAllDone || ScreenSaverOn() || AutolockOn() ) |
|
818 |
{ |
|
819 |
CLOG_WRITE( "CConnDlgSelectConnectionPlugin::StartL: Screen saver or Autolock is active or start up phase not completed yet." ); |
|
820 |
aMessage.Complete( KErrCancel ); |
|
821 |
return; |
|
822 |
} |
|
823 |
||
824 |
iPrefs.Copy( ( TPtrC8 ) aBuffer ); |
|
825 |
||
826 |
iCancelled = ETrue; // This method could leave before displaying the dialog. |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
827 |
iReplySlot = aReplySlot; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
828 |
iMessage = aMessage; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
829 |
|
58 | 830 |
__ASSERT_DEBUG( !iActivePlugin, |
831 |
User::Panic( KErrActiveObjectNull, KErrNone ) ); |
|
832 |
||
833 |
iElementID = iPrefs().iRank; |
|
834 |
iActivePlugin = CActiveSelectConnectionPlugin::NewL( this, |
|
835 |
iElementID, |
|
836 |
iPrefs().iBearerSet ); |
|
837 |
// Check if there is a suitable active connection |
|
838 |
TInt snap( 0 ); |
|
839 |
TInt iap( 0 ); |
|
840 |
TInt bearer( ECommDbBearerWLAN ); // User conn. is always WLAN in 9.1 |
|
841 |
||
842 |
// Is there active User connection |
|
843 |
TInt err = GetUserConnection( iap, snap ); |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
844 |
|
58 | 845 |
if ( ( err != KErrNone ) || ( iap == 0 && snap == 0 ) ) |
846 |
{ |
|
847 |
// Is there any active connection |
|
848 |
err = GetActiveConnection( iap, snap, bearer ); |
|
849 |
} |
|
850 |
||
851 |
RVpnServ vpn; |
|
852 |
TInt vpnErr( KErrNone ); |
|
853 |
TInt policyCount( 0 ); |
|
854 |
TBool forceDialogForIntranetUsers( EFalse ); |
|
55
fc7b30ed2058
Revision: 201030
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
855 |
|
58 | 856 |
vpnErr = vpn.Connect(); |
857 |
if ( !vpnErr ) |
|
858 |
{ |
|
859 |
vpnErr = vpn.EnumeratePolicies(policyCount); |
|
860 |
if ( !vpnErr && policyCount > 0 ) |
|
861 |
{ |
|
862 |
forceDialogForIntranetUsers = ETrue; |
|
863 |
} |
|
864 |
vpn.Close(); |
|
865 |
} |
|
55
fc7b30ed2058
Revision: 201030
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
866 |
|
58 | 867 |
if ( !forceDialogForIntranetUsers && |
868 |
( err == KErrNone ) && |
|
869 |
( iap != 0 || snap != 0 ) && |
|
870 |
( iPrefs().iBearerSet & bearer ) && |
|
871 |
( iPrefs().iDirection == 0 ) ) // JavaVM sets iDirection to "1" |
|
872 |
{ |
|
873 |
// a suitable connection is already active |
|
874 |
SetElementIDL( iap, snap ); |
|
875 |
CompleteL( KErrNone ); |
|
57
05bc53fe583b
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
55
diff
changeset
|
876 |
} |
58 | 877 |
else |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
878 |
{ |
58 | 879 |
// display dialog |
880 |
iActivePlugin->ShowSelectConnectionL(); |
|
881 |
iCancelled = EFalse; // Dialog is now up and running |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
882 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
883 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
884 |
|
58 | 885 |
|
886 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
887 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
888 |
// void CConnDlgSelectConnectionPlugin::Cancel() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
889 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
890 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
891 |
void CConnDlgSelectConnectionPlugin::Cancel() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
892 |
{ |
58 | 893 |
CLOG_ENTERFN( "CConnDlgSelectConnectionPlugin::Cancel" ); |
894 |
||
895 |
delete iActivePlugin; |
|
896 |
CLOG_WRITE( "iActivePlugin deleted" ); |
|
897 |
iActivePlugin = NULL; |
|
898 |
CLOG_WRITE( "iActivePlugin NULLed" ); |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
899 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
900 |
if ( !iCancelled ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
901 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
902 |
CLOG_WRITE( "iCancelled == EFalse" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
903 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
904 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
905 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
906 |
CLOG_WRITE( "Going to Complete iMessage (KErrCancel)" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
907 |
iMessage.Complete( KErrCancel ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
908 |
CLOG_WRITE( "iMessage completed" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
909 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
910 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
911 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
912 |
CLOG_LEAVEFN( "CConnDlgSelectConnectionPlugin::Cancel" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
913 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
914 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
915 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
916 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
917 |
// void CConnDlgSelectConnectionPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
918 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
919 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
920 |
void CConnDlgSelectConnectionPlugin::CompleteL( TInt aStatus ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
921 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
922 |
CLOG_ENTERFN( "CConnDlgSelectConnectionPlugin::CompleteL" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
923 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
924 |
iCancelled = ETrue; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
925 |
if ( !iMessage.IsNull() ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
926 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
927 |
if ( aStatus == KErrNone ) |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
928 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
929 |
iMessage.WriteL( iReplySlot, TPckg<TUint32>( iElementID ) ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
930 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
931 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
932 |
CLOG_WRITEF( _L( "CConnDlgSelectConnectionPlugin::CompleteL iElementID : %d" ), iElementID ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
933 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
934 |
iMessage.Complete( aStatus ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
935 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
936 |
Cancel(); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
937 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
938 |
CLOG_LEAVEFN( "CConnDlgSelectConnectionPlugin::CompleteL" ); |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
939 |
} |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
940 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
941 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
942 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
943 |
// CConnDlgSelectConnectionPlugin* CConnDlgSelectConnectionPlugin::NewL() |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
944 |
// --------------------------------------------------------- |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
945 |
// |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
946 |
CConnDlgSelectConnectionPlugin* CConnDlgSelectConnectionPlugin::NewL( |
58 | 947 |
const TBool aResourceFileResponsible ) |
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
948 |
{ |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
949 |
CConnDlgSelectConnectionPlugin* self = |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
950 |
new (ELeave) CConnDlgSelectConnectionPlugin(); |
58 | 951 |
CleanupStack::PushL( self ); |
952 |
self->ConstructL( KResourceFileName, aResourceFileResponsible ); |
|
953 |
CleanupStack::Pop(); |
|
954 |
||
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
955 |
return self; |
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
956 |
} |
58 | 957 |
|
958 |
||
959 |
// --------------------------------------------------------- |
|
960 |
// CConnDlgSelectConnectionPlugin::SetSelectedIDsL |
|
961 |
// --------------------------------------------------------- |
|
962 |
// |
|
963 |
void CConnDlgSelectConnectionPlugin::SetElementIDL( TUint32 aIAPId, |
|
964 |
TUint32 aDestinationId ) |
|
965 |
{ |
|
966 |
iElementID = iActivePlugin->GetElementIDL( aIAPId, aDestinationId ); |
|
967 |
} |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
968 |
|
58 | 969 |
|
970 |
// --------------------------------------------------------- |
|
971 |
// CConnDlgSelectConnectionPlugin::GetUserConnection |
|
972 |
// --------------------------------------------------------- |
|
973 |
// |
|
974 |
TInt CConnDlgSelectConnectionPlugin::GetUserConnection( TInt& aIapId, |
|
975 |
TInt& aSnapId ) |
|
976 |
{ |
|
977 |
aIapId = 0; |
|
978 |
aSnapId = 0; |
|
979 |
||
980 |
TInt err = RProperty::Get( KMPMUserConnectionCategory, |
|
981 |
KMPMPSKeyUserConnectionSnap, |
|
982 |
aSnapId ); |
|
983 |
||
984 |
if ( err != KErrNone || aSnapId == 0 ) |
|
985 |
{ |
|
986 |
err = RProperty::Get( KMPMUserConnectionCategory, |
|
987 |
KMPMPSKeyUserConnectionIap, |
|
988 |
aIapId ); |
|
989 |
} |
|
990 |
||
991 |
CLOG_WRITEF( _L( "KMPMPSKeyUserConnectionSnap : %d" ), aSnapId ); |
|
992 |
CLOG_WRITEF( _L( "KMPMPSKeyUserConnectionIap : %d" ), aIapId ); |
|
993 |
CLOG_WRITEF( _L( "err : %d" ), err ); |
|
994 |
||
995 |
return err; |
|
996 |
} |
|
997 |
||
998 |
||
999 |
// --------------------------------------------------------- |
|
1000 |
// CConnDlgSelectConnectionPlugin::GetActiveConnection |
|
1001 |
// --------------------------------------------------------- |
|
1002 |
// |
|
1003 |
TInt CConnDlgSelectConnectionPlugin::GetActiveConnection( TInt& aIapId, |
|
1004 |
TInt& aSnapId, |
|
1005 |
TInt& aBearer ) |
|
1006 |
{ |
|
1007 |
aIapId = 0; |
|
1008 |
aSnapId = 0; |
|
1009 |
aBearer = 0; |
|
1010 |
||
1011 |
TInt err = RProperty::Get( KMPMActiveConnectionCategory, |
|
1012 |
KMPMPSKeyActiveConnectionSnap, |
|
1013 |
aSnapId ); |
|
1014 |
||
1015 |
if ( err != KErrNone || aSnapId == 0 ) |
|
1016 |
{ |
|
1017 |
err = RProperty::Get( KMPMActiveConnectionCategory, |
|
1018 |
KMPMPSKeyActiveConnectionIap, |
|
1019 |
aIapId ); |
|
1020 |
} |
|
1021 |
||
1022 |
CLOG_WRITEF( _L( "KMPMPSKeyActiveConnectionSnap : %d" ), aSnapId ); |
|
1023 |
CLOG_WRITEF( _L( "KMPMPSKeyActiveConnectionIap : %d" ), aIapId ); |
|
1024 |
CLOG_WRITEF( _L( "err : %d" ), err ); |
|
1025 |
||
1026 |
if ( err == KErrNone ) |
|
1027 |
{ |
|
1028 |
err = RProperty::Get( KMPMActiveConnectionCategory, |
|
1029 |
KMPMPSKeyActiveConnectionBearer, |
|
1030 |
aBearer ); |
|
1031 |
} |
|
1032 |
||
1033 |
CLOG_WRITEF( _L( "KMPMPSKeyActiveConnectionBearer : %d" ), aBearer ); |
|
1034 |
CLOG_WRITEF( _L( "iPrefs().iBearerSet : %d" ), iPrefs().iBearerSet ); |
|
1035 |
CLOG_WRITEF( _L( "err : %d" ), err ); |
|
1036 |
||
1037 |
return err; |
|
1038 |
} |
|
0
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
1039 |
|
5a93021fdf25
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
diff
changeset
|
1040 |
// End of File |