summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2010-10-30 16:24:31 +0100
committerCaolán McNamara <caolanm@redhat.com>2010-10-30 17:01:20 +0100
commitfcf499e028a751c8820620c99c1ddccf88b5007b (patch)
treef21c83177346ce17b6e9c349b73e56313f71b4fc
parentb86494ca371f4891391167142e77f09e98acb08c (diff)
small startup optimization
-rw-r--r--vcl/source/app/settings.cxx34
1 files changed, 17 insertions, 17 deletions
diff --git a/vcl/source/app/settings.cxx b/vcl/source/app/settings.cxx
index 9acfac2cb4d5..1530a0649689 100644
--- a/vcl/source/app/settings.cxx
+++ b/vcl/source/app/settings.cxx
@@ -705,35 +705,35 @@ void StyleSettings::Set3DColors( const Color& rColor )
{
switch ( nStyle )
{
- case STYLE_SYMBOLS_DEFAULT: return ::rtl::OUString::createFromAscii( "default" );
- case STYLE_SYMBOLS_HICONTRAST: return ::rtl::OUString::createFromAscii( "hicontrast" );
- case STYLE_SYMBOLS_INDUSTRIAL: return ::rtl::OUString::createFromAscii( "tango" ); // industrial is dead
- case STYLE_SYMBOLS_CRYSTAL: return ::rtl::OUString::createFromAscii( "crystal" );
- case STYLE_SYMBOLS_TANGO: return ::rtl::OUString::createFromAscii( "tango" );
- case STYLE_SYMBOLS_OXYGEN: return ::rtl::OUString::createFromAscii( "oxygen" );
- case STYLE_SYMBOLS_CLASSIC: return ::rtl::OUString::createFromAscii( "classic" );
+ case STYLE_SYMBOLS_DEFAULT: return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("default"));
+ case STYLE_SYMBOLS_HICONTRAST: return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("hicontrast"));
+ case STYLE_SYMBOLS_INDUSTRIAL: return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("tango")); // industrial is dead
+ case STYLE_SYMBOLS_CRYSTAL: return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("crystal"));
+ case STYLE_SYMBOLS_TANGO: return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("tango"));
+ case STYLE_SYMBOLS_OXYGEN: return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("oxygen"));
+ case STYLE_SYMBOLS_CLASSIC: return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("classic"));
}
- return ::rtl::OUString::createFromAscii( "auto" );
+ return ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("auto"));
}
// -----------------------------------------------------------------------
ULONG StyleSettings::ImplNameToSymbolsStyle( const ::rtl::OUString &rName ) const
{
- if ( rName == ::rtl::OUString::createFromAscii( "default" ) )
+ if ( rName == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("default")) )
return STYLE_SYMBOLS_DEFAULT;
- else if ( rName == ::rtl::OUString::createFromAscii( "hicontrast" ) )
+ else if ( rName == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("hicontrast")) )
return STYLE_SYMBOLS_HICONTRAST;
- else if ( rName == ::rtl::OUString::createFromAscii( "industrial" ) )
+ else if ( rName == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("industrial")) )
return STYLE_SYMBOLS_TANGO; // industrial is dead
- else if ( rName == ::rtl::OUString::createFromAscii( "crystal" ) )
+ else if ( rName == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("crystal")) )
return STYLE_SYMBOLS_CRYSTAL;
- else if ( rName == ::rtl::OUString::createFromAscii( "tango" ) )
+ else if ( rName == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("tango")) )
return STYLE_SYMBOLS_TANGO;
- else if ( rName == ::rtl::OUString::createFromAscii( "oxygen" ) )
+ else if ( rName == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("oxygen")) )
return STYLE_SYMBOLS_OXYGEN;
- else if ( rName == ::rtl::OUString::createFromAscii( "classic" ) )
+ else if ( rName == ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("classic")) )
return STYLE_SYMBOLS_CLASSIC;
return STYLE_SYMBOLS_AUTO;
@@ -1947,11 +1947,11 @@ BOOL AllSettings::GetLayoutRTL() const
nUIMirroring = 0; // ask configuration only once
utl::OConfigurationNode aNode = utl::OConfigurationTreeRoot::tryCreateWithServiceFactory(
vcl::unohelper::GetMultiServiceFactory(),
- OUString::createFromAscii( "org.openoffice.Office.Common/I18N/CTL" ) ); // note: case sensisitive !
+ OUString(RTL_CONSTASCII_USTRINGPARAM("org.openoffice.Office.Common/I18N/CTL")) ); // note: case sensisitive !
if ( aNode.isValid() )
{
BOOL bTmp = BOOL();
- ::com::sun::star::uno::Any aValue = aNode.getNodeValue( OUString::createFromAscii( "UIMirroring" ) );
+ ::com::sun::star::uno::Any aValue = aNode.getNodeValue( OUString(RTL_CONSTASCII_USTRINGPARAM("UIMirroring")) );
if( aValue >>= bTmp )
{
// found true or false; if it was nil, nothing is changed