diff -r 5a93021fdf25 -r 40cb640ef159 connectionutilities/ConnectionDialogs/ConnectionUiUtilities/NotifSrc/WepWpaQueryDlg.cpp --- a/connectionutilities/ConnectionDialogs/ConnectionUiUtilities/NotifSrc/WepWpaQueryDlg.cpp Thu Dec 17 08:55:21 2009 +0200 +++ b/connectionutilities/ConnectionDialogs/ConnectionUiUtilities/NotifSrc/WepWpaQueryDlg.cpp Thu Jan 07 12:56:54 2010 +0200 @@ -27,6 +27,7 @@ #include "EasyWepDlgNotif.h" #include "EasyWpaDlgNotif.h" #include "ConnectionDialogsLogger.h" +#include "ExpiryTimer.h" // CONSTANTS @@ -85,6 +86,7 @@ { STATIC_CAST( CEikServAppUi*, CCoeEnv::Static()->AppUi() )->SuppressAppSwitching( EFalse ); + delete iExpiryTimer; } @@ -272,18 +274,33 @@ } // --------------------------------------------------------- -// CWepWpaQueryDlg::NeedToDismissQueryL +// CWepWpaQueryDlg::OfferKeyEventL // --------------------------------------------------------- // -TBool CWepWpaQueryDlg::NeedToDismissQueryL(const TKeyEvent& aKeyEvent) +TKeyResponse CWepWpaQueryDlg::OfferKeyEventL( const TKeyEvent& aKeyEvent, + TEventCode aType) { - if (aKeyEvent.iCode == EKeyPhoneSend) + if( aType == EEventKey && aKeyEvent.iCode == EKeyPhoneSend ) { - TryExitL(EEikBidCancel); - return ETrue; + // Let's not obscure the Dialer in the background + if ( !iExpiryTimer ) + { + iExpiryTimer = CExpiryTimer::NewL( *this ); + } + else + { + iExpiryTimer->Cancel(); + } + + iExpiryTimer->StartShort(); } - - return EFalse; + + return CAknTextQueryDialog::OfferKeyEventL( aKeyEvent,aType ); + } + +void CWepWpaQueryDlg::HandleTimedOut() + { + TRAP_IGNORE( TryExitL( EAknSoftkeyCancel ) ); } // End of File