|
1 /* |
|
2 * Copyright (c) 2004 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * Implementation of class CConnectionUiUtilitiesImpl. |
|
16 * |
|
17 * |
|
18 */ |
|
19 |
|
20 |
|
21 // INCLUDE FILES |
|
22 |
|
23 #include <bautils.h> |
|
24 #include <StringLoader.h> |
|
25 #include <commdb.h> |
|
26 #include <aknnotewrappers.h> |
|
27 #include <AknGlobalNote.h> |
|
28 #include <aknradiobuttonsettingpage.h> |
|
29 #include <ConnectionUiUtilities.h> |
|
30 #include <AknsUtils.h> |
|
31 #include <featmgr.h> |
|
32 #ifndef SYMBIAN_ENABLE_SPLIT_HEADERS |
|
33 #include <commsdat.h> |
|
34 #else |
|
35 #include <commsdat.h> |
|
36 #include <commsdat_partner.h> |
|
37 #endif |
|
38 |
|
39 #ifndef __WINS__ |
|
40 #include <wlanmgmtclient.h> |
|
41 #include <WlanCdbCols.h> |
|
42 #endif // ! __WINS__ |
|
43 |
|
44 #include "ConnectionUiUtilitiesImpl.h" |
|
45 #include "ChangeConnectionDlg.h" |
|
46 #include "ActiveCChangeConnectionDlg.h" |
|
47 |
|
48 #include <ConnectionUiUtilities.rsg> |
|
49 #include <data_caging_path_literals.hrh> |
|
50 |
|
51 #include "ConnectionDialogsLogger.h" |
|
52 |
|
53 |
|
54 // CONSTANTS |
|
55 |
|
56 // ROM folder |
|
57 _LIT( KDriveZ, "z:" ); |
|
58 |
|
59 // RSC file name. |
|
60 _LIT( KConnUiUtilsResName, "ConnectionUiUtilities.rsc" ); |
|
61 |
|
62 |
|
63 |
|
64 // ================= MEMBER FUNCTIONS ======================= |
|
65 |
|
66 // --------------------------------------------------------- |
|
67 // CConnectionUiUtilitiesImpl::NewL |
|
68 // --------------------------------------------------------- |
|
69 // |
|
70 CConnectionUiUtilitiesImpl* CConnectionUiUtilitiesImpl::NewL() |
|
71 { |
|
72 CConnectionUiUtilitiesImpl* utilsImpl = |
|
73 new ( ELeave ) CConnectionUiUtilitiesImpl(); |
|
74 CleanupStack::PushL( utilsImpl ); |
|
75 utilsImpl->ConstructL(); |
|
76 CleanupStack::Pop( utilsImpl ); |
|
77 return utilsImpl; |
|
78 } |
|
79 |
|
80 |
|
81 // --------------------------------------------------------- |
|
82 // CConnectionUiUtilitiesImpl::CConnectionUiUtilitiesImpl |
|
83 // --------------------------------------------------------- |
|
84 // |
|
85 CConnectionUiUtilitiesImpl::CConnectionUiUtilitiesImpl() |
|
86 : iResOffset( 0 ), |
|
87 iIsWlanSupported( EFalse ) |
|
88 { |
|
89 for ( TInt i = 0; i < KNumberOfWrappedDialogs; i++ ) |
|
90 { |
|
91 iActiveWrapper[i] = NULL; |
|
92 } |
|
93 } |
|
94 |
|
95 |
|
96 // --------------------------------------------------------- |
|
97 // CConnectionUiUtilitiesImpl::ConstructL |
|
98 // --------------------------------------------------------- |
|
99 // |
|
100 void CConnectionUiUtilitiesImpl::ConstructL() |
|
101 { |
|
102 User::LeaveIfError( iNotif.Connect() ); |
|
103 |
|
104 FeatureManager::InitializeLibL(); |
|
105 iIsWlanSupported = |
|
106 FeatureManager::FeatureSupported( KFeatureIdProtocolWlan ); |
|
107 FeatureManager::UnInitializeLib(); |
|
108 } |
|
109 |
|
110 |
|
111 // --------------------------------------------------------- |
|
112 // CConnectionUiUtilitiesImpl::~CConnectionUiUtilitiesImpl |
|
113 // --------------------------------------------------------- |
|
114 // |
|
115 CConnectionUiUtilitiesImpl::~CConnectionUiUtilitiesImpl() |
|
116 { |
|
117 if ( iResOffset ) |
|
118 { |
|
119 CCoeEnv::Static()->DeleteResourceFile( iResOffset ); |
|
120 } |
|
121 iNotif.Close(); |
|
122 |
|
123 for ( TInt i = 0; i < KNumberOfWrappedDialogs; i++ ) |
|
124 { |
|
125 delete iActiveWrapper[i]; |
|
126 } |
|
127 } |
|
128 |
|
129 // --------------------------------------------------------- |
|
130 // CConnectionUiUtilitiesImpl::LoadResourceFileL |
|
131 // --------------------------------------------------------- |
|
132 // |
|
133 void CConnectionUiUtilitiesImpl::LoadResourceFileL() |
|
134 { |
|
135 if ( !iResOffset ) |
|
136 { |
|
137 // can't use resource here because it has not been added yet.... |
|
138 TFileName fileName; |
|
139 |
|
140 fileName.Append( KDriveZ ); |
|
141 fileName.Append( KDC_RESOURCE_FILES_DIR ); |
|
142 fileName.Append( KConnUiUtilsResName ); |
|
143 |
|
144 BaflUtils::NearestLanguageFile( CCoeEnv::Static()->FsSession(), |
|
145 fileName ); |
|
146 iResOffset = CCoeEnv::Static()->AddResourceFileL( fileName ); |
|
147 } |
|
148 } |
|
149 |
|
150 // --------------------------------------------------------- |
|
151 // CConnectionUiUtilitiesImpl::AlwaysAskPageL |
|
152 // --------------------------------------------------------- |
|
153 // |
|
154 |
|
155 TBool CConnectionUiUtilitiesImpl::AlwaysAskPageL( |
|
156 TCuuAlwaysAskResults& aResult ) |
|
157 { |
|
158 LoadResourceFileL(); |
|
159 // options array |
|
160 CDesCArrayFlat* values = new( ELeave )CDesCArrayFlat( 1 ); |
|
161 CleanupStack::PushL( values ); |
|
162 |
|
163 HBufC* value1 = CCoeEnv::Static()->AllocReadResourceLC( |
|
164 R_ALWAYS_ASK_ALWAYS_ASK ); |
|
165 values->AppendL( *value1 ); |
|
166 CleanupStack::PopAndDestroy( value1 ); |
|
167 |
|
168 HBufC* value2 = CCoeEnv::Static()->AllocReadResourceLC( |
|
169 R_ALWAYS_ASK_USER_DEFINED ); |
|
170 values->AppendL( *value2 ); |
|
171 CleanupStack::PopAndDestroy( value2 ); |
|
172 |
|
173 TInt index( 0 ); |
|
174 switch ( aResult ) |
|
175 { |
|
176 case ECuuAlwaysAsk: |
|
177 { |
|
178 index = 0; |
|
179 break; |
|
180 } |
|
181 case ECuuUserDefined: |
|
182 { |
|
183 index = 1; |
|
184 break; |
|
185 } |
|
186 default: |
|
187 break; |
|
188 } |
|
189 |
|
190 CAknRadioButtonSettingPage* dlg = new ( ELeave )CAknRadioButtonSettingPage( |
|
191 R_ALWAYS_ASK_PAGE, index, values ); |
|
192 |
|
193 TBool oKPressed( EFalse ); |
|
194 |
|
195 CleanupStack::PushL( dlg ); |
|
196 |
|
197 AknsUtils::SetAvkonSkinEnabledL( ETrue ); |
|
198 |
|
199 CleanupStack::Pop( dlg ); |
|
200 |
|
201 if ( dlg->ExecuteLD( CAknSettingPage::EUpdateWhenChanged ) ) |
|
202 { |
|
203 oKPressed = ETrue; |
|
204 } |
|
205 |
|
206 switch ( index ) |
|
207 { |
|
208 case 0: |
|
209 { |
|
210 aResult = ECuuAlwaysAsk; |
|
211 break; |
|
212 } |
|
213 case 1: |
|
214 { |
|
215 aResult = ECuuUserDefined; |
|
216 break; |
|
217 } |
|
218 default: |
|
219 break; |
|
220 } |
|
221 |
|
222 CleanupStack::PopAndDestroy( values ); |
|
223 |
|
224 return oKPressed; |
|
225 } |
|
226 |
|
227 // --------------------------------------------------------- |
|
228 // CConnectionUiUtilitiesImpl::ChangeConnectionL |
|
229 // --------------------------------------------------------- |
|
230 // |
|
231 TBool CConnectionUiUtilitiesImpl::ChangeConnectionL( TUint32& aIAPId, |
|
232 TConnectionPrefs aPrefs ) |
|
233 { |
|
234 CLOG_ENTERFN( "CConnectionUiUtilitiesImpl::ChangeConnectionL " ); |
|
235 |
|
236 TUint32 origId = aIAPId; |
|
237 LoadResourceFileL(); |
|
238 CCommsDatabase* db = CCommsDatabase::NewL( EDatabaseTypeUnspecified ); |
|
239 CleanupStack::PushL( db ); |
|
240 |
|
241 TBuf<CommsDat::KMaxTextLength> connName; |
|
242 |
|
243 GetConnectionNameL( aIAPId, *db, connName ); |
|
244 CleanupStack::PopAndDestroy( db ); // db |
|
245 |
|
246 CActiveCChangeConnectionDlg* activeChangeConnDlg = |
|
247 CActiveCChangeConnectionDlg::NewL( &aIAPId, aPrefs, connName ); |
|
248 CleanupStack::PushL( activeChangeConnDlg ); |
|
249 |
|
250 TBool retval = activeChangeConnDlg->StartSearchIAPsL(); |
|
251 |
|
252 CLOG_WRITE( "activeChangeConnDlg->StartSearchIAPsL();" ); |
|
253 |
|
254 CLOG_WRITEF( _L( "aIAPId : %d" ), aIAPId ); |
|
255 CLOG_WRITEF( _L( "origId : %d" ), origId ); |
|
256 CLOG_WRITEF( _L( "retval : %d" ), retval ); |
|
257 |
|
258 CleanupStack::PopAndDestroy( activeChangeConnDlg ); |
|
259 |
|
260 CLOG_LEAVEFN( "CConnectionUiUtilitiesImpl::ChangeConnectionL " ); |
|
261 |
|
262 return retval; |
|
263 } |
|
264 |
|
265 |
|
266 // --------------------------------------------------------- |
|
267 // CConnectionUiUtilitiesImpl::ShowConnectionChangedNoteL |
|
268 // --------------------------------------------------------- |
|
269 // |
|
270 void CConnectionUiUtilitiesImpl::ShowConnectionChangedNoteL( |
|
271 const TUint32& aIAPId ) |
|
272 |
|
273 { |
|
274 LoadResourceFileL(); |
|
275 CCommsDatabase* db = CCommsDatabase::NewL( EDatabaseTypeUnspecified ); |
|
276 CleanupStack::PushL( db ); |
|
277 |
|
278 TBuf<CommsDat::KMaxTextLength> connName; |
|
279 |
|
280 GetConnectionNameL( aIAPId, *db, connName ); |
|
281 CleanupStack::PopAndDestroy( db ); |
|
282 |
|
283 HBufC* stringLabel = StringLoader::LoadLC( R_CONN_CHANGED, connName ); |
|
284 |
|
285 CAknInformationNote* infNote = new( ELeave )CAknInformationNote(); |
|
286 infNote->ExecuteLD( *stringLabel ); |
|
287 |
|
288 CleanupStack::PopAndDestroy( stringLabel ); |
|
289 } |
|
290 |
|
291 |
|
292 |
|
293 // --------------------------------------------------------- |
|
294 // CConnectionUiUtilitiesImpl::SearchWLANNetwork |
|
295 // --------------------------------------------------------- |
|
296 // |
|
297 TBool CConnectionUiUtilitiesImpl::SearchWLANNetwork( TWlanSsid& aSSID, |
|
298 TWlanConnectionMode& aConnectionMode, |
|
299 TWlanConnectionSecurityMode& aSecurityMode ) |
|
300 { |
|
301 return SearchWLANNetwork( aSSID, |
|
302 aConnectionMode, |
|
303 aSecurityMode, |
|
304 iDummyExtSecMode, |
|
305 iDummy ); |
|
306 } |
|
307 |
|
308 // --------------------------------------------------------- |
|
309 // CConnectionUiUtilitiesImpl::SearchWLANNetwork |
|
310 // --------------------------------------------------------- |
|
311 // |
|
312 TBool CConnectionUiUtilitiesImpl::SearchWLANNetwork( TWlanSsid& aSSID, |
|
313 TWlanConnectionMode& aConnectionMode, |
|
314 TWlanConnectionExtentedSecurityMode& aExtSecurityMode ) |
|
315 { |
|
316 return SearchWLANNetwork( aSSID, |
|
317 aConnectionMode, |
|
318 iDummySecMode, |
|
319 aExtSecurityMode, |
|
320 iDummy ); |
|
321 } |
|
322 |
|
323 // --------------------------------------------------------- |
|
324 // CConnectionUiUtilitiesImpl::SearchWLANNetwork |
|
325 // --------------------------------------------------------- |
|
326 // |
|
327 TBool CConnectionUiUtilitiesImpl::SearchWLANNetwork( TWlanSsid& aSSID, |
|
328 TWlanConnectionMode& aConnectionMode, |
|
329 TWlanConnectionSecurityMode& aSecurityMode, |
|
330 TBool& aProtectedSetupSupported ) |
|
331 { |
|
332 return SearchWLANNetwork( aSSID, |
|
333 aConnectionMode, |
|
334 aSecurityMode, |
|
335 iDummyExtSecMode, |
|
336 aProtectedSetupSupported ); |
|
337 } |
|
338 |
|
339 // --------------------------------------------------------- |
|
340 // CConnectionUiUtilitiesImpl::SearchWLANNetwork |
|
341 // --------------------------------------------------------- |
|
342 // |
|
343 TBool CConnectionUiUtilitiesImpl::SearchWLANNetwork( TWlanSsid& aSSID, |
|
344 TWlanConnectionMode& aConnectionMode, |
|
345 TWlanConnectionExtentedSecurityMode& aExtSecurityMode, |
|
346 TBool& aProtectedSetupSupported ) |
|
347 { |
|
348 return SearchWLANNetwork( aSSID, |
|
349 aConnectionMode, |
|
350 iDummySecMode, |
|
351 aExtSecurityMode, |
|
352 aProtectedSetupSupported ); |
|
353 } |
|
354 |
|
355 // --------------------------------------------------------- |
|
356 // CConnectionUiUtilitiesImpl::SearchWLANNetwork |
|
357 // --------------------------------------------------------- |
|
358 // |
|
359 TBool CConnectionUiUtilitiesImpl::SearchWLANNetwork( TWlanSsid& aSSID, |
|
360 TWlanConnectionMode& aConnectionMode, |
|
361 TWlanConnectionSecurityMode& aSecurityMode, |
|
362 TWlanConnectionExtentedSecurityMode& aExtSecurityMode, |
|
363 TBool& aProtectedSetupSupported ) |
|
364 { |
|
365 TBool result( EFalse ); |
|
366 |
|
367 if ( iIsWlanSupported ) |
|
368 { |
|
369 iNetworkPrefs(); |
|
370 |
|
371 if ( !iActiveWrapper[ESearchWlan] ) |
|
372 { |
|
373 TRAP_IGNORE( iActiveWrapper[ESearchWlan] = |
|
374 CActiveWrapper::NewL( ESearchWlan ) ); |
|
375 } |
|
376 |
|
377 if ( iActiveWrapper[ESearchWlan] ) |
|
378 { |
|
379 iActiveWrapper[ESearchWlan]->StartSearchWLANNetwork( |
|
380 iNetworkPrefs ); |
|
381 |
|
382 CLOG_WRITEF( _L( "iActiveWrapper[ESearchWlan]->iStatus.Int(): %d" ), |
|
383 iActiveWrapper[ESearchWlan]->iStatus.Int() ); |
|
384 |
|
385 result = iActiveWrapper[ESearchWlan]->iStatus.Int() ? EFalse : |
|
386 ETrue; |
|
387 } |
|
388 |
|
389 if( result ) |
|
390 { |
|
391 aSSID = iNetworkPrefs().iSsId; |
|
392 aConnectionMode = iNetworkPrefs().iNetworkMode; |
|
393 aSecurityMode = iNetworkPrefs().iSecMode; |
|
394 aExtSecurityMode = iNetworkPrefs().iExtSecMode; |
|
395 aProtectedSetupSupported = |
|
396 iNetworkPrefs().iProtectedSetupSupported; |
|
397 } |
|
398 } |
|
399 |
|
400 CLOG_WRITEF( _L( "SearchWLANNetwork result : %b" ), result ); |
|
401 |
|
402 return result; |
|
403 } |
|
404 |
|
405 |
|
406 // --------------------------------------------------------- |
|
407 // CConnectionUiUtilitiesImpl::CancelSearchWLANNetwork |
|
408 // --------------------------------------------------------- |
|
409 // |
|
410 void CConnectionUiUtilitiesImpl::CancelSearchWLANNetwork() |
|
411 { |
|
412 if ( iIsWlanSupported ) |
|
413 { |
|
414 iActiveWrapper[ESearchWlan]->Cancel(); |
|
415 } |
|
416 } |
|
417 |
|
418 |
|
419 // --------------------------------------------------------- |
|
420 // CConnectionUiUtilitiesImpl::GetConnectionNameL |
|
421 // --------------------------------------------------------- |
|
422 // |
|
423 void CConnectionUiUtilitiesImpl::GetConnectionNameL( const TUint32& aIAPId, |
|
424 CCommsDatabase& aDb, |
|
425 TDes& aConnectionName ) |
|
426 { |
|
427 __ASSERT_DEBUG( &aDb, User::Panic( KErrNullPointer, KErrNone ) ); |
|
428 |
|
429 CCommsDbTableView* table = aDb.OpenViewMatchingUintLC( TPtrC( IAP ), |
|
430 TPtrC( COMMDB_ID ), |
|
431 aIAPId ); |
|
432 User::LeaveIfError( table->GotoFirstRecord() ); |
|
433 table->ReadTextL( TPtrC( COMMDB_NAME ), aConnectionName ); |
|
434 if ( aConnectionName.Length() == 0 || |
|
435 aConnectionName.Left( KMrouterName().Length() ).CompareF( |
|
436 KMrouterName ) == 0 ) |
|
437 { |
|
438 User::Leave( KErrGeneral ); |
|
439 } |
|
440 |
|
441 TUint32 serviceId; |
|
442 // Get IAP service |
|
443 table->ReadUintL( TPtrC( IAP_SERVICE ), serviceId ); |
|
444 |
|
445 CleanupStack::PopAndDestroy( table ); |
|
446 |
|
447 #ifndef __WINS__ |
|
448 if ( iIsWlanSupported ) |
|
449 { |
|
450 CCommsDbTableView* wLanServiceTable = NULL; |
|
451 |
|
452 TRAPD( err, |
|
453 { // this leaves if the table is empty.... |
|
454 wLanServiceTable = aDb.OpenViewMatchingUintLC( |
|
455 TPtrC( WLAN_SERVICE ), |
|
456 TPtrC( WLAN_SERVICE_ID ), |
|
457 serviceId ); |
|
458 CleanupStack::Pop( wLanServiceTable ); // wLanServiceTable |
|
459 } ); |
|
460 |
|
461 CLOG_WRITEF( _L( "OpenViewMatchingUintLC returned %d" ), err ); |
|
462 |
|
463 if ( err == KErrNone ) |
|
464 { |
|
465 CleanupStack::PushL( wLanServiceTable ); |
|
466 |
|
467 TInt errorCode = wLanServiceTable->GotoFirstRecord(); |
|
468 TWlanSsid ssid; |
|
469 |
|
470 if ( errorCode == KErrNone ) |
|
471 { |
|
472 wLanServiceTable->ReadTextL( TPtrC( NU_WLAN_SSID ), ssid ); |
|
473 if ( ssid.Length() == 0 ) |
|
474 { |
|
475 CLOG_WRITEF( _L( "It is the EasyWlan!" ) ); |
|
476 |
|
477 TWlanSsid ssidConn; |
|
478 CWlanMgmtClient *wlanMgmtClient = CWlanMgmtClient::NewL(); |
|
479 CleanupStack::PushL( wlanMgmtClient ); |
|
480 |
|
481 if ( !wlanMgmtClient->GetConnectionSsid( ssidConn ) ) |
|
482 { |
|
483 CLOG_WRITEF( _L( "ssidConn.Length() = %d" ), ssidConn.Length() ); |
|
484 |
|
485 aConnectionName.Copy( ssidConn ); |
|
486 } |
|
487 |
|
488 wlanMgmtClient->CancelNotifications(); |
|
489 CleanupStack::PopAndDestroy( wlanMgmtClient ); |
|
490 } |
|
491 } |
|
492 |
|
493 CleanupStack::PopAndDestroy( wLanServiceTable ); |
|
494 } |
|
495 else if ( err != KErrNotFound ) |
|
496 { |
|
497 User::LeaveIfError( err ); |
|
498 } |
|
499 } |
|
500 |
|
501 #endif // !__WINS__ |
|
502 |
|
503 CLOG_WRITEF( _L( "connectionName = %S" ), &aConnectionName ); |
|
504 } |
|
505 |
|
506 |
|
507 // --------------------------------------------------------- |
|
508 // CConnectionUiUtilitiesImpl::OffLineWlanNote |
|
509 // --------------------------------------------------------- |
|
510 // |
|
511 TBool CConnectionUiUtilitiesImpl::OffLineWlanNote() |
|
512 { |
|
513 CLOG_ENTERFN( "CConnectionUiUtilitiesImpl::OffLineWlanNote" ); |
|
514 |
|
515 if ( iIsWlanSupported ) |
|
516 { |
|
517 if ( !iActiveWrapper[EOffLineWlan] ) |
|
518 { |
|
519 TRAP_IGNORE( iActiveWrapper[EOffLineWlan] = |
|
520 CActiveWrapper::NewL( EOffLineWlan ) ); |
|
521 CLOG_WRITE( "iActiveWrapper created" ); |
|
522 } |
|
523 |
|
524 if ( iActiveWrapper[EOffLineWlan] ) |
|
525 { |
|
526 CLOG_WRITE( "Starting generic note" ); |
|
527 iActiveWrapper[EOffLineWlan]->StartGenericNote( EOffLineWlan ); |
|
528 CLOG_WRITE( "Generic note started" ); |
|
529 return iActiveWrapper[EOffLineWlan]->iStatus.Int() ? EFalse : |
|
530 ETrue; |
|
531 } |
|
532 } |
|
533 |
|
534 CLOG_LEAVEFN( "CConnectionUiUtilitiesImpl::OffLineWlanNote" ); |
|
535 |
|
536 return EFalse; |
|
537 } |
|
538 |
|
539 |
|
540 // --------------------------------------------------------- |
|
541 // CConnectionUiUtilitiesImpl::OffLineWlanNote |
|
542 // --------------------------------------------------------- |
|
543 // |
|
544 void CConnectionUiUtilitiesImpl::OffLineWlanNote( TRequestStatus& aStatus ) |
|
545 { |
|
546 CLOG_ENTERFN( "CConnectionUiUtilitiesImpl::OffLineWlanNote Async" ); |
|
547 |
|
548 if ( iIsWlanSupported ) |
|
549 { |
|
550 if ( iActiveWrapper[EOffLineWlan] ) |
|
551 { // deleting, to be sure to call the right Cancel function |
|
552 delete iActiveWrapper[EOffLineWlan]; |
|
553 iActiveWrapper[EOffLineWlan] = NULL; |
|
554 } |
|
555 |
|
556 iNotif.OffLineWlanNote( aStatus, ETrue ); |
|
557 } |
|
558 |
|
559 CLOG_LEAVEFN( "CConnectionUiUtilitiesImpl::OffLineWlanNote Async" ); |
|
560 } |
|
561 |
|
562 // --------------------------------------------------------- |
|
563 // CConnectionUiUtilitiesImpl::CancelOffLineWlanNote |
|
564 // --------------------------------------------------------- |
|
565 // |
|
566 void CConnectionUiUtilitiesImpl::CancelOffLineWlanNote() |
|
567 { |
|
568 if ( iIsWlanSupported ) |
|
569 { |
|
570 if ( iActiveWrapper[EOffLineWlan] ) |
|
571 { |
|
572 iActiveWrapper[EOffLineWlan]->Cancel(); |
|
573 } |
|
574 else |
|
575 { // Asynchronous version |
|
576 iNotif.CancelOffLineWlanNote(); |
|
577 } |
|
578 } |
|
579 } |
|
580 |
|
581 // --------------------------------------------------------- |
|
582 // CConnectionUiUtilitiesImpl::OffLineWlanDisabledNote |
|
583 // --------------------------------------------------------- |
|
584 // |
|
585 void CConnectionUiUtilitiesImpl::OffLineWlanDisabledNote() |
|
586 { |
|
587 if ( iIsWlanSupported ) |
|
588 { |
|
589 if ( !iActiveWrapper[EWlanDisabled] ) |
|
590 { |
|
591 TRAP_IGNORE( iActiveWrapper[EWlanDisabled] = |
|
592 CActiveWrapper::NewL( EWlanDisabled ) ); |
|
593 } |
|
594 |
|
595 if ( iActiveWrapper[EWlanDisabled] ) |
|
596 { |
|
597 iActiveWrapper[EWlanDisabled]->StartGenericNote( EWlanDisabled ); |
|
598 } |
|
599 } |
|
600 } |
|
601 |
|
602 // --------------------------------------------------------- |
|
603 // CConnectionUiUtilitiesImpl::EasyWepDlg |
|
604 // --------------------------------------------------------- |
|
605 // |
|
606 TBool CConnectionUiUtilitiesImpl::EasyWepDlg( TDes* aKey, TBool& aHex ) |
|
607 { |
|
608 TInt status = KErrNone; |
|
609 |
|
610 if ( iIsWlanSupported ) |
|
611 { |
|
612 iWepKey().iKey.Copy( *aKey ); |
|
613 if ( !iActiveWrapper[EWlanEasyWep] ) |
|
614 { |
|
615 TRAP_IGNORE( iActiveWrapper[EWlanEasyWep] = |
|
616 CActiveWrapper::NewL( EWlanEasyWep ) ); |
|
617 } |
|
618 |
|
619 if ( iActiveWrapper[EWlanEasyWep] ) |
|
620 { |
|
621 status = iActiveWrapper[EWlanEasyWep]->StartEasyWepDlg( iWepKey ); |
|
622 } |
|
623 aKey->Copy( iWepKey().iKey ); |
|
624 aHex = iWepKey().iHex; |
|
625 } |
|
626 return ( status == KErrNone ) ? ETrue : EFalse; |
|
627 } |
|
628 |
|
629 // --------------------------------------------------------- |
|
630 // CConnectionUiUtilitiesImpl::EasyWepDlgAsync |
|
631 // --------------------------------------------------------- |
|
632 // |
|
633 void CConnectionUiUtilitiesImpl::EasyWepDlgAsync( TRequestStatus& aStatus, TDes* aKey, TBool& aHex ) |
|
634 { |
|
635 if ( iIsWlanSupported ) |
|
636 { |
|
637 if ( !iActiveWrapper[EWlanEasyWep] ) |
|
638 { |
|
639 TRAP_IGNORE( iActiveWrapper[EWlanEasyWep] = |
|
640 CActiveWrapper::NewL( EWlanEasyWep ) ); |
|
641 } |
|
642 |
|
643 if ( iActiveWrapper[EWlanEasyWep] ) |
|
644 { |
|
645 iActiveWrapper[EWlanEasyWep]->StartEasyWepDlgAsync( aStatus, aKey, aHex ); |
|
646 } |
|
647 } |
|
648 } |
|
649 |
|
650 |
|
651 |
|
652 // --------------------------------------------------------- |
|
653 // CConnectionUiUtilitiesImpl::CancelEasyWepDlg |
|
654 // --------------------------------------------------------- |
|
655 // |
|
656 void CConnectionUiUtilitiesImpl::CancelEasyWepDlg() |
|
657 { |
|
658 if ( iIsWlanSupported ) |
|
659 { |
|
660 iActiveWrapper[EWlanEasyWep]->Cancel(); |
|
661 } |
|
662 } |
|
663 |
|
664 // --------------------------------------------------------- |
|
665 // CConnectionUiUtilitiesImpl::EasyWpaDlg |
|
666 // --------------------------------------------------------- |
|
667 // |
|
668 TBool CConnectionUiUtilitiesImpl::EasyWpaDlg( TDes* aKey ) |
|
669 { |
|
670 TInt status = KErrNone; |
|
671 if ( iIsWlanSupported ) |
|
672 { |
|
673 iWpaKey().Copy( *aKey ); |
|
674 if ( !iActiveWrapper[EWlanEasyWpa] ) |
|
675 { |
|
676 TRAP_IGNORE( iActiveWrapper[EWlanEasyWpa] = |
|
677 CActiveWrapper::NewL( EWlanEasyWpa ) ); |
|
678 } |
|
679 |
|
680 if ( iActiveWrapper[EWlanEasyWpa] ) |
|
681 { |
|
682 status = iActiveWrapper[EWlanEasyWpa]->StartEasyWpaDlg( iWpaKey ); |
|
683 } |
|
684 aKey->Copy( iWpaKey() ); |
|
685 } |
|
686 return ( status == KErrNone ) ? ETrue : EFalse; |
|
687 } |
|
688 |
|
689 // --------------------------------------------------------- |
|
690 // CConnectionUiUtilitiesImpl::StartEasyWpaDlgAsync |
|
691 // --------------------------------------------------------- |
|
692 // |
|
693 void CConnectionUiUtilitiesImpl::EasyWpaDlgAsync( TRequestStatus& aStatus, TDes* aKey ) |
|
694 { |
|
695 if ( iIsWlanSupported ) |
|
696 { |
|
697 if ( !iActiveWrapper[EWlanEasyWpa] ) |
|
698 { |
|
699 TRAP_IGNORE( iActiveWrapper[EWlanEasyWpa] = |
|
700 CActiveWrapper::NewL( EWlanEasyWpa ) ); |
|
701 } |
|
702 |
|
703 if ( iActiveWrapper[EWlanEasyWpa] ) |
|
704 { |
|
705 iActiveWrapper[EWlanEasyWpa]->StartEasyWpaDlgAsync( aStatus, aKey ); |
|
706 } |
|
707 } |
|
708 } |
|
709 |
|
710 // --------------------------------------------------------- |
|
711 // CConnectionUiUtilitiesImpl::CancelEasyWpaDlg |
|
712 // --------------------------------------------------------- |
|
713 // |
|
714 void CConnectionUiUtilitiesImpl::CancelEasyWpaDlg() |
|
715 { |
|
716 if ( iIsWlanSupported ) |
|
717 { |
|
718 iActiveWrapper[EWlanEasyWpa]->Cancel(); |
|
719 } |
|
720 } |
|
721 |
|
722 // --------------------------------------------------------- |
|
723 // CConnectionUiUtilitiesImpl::WLANNetworkUnavailableNote |
|
724 // --------------------------------------------------------- |
|
725 // |
|
726 void CConnectionUiUtilitiesImpl::WLANNetworkUnavailableNote() |
|
727 { |
|
728 if ( iIsWlanSupported ) |
|
729 { |
|
730 if ( !iActiveWrapper[EWlanNetwUnavail] ) |
|
731 { |
|
732 TRAP_IGNORE( iActiveWrapper[EWlanNetwUnavail] = |
|
733 CActiveWrapper::NewL( EWlanNetwUnavail ) ); |
|
734 } |
|
735 |
|
736 if ( iActiveWrapper[EWlanNetwUnavail] ) |
|
737 { |
|
738 iActiveWrapper[EWlanNetwUnavail]->StartGenericNote( |
|
739 EWlanNetwUnavail ); |
|
740 } |
|
741 } |
|
742 } |
|
743 |
|
744 // --------------------------------------------------------- |
|
745 // CConnectionUiUtilitiesImpl::SearchWLANNetworkSync |
|
746 // --------------------------------------------------------- |
|
747 // |
|
748 TBool CConnectionUiUtilitiesImpl::SearchWLANNetworkSync( TWlanSsid& aSSID, |
|
749 TWlanConnectionMode& aConnectionMode, |
|
750 TWlanConnectionSecurityMode& aSecurityMode ) |
|
751 { |
|
752 return SearchWLANNetworkSync( aSSID, aConnectionMode, aSecurityMode, |
|
753 iDummy ); |
|
754 } |
|
755 |
|
756 |
|
757 // --------------------------------------------------------- |
|
758 // CConnectionUiUtilitiesImpl::SearchWLANNetworkSync |
|
759 // --------------------------------------------------------- |
|
760 // |
|
761 TBool CConnectionUiUtilitiesImpl::SearchWLANNetworkSync( TWlanSsid& aSSID, |
|
762 TWlanConnectionMode& aConnectionMode, |
|
763 TWlanConnectionSecurityMode& aSecurityMode, |
|
764 TBool& aProtectedSetupSupported ) |
|
765 { |
|
766 TBool result( EFalse ); |
|
767 |
|
768 if ( iIsWlanSupported ) |
|
769 { |
|
770 TRequestStatus status; |
|
771 iNetworkPrefs(); |
|
772 |
|
773 iNotif.SearchWLANNetwork( iNetworkPrefs, status, EFalse ); |
|
774 User::WaitForRequest( status ); |
|
775 |
|
776 if( status == KErrNone ) |
|
777 { |
|
778 aSSID = iNetworkPrefs().iSsId; |
|
779 aConnectionMode = iNetworkPrefs().iNetworkMode; |
|
780 aSecurityMode = iNetworkPrefs().iSecMode; |
|
781 aProtectedSetupSupported = |
|
782 iNetworkPrefs().iProtectedSetupSupported; |
|
783 result = ETrue; |
|
784 } |
|
785 } |
|
786 |
|
787 CLOG_WRITEF( _L( "SearchWLANNetworkSync result : %b" ), result ); |
|
788 return result; |
|
789 } |
|
790 |
|
791 |
|
792 // --------------------------------------------------------- |
|
793 // CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync |
|
794 // --------------------------------------------------------- |
|
795 // |
|
796 void CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync( |
|
797 TRequestStatus& aStatus, |
|
798 TWlanSsid& aSSID, |
|
799 TWlanConnectionMode& aConnectionMode, |
|
800 TWlanConnectionSecurityMode& aSecurityMode ) |
|
801 { |
|
802 SearchWLANNetworkAsync( aStatus, |
|
803 aSSID, |
|
804 aConnectionMode, |
|
805 aSecurityMode, |
|
806 iDummyExtSecMode, |
|
807 iDummy ); |
|
808 } |
|
809 |
|
810 // --------------------------------------------------------- |
|
811 // CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync |
|
812 // --------------------------------------------------------- |
|
813 // |
|
814 void CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync( |
|
815 TRequestStatus& aStatus, |
|
816 TWlanSsid& aSSID, |
|
817 TWlanConnectionMode& aConnectionMode, |
|
818 TWlanConnectionExtentedSecurityMode& aExtSecurityMode ) |
|
819 { |
|
820 SearchWLANNetworkAsync( aStatus, |
|
821 aSSID, |
|
822 aConnectionMode, |
|
823 iDummySecMode, |
|
824 aExtSecurityMode, |
|
825 iDummy ); |
|
826 } |
|
827 |
|
828 // --------------------------------------------------------- |
|
829 // CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync |
|
830 // --------------------------------------------------------- |
|
831 // |
|
832 void CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync( |
|
833 TRequestStatus& aStatus, |
|
834 TWlanSsid& aSSID, |
|
835 TWlanConnectionMode& aConnectionMode, |
|
836 TWlanConnectionSecurityMode& aSecurityMode, |
|
837 TBool& aProtectedSetupSupported ) |
|
838 { |
|
839 SearchWLANNetworkAsync( aStatus, |
|
840 aSSID, |
|
841 aConnectionMode, |
|
842 aSecurityMode, |
|
843 iDummyExtSecMode, |
|
844 aProtectedSetupSupported ); |
|
845 } |
|
846 |
|
847 // --------------------------------------------------------- |
|
848 // CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync |
|
849 // --------------------------------------------------------- |
|
850 // |
|
851 void CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync( |
|
852 TRequestStatus& aStatus, |
|
853 TWlanSsid& aSSID, |
|
854 TWlanConnectionMode& aConnectionMode, |
|
855 TWlanConnectionExtentedSecurityMode& aExtSecurityMode, |
|
856 TBool& aProtectedSetupSupported ) |
|
857 { |
|
858 SearchWLANNetworkAsync( aStatus, |
|
859 aSSID, |
|
860 aConnectionMode, |
|
861 iDummySecMode, |
|
862 aExtSecurityMode, |
|
863 aProtectedSetupSupported ); |
|
864 } |
|
865 |
|
866 // --------------------------------------------------------- |
|
867 // CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync |
|
868 // --------------------------------------------------------- |
|
869 // |
|
870 void CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync( |
|
871 TRequestStatus& aStatus, |
|
872 TWlanSsid& aSSID, |
|
873 TWlanConnectionMode& aConnectionMode, |
|
874 TWlanConnectionSecurityMode& aSecurityMode, |
|
875 TWlanConnectionExtentedSecurityMode& aExtSecurityMode, |
|
876 TBool& aProtectedSetupSupported ) |
|
877 { |
|
878 CLOG_ENTERFN( "CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync" ); |
|
879 |
|
880 if ( iIsWlanSupported ) |
|
881 { |
|
882 if ( !iActiveWrapper[ESearchWlan] ) |
|
883 { |
|
884 TRAP_IGNORE( iActiveWrapper[ESearchWlan] = |
|
885 CActiveWrapper::NewL( ESearchWlan ) ); |
|
886 } |
|
887 |
|
888 if ( iActiveWrapper[ESearchWlan] ) |
|
889 { |
|
890 iActiveWrapper[ESearchWlan]->StartSearchWLANNetworkAsync( aStatus, |
|
891 aSSID, aConnectionMode, aSecurityMode, |
|
892 aExtSecurityMode, |
|
893 aProtectedSetupSupported ); |
|
894 |
|
895 CLOG_WRITEF( _L( "iActiveWrapper[ESearchWlan]->iStatus.Int(): %d" ), |
|
896 iActiveWrapper[ESearchWlan]->iStatus.Int() ); |
|
897 } |
|
898 } |
|
899 |
|
900 CLOG_LEAVEFN( "CConnectionUiUtilitiesImpl::SearchWLANNetworkAsync" ); |
|
901 } |
|
902 |
|
903 // --------------------------------------------------------- |
|
904 // CConnectionUiUtilitiesImpl::ConnectedViaDestAndConnMethodNote |
|
905 // --------------------------------------------------------- |
|
906 // |
|
907 void CConnectionUiUtilitiesImpl::ConnectedViaDestAndConnMethodNote( |
|
908 const TUint32 aDestId, |
|
909 const TUint32 aConnMId ) |
|
910 { |
|
911 if ( !iActiveWrapper[EConnViaDestCM] ) |
|
912 { |
|
913 TRAP_IGNORE( iActiveWrapper[EConnViaDestCM] = |
|
914 CActiveWrapper::NewL( EConnViaDestCM ) ); |
|
915 } |
|
916 |
|
917 if ( iActiveWrapper[EConnViaDestCM] ) |
|
918 { |
|
919 iActiveWrapper[EConnViaDestCM]->StartGenericNote( EConnViaDestCM, |
|
920 aConnMId, aDestId ); |
|
921 } |
|
922 } |
|
923 |
|
924 // --------------------------------------------------------- |
|
925 // CConnectionUiUtilitiesImpl::ConnectedViaDestAndConnMethodNote |
|
926 // --------------------------------------------------------- |
|
927 // |
|
928 void CConnectionUiUtilitiesImpl::ConnectedViaDestAndConnMethodNote( |
|
929 const TUint32 aDestId, |
|
930 const TUint32 aConnMId, |
|
931 TRequestStatus& aStatus ) |
|
932 { |
|
933 iNotif.ConnectedViaDestAndConnMethodNote( aDestId, aConnMId, aStatus ); |
|
934 } |
|
935 |
|
936 // --------------------------------------------------------- |
|
937 // CConnectionUiUtilitiesImpl::CancelConnectedViaDestAndConnMethodNote |
|
938 // --------------------------------------------------------- |
|
939 // |
|
940 void CConnectionUiUtilitiesImpl::CancelConnectedViaDestAndConnMethodNote() |
|
941 { |
|
942 iNotif.CancelConnectedViaDestAndConnMethodNote(); |
|
943 } |
|
944 |
|
945 // --------------------------------------------------------- |
|
946 // CConnectionUiUtilitiesImpl::ChangingConnectionToNote |
|
947 // --------------------------------------------------------- |
|
948 // |
|
949 void CConnectionUiUtilitiesImpl::ChangingConnectionToNote( |
|
950 const TUint32 aConnMId ) |
|
951 { |
|
952 if ( !iActiveWrapper[EChangingConnTo] ) |
|
953 { |
|
954 TRAP_IGNORE( iActiveWrapper[EChangingConnTo] = |
|
955 CActiveWrapper::NewL( EChangingConnTo ) ); |
|
956 } |
|
957 |
|
958 if ( iActiveWrapper[EChangingConnTo] ) |
|
959 { |
|
960 iActiveWrapper[EChangingConnTo]->StartGenericNote( EChangingConnTo, |
|
961 aConnMId ); |
|
962 } |
|
963 } |
|
964 |
|
965 // --------------------------------------------------------- |
|
966 // CConnectionUiUtilitiesImpl::ChangingConnectionToNote |
|
967 // --------------------------------------------------------- |
|
968 // |
|
969 void CConnectionUiUtilitiesImpl::ChangingConnectionToNote( |
|
970 const TUint32 aConnMId, |
|
971 TRequestStatus& aStatus ) |
|
972 { |
|
973 iNotif.ChangingConnectionToNote( aConnMId, aStatus ); |
|
974 } |
|
975 |
|
976 |
|
977 // --------------------------------------------------------- |
|
978 // CConnectionUiUtilitiesImpl::CancelChangingConnectionToNote |
|
979 // --------------------------------------------------------- |
|
980 // |
|
981 void CConnectionUiUtilitiesImpl::CancelChangingConnectionToNote() |
|
982 { |
|
983 iActiveWrapper[EChangingConnTo]->Cancel(); |
|
984 } |
|
985 |
|
986 // --------------------------------------------------------- |
|
987 // CConnectionUiUtilitiesImpl::ConfirmMethodUsageQuery |
|
988 // --------------------------------------------------------- |
|
989 // |
|
990 void CConnectionUiUtilitiesImpl::ConfirmMethodUsageQuery( |
|
991 TMsgQueryLinkedResults& aResult, |
|
992 const TBool aHomeNetwork, |
|
993 TRequestStatus& aStatus ) |
|
994 { |
|
995 iNotif.ConfirmMethodUsageQuery( aResult, aHomeNetwork, aStatus ); |
|
996 } |
|
997 |
|
998 // --------------------------------------------------------- |
|
999 // CConnectionUiUtilitiesImpl::CancelConfirmMethodUsageQuery |
|
1000 // --------------------------------------------------------- |
|
1001 // |
|
1002 void CConnectionUiUtilitiesImpl::CancelConfirmMethodUsageQuery() |
|
1003 { |
|
1004 iNotif.CancelConfirmMethodUsageQuery(); |
|
1005 } |
|
1006 |
|
1007 |
|
1008 // --------------------------------------------------------- |
|
1009 // CConnectionUiUtilitiesImpl::ConnectedViaConnMethodNote |
|
1010 // --------------------------------------------------------- |
|
1011 // |
|
1012 void CConnectionUiUtilitiesImpl::ConnectedViaConnMethodNote( |
|
1013 const TUint32 aConnMId ) |
|
1014 { |
|
1015 if ( !iActiveWrapper[EConnViaCM] ) |
|
1016 { |
|
1017 TRAP_IGNORE( iActiveWrapper[EConnViaCM] = |
|
1018 CActiveWrapper::NewL( EConnViaCM ) ); |
|
1019 } |
|
1020 |
|
1021 if ( iActiveWrapper[EConnViaCM] ) |
|
1022 { |
|
1023 iActiveWrapper[EConnViaCM]->StartGenericNote( EConnViaCM, aConnMId ); |
|
1024 } |
|
1025 } |
|
1026 |
|
1027 // --------------------------------------------------------- |
|
1028 // CConnectionUiUtilitiesImpl::ConnectedViaConnMethodNote |
|
1029 // --------------------------------------------------------- |
|
1030 // |
|
1031 void CConnectionUiUtilitiesImpl::ConnectedViaConnMethodNote( |
|
1032 const TUint32 aConnMId, |
|
1033 TRequestStatus& aStatus ) |
|
1034 { |
|
1035 iNotif.ConnectedViaConnMethodNote( aConnMId, aStatus ); |
|
1036 } |
|
1037 |
|
1038 |
|
1039 // --------------------------------------------------------- |
|
1040 // CConnectionUiUtilitiesImpl::CancelConnectedViaConnMethodNote |
|
1041 // --------------------------------------------------------- |
|
1042 // |
|
1043 void CConnectionUiUtilitiesImpl::CancelConnectedViaConnMethodNote() |
|
1044 { |
|
1045 iNotif.CancelConnectedViaConnMethodNote(); |
|
1046 } |
|
1047 |
|
1048 |
|
1049 // --------------------------------------------------------- |
|
1050 // CConnectionUiUtilitiesImpl::WlanPowerSaveTestNote |
|
1051 // --------------------------------------------------------- |
|
1052 // |
|
1053 void CConnectionUiUtilitiesImpl::WlanPowerSaveTestNote( |
|
1054 TBool& aDisable, |
|
1055 TRequestStatus& aStatus ) |
|
1056 { |
|
1057 iNotif.WlanPowerSaveTestNote( aDisable, aStatus ); |
|
1058 } |
|
1059 |
|
1060 |
|
1061 // --------------------------------------------------------- |
|
1062 // CConnectionUiUtilitiesImpl::CancelWlanPowerSaveTestNote |
|
1063 // --------------------------------------------------------- |
|
1064 // |
|
1065 void CConnectionUiUtilitiesImpl::CancelWlanPowerSaveTestNote() |
|
1066 { |
|
1067 iNotif.CancelWlanPowerSaveTestNote(); |
|
1068 } |
|
1069 |
|
1070 // --------------------------------------------------------- |
|
1071 // CConnectionUiUtilitiesImpl::EasyWapiDlg |
|
1072 // --------------------------------------------------------- |
|
1073 // |
|
1074 TBool CConnectionUiUtilitiesImpl::EasyWapiDlg( TDes* aKey ) |
|
1075 { |
|
1076 TInt status( KErrNone ); |
|
1077 |
|
1078 if ( iIsWlanSupported ) |
|
1079 { |
|
1080 iWapiKey().Copy( *aKey ); |
|
1081 |
|
1082 if ( !iActiveWrapper[ EWlanEasyWapi ] ) |
|
1083 { |
|
1084 TRAP_IGNORE( iActiveWrapper[ EWlanEasyWapi ] = |
|
1085 CActiveWrapper::NewL( EWlanEasyWapi ) ); |
|
1086 } |
|
1087 |
|
1088 if ( iActiveWrapper[ EWlanEasyWapi ] ) |
|
1089 { |
|
1090 status = iActiveWrapper[ EWlanEasyWapi ]->StartEasyWapiDlg( iWapiKey ); |
|
1091 } |
|
1092 |
|
1093 aKey->Copy( iWapiKey() ); |
|
1094 } |
|
1095 return ( status == KErrNone ) ? ETrue : EFalse; |
|
1096 } |
|
1097 |
|
1098 // --------------------------------------------------------- |
|
1099 // CConnectionUiUtilitiesImpl::NoWLANNetworksAvailableNote |
|
1100 // --------------------------------------------------------- |
|
1101 // |
|
1102 void CConnectionUiUtilitiesImpl::NoWLANNetworksAvailableNote() |
|
1103 { |
|
1104 if ( iIsWlanSupported ) |
|
1105 { |
|
1106 if ( !iActiveWrapper[ ENoWlanNetwsAvail ] ) |
|
1107 { |
|
1108 TRAP_IGNORE( iActiveWrapper[ ENoWlanNetwsAvail ] = |
|
1109 CActiveWrapper::NewL( ENoWlanNetwsAvail ) ); |
|
1110 } |
|
1111 |
|
1112 if ( iActiveWrapper[ ENoWlanNetwsAvail ] ) |
|
1113 { |
|
1114 iActiveWrapper[ ENoWlanNetwsAvail ]->StartGenericNote( |
|
1115 ENoWlanNetwsAvail ); |
|
1116 } |
|
1117 } |
|
1118 } |
|
1119 |
|
1120 |
|
1121 // --------------------------------------------------------- |
|
1122 // CConnectionUiUtilitiesImpl::ConnectingViaDiscreetPopup |
|
1123 // --------------------------------------------------------- |
|
1124 // |
|
1125 void CConnectionUiUtilitiesImpl::ConnectingViaDiscreetPopup( const TUint32& aIapId, TBool aConnectionAlreadyActive ) |
|
1126 { |
|
1127 iConnInfo().iIapId = aIapId; |
|
1128 iConnInfo().iConnectionAlreadyActive = aConnectionAlreadyActive; |
|
1129 |
|
1130 if ( !iActiveWrapper[ EConnectingViaDiscreetPopup ] ) |
|
1131 { |
|
1132 TRAP_IGNORE( iActiveWrapper[ EConnectingViaDiscreetPopup ] = |
|
1133 CActiveWrapper::NewL( EConnectingViaDiscreetPopup ) ); |
|
1134 } |
|
1135 |
|
1136 if ( iActiveWrapper[ EConnectingViaDiscreetPopup ] ) |
|
1137 { |
|
1138 iActiveWrapper[ EConnectingViaDiscreetPopup ] |
|
1139 ->StartConnectingViaDiscreetPopup( iConnInfo ); |
|
1140 } |
|
1141 } |
|
1142 |
|
1143 |
|
1144 |
|
1145 // --------------------------------------------------------- |
|
1146 // CConnectionUiUtilitiesImpl::ConnectionErrorDiscreetPopup |
|
1147 // --------------------------------------------------------- |
|
1148 // |
|
1149 void CConnectionUiUtilitiesImpl::ConnectionErrorDiscreetPopup( const TInt& aErrCode ) |
|
1150 { |
|
1151 TPckgBuf< TInt > buf; |
|
1152 buf() = aErrCode; |
|
1153 |
|
1154 if ( !iActiveWrapper[ EConnectionErrorDiscreetPopup ] ) |
|
1155 { |
|
1156 TRAP_IGNORE( iActiveWrapper[ EConnectionErrorDiscreetPopup ] = |
|
1157 CActiveWrapper::NewL( EConnectionErrorDiscreetPopup ) ); |
|
1158 } |
|
1159 |
|
1160 if ( iActiveWrapper[ EConnectionErrorDiscreetPopup ] ) |
|
1161 { |
|
1162 iActiveWrapper[ EConnectionErrorDiscreetPopup ] |
|
1163 ->StartConnectionErrorDiscreetPopup( buf ); |
|
1164 } |
|
1165 } |
|
1166 |
|
1167 // End of File |