[Libreoffice-commits] core.git: toolkit/inc toolkit/source

Noel Grandin (via logerrit) logerrit at kemper.freedesktop.org
Tue Mar 3 18:33:49 UTC 2020


 toolkit/inc/helper/servicenames.hxx                  |   80 -------------------
 toolkit/source/awt/vclxmenu.cxx                      |    4 
 toolkit/source/controls/dialogcontrol.cxx            |    2 
 toolkit/source/controls/formattedcontrol.cxx         |    4 
 toolkit/source/controls/roadmapcontrol.cxx           |    4 
 toolkit/source/controls/stdtabcontroller.cxx         |    2 
 toolkit/source/controls/stdtabcontrollermodel.cxx    |    4 
 toolkit/source/controls/tkscrollbar.cxx              |    4 
 toolkit/source/controls/unocontrolcontainermodel.cxx |    2 
 toolkit/source/controls/unocontrols.cxx              |   69 ++++++++--------
 toolkit/source/helper/servicenames.cxx               |   72 -----------------
 11 files changed, 49 insertions(+), 198 deletions(-)

New commits:
commit f7dddbd7f2d93f3b6c1a85917b4434e388dfe1c9
Author:     Noel Grandin <noel.grandin at collabora.co.uk>
AuthorDate: Tue Mar 3 15:09:36 2020 +0200
Commit:     Noel Grandin <noel.grandin at collabora.co.uk>
CommitDate: Tue Mar 3 19:33:14 2020 +0100

    inline some use-once constants
    
    Change-Id: I201b195438ef3df067cfa6db97c3b37b23061142
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/89887
    Tested-by: Jenkins
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/toolkit/inc/helper/servicenames.hxx b/toolkit/inc/helper/servicenames.hxx
index 73e0a3260f51..cd888c94d2eb 100644
--- a/toolkit/inc/helper/servicenames.hxx
+++ b/toolkit/inc/helper/servicenames.hxx
@@ -21,84 +21,6 @@
 
 #include <sal/types.h>
 
-extern const char szServiceName_Toolkit[], szServiceName2_Toolkit[];
-extern const char szServiceName_MVCIntrospection[], szServiceName2_MVCIntrospection[];
-extern const char szServiceName_PopupMenu[], szServiceName2_PopupMenu[];
-extern const char szServiceName_MenuBar[], szServiceName2_MenuBar[];
-extern const char szServiceName_Pointer[], szServiceName2_Pointer[];
-extern const char szServiceName_UnoControlContainer[];
-extern const char szServiceName_UnoControlContainerModel[];
-extern const char szServiceName2_UnoMultiPageControl[];
-extern const char szServiceName2_UnoMultiPageModel[];
-extern const char szServiceName2_UnoPageControl[];
-extern const char szServiceName2_UnoPageModel[];
-extern const char szServiceName2_UnoFrameControl[];
-extern const char szServiceName2_UnoFrameModel[];
-extern const char szServiceName_TabController[], szServiceName2_TabController[];
-extern const char szServiceName_TabControllerModel[], szServiceName2_TabControllerModel[];
-extern const char szServiceName_UnoControlDialog[], szServiceName2_UnoControlDialog[];
-extern const char szServiceName_UnoControlDialogModel[], szServiceName2_UnoControlDialogModel[];
-extern const char szServiceName_UnoControlEdit[], szServiceName2_UnoControlEdit[];
-extern const char szServiceName_UnoControlEditModel[];
-extern const char szServiceName_UnoControlFileControl[];
-extern const char szServiceName_UnoControlFileControlModel[];
-extern const char szServiceName_UnoControlButton[];
-extern const char szServiceName_UnoControlButtonModel[];
-extern const char szServiceName_UnoControlImageButton[], szServiceName2_UnoControlImageButton[];
-extern const char szServiceName_UnoControlImageButtonModel[], szServiceName2_UnoControlImageButtonModel[];
-extern const char szServiceName_UnoControlImageControl[];
-extern const char szServiceName_UnoControlImageControlModel[];
-extern const char szServiceName_UnoControlRadioButton[];
-extern const char szServiceName_UnoControlRadioButtonModel[];
-extern const char szServiceName_UnoControlCheckBox[];
-extern const char szServiceName_UnoControlCheckBoxModel[];
-extern const char szServiceName_UnoControlListBox[];
-extern const char szServiceName_UnoControlListBoxModel[];
-extern const char szServiceName_UnoControlComboBox[];
-extern const char szServiceName_UnoControlComboBoxModel[];
-extern const char szServiceName_UnoControlFixedText[];
-extern const char szServiceName_UnoControlGroupBox[];
-extern const char szServiceName_UnoControlGroupBoxModel[];
-extern const char szServiceName_UnoControlDateField[];
-extern const char szServiceName_UnoControlDateFieldModel[];
-extern const char szServiceName_UnoControlTimeField[];
-extern const char szServiceName_UnoControlTimeFieldModel[];
-extern const char szServiceName_UnoControlNumericField[];
-extern const char szServiceName_UnoControlNumericFieldModel[];
-extern const char szServiceName_UnoControlCurrencyField[];
-extern const char szServiceName_UnoControlCurrencyFieldModel[];
-extern const char szServiceName_UnoControlPatternField[];
-extern const char szServiceName_UnoControlPatternFieldModel[];
-extern const char szServiceName_UnoControlFormattedField[];
-extern const char szServiceName_UnoControlFormattedFieldModel[];
-extern const char szServiceName_UnoControlProgressBar[];
-extern const char szServiceName_UnoControlProgressBarModel[];
-extern const char szServiceName_UnoControlScrollBar[];
-extern const char szServiceName_UnoControlScrollBarModel[];
-extern const char szServiceName_UnoControlFixedLine[];
-extern const char szServiceName_UnoControlFixedLineModel[];
-extern const char szServiceName_PrinterServer[], szServiceName2_PrinterServer[];
-extern const char szServiceName_UnoControlRoadmap[];
-extern const char szServiceName_UnoControlRoadmapModel[];
-
-extern const char szServiceName_UnoSpinButtonControl[], szServiceName_UnoSpinButtonModel[];
-
-extern const char szServiceName_GridControl[];
-extern const char szServiceName_DefaultGridDataModel[];
-extern const char szServiceName_DefaultGridColumnModel[];
-extern const char szServiceName_GridColumn[];
-extern const char szServiceName_SortableGridDataModel[];
-
-extern const char szServiceName_AnimatedImagesControl[];
-extern const char szServiceName_AnimatedImagesControlModel[];
-extern const char szServiceName_SpinningProgressControlModel[];
-
-extern const char szServiceName_UnoControlTabPageModel[], szServiceName2_UnoControlTabPageModel[];
-extern const char szServiceName_UnoControlTabPage[];
-extern const char szServiceName_UnoControlTabPageContainerModel[];
-extern const char szServiceName_UnoControlTabPageContainer[];
-
-// ExtUnoWrapper:
-extern const char szServiceName_ImageProducer[], szServiceName2_ImageProducer[];
+extern const char szServiceName_UnoControlDialog[];
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/toolkit/source/awt/vclxmenu.cxx b/toolkit/source/awt/vclxmenu.cxx
index 28dddc7c9c95..0ba38df421c2 100644
--- a/toolkit/source/awt/vclxmenu.cxx
+++ b/toolkit/source/awt/vclxmenu.cxx
@@ -187,11 +187,11 @@ css::uno::Sequence< OUString > SAL_CALL VCLXMenu::getSupportedServiceNames(  )
 
     if ( bIsPopupMenu )
         return css::uno::Sequence<OUString>{
-            OUString::createFromAscii(szServiceName2_PopupMenu),
+            "com.sun.star.awt.PopupMenu",
             "stardiv.vcl.PopupMenu"};
     else
         return css::uno::Sequence<OUString>{
-            OUString::createFromAscii(szServiceName2_MenuBar),
+            "com.sun.star.awt.MenuBar",
             "stardiv.vcl.MenuBar"};
 }
 
diff --git a/toolkit/source/controls/dialogcontrol.cxx b/toolkit/source/controls/dialogcontrol.cxx
index 4ea2a81f4c76..a4c695223f57 100644
--- a/toolkit/source/controls/dialogcontrol.cxx
+++ b/toolkit/source/controls/dialogcontrol.cxx
@@ -384,7 +384,7 @@ sal_Bool UnoDialogControl::supportsService(OUString const & ServiceName)
 css::uno::Sequence<OUString> UnoDialogControl::getSupportedServiceNames()
 {
     return css::uno::Sequence<OUString>{
-        OUString::createFromAscii(szServiceName2_UnoControlDialog),
+        "com.sun.star.awt.UnoControlDialog",
         "stardiv.vcl.control.Dialog"};
 }
 
diff --git a/toolkit/source/controls/formattedcontrol.cxx b/toolkit/source/controls/formattedcontrol.cxx
index 52fc287b2dee..015b38e1f7b6 100644
--- a/toolkit/source/controls/formattedcontrol.cxx
+++ b/toolkit/source/controls/formattedcontrol.cxx
@@ -161,7 +161,7 @@ namespace toolkit
 
     OUString UnoControlFormattedFieldModel::getServiceName()
     {
-        return OUString::createFromAscii( szServiceName_UnoControlFormattedFieldModel );
+        return "stardiv.vcl.controlmodel.FormattedField";
     }
 
 
@@ -371,7 +371,7 @@ namespace toolkit
         Any aReturn;
         switch (nPropId)
         {
-            case BASEPROPERTY_DEFAULTCONTROL: aReturn <<= OUString::createFromAscii( szServiceName_UnoControlFormattedField ); break;
+            case BASEPROPERTY_DEFAULTCONTROL: aReturn <<= OUString("stardiv.vcl.control.FormattedField"); break;
 
             case BASEPROPERTY_TREATASNUMBER: aReturn <<= true; break;
 
diff --git a/toolkit/source/controls/roadmapcontrol.cxx b/toolkit/source/controls/roadmapcontrol.cxx
index a1e02bd94edb..9bc540593742 100644
--- a/toolkit/source/controls/roadmapcontrol.cxx
+++ b/toolkit/source/controls/roadmapcontrol.cxx
@@ -79,7 +79,7 @@ static void lcl_throwIndexOutOfBoundsException( )
 
     OUString UnoControlRoadmapModel::getServiceName()
     {
-        return OUString::createFromAscii( szServiceName_UnoControlRoadmapModel );
+        return "stardiv.vcl.controlmodel.Roadmap";
     }
 
     OUString UnoControlRoadmapModel::getImplementationName()
@@ -117,7 +117,7 @@ static void lcl_throwIndexOutOfBoundsException( )
                     aReturn <<= sal_Int16(2);              // No Border
                     break;
                 case BASEPROPERTY_DEFAULTCONTROL:
-                    aReturn <<= OUString::createFromAscii( szServiceName_UnoControlRoadmap );
+                    aReturn <<= OUString( "stardiv.vcl.control.Roadmap" );
                     break;
             default : aReturn = UnoControlRoadmapModel_Base::ImplGetDefaultValue( nPropId ); break;
         }
diff --git a/toolkit/source/controls/stdtabcontroller.cxx b/toolkit/source/controls/stdtabcontroller.cxx
index 5e4d81da4e77..b0c6142476b0 100644
--- a/toolkit/source/controls/stdtabcontroller.cxx
+++ b/toolkit/source/controls/stdtabcontroller.cxx
@@ -376,7 +376,7 @@ sal_Bool StdTabController::supportsService(OUString const & ServiceName)
 css::uno::Sequence<OUString> StdTabController::getSupportedServiceNames()
 {
     return css::uno::Sequence<OUString>{
-        OUString::createFromAscii(szServiceName2_TabController),
+        "com.sun.star.awt.TabController",
         "stardiv.vcl.control.TabController"};
 }
 
diff --git a/toolkit/source/controls/stdtabcontrollermodel.cxx b/toolkit/source/controls/stdtabcontrollermodel.cxx
index e675710b91f2..5a4f65b60925 100644
--- a/toolkit/source/controls/stdtabcontrollermodel.cxx
+++ b/toolkit/source/controls/stdtabcontrollermodel.cxx
@@ -369,7 +369,7 @@ void StdTabControllerModel::getGroupByName( const OUString& rName, css::uno::Seq
 // css::io::XPersistObject
 OUString StdTabControllerModel::getServiceName(  )
 {
-    return OUString::createFromAscii( szServiceName_TabControllerModel );
+    return "stardiv.vcl.controlmodel.TabController";
 }
 
 void StdTabControllerModel::write( const css::uno::Reference< css::io::XObjectOutputStream >& OutStream )
@@ -425,7 +425,7 @@ sal_Bool StdTabControllerModel::supportsService(OUString const & ServiceName)
 css::uno::Sequence<OUString> StdTabControllerModel::getSupportedServiceNames()
 {
     return css::uno::Sequence<OUString>{
-        OUString::createFromAscii(szServiceName2_TabControllerModel),
+        "com.sun.star.awt.TabControllerModel",
         "stardiv.vcl.controlmodel.TabController"};
 }
 
diff --git a/toolkit/source/controls/tkscrollbar.cxx b/toolkit/source/controls/tkscrollbar.cxx
index c45810420e68..d2d1c2248921 100644
--- a/toolkit/source/controls/tkscrollbar.cxx
+++ b/toolkit/source/controls/tkscrollbar.cxx
@@ -47,7 +47,7 @@ namespace toolkit
 
     OUString UnoControlScrollBarModel::getServiceName( )
     {
-        return OUString::createFromAscii( szServiceName_UnoControlScrollBarModel );
+        return "stardiv.vcl.controlmodel.ScrollBar";
     }
 
     OUString UnoControlScrollBarModel::getImplementationName()
@@ -72,7 +72,7 @@ namespace toolkit
         case BASEPROPERTY_LIVE_SCROLL:
             return uno::makeAny( false );
         case BASEPROPERTY_DEFAULTCONTROL:
-            return uno::makeAny( OUString::createFromAscii( szServiceName_UnoControlScrollBar ) );
+            return uno::makeAny( OUString( "stardiv.vcl.control.ScrollBar" ) );
 
         default:
             return UnoControlModel::ImplGetDefaultValue( nPropId );
diff --git a/toolkit/source/controls/unocontrolcontainermodel.cxx b/toolkit/source/controls/unocontrolcontainermodel.cxx
index 8487f55c18c2..83079df8bdfc 100644
--- a/toolkit/source/controls/unocontrolcontainermodel.cxx
+++ b/toolkit/source/controls/unocontrolcontainermodel.cxx
@@ -41,7 +41,7 @@ UnoControlContainerModel::UnoControlContainerModel( const css::uno::Reference< c
 
 OUString UnoControlContainerModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlContainerModel );
+    return "stardiv.vcl.controlmodel.ControlContainer";
 }
 
 OUString UnoControlContainerModel::getImplementationName()
diff --git a/toolkit/source/controls/unocontrols.cxx b/toolkit/source/controls/unocontrols.cxx
index 87499c496118..9d8cc4d0b960 100644
--- a/toolkit/source/controls/unocontrols.cxx
+++ b/toolkit/source/controls/unocontrols.cxx
@@ -96,7 +96,7 @@ UnoControlEditModel::UnoControlEditModel( const Reference< XComponentContext >&
 
 OUString UnoControlEditModel::getServiceName( )
 {
-    return OUString::createFromAscii( szServiceName_UnoControlEditModel );
+    return "stardiv.vcl.controlmodel.Edit";
 }
 
 uno::Any UnoControlEditModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
@@ -109,7 +109,7 @@ uno::Any UnoControlEditModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
         aReturn <<= sal_Int16(awt::LineEndFormat::LINE_FEED);   // LF
         break;
     case BASEPROPERTY_DEFAULTCONTROL:
-        aReturn <<= OUString::createFromAscii( szServiceName_UnoControlEdit );
+        aReturn <<= OUString( "stardiv.vcl.control.Edit" );
         break;
     default:
         aReturn = UnoControlModel::ImplGetDefaultValue( nPropId );
@@ -463,7 +463,7 @@ uno::Sequence< OUString > UnoEditControl::getSupportedServiceNames()
 {
     uno::Sequence< OUString > aNames = UnoControlBase::getSupportedServiceNames( );
     aNames.realloc( aNames.getLength() + 2 );
-    aNames[ aNames.getLength() - 2 ] = OUString::createFromAscii( szServiceName2_UnoControlEdit );
+    aNames[ aNames.getLength() - 2 ] = "com.sun.star.awt.UnoControlEdit";
     aNames[ aNames.getLength() - 1 ] = "stardiv.vcl.control.Edit";
     return aNames;
 }
@@ -503,14 +503,14 @@ UnoControlFileControlModel::UnoControlFileControlModel( const Reference< XCompon
 
 OUString UnoControlFileControlModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlFileControlModel );
+    return "stardiv.vcl.controlmodel.FileControl";
 }
 
 uno::Any UnoControlFileControlModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any( OUString::createFromAscii( szServiceName_UnoControlFileControl ) );
+        return uno::Any( OUString( "stardiv.vcl.control.FileControl" ) );
     }
     return UnoControlModel::ImplGetDefaultValue( nPropId );
 }
@@ -673,7 +673,7 @@ UnoControlButtonModel::UnoControlButtonModel( const Reference< XComponentContext
 
 OUString UnoControlButtonModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlButtonModel );
+    return "stardiv.vcl.controlmodel.Button";
 }
 
 uno::Any UnoControlButtonModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
@@ -681,7 +681,7 @@ uno::Any UnoControlButtonModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
     switch ( nPropId )
     {
     case BASEPROPERTY_DEFAULTCONTROL:
-        return uno::makeAny( OUString::createFromAscii( szServiceName_UnoControlButton ) );
+        return uno::makeAny( OUString( "stardiv.vcl.control.Button" ) );
     case BASEPROPERTY_TOGGLE:
         return uno::makeAny( false );
     case BASEPROPERTY_ALIGN:
@@ -896,7 +896,7 @@ UnoControlImageControlModel::UnoControlImageControlModel( const Reference< XComp
 
 OUString UnoControlImageControlModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlImageControlModel );
+    return "stardiv.vcl.controlmodel.ImageControl";
 }
 
 OUString UnoControlImageControlModel::getImplementationName()
@@ -919,7 +919,7 @@ UnoControlImageControlModel::getSupportedServiceNames()
 uno::Any UnoControlImageControlModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
-        return uno::makeAny( OUString::createFromAscii( szServiceName_UnoControlImageControl ) );
+        return uno::makeAny( OUString( "stardiv.vcl.control.ImageControl" ) );
 
     if ( nPropId == BASEPROPERTY_IMAGE_SCALE_MODE )
         return makeAny( awt::ImageScaleMode::ANISOTROPIC );
@@ -1064,7 +1064,7 @@ UnoControlRadioButtonModel::UnoControlRadioButtonModel( const Reference< XCompon
 
 OUString UnoControlRadioButtonModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlRadioButtonModel );
+    return "stardiv.vcl.controlmodel.RadioButton";
 }
 
 uno::Any UnoControlRadioButtonModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
@@ -1072,7 +1072,7 @@ uno::Any UnoControlRadioButtonModel::ImplGetDefaultValue( sal_uInt16 nPropId ) c
     switch ( nPropId )
     {
     case BASEPROPERTY_DEFAULTCONTROL:
-        return uno::makeAny( OUString::createFromAscii( szServiceName_UnoControlRadioButton ) );
+        return uno::makeAny( OUString( "stardiv.vcl.control.RadioButton" ) );
 
     case BASEPROPERTY_VISUALEFFECT:
         return uno::makeAny( sal_Int16(awt::VisualEffect::LOOK3D) );
@@ -1304,7 +1304,7 @@ UnoControlCheckBoxModel::UnoControlCheckBoxModel( const Reference< XComponentCon
 
 OUString UnoControlCheckBoxModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlCheckBoxModel );
+    return "stardiv.vcl.controlmodel.CheckBox";
 }
 
 uno::Any UnoControlCheckBoxModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
@@ -1312,7 +1312,7 @@ uno::Any UnoControlCheckBoxModel::ImplGetDefaultValue( sal_uInt16 nPropId ) cons
     switch ( nPropId )
     {
     case BASEPROPERTY_DEFAULTCONTROL:
-        return uno::makeAny( OUString::createFromAscii( szServiceName_UnoControlCheckBox ) );
+        return uno::makeAny( OUString( "stardiv.vcl.control.CheckBox" ) );
 
     case BASEPROPERTY_VISUALEFFECT:
         return uno::makeAny( sal_Int16(awt::VisualEffect::LOOK3D) );
@@ -1714,7 +1714,7 @@ uno::Any UnoControlFixedTextModel::ImplGetDefaultValue( sal_uInt16 nPropId ) con
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any( OUString::createFromAscii( szServiceName_UnoControlFixedText ) );
+        return uno::Any( OUString( "stardiv.vcl.control.FixedText" ) );
     }
     else if ( nPropId == BASEPROPERTY_BORDER )
     {
@@ -1884,14 +1884,14 @@ UnoControlGroupBoxModel::UnoControlGroupBoxModel( const Reference< XComponentCon
 
 OUString UnoControlGroupBoxModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlGroupBoxModel );
+    return "stardiv.vcl.controlmodel.GroupBox";
 }
 
 uno::Any UnoControlGroupBoxModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any(OUString::createFromAscii( szServiceName_UnoControlGroupBox ) );
+        return uno::Any(OUString( "stardiv.vcl.control.GroupBox" ) );
     }
     return UnoControlModel::ImplGetDefaultValue( nPropId );
 }
@@ -2124,7 +2124,7 @@ css::uno::Sequence<OUString> UnoControlListBoxModel::getSupportedServiceNames()
 
 OUString UnoControlListBoxModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlListBoxModel );
+    return "stardiv.vcl.controlmodel.ListBox";
 }
 
 
@@ -2132,7 +2132,7 @@ uno::Any UnoControlListBoxModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any( OUString::createFromAscii( szServiceName_UnoControlListBox ) );
+        return uno::Any( OUString( "stardiv.vcl.control.ListBox" ) );
     }
     return UnoControlModel::ImplGetDefaultValue( nPropId );
 }
@@ -2983,8 +2983,9 @@ uno::Reference< beans::XPropertySetInfo > UnoControlComboBoxModel::getPropertySe
 
 OUString UnoControlComboBoxModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlComboBoxModel );
+    return "stardiv.vcl.controlmodel.ComboBox";
 }
+
 void SAL_CALL UnoControlComboBoxModel::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const uno::Any& rValue )
 {
     UnoControlModel::setFastPropertyValue_NoBroadcast( nHandle, rValue );
@@ -3021,7 +3022,7 @@ uno::Any UnoControlComboBoxModel::ImplGetDefaultValue( sal_uInt16 nPropId ) cons
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any( OUString::createFromAscii( szServiceName_UnoControlComboBox ) );
+        return uno::Any( OUString( "stardiv.vcl.control.ComboBox" ) );
     }
     return UnoControlModel::ImplGetDefaultValue( nPropId );
 }
@@ -3459,14 +3460,14 @@ UnoControlDateFieldModel::UnoControlDateFieldModel( const Reference< XComponentC
 
 OUString UnoControlDateFieldModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlDateFieldModel );
+    return "stardiv.vcl.controlmodel.DateField";
 }
 
 uno::Any UnoControlDateFieldModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any( OUString::createFromAscii( szServiceName_UnoControlDateField ) );
+        return uno::Any( OUString( "stardiv.vcl.control.DateField" ) );
     }
     return UnoControlModel::ImplGetDefaultValue( nPropId );
 }
@@ -3734,14 +3735,14 @@ UnoControlTimeFieldModel::UnoControlTimeFieldModel( const Reference< XComponentC
 
 OUString UnoControlTimeFieldModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlTimeFieldModel );
+    return "stardiv.vcl.controlmodel.TimeField";
 }
 
 uno::Any UnoControlTimeFieldModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any( OUString::createFromAscii( szServiceName_UnoControlTimeField ) );
+        return uno::Any( OUString( "stardiv.vcl.control.TimeField" ) );
     }
     return UnoControlModel::ImplGetDefaultValue( nPropId );
 }
@@ -3968,14 +3969,14 @@ UnoControlNumericFieldModel::UnoControlNumericFieldModel( const Reference< XComp
 
 OUString UnoControlNumericFieldModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlNumericFieldModel );
+    return "stardiv.vcl.controlmodel.NumericField";
 }
 
 uno::Any UnoControlNumericFieldModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any( OUString::createFromAscii( szServiceName_UnoControlNumericField ) );
+        return uno::Any( OUString( "stardiv.vcl.control.NumericField" ) );
     }
     return UnoControlModel::ImplGetDefaultValue( nPropId );
 }
@@ -4193,14 +4194,14 @@ UnoControlCurrencyFieldModel::UnoControlCurrencyFieldModel( const Reference< XCo
 
 OUString UnoControlCurrencyFieldModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlCurrencyFieldModel );
+    return "stardiv.vcl.controlmodel.CurrencyField";
 }
 
 uno::Any UnoControlCurrencyFieldModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any( OUString::createFromAscii( szServiceName_UnoControlCurrencyField ) );
+        return uno::Any( OUString( "stardiv.vcl.control.CurrencyField" ) );
     }
     if ( nPropId == BASEPROPERTY_CURSYM_POSITION )
     {
@@ -4422,14 +4423,14 @@ UnoControlPatternFieldModel::UnoControlPatternFieldModel( const Reference< XComp
 
 OUString UnoControlPatternFieldModel::getServiceName()
 {
-    return OUString::createFromAscii( szServiceName_UnoControlPatternFieldModel );
+    return "stardiv.vcl.controlmodel.PatternField";
 }
 
 uno::Any UnoControlPatternFieldModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any( OUString::createFromAscii( szServiceName_UnoControlPatternField ) );
+        return uno::Any( OUString( "stardiv.vcl.control.PatternField" ) );
     }
     return UnoControlModel::ImplGetDefaultValue( nPropId );
 }
@@ -4604,14 +4605,14 @@ UnoControlProgressBarModel::UnoControlProgressBarModel( const Reference< XCompon
 
 OUString UnoControlProgressBarModel::getServiceName( )
 {
-    return OUString::createFromAscii( szServiceName_UnoControlProgressBarModel );
+    return "stardiv.vcl.controlmodel.ProgressBar";
 }
 
 uno::Any UnoControlProgressBarModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any( OUString::createFromAscii( szServiceName_UnoControlProgressBar ) );
+        return uno::Any( OUString( "stardiv.vcl.control.ProgressBar" ) );
     }
 
     return UnoControlModel::ImplGetDefaultValue( nPropId );
@@ -4770,14 +4771,14 @@ UnoControlFixedLineModel::UnoControlFixedLineModel( const Reference< XComponentC
 
 OUString UnoControlFixedLineModel::getServiceName( )
 {
-    return OUString::createFromAscii( szServiceName_UnoControlFixedLineModel );
+    return "stardiv.vcl.controlmodel.FixedLine";
 }
 
 uno::Any UnoControlFixedLineModel::ImplGetDefaultValue( sal_uInt16 nPropId ) const
 {
     if ( nPropId == BASEPROPERTY_DEFAULTCONTROL )
     {
-        return uno::Any( OUString::createFromAscii( szServiceName_UnoControlFixedLine ) );
+        return uno::Any( OUString( "stardiv.vcl.control.FixedLine" ) );
     }
     return UnoControlModel::ImplGetDefaultValue( nPropId );
 }
diff --git a/toolkit/source/helper/servicenames.cxx b/toolkit/source/helper/servicenames.cxx
index 49c5c4d69838..e7b7d7b18991 100644
--- a/toolkit/source/helper/servicenames.cxx
+++ b/toolkit/source/helper/servicenames.cxx
@@ -20,78 +20,6 @@
 #include <sal/types.h>
 #include <helper/servicenames.hxx>
 
-const char szServiceName_Toolkit[] = "stardiv.vcl.VclToolkit";
-const char szServiceName2_Toolkit[] = "com.sun.star.awt.Toolkit";
-const char szServiceName_PopupMenu[] = "stardiv.vcl.PopupMenu";
-const char szServiceName2_PopupMenu[] = "com.sun.star.awt.PopupMenu";
-const char szServiceName_MenuBar[] = "stardiv.vcl.MenuBar";
-const char szServiceName2_MenuBar[] = "com.sun.star.awt.MenuBar";
-const char szServiceName_Pointer[] = "stardiv.vcl.Pointer";
-const char szServiceName2_Pointer[] = "com.sun.star.awt.Pointer";
-const char szServiceName_UnoControlContainer[] = "stardiv.vcl.control.ControlContainer";
-const char szServiceName_UnoControlContainerModel[] = "stardiv.vcl.controlmodel.ControlContainer";
-const char szServiceName_TabController[] = "stardiv.vcl.control.TabController";
-const char szServiceName2_TabController[] = "com.sun.star.awt.TabController";
-const char szServiceName_TabControllerModel[] = "stardiv.vcl.controlmodel.TabController";
-const char szServiceName2_TabControllerModel[] = "com.sun.star.awt.TabControllerModel";
 const char szServiceName_UnoControlDialog[] = "stardiv.vcl.control.Dialog";
-const char szServiceName2_UnoControlDialog[] = "com.sun.star.awt.UnoControlDialog";
-const char szServiceName_UnoControlDialogModel[] = "stardiv.vcl.controlmodel.Dialog";
-const char szServiceName2_UnoControlDialogModel[] = "com.sun.star.awt.UnoControlDialogModel";
-const char szServiceName_UnoControlEdit[] = "stardiv.vcl.control.Edit";
-const char szServiceName2_UnoControlEdit[] = "com.sun.star.awt.UnoControlEdit";
-const char szServiceName_UnoControlEditModel[] = "stardiv.vcl.controlmodel.Edit";
-const char szServiceName_UnoControlFileControl[] = "stardiv.vcl.control.FileControl";
-const char szServiceName_UnoControlFileControlModel[] = "stardiv.vcl.controlmodel.FileControl";
-const char szServiceName_UnoControlButton[] = "stardiv.vcl.control.Button";
-const char szServiceName_UnoControlButtonModel[] = "stardiv.vcl.controlmodel.Button";
-const char szServiceName_UnoControlImageButton[] = "stardiv.vcl.control.ImageButton";
-const char szServiceName2_UnoControlImageButton[] = "com.sun.star.awt.UnoControlImageButton";
-const char szServiceName_UnoControlImageButtonModel[] = "stardiv.vcl.controlmodel.ImageButton";
-const char szServiceName2_UnoControlImageButtonModel[] = "com.sun.star.awt.UnoControlImageButtonModel";
-const char szServiceName_UnoControlImageControl[] = "stardiv.vcl.control.ImageControl";
-const char szServiceName_UnoControlImageControlModel[] = "stardiv.vcl.controlmodel.ImageControl";
-const char szServiceName_UnoControlRadioButton[] = "stardiv.vcl.control.RadioButton";
-const char szServiceName_UnoControlRadioButtonModel[] = "stardiv.vcl.controlmodel.RadioButton";
-const char szServiceName_UnoControlCheckBox[] = "stardiv.vcl.control.CheckBox";
-const char szServiceName_UnoControlCheckBoxModel[] = "stardiv.vcl.controlmodel.CheckBox";
-const char szServiceName_UnoControlListBox[] = "stardiv.vcl.control.ListBox";
-const char szServiceName_UnoControlListBoxModel[] = "stardiv.vcl.controlmodel.ListBox";
-const char szServiceName_UnoControlComboBox[] = "stardiv.vcl.control.ComboBox";
-const char szServiceName_UnoControlComboBoxModel[] = "stardiv.vcl.controlmodel.ComboBox";
-const char szServiceName_UnoControlFixedText[] = "stardiv.vcl.control.FixedText";
-const char szServiceName_UnoControlGroupBox[] = "stardiv.vcl.control.GroupBox";
-const char szServiceName_UnoControlGroupBoxModel[] = "stardiv.vcl.controlmodel.GroupBox";
-const char szServiceName_UnoControlDateField[] = "stardiv.vcl.control.DateField";
-const char szServiceName_UnoControlDateFieldModel[] = "stardiv.vcl.controlmodel.DateField";
-const char szServiceName_UnoControlTimeField[] = "stardiv.vcl.control.TimeField";
-const char szServiceName_UnoControlTimeFieldModel[] = "stardiv.vcl.controlmodel.TimeField";
-const char szServiceName_UnoControlNumericField[] = "stardiv.vcl.control.NumericField";
-const char szServiceName_UnoControlNumericFieldModel[] = "stardiv.vcl.controlmodel.NumericField";
-const char szServiceName_UnoControlCurrencyField[] = "stardiv.vcl.control.CurrencyField";
-const char szServiceName_UnoControlCurrencyFieldModel[] = "stardiv.vcl.controlmodel.CurrencyField";
-const char szServiceName_UnoControlPatternField[] = "stardiv.vcl.control.PatternField";
-const char szServiceName_UnoControlPatternFieldModel[] = "stardiv.vcl.controlmodel.PatternField";
-const char szServiceName_UnoControlFormattedField[] = "stardiv.vcl.control.FormattedField";
-const char szServiceName_UnoControlFormattedFieldModel[] = "stardiv.vcl.controlmodel.FormattedField";
-const char szServiceName_MVCIntrospection[] = "stardiv.vcl.MVCIntrospection";
-const char szServiceName2_MVCIntrospection[] = "com.sun.star.awt.MVCIntrospection";
-const char szServiceName_PrinterServer[] = "stardiv.vcl.PrinterServer";
-const char szServiceName2_PrinterServer[] = "com.sun.star.awt.PrinterServer";
-const char szServiceName_UnoControlProgressBar[] = "stardiv.vcl.control.ProgressBar";
-const char szServiceName_UnoControlProgressBarModel[] = "stardiv.vcl.controlmodel.ProgressBar";
-const char szServiceName_UnoControlScrollBar[] = "stardiv.vcl.control.ScrollBar";
-const char szServiceName_UnoControlScrollBarModel[] = "stardiv.vcl.controlmodel.ScrollBar";
-const char szServiceName_UnoControlFixedLine[] = "stardiv.vcl.control.FixedLine";
-const char szServiceName_UnoControlFixedLineModel[] = "stardiv.vcl.controlmodel.FixedLine";
-const char szServiceName_UnoControlRoadmap[] = "stardiv.vcl.control.Roadmap";
-const char szServiceName_UnoControlRoadmapModel[] = "stardiv.vcl.controlmodel.Roadmap";
-const char szServiceName_UnoSpinButtonControl[] = "com.sun.star.awt.UnoControlSpinButton";
-const char szServiceName_UnoSpinButtonModel[] = "com.sun.star.awt.UnoControlSpinButtonModel";
-const char szServiceName_GridControl[] = "com.sun.star.awt.grid.UnoControlGrid";
-const char szServiceName_DefaultGridDataModel[] = "com.sun.star.awt.grid.DefaultGridDataModel";
-const char szServiceName_DefaultGridColumnModel[] = "com.sun.star.awt.grid.DefaultGridColumnModel";
-const char szServiceName_GridColumn[] = "com.sun.star.awt.grid.GridColumn";
-const char szServiceName_SortableGridDataModel[] = "com.sun.star.awt.grid.SortableGridDataModel";
 
 /* vim:set shiftwidth=4 softtabstop=4 expandtab: */


More information about the Libreoffice-commits mailing list