From 47e678b6d9e8cef411ffc1c7dd5d8098ca6e9086 Mon Sep 17 00:00:00 2001 From: Amith Kumar Mahale Date: Tue, 2 Jul 2013 18:54:30 +0530 Subject: [PATCH] Fix for N_SE-44385 Change-Id: Ic802f320dbf41b59ee9811a6c308fc50aacaa508 Signed-off-by: Amith Kumar Mahale --- src/PhnDialAppForm.cpp | 1 + src/PhnTabDialer.cpp | 17 +++++++++-------- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/src/PhnDialAppForm.cpp b/src/PhnDialAppForm.cpp index e70c42d..d5bca5d 100644 --- a/src/PhnDialAppForm.cpp +++ b/src/PhnDialAppForm.cpp @@ -71,6 +71,7 @@ DialAppForm::OnInitializing(void) result DialAppForm::OnTerminating(void) { + SetFormBackEventListener(null); return E_SUCCESS; } diff --git a/src/PhnTabDialer.cpp b/src/PhnTabDialer.cpp index 7bd1c6f..9767285 100644 --- a/src/PhnTabDialer.cpp +++ b/src/PhnTabDialer.cpp @@ -945,22 +945,23 @@ DialTabDialer::OnActionPerformed(const Control& source, int actionId) { String contactNo = pEditField->GetText(); contactNo.Replace(L"-",L""); - String phoneNumberPattern(L"#$"); + // Regular expression to check the beginning is with Pause/Wait + String phoneNumberPattern(L"^(,|;)"); RegularExpression checkPhoneNumber; checkPhoneNumber.Construct(phoneNumberPattern); - //If phone number ends with # then show an error popup - /* bool resultMatch = checkPhoneNumber.Match(contactNo,false); + //If phone number starts with , or ; then show an error popup + bool resultMatch = checkPhoneNumber.Match(contactNo,false); if(resultMatch == true) { - MessageBox numberEndsWithHash; + MessageBox numberStartsWithPW; String msg(L"Phone number "); msg.Append(contactNo); - msg.Append(L" ends with # "); - numberEndsWithHash.Construct(L"GPRS is not supported", msg, MSGBOX_STYLE_NONE,3000); + msg.Append(L" is Invalid"); + numberStartsWithPW.Construct(L"Invalid Number", msg, MSGBOX_STYLE_NONE,3000); int modalResult = 0; - numberEndsWithHash.ShowAndWait(modalResult); + numberStartsWithPW.ShowAndWait(modalResult); return; - }*/ + } if (DialOutgoingCall(contactNo) == true) { __pDialPresentationModel->ClearSearchResults(); -- 2.7.4