webengine/osswebengine/WebKit/s60/webview/BrCtl.cpp
branchRCL_3
changeset 42 a1a5d4e727e8
parent 41 4bd5176e1bc8
child 44 800203832575
--- a/webengine/osswebengine/WebKit/s60/webview/BrCtl.cpp	Tue May 25 13:52:38 2010 +0300
+++ b/webengine/osswebengine/WebKit/s60/webview/BrCtl.cpp	Wed Jun 09 10:52:50 2010 +0300
@@ -2211,7 +2211,15 @@
 {
     m_windoCloseTimer->Cancel();
     if (brCtlWindowObserver())
-        TRAP_IGNORE(brCtlWindowObserver()->HandleWindowCommandL(KNullDesC(), ECloseWindow));
+        {
+        TRAPD(err,brCtlWindowObserver()->HandleWindowCommandL(KNullDesC(), ECloseWindow));
+		if ( err == KLeaveExit )
+		    { // while we exit the browser it actually leaves with KLeaveExit from the system.
+		      // If we block this here then the exit would not happen so propogate the leave 
+		      // condition to the system for handling
+		    User::Leave(KLeaveExit);
+		    }        
+        }
 }
 
 TBool CBrCtl::sendCommandsToClient(