35 // ----------------------------------------------------------------------------- |
35 // ----------------------------------------------------------------------------- |
36 // CHssIapSettingsHandler |
36 // CHssIapSettingsHandler |
37 // ----------------------------------------------------------------------------- |
37 // ----------------------------------------------------------------------------- |
38 // |
38 // |
39 CHssIapSettingsHandler::CHssIapSettingsHandler( ) |
39 CHssIapSettingsHandler::CHssIapSettingsHandler( ) |
40 { |
40 { |
41 DEBUG("CHssIapSettingsHandler::CHssIapSettingsHandler"); |
41 DEBUG("CHssIapSettingsHandler::CHssIapSettingsHandler"); |
42 } |
42 } |
43 |
43 |
44 // ----------------------------------------------------------------------------- |
44 // ----------------------------------------------------------------------------- |
45 // ConstructL |
45 // ConstructL |
46 // ----------------------------------------------------------------------------- |
46 // ----------------------------------------------------------------------------- |
47 // |
47 // |
66 // ----------------------------------------------------------------------------- |
66 // ----------------------------------------------------------------------------- |
67 // ~CHssIapSettingsHandler |
67 // ~CHssIapSettingsHandler |
68 // ----------------------------------------------------------------------------- |
68 // ----------------------------------------------------------------------------- |
69 // |
69 // |
70 CHssIapSettingsHandler::~CHssIapSettingsHandler() |
70 CHssIapSettingsHandler::~CHssIapSettingsHandler() |
71 { |
71 { |
72 DEBUG("CHssIapSettingsHandler::~CHssIapSettingsHandler()"); |
72 DEBUG("CHssIapSettingsHandler::~CHssIapSettingsHandler()"); |
73 } |
73 } |
74 |
74 |
75 // ----------------------------------------------------------------------------- |
75 // ----------------------------------------------------------------------------- |
76 // CreateClientIapL |
76 // CreateClientIapL |
77 // ----------------------------------------------------------------------------- |
77 // ----------------------------------------------------------------------------- |
148 destination = cmManager.DestinationL( destinations[i] ); |
148 destination = cmManager.DestinationL( destinations[i] ); |
149 CleanupClosePushL( destination ); |
149 CleanupClosePushL( destination ); |
150 // Internet destination will always exist in the system. |
150 // Internet destination will always exist in the system. |
151 // Internet destination will have ESnapPurposeInternet set in its metadata. |
151 // Internet destination will have ESnapPurposeInternet set in its metadata. |
152 if (destination.MetadataL( CMManager::ESnapMetadataPurpose ) == |
152 if (destination.MetadataL( CMManager::ESnapMetadataPurpose ) == |
153 CMManager::ESnapPurposeInternet ) |
153 CMManager::ESnapPurposeInternet ) |
154 { |
154 { |
155 CWlanMgmtClient* wlanMgmtClient = CWlanMgmtClient::NewL(); |
155 CWlanMgmtClient* wlanMgmtClient = CWlanMgmtClient::NewL(); |
156 CleanupStack::PushL( wlanMgmtClient ); |
156 CleanupStack::PushL( wlanMgmtClient ); |
157 |
157 |
158 TWlanConnectionMode connMode( EWlanConnectionModeNotConnected ); |
158 TWlanConnectionMode connMode( EWlanConnectionModeNotConnected ); |
254 aUid = TUid::Null(); |
254 aUid = TUid::Null(); |
255 RCmManagerExt cmManager; |
255 RCmManagerExt cmManager; |
256 cmManager.OpenL(); |
256 cmManager.OpenL(); |
257 CleanupClosePushL( cmManager ); |
257 CleanupClosePushL( cmManager ); |
258 |
258 |
259 RCmConnectionMethodExt plugin = cmManager.ConnectionMethodL( aIapId ); |
259 RCmConnectionMethodExt plugin = cmManager.ConnectionMethodL( aIapId ); |
260 CleanupClosePushL( plugin ); |
260 CleanupClosePushL( plugin ); |
261 |
261 |
262 HBufC* uid = plugin.GetStringAttributeL( EWlanServiceExtensionTableName ); |
262 HBufC* uid = plugin.GetStringAttributeL( EWlanServiceExtensionTableName ); |
263 |
263 |
264 TBuf8<KExtensionAPILength> buffer; |
264 TBuf8<KExtensionAPILength> buffer; |
265 buffer.Copy( *uid ); |
265 buffer.Copy( *uid ); |
266 delete uid; |
266 delete uid; |
267 // Find and remove [ and ]. |
267 // Find and remove [ and ]. |
268 // If found [ it's known that buffer contains UID |
268 // If found [ it's known that buffer contains UID |
269 TInt indx = buffer.Find( KMark1 ); |
269 TInt indx = buffer.Find( KMark1 ); |
270 if ( KErrNotFound != indx ) |
270 if ( KErrNotFound != indx ) |
271 { |
271 { |
272 DEBUG("CHssIapSettingsHandler::FindClientL Client is found"); |
272 DEBUG("CHssIapSettingsHandler::FindClientL Client is found"); |
273 buffer.Delete( indx, 1 ); |
273 buffer.Delete( indx, 1 ); |
274 indx = buffer.Find( KMark2 ); |
274 indx = buffer.Find( KMark2 ); |
275 if ( KErrNotFound != indx ) |
275 if ( KErrNotFound != indx ) |