From 363cc397172f2b0a94d9c4dc44fc8d95072795a3 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Tue, 19 Nov 2013 12:47:37 +0200 Subject: convert equalsAsciiL calls to startWith calls where possible Simplify code like: aStr.equalsAsciiL( "%", 1 ) to aStr.startsWith( "%" ) Change-Id: Iee0e4e60b0ae6d567fa8f72db5d616fffbec3c00 --- sfx2/source/control/unoctitm.cxx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'sfx2/source') diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx index 66d54208fd86..7fdde8e0a71c 100644 --- a/sfx2/source/control/unoctitm.cxx +++ b/sfx2/source/control/unoctitm.cxx @@ -602,8 +602,8 @@ void SAL_CALL SfxDispatchController_Impl::dispatch( const ::com::sun::star::util if ( pDispatch && ( - (aURL.Protocol.equalsAsciiL( ".uno:", 5 ) && aURL.Path == aDispatchURL.Path) || - (aURL.Protocol.equalsAsciiL( "slot:", 5 ) && aURL.Path.toInt32() == GetId()) + (aURL.Protocol.startsWith( ".uno:" ) && aURL.Path == aDispatchURL.Path) || + (aURL.Protocol.startsWith( "slot:" ) && aURL.Path.toInt32() == GetId()) ) ) { @@ -629,17 +629,17 @@ void SAL_CALL SfxDispatchController_Impl::dispatch( const ::com::sun::star::util for( sal_Int32 n=0; n>=bTemp ) nCall = bTemp ? SFX_CALLMODE_SYNCHRON : SFX_CALLMODE_ASYNCHRON; } - else if( rProp.Name.equalsAsciiL("Bookmark",8)) + else if( rProp.Name.startsWith("Bookmark")) { nMarkArg = n; aAddArgs.push_back( aArgs[n] ); } - else if( rProp.Name.equalsAsciiL("KeyModifier",11)) + else if( rProp.Name.startsWith("KeyModifier")) rProp.Value >>= nModifier; else aAddArgs.push_back( aArgs[n] ); -- cgit