diff options
author | Luboš Luňák <l.lunak@suse.cz> | 2013-08-21 15:07:31 +0200 |
---|---|---|
committer | Luboš Luňák <l.lunak@suse.cz> | 2013-08-21 15:10:35 +0200 |
commit | 64b993e046f23baaacaff1572b7d2a816588b5ef (patch) | |
tree | 237dce36a1d4787d168a0520839f6aab22500487 /vbahelper | |
parent | 75f41baab6ce75786a91fe461835ee16a23ec18e (diff) |
finish deprecation of O(U)String::valueOf()
Compiler plugin to replace with matching number(), boolean() or OUString ctor,
ran it, few manual tweaks, mark as really deprecated.
Change-Id: I4a79bdbcf4c460d21e73b635d2bd3725c22876b2
Diffstat (limited to 'vbahelper')
-rw-r--r-- | vbahelper/source/msforms/vbacontrols.cxx | 2 | ||||
-rw-r--r-- | vbahelper/source/vbahelper/vbacommandbarhelper.cxx | 2 | ||||
-rw-r--r-- | vbahelper/source/vbahelper/vbahelper.cxx | 16 | ||||
-rw-r--r-- | vbahelper/source/vbahelper/vbashapes.cxx | 2 |
4 files changed, 11 insertions, 11 deletions
diff --git a/vbahelper/source/msforms/vbacontrols.cxx b/vbahelper/source/msforms/vbacontrols.cxx index e9710859d2d7..7e9ded29e2dd 100644 --- a/vbahelper/source/msforms/vbacontrols.cxx +++ b/vbahelper/source/msforms/vbacontrols.cxx @@ -289,7 +289,7 @@ uno::Any SAL_CALL ScVbaControls::Add( const uno::Any& Object, const uno::Any& St while( xDialogContainer->hasByName( aNewName ) && (nInd < SAL_MAX_INT32) ) { aNewName = aComServiceName; - aNewName += OUString::valueOf( nInd++ ); + aNewName += OUString::number( nInd++ ); } } diff --git a/vbahelper/source/vbahelper/vbacommandbarhelper.cxx b/vbahelper/source/vbahelper/vbacommandbarhelper.cxx index 0273548892c2..57a35c053c9c 100644 --- a/vbahelper/source/vbahelper/vbacommandbarhelper.cxx +++ b/vbahelper/source/vbahelper/vbacommandbarhelper.cxx @@ -263,7 +263,7 @@ OUString VbaCommandBarHelper::generateCustomURL() // use a random number to minimize possible clash with existing custom toolbars srand( unsigned( time( NULL ) )); - url += OUString::valueOf( sal_Int64( rand() ), 16 ); + url += OUString::number( rand(), 16 ); return url; } diff --git a/vbahelper/source/vbahelper/vbahelper.cxx b/vbahelper/source/vbahelper/vbahelper.cxx index d12bfdd425b7..98e439bf73cb 100644 --- a/vbahelper/source/vbahelper/vbahelper.cxx +++ b/vbahelper/source/vbahelper/vbahelper.cxx @@ -362,9 +362,9 @@ void PrintOutHelper( SfxViewShell* pViewShell, const uno::Any& From, const uno:: if (( nFrom || nTo ) ) { if ( nFrom ) - sRange = ( OUString::valueOf( nFrom ) + sRange ); + sRange = ( OUString::number( nFrom ) + sRange ); if ( nTo ) - sRange += OUString::valueOf( nTo ); + sRange += OUString::number( nTo ); } if ( PrToFileName.getValue() ) @@ -479,17 +479,17 @@ OUString extractStringFromAny( const uno::Any& rAny, bool bUppercaseBool ) throw case uno::TypeClass_BOOLEAN: return bUppercaseBool ? (rAny.get< bool >() ? OUString( "TRUE" ) : OUString( "FALSE" )) : - OUString::valueOf( (sal_Bool)rAny.get< bool >() ); + OUString::boolean( (sal_Bool)rAny.get< bool >() ); case uno::TypeClass_FLOAT: - return OUString::valueOf( rAny.get< float >() ); + return OUString::number( rAny.get< float >() ); case uno::TypeClass_DOUBLE: - return OUString::valueOf( rAny.get< double >() ); + return OUString::number( rAny.get< double >() ); case uno::TypeClass_BYTE: case uno::TypeClass_SHORT: case uno::TypeClass_LONG: - return OUString::valueOf( rAny.get< sal_Int32 >() ); + return OUString::number( rAny.get< sal_Int32 >() ); case uno::TypeClass_HYPER: - return OUString::valueOf( rAny.get< sal_Int64 >() ); + return OUString::number( rAny.get< sal_Int64 >() ); default:; } throw uno::RuntimeException( "Invalid type, cannot convert to string." , 0 ); @@ -531,7 +531,7 @@ ContainerUtilities::getUniqueName( const uno::Sequence< OUString >& _slist, cons return scompname; } } - scompname = _sElementName + _sSuffixSeparator + OUString::valueOf( a++ ); + scompname = _sElementName + _sSuffixSeparator + OUString::number( a++ ); } return OUString(); } diff --git a/vbahelper/source/vbahelper/vbashapes.cxx b/vbahelper/source/vbahelper/vbashapes.cxx index 9ecd72064bb2..1303eac17b2f 100644 --- a/vbahelper/source/vbahelper/vbashapes.cxx +++ b/vbahelper/source/vbahelper/vbashapes.cxx @@ -436,7 +436,7 @@ ScVbaShapes::createName( OUString sName ) { sal_Int32 nActNumber = 1 + m_nNewShapeCount; m_nNewShapeCount++; - sName += OUString::valueOf( nActNumber ); + sName += OUString::number( nActNumber ); return sName; } |