[Libreoffice-commits] .: 2 commits - forms/source

Caolán McNamara caolan at kemper.freedesktop.org
Wed Nov 17 08:33:31 PST 2010


 forms/source/misc/InterfaceContainer.cxx |   10 +++++-----
 forms/source/misc/limitedformats.cxx     |    6 +++---
 forms/source/misc/services.cxx           |    8 ++++----
 forms/source/runtime/formoperations.cxx  |    2 +-
 4 files changed, 13 insertions(+), 13 deletions(-)

New commits:
commit 323dd4a9f75c58f5521c96a3d00847004f7ca58e
Author: pjacquod <pjacquod at alumni.ethz.ch>
Date:   Tue Nov 16 00:09:27 2010 +0100

    RTL_CONSTASCII_USTRINGPARAM in components misc
    
    components/forms/source/misc should be OK now

diff --git a/forms/source/misc/InterfaceContainer.cxx b/forms/source/misc/InterfaceContainer.cxx
index fd54c4c..400f2d7 100644
--- a/forms/source/misc/InterfaceContainer.cxx
+++ b/forms/source/misc/InterfaceContainer.cxx
@@ -96,7 +96,7 @@ lcl_hasVbaEvents( const Sequence< ScriptEventDescriptor >& sEvents  )
     const ScriptEventDescriptor* pEnd = ( pDesc + sEvents.getLength() );
     for ( ; pDesc != pEnd; ++pDesc )
     {
-        if ( pDesc->ScriptType.equals( rtl::OUString::createFromAscii( "VBAInterop" ) ) )
+        if ( pDesc->ScriptType.equals( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("VBAInterop") ) ) )
             return true;
     }
     return false;
@@ -112,7 +112,7 @@ lcl_stripVbaEvents( const Sequence< ScriptEventDescriptor >& sEvents )
     sal_Int32 nCopied = 0;
     for ( ; pDesc != pEnd; ++pDesc )
     {
-        if ( !pDesc->ScriptType.equals( rtl::OUString::createFromAscii( "VBAInterop" ) ) )
+        if ( !pDesc->ScriptType.equals( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("VBAInterop") ) ) )
         {
             sStripped[ nCopied++ ] = *pDesc;
         }
@@ -134,7 +134,7 @@ void OInterfaceContainer::impl_addVbEvents_nolck_nothrow(  const sal_Int32 i_nIn
                 break;
 
             Reference< XMultiServiceFactory > xDocFac( xDoc, UNO_QUERY_THROW );
-            Reference< XCodeNameQuery > xNameQuery( xDocFac->createInstance( rtl::OUString::createFromAscii( "ooo.vba.VBACodeNameProvider" ) ), UNO_QUERY );
+            Reference< XCodeNameQuery > xNameQuery( xDocFac->createInstance( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo.vba.VBACodeNameProvider") ) ), UNO_QUERY );
             if ( !xNameQuery.is() )
                 break;
 
@@ -152,9 +152,9 @@ void OInterfaceContainer::impl_addVbEvents_nolck_nothrow(  const sal_Int32 i_nIn
 
             Reference< XPropertySet > xProps( xElement, UNO_QUERY_THROW );
             ::rtl::OUString sServiceName;
-            xProps->getPropertyValue( rtl::OUString::createFromAscii("DefaultControl" ) ) >>= sServiceName;
+            xProps->getPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DefaultControl") ) ) >>= sServiceName;
 
-            Reference< ooo::vba::XVBAToOOEventDescGen > xDescSupplier( m_xServiceFactory->createInstance( rtl::OUString::createFromAscii( "ooo.vba.VBAToOOEventDesc" ) ), UNO_QUERY_THROW );
+            Reference< ooo::vba::XVBAToOOEventDescGen > xDescSupplier( m_xServiceFactory->createInstance( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("ooo.vba.VBAToOOEventDesc") ) ), UNO_QUERY_THROW );
             Reference< XInterface > xInterface = m_xServiceFactory->createInstance( sServiceName );
             Sequence< ScriptEventDescriptor > vbaEvents = xDescSupplier->getEventDescriptions( xInterface, sCodeName );
             // register the vba script events
diff --git a/forms/source/misc/limitedformats.cxx b/forms/source/misc/limitedformats.cxx
index d63cb79..5951697 100644
--- a/forms/source/misc/limitedformats.cxx
+++ b/forms/source/misc/limitedformats.cxx
@@ -64,8 +64,8 @@ namespace frm
     //---------------------------------------------------------------------
     static const Locale& getLocale(LocaleType _eType)
     {
-        static const Locale s_aEnglishUS( ::rtl::OUString::createFromAscii("en"), ::rtl::OUString::createFromAscii("us"), ::rtl::OUString() );
-        static const Locale s_aGerman( ::rtl::OUString::createFromAscii("de"), ::rtl::OUString::createFromAscii("DE"), ::rtl::OUString() );
+        static const Locale s_aEnglishUS( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("en") ), ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("us") ), ::rtl::OUString() );
+        static const Locale s_aGerman( ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("de") ), ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("DE") ), ::rtl::OUString() );
         static const ::rtl::OUString s_sEmptyString;
         static const Locale s_aSystem( s_sEmptyString, s_sEmptyString, s_sEmptyString );
 
@@ -342,7 +342,7 @@ namespace frm
 
             if (!bFoundIt)
             {	// somebody gave us an format which we can't translate
-                ::rtl::OUString sMessage = ::rtl::OUString::createFromAscii("This control supports only a very limited number of formats.");
+                ::rtl::OUString sMessage (RTL_CONSTASCII_USTRINGPARAM("This control supports only a very limited number of formats.") );
                 throw IllegalArgumentException(sMessage, NULL, 2);
             }
 
diff --git a/forms/source/misc/services.cxx b/forms/source/misc/services.cxx
index a06f4be..844180f 100644
--- a/forms/source/misc/services.cxx
+++ b/forms/source/misc/services.cxx
@@ -134,7 +134,7 @@ void registerClassInfo(
 //.......................................................................................
 #define REGISTER_CLASS_CORE(classImplName) \
     registerClassInfo( \
-        ::rtl::OUString::createFromAscii("com.sun.star.form.") + ::rtl::OUString::createFromAscii(#classImplName), \
+        ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.form.") ) + ::rtl::OUString::createFromAscii(#classImplName), \
         aServices, \
         frm::classImplName##_CreateInstance)
 
@@ -229,7 +229,7 @@ void ensureClassInfos()
     aServices.getArray()[2] = frm::FRM_SUN_COMPONENT_DATABASE_FORMATTEDFIELD;
     aServices.getArray()[3] = frm::BINDABLE_DATABASE_FORMATTED_FIELD;
 
-    registerClassInfo(::rtl::OUString::createFromAscii("com.sun.star.comp.forms.OFormattedFieldWrapper_ForcedFormatted"),
+    registerClassInfo(::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("com.sun.star.comp.forms.OFormattedFieldWrapper_ForcedFormatted") ),
         aServices,
         frm::OFormattedFieldWrapper_CreateInstance_ForceFormatted);
 
@@ -287,9 +287,9 @@ void ensureClassInfos()
 //---------------------------------------------------------------------------------------
 void registerServiceProvider(const ::rtl::OUString& _rServiceImplName, const Sequence< ::rtl::OUString >& _rServices, XRegistryKey* _pKey)
 {
-    ::rtl::OUString sMainKeyName = ::rtl::OUString::createFromAscii("/");
+    ::rtl::OUString sMainKeyName (RTL_CONSTASCII_USTRINGPARAM("/") );
     sMainKeyName += _rServiceImplName;
-    sMainKeyName += ::rtl::OUString::createFromAscii("/UNO/SERVICES");
+    sMainKeyName += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM("/UNO/SERVICES") );
     Reference< XRegistryKey > xNewKey = _pKey->createKey(sMainKeyName);
     OSL_ENSURE(xNewKey.is(), "forms::registerProvider : could not create a registry key !");
     if (!xNewKey.is())
commit ecb9a0e115cffd8511823365cf77a8afefc21a33
Author: pjacquod <pjacquod at alumni.ethz.ch>
Date:   Mon Nov 15 23:59:34 2010 +0100

    RTL_CONSTASCII_USTRINGPARAM components in runtime
    
    components/forms/source/runtime should be OK now

diff --git a/forms/source/runtime/formoperations.cxx b/forms/source/runtime/formoperations.cxx
index e857787..06382b2 100644
--- a/forms/source/runtime/formoperations.cxx
+++ b/forms/source/runtime/formoperations.cxx
@@ -414,7 +414,7 @@ namespace frm
 
                 ::rtl::OUString sValue = ::rtl::OUString::valueOf( sal_Int32( nCount ) );
                 if ( !bFinalCount )
-                    sValue += ::rtl::OUString::createFromAscii( " *" );
+                    sValue += ::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(" *") );
 
                 aState.State <<= sValue;
                 aState.Enabled = sal_True;


More information about the Libreoffice-commits mailing list