securitydialogs/Autolock/src/AutolockContainer.cpp
branchRCL_3
changeset 11 9971b621ef6c
parent 1 d5423fbb4f29
child 13 53af9c3d61e4
--- a/securitydialogs/Autolock/src/AutolockContainer.cpp	Wed Apr 14 16:51:06 2010 +0300
+++ b/securitydialogs/Autolock/src/AutolockContainer.cpp	Tue Apr 27 17:31:46 2010 +0300
@@ -29,6 +29,9 @@
 #include <Autolock.rsg>
 #include "autolock.hrh"
 #include <eikdef.h>
+#include <aknnotedialog.h>
+#include <aknkeylock.h>
+#include <AknSoftNotifier.h>
 
 #include <coreapplicationuisdomainpskeys.h>
 
@@ -303,7 +306,24 @@
 					gc.SetPenStyle(CGraphicsContext::EDottedPen);
 					gc.DrawRoundRect(box,cornerSize);
         	gc.BitBltMasked(TPoint(aCallRect_x,aCallRect_y),iBitmapCall,TRect(TPoint(0,0),TPoint(aCallRect_width,aCallRect_height)), iMaskCall, ETrue);
-    	  	aCallRect_y+=100;	// coordinates are realtive to TRect, not to Screen
+    	  	aCallRect_y+=100;	// coordinates are relative to TRect, not to Screen
+    	  	
+    	  	// if active call, dismiss all pending notes. This avoids them on top of the BigRedButton
+    	  	CAknSoftNotifier *softNotifier = NULL;
+			    TRAPD (err, {
+			            softNotifier = CAknSoftNotifier::NewL();
+			            softNotifier->AddNotificationL(ESetIdleState, 0);
+			            // softNotifier->SetIdleStateL(EFalse);
+			    };)
+			    delete softNotifier;
+			    // during any call ,the touch need to be enabled, so that BigRedButton is available
+			    // It will be re-enabled when the call ends
+		    	RAknKeyLock keylock;
+			    if ( keylock.Connect() == KErrNone )
+				    {
+				    keylock.DisableWithoutNote();
+				    keylock.Close();
+				    }
         	}
         }
     else if (iBitmap && !iMask)