supl/locationsuplfw/gateway/src/epos_csuplsessionrequest.cpp
branchRCL_3
changeset 42 02ba3f1733c6
parent 41 d746aee05493
child 44 2b4ea9893b66
--- a/supl/locationsuplfw/gateway/src/epos_csuplsessionrequest.cpp	Thu Jul 15 19:06:58 2010 +0300
+++ b/supl/locationsuplfw/gateway/src/epos_csuplsessionrequest.cpp	Thu Aug 19 10:20:18 2010 +0300
@@ -97,10 +97,12 @@
 CSuplSessionRequest::~CSuplSessionRequest()
     {
     DEBUG_TRACE("CSuplSessionRequest::~CSuplSessionRequest", __LINE__)
-    iSessnMgr.RemoveFromQueueForReIssueRequest(*this);
+    //iSessnMgr.RemoveFromQueueForReIssueRequest(*this);
     
     if (iParamExtendedFallback)
+		{
         delete iParamExtendedFallback;
+		}
     
 	if (IsActive())      
       	Cancel();
@@ -122,12 +124,16 @@
 	
 	iSessnMgr.RunSuplSessionL(aSuplSessn, iStatus, aHslpAddress, fallBack, aSetCaps, aReqId, aFirstReq);
 	SetActive();
-	iSessionStarted = ETrue;
 	iParamFallback = ETrue;
 	iParamSuplSessn = aSuplSessn;
 	iParamSetCaps = aSetCaps;
 	iParamReqId = aReqId;
 	iParamFirstReq = aFirstReq;
+    if (iParamExtendedFallback)
+        {
+        delete iParamExtendedFallback;
+        iParamExtendedFallback = NULL;
+        }
 	iParamExtendedQopUsed = EFalse;
     }
 // ---------------------------------------------------------
@@ -147,12 +153,16 @@
 	iSessnMgr.RunSuplSessionL(aSuplSessn, iStatus, aHslpAddress, fallBack, aSetCaps, aReqId, aQop, aFirstReq);
 	SetActive();
 	
-	iSessionStarted = ETrue;
     iParamFallback = ETrue;
 	iParamSuplSessn = aSuplSessn;
 	iParamSetCaps = aSetCaps;
 	iParamReqId = aReqId;
 	iParamFirstReq = aFirstReq;
+    if (iParamExtendedFallback)
+        {
+        delete iParamExtendedFallback;
+        iParamExtendedFallback = NULL;
+        }
 	iParamQop = aQop;	
 	iParamExtendedQopUsed = ETrue;	
     }
@@ -165,7 +175,6 @@
     iSessnMgr.RunSuplSessionL(aSuplSessn, iStatus, aHslpAddress, aFallBack, aSetCaps, aReqId, aFirstReq);
 	SetActive();
 	
-	iSessionStarted = ETrue;
     iParamFallback = aFallBack;
 	iParamSuplSessn = aSuplSessn;
 	iParamSetCaps = aSetCaps;
@@ -189,7 +198,6 @@
     iSessnMgr.RunSuplSessionL(aSuplSessn, iStatus, aHslpAddress, aFallBack, aSetCaps, aReqId, aQop, aFirstReq);
     SetActive();
 	
-	iSessionStarted = ETrue;
     iParamFallback = aFallBack;
 	iParamSuplSessn = aSuplSessn;
 	iParamSetCaps = aSetCaps;
@@ -252,7 +260,6 @@
     if (IsActive())
         {
 		iObserver->CompleteRunSession(KErrServerTerminated);
-		iSessionStarted = EFalse;
         Cancel();
         }
     }
@@ -268,7 +275,6 @@
     DEBUG_TRACE("CSuplSessionRequest::RunL", __LINE__)
     TInt err = iStatus.Int();
 	
-	iSessionStarted = EFalse;
 	if(err != KErrNone && iRequestPhase == ESuplSessionRequest)
 		{
 		DEBUG_TRACE("Retrying session", __LINE__)
@@ -311,6 +317,17 @@
 	        	iNetObserver->CompleteForwardMessageL(iHandle);
 	        	break;
 	        	}
+				
+			case ESuplLocationConversionRequest:
+			case ESuplCancelLocationConversionRequest:
+            {
+            iRequestPhase = ESuplReqInactive;
+            iObserver->CompleteRunSession(err);
+            break;
+            }
+
+			
+
 
 	        default :
 	            DebugPanic(EPosSuplServerPanicRequestInconsistency);
@@ -483,8 +500,38 @@
     {
     DEBUG_TRACE("CSuplSessionRequest::CancelTriggerringRequest", __LINE__)
     iRequestPhase = ESuplStopTriggerRequest;
-    iSessnMgr.CancelTriggerringSession(iSuplSessn);	
-	//SetActive();
+    iSessnMgr.CancelTriggerringSession(iSuplSessn); 
+    //SetActive();
+    }
+
+// ---------------------------------------------------------
+// CSuplSessionRequest::MakeLocationConversionRequestL
+//
+// (other items were commented in a header).
+// ---------------------------------------------------------
+//
+void CSuplSessionRequest::MakeLocationConversionRequestL( CSuplSessionBase* aSuplSessn,
+                                                          TGeoCellInfo& aCellInfo )
+    {
+    DEBUG_TRACE("CSuplSessionRequest::MakeLocationConversionRequestL", __LINE__)
+    iRequestPhase = ESuplLocationConversionRequest;
+    iStatus = KRequestPending;
+    iSessnMgr.MakeLocationConversionRequestL(aSuplSessn,aCellInfo,iStatus );
+    SetActive();       
+    }
+
+        
+// ---------------------------------------------------------
+// CSuplSessionRequest::CancelLocationConversionRequest
+//
+// (other items were commented in a header).
+// ---------------------------------------------------------
+//
+void CSuplSessionRequest::CancelLocationConversionRequest()
+    {
+    DEBUG_TRACE("CSuplSessionRequest::CancelLocationConversionRequest", __LINE__)
+    iRequestPhase = ESuplCancelLocationConversionRequest;
+    iSessnMgr.CancelLocationConversionRequest(iSuplSessn); 
     }
     
 //  End of File