hotspotfw/hsserver/src/hotspotserver.cpp
changeset 2 6e4b6261703d
parent 0 56b72877c1cb
child 3 ff3b37722600
--- a/hotspotfw/hsserver/src/hotspotserver.cpp	Thu Jan 07 13:31:53 2010 +0200
+++ b/hotspotfw/hsserver/src/hotspotserver.cpp	Mon Jan 18 21:21:32 2010 +0200
@@ -16,10 +16,6 @@
 */
 
 
-
-
-
-
 // INCLUDE FILES
 #include <e32std.h>
 #include <f32file.h>
@@ -172,38 +168,20 @@
 //
 void CHotSpotServer::ConstructL()
     {
-  
     DEBUG("**** HotSpotServer: CHotSpotServer::ConstructL");
-	StartL( KHotSpotServerName );
-	
-	iIapCheckValue = EFalse;
+    StartL( KHotSpotServerName );
+
+    iIapCheckValue = EFalse;
     iLogoutSent = EFalse;
     iLoginValue = ETrue;
     iAssociationValue = EFalse;
-	
-#ifndef __WINS__
-
-    // Change config daemon for Easy WLAN access point
-    iConfigDaemonChanged = KErrNone;
-    TBool retVal( EFalse );
-    iEasyWlanId = KEasyWlanServiceId; // Set to default value
-    TRAPD( leave, retVal = EasyWlanIdL() );
-    if ( KErrNone != leave )
-        {
-        iConfigDaemonChanged = leave;
-        }
-    if ( !retVal )
-        {
-        iConfigDaemonChanged = KErrGeneral;
-        }
-    DEBUG1("**** HotSpotServer: CHotSpotServer::ConstructL iConfigDaemonChanged: %d", iConfigDaemonChanged );
-#endif        
-    // Activate notifications for IAP check purposes
+    
+    // Activate notifications for IAP check purposes. Done with every server startup.
     // When EWlanConnectionModeNotConnected is received we can cancel this and 
     // we know that it safe to go through IAPs.
     iMgtClient = CWlanMgmtClient::NewL();
 #ifndef __WINS__
- 	iMgtClient->ActivateNotificationsL( *this );
+    iMgtClient->ActivateNotificationsL( *this );
 #endif 
     }
 
@@ -221,7 +199,6 @@
 #ifndef __WINS__
             iMgtClient->CancelNotifications();
 #endif
-            DEBUG("CHotSpotServer::ConnectionStateChanged2");
             }
     	
      	TRAPD(err, CheckIapsL());
@@ -229,12 +206,7 @@
      		{
      		DEBUG1("CHotSpotServer::ConnectionStateChanged(): %d", err);
      		}
-     	if ( iConfigDaemonChanged != KErrNone )
-     	    {
-     	    // ConstructL call leaved. Let's call again once more.
-     	    TRAP_IGNORE( EasyWlanIdL() );
-     	    }
-     	}
+    	}
     }
 
 // -----------------------------------------------------------------------------
@@ -533,46 +505,6 @@
 	}
 
 // -----------------------------------------------------------------------------
-// EasyWlanIdL
-// -----------------------------------------------------------------------------
-//
-TBool CHotSpotServer::EasyWlanIdL()
-    {
-    TBool ret( EFalse );
-    DEBUG("CHotSpotServer::EasyWlanIdL()");
-    RCmManagerExt cmManager;
-    cmManager.OpenL();
-    CleanupClosePushL( cmManager );
-    
-    iEasyWlanId = cmManager.EasyWlanIdL();
-    DEBUG1("CHotSpotServer::EasyWlanIdL() ret: % d", iEasyWlanId);
-    // if iEasyWlanId is 0, then it was not found
-    if ( iEasyWlanId > 0 )
-        {
-        RCmConnectionMethodExt plugin = cmManager.ConnectionMethodL( iEasyWlanId );
-        CleanupClosePushL( plugin );
-        //iEasyWlanId = plugin.GetIntAttributeL( /*ECmIapServiceId*/EWlanServiceId )
-        plugin.SetStringAttributeL( ECmConfigDaemonManagerName, KHotSpotPlugin );
-        // commit changes
-        plugin.UpdateL();
-        CleanupStack::PopAndDestroy( &plugin ); // Close() called on "plugin"
-        ret = ETrue;
-        }
-    CleanupStack::PopAndDestroy( &cmManager );
-    DEBUG("CHotSpotServer::EasyWlanIdL() DONE");
-    return ret;
-    }
-
-// -----------------------------------------------------------------------------
-// GetEasyWlanId
-// -----------------------------------------------------------------------------
-//
-TUint32 CHotSpotServer::GetEasyWlanId()
-    {
-    return iEasyWlanId;
-    }
-
-// -----------------------------------------------------------------------------
 // GetLoginTimerMicroSecs
 // -----------------------------------------------------------------------------
 //