Revision: 201033 RCL_3 PDK_3.0.3
authorDremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
Tue, 14 Sep 2010 21:02:05 +0300
branchRCL_3
changeset 23 755430a7d64b
parent 22 d38647835c2e
Revision: 201033 Kit: 201035
callcontinuity/vcchotrigger/src/vcchotrigger.cpp
commsconfig/cscsettingsui/src/cscsettingsuimainview.cpp
sipvoipprovider/src/svpuriparser.cpp
voipplugins/accountcreationplugin/engine/inc/acphttphandler.h
voipplugins/accountcreationplugin/engine/src/acphttphandler.cpp
voipplugins/svtmatching/inc/svtmatching.h
voipplugins/svtmatching/inc/svturiparser.h
voipplugins/svtmatching/src/svtmatching.cpp
--- a/callcontinuity/vcchotrigger/src/vcchotrigger.cpp	Wed Sep 01 12:29:57 2010 +0100
+++ b/callcontinuity/vcchotrigger/src/vcchotrigger.cpp	Tue Sep 14 21:02:05 2010 +0300
@@ -349,8 +349,10 @@
     TVccHoStatus hoStatus( EVccHoStateUnknown );
     iEngPsProperty->GetCurrentHoStatus( hoStatus );
     
-    if( hoStatus != EVccCsToPsHoStarted || hoStatus != EVccCsToPsHoInprogress 
-        || hoStatus != EVccPsToCsHoStarted || hoStatus != EVccPsToCsHoInprogress )
+    RUBY_DEBUG1( " hoStatus = %d ", hoStatus );
+    
+    if( hoStatus != EVccCsToPsHoStarted && hoStatus != EVccCsToPsHoInprogress 
+        && hoStatus != EVccPsToCsHoStarted && hoStatus != EVccPsToCsHoInprogress )
         {
         RUBY_DEBUG0( "HO not in progress,  updating keys" );
         TRAP_IGNORE( UpdatePsKeysL() );
--- a/commsconfig/cscsettingsui/src/cscsettingsuimainview.cpp	Wed Sep 01 12:29:57 2010 +0100
+++ b/commsconfig/cscsettingsui/src/cscsettingsuimainview.cpp	Tue Sep 14 21:02:05 2010 +0300
@@ -438,33 +438,12 @@
     CSCSETUIDEBUG( "CCSCSettingsUiMainView::DynInitMenuPaneL - begin" );
     
     if ( aMenuPane && R_CSCSETTINGSUI_MAINVIEW_MENU == aResourceId )
-        {
-        TMainListBoxItem listBoxItem = iContainer->CurrentItem();
-    
-        switch ( listBoxItem.iItem )
-            {
-            // Hide "Change" and show "Open"
-            case TMainListBoxItem::EServiceConn:
-                aMenuPane->SetItemDimmed( ECSCSettingsUiChange, ETrue );
-                aMenuPane->SetItemDimmed( ECSCSettingsUiOpen, EFalse );
-                break;
-            // Show "Change" and hide "Open"
-            case TMainListBoxItem::EUsername:
-            case TMainListBoxItem::EPassword:
-            case TMainListBoxItem::EPreferredService:
-            case TMainListBoxItem::EVccPreferredService:
-            case TMainListBoxItem::EHandoverNotifTone:
-            case TMainListBoxItem::EAutoacceptInv:     
-            case TMainListBoxItem::EImTone:
-                aMenuPane->SetItemDimmed( ECSCSettingsUiChange, EFalse );
-                aMenuPane->SetItemDimmed( ECSCSettingsUiOpen, ETrue );
-                break;   
-            // Hide both of options. Case should not be possible.       
-            default:
-                 aMenuPane->SetItemDimmed( ECSCSettingsUiChange, ETrue );
-                 aMenuPane->SetItemDimmed( ECSCSettingsUiOpen, ETrue );
-            break;
-            }
+        {        
+        // Hide "Change" and "Open".
+        // Because there is no highlight now.
+        aMenuPane->SetItemDimmed( ECSCSettingsUiChange, ETrue );
+        aMenuPane->SetItemDimmed( ECSCSettingsUiOpen, ETrue );
+           
         if ( !(iModel.CCHHandler().IsServiceDisabled( 
             iModel.CurrentSPEntryId() ) ) )
             {
--- a/sipvoipprovider/src/svpuriparser.cpp	Wed Sep 01 12:29:57 2010 +0100
+++ b/sipvoipprovider/src/svpuriparser.cpp	Tue Sep 14 21:02:05 2010 +0300
@@ -694,19 +694,10 @@
     
     // Escape decode
     CSVPUriParser::EscapeDecodeSipUriL( utf8 );
-    
-    // Convert from UTF8 to unicode
-    HBufC* unicode16 = EscapeUtils::ConvertToUnicodeFromUtf8L( *utf8 );
+
+    // Create SIP From header
+    CSIPFromHeader* originatorHdr = CSIPFromHeader::DecodeL( *utf8 );
     CleanupStack::PopAndDestroy( utf8 ); // CS:0
-    CleanupStack::PushL( unicode16 ); // CS:1
-    HBufC8* unicode8 = HBufC8::NewL( unicode16->Length() );
-    ( unicode8->Des() ).Copy( *unicode16 );
-    CleanupStack::PopAndDestroy( unicode16 ); // CS:0
-    CleanupStack::PushL( unicode8 ); // CS:1
-    
-    // Create SIP From header
-    CSIPFromHeader* originatorHdr = CSIPFromHeader::DecodeL( *unicode8 );
-    CleanupStack::PopAndDestroy( unicode8 ); // CS:0
     CleanupStack::PushL( originatorHdr ); // CS:1
     
     // Extract and parse display name, format is "..."
@@ -761,7 +752,18 @@
 
     SVPDEBUG2( "CSVPUriParser::ParseDisplayNameL, display name: %S", 
         displayName )
-    return displayName;
+    
+    CleanupStack::PushL( displayName );
+    HBufC8* utf8DisplayName8 = HBufC8::NewL( displayName->Length() );
+    ( utf8DisplayName8->Des() ).Copy( *displayName );
+    CleanupStack::PopAndDestroy( displayName );
+
+    CleanupStack::PushL( utf8DisplayName8 ); 
+    // Convert from UTF8 to unicode
+    HBufC* unicodeDisplayName = EscapeUtils::ConvertToUnicodeFromUtf8L( *utf8DisplayName8 );
+    CleanupStack::PopAndDestroy(utf8DisplayName8);
+
+    return unicodeDisplayName;
     }
 
 // ---------------------------------------------------------------------------
@@ -782,18 +784,9 @@
     // Escape decode
     CSVPUriParser::EscapeDecodeSipUriL( utf8 );
     
-    // Convert from UTF8 to unicode
-    HBufC* unicode16 = EscapeUtils::ConvertToUnicodeFromUtf8L( *utf8 );
+    // Create SIP From header
+    CSIPFromHeader* originatorHdr = CSIPFromHeader::DecodeL( *utf8 );
     CleanupStack::PopAndDestroy( utf8 ); // CS:0
-    CleanupStack::PushL( unicode16 ); // CS:1
-    HBufC8* unicode8 = HBufC8::NewL( unicode16->Length() );
-    ( unicode8->Des() ).Copy( *unicode16 );
-    CleanupStack::PopAndDestroy( unicode16 ); // CS:0
-    CleanupStack::PushL( unicode8 ); // CS:1
-    
-    // Create SIP From header
-    CSIPFromHeader* originatorHdr = CSIPFromHeader::DecodeL( *unicode8 );
-    CleanupStack::PopAndDestroy( unicode8 ); // CS:0
     CleanupStack::PushL( originatorHdr ); // CS:1
         
     // Extract URI, returned without angle brackets
@@ -807,10 +800,9 @@
         {
         uri8->Des().Delete( posSemiColon, uri8->Length() - posSemiColon );
         }
-
-    // Convert to 16-bit
-    HBufC* uri = HBufC::NewL( uri8->Length() );
-    ( uri->Des() ).Copy( *uri8 );
+    
+    // Convert from UTF8 to unicode
+    HBufC* uri = EscapeUtils::ConvertToUnicodeFromUtf8L( *uri8 );
     CleanupStack::PopAndDestroy( uri8 ); // CS:0
 
     // Handle anonymous
--- a/voipplugins/accountcreationplugin/engine/inc/acphttphandler.h	Wed Sep 01 12:29:57 2010 +0100
+++ b/voipplugins/accountcreationplugin/engine/inc/acphttphandler.h	Tue Sep 14 21:02:05 2010 +0300
@@ -279,6 +279,12 @@
     TBool iPromptShown;
     
     /**
+     * The flag indicates whether the cancellation from end user is sponsored
+     * when opening the connection of downloading or not.
+     */ 
+    TBool iCancelRequest;
+    
+    /**
      * Selected IAP id.
      */
     TUint32 iIapId;
--- a/voipplugins/accountcreationplugin/engine/src/acphttphandler.cpp	Wed Sep 01 12:29:57 2010 +0100
+++ b/voipplugins/accountcreationplugin/engine/src/acphttphandler.cpp	Tue Sep 14 21:02:05 2010 +0300
@@ -40,7 +40,7 @@
 // ---------------------------------------------------------------------------
 //
 CAcpHttpHandler::CAcpHttpHandler( MAcpHttpHandlerObserver& aObserver )
-    : CActive( CActive::EPriorityStandard ), iObserver( aObserver )
+    : CActive( CActive::EPriorityStandard ), iObserver( aObserver ), iCancelRequest( EFalse )
     {
     CActiveScheduler::Add( this );
     }
@@ -311,6 +311,7 @@
     if ( !iTransactionRunning )
         {
         ACPLOG( "CAcpHttpHandler::CancelTransaction end (not running)" );
+        iCancelRequest = ETrue;
         return;
         }
     
@@ -559,9 +560,18 @@
             iConnectionOpen = ETrue;
             }
         
-        // Submit the first transaction. Further transactions are submitted
-        // in GetDataL.
-        SubmitTransactionL();
+        // If the cancel button is pressed by the end user during the period of connection-opening,
+        // transaction need not to be submitted. Otherwise, need to be submitted.
+        if ( iCancelRequest )
+            {
+            iCancelRequest = EFalse;     
+            }
+        else
+            {
+            // Submit the first transaction. Further transactions are submitted
+            // in GetDataL.
+            SubmitTransactionL();
+            }
         }
     else
         {
--- a/voipplugins/svtmatching/inc/svtmatching.h	Wed Sep 01 12:29:57 2010 +0100
+++ b/voipplugins/svtmatching/inc/svtmatching.h	Tue Sep 14 21:02:05 2010 +0300
@@ -66,9 +66,14 @@
      *                            of address will be used for matching (e.g. by value 0).
      *                            If length of the address is less than value of the parameter the whole
      *                            of address will be used for matching.
+     * @param aAllowUserNameMatch - ETrue on return if matching using the user name part of 
+     *                              the address is allowed.
      * @return - Return KErrNone if operation succeed.
      */
-    TInt GetAddressForMatching( RBuf& aParsedAddress, TInt& aMeaningfulDigits );
+    TInt GetAddressForMatching( 
+        RBuf& aParsedAddress, 
+        TInt& aMeaningfulDigits, 
+        TBool& aAllowUsernameMatch );
 
     /**
      * Returns contact store uris which are opened and will be used for matching.
--- a/voipplugins/svtmatching/inc/svturiparser.h	Wed Sep 01 12:29:57 2010 +0100
+++ b/voipplugins/svtmatching/inc/svturiparser.h	Tue Sep 14 21:02:05 2010 +0300
@@ -81,14 +81,14 @@
     void CheckForSpacesL( const TDesC& aOriginal, 
                           RBuf& aCheckedAddress ) const;
 
-private:
-    
     /**
      * Checks is a string valid for CS call.
      * @param aOriginal - String to be checked.
      * @return ETrue if string valid for CS call.
      */ 
     TBool IsValidGsmNumber( const TDesC& aOriginal ) const;
+      
+private:
     
     /**
      * Parses username part from sip uri.
--- a/voipplugins/svtmatching/src/svtmatching.cpp	Wed Sep 01 12:29:57 2010 +0100
+++ b/voipplugins/svtmatching/src/svtmatching.cpp	Tue Sep 14 21:02:05 2010 +0300
@@ -107,7 +107,8 @@
 //
 TInt CSvtMatching::GetAddressForMatching( 
     RBuf& aParsedAddress, 
-    TInt& aMeaningfulDigits )
+    TInt& aMeaningfulDigits,
+    TBool& aAllowUserNameMatch )
     {
     if( iServiceId == 0 || !iOriginalAddress )
         {
@@ -127,8 +128,31 @@
         if ( KErrNone == ret )
             {
             aMeaningfulDigits = iSettingsHandler->MeaningfulDigits();
-            }
-        }        
+            
+            switch ( iSettingsHandler->IgnoreDomainPartValue() )
+                {
+                case 1:
+                    {
+                    aAllowUserNameMatch = EFalse;
+                    if ( iUriParser->IsValidGsmNumber( aParsedAddress ) )
+                        {
+                        aAllowUserNameMatch = ETrue;
+                        }
+                    }
+                    break;
+                case 2:
+                    {
+                    aAllowUserNameMatch = ETrue;
+                    }
+                    break;
+                case 0:
+                default:
+                    aAllowUserNameMatch = EFalse;
+                    break;
+                }
+            }     
+        }
+    
     return ret;
     }