diff options
Diffstat (limited to 'svx')
-rw-r--r-- | svx/source/fmcomp/fmgridif.cxx | 21 | ||||
-rw-r--r-- | svx/source/form/fmdmod.cxx | 40 | ||||
-rw-r--r-- | svx/source/form/fmundo.cxx | 12 |
3 files changed, 36 insertions, 37 deletions
diff --git a/svx/source/fmcomp/fmgridif.cxx b/svx/source/fmcomp/fmgridif.cxx index fbb6d18f221e..6f40844c9088 100644 --- a/svx/source/fmcomp/fmgridif.cxx +++ b/svx/source/fmcomp/fmgridif.cxx @@ -1594,24 +1594,22 @@ Reference< XIndexContainer > FmXGridPeer::getColumns() throw( RuntimeException, void FmXGridPeer::addColumnListeners(const Reference< XPropertySet >& xCol) { - static const OUString aPropsListenedTo[] = + static const OUStringLiteral aPropsListenedTo[] = { - OUString(FM_PROP_LABEL), OUString(FM_PROP_WIDTH), OUString(FM_PROP_HIDDEN), OUString(FM_PROP_ALIGN), OUString(FM_PROP_FORMATKEY) + OUStringLiteral(FM_PROP_LABEL), OUStringLiteral(FM_PROP_WIDTH), OUStringLiteral(FM_PROP_HIDDEN), + OUStringLiteral(FM_PROP_ALIGN), OUStringLiteral(FM_PROP_FORMATKEY) }; // as not all properties have to be supported by all columns we have to check this // before adding a listener Reference< XPropertySetInfo > xInfo = xCol->getPropertySetInfo(); - Property aPropDesc; - const OUString* pProps = aPropsListenedTo; - const OUString* pPropsEnd = pProps + SAL_N_ELEMENTS( aPropsListenedTo ); - for (; pProps != pPropsEnd; ++pProps) + for (unsigned i=0; i<SAL_N_ELEMENTS(aPropsListenedTo); ++i) { - if ( xInfo->hasPropertyByName( *pProps ) ) + if ( xInfo->hasPropertyByName( aPropsListenedTo[i] ) ) { - aPropDesc = xInfo->getPropertyByName( *pProps ); + Property aPropDesc = xInfo->getPropertyByName( aPropsListenedTo[i] ); if ( 0 != ( aPropDesc.Attributes & PropertyAttribute::BOUND ) ) - xCol->addPropertyChangeListener( *pProps, this ); + xCol->addPropertyChangeListener( aPropsListenedTo[i], this ); } } } @@ -1621,9 +1619,10 @@ void FmXGridPeer::removeColumnListeners(const Reference< XPropertySet >& xCol) { // the same props as in addColumnListeners ... linux has problems with global static UStrings, so // we have to do it this way .... - static const OUString aPropsListenedTo[] = + static const OUStringLiteral aPropsListenedTo[] = { - OUString(FM_PROP_LABEL), OUString(FM_PROP_WIDTH), OUString(FM_PROP_HIDDEN), OUString(FM_PROP_ALIGN), OUString(FM_PROP_FORMATKEY) + OUStringLiteral(FM_PROP_LABEL), OUStringLiteral(FM_PROP_WIDTH), OUStringLiteral(FM_PROP_HIDDEN), + OUStringLiteral(FM_PROP_ALIGN), OUStringLiteral(FM_PROP_FORMATKEY) }; Reference< XPropertySetInfo > xInfo = xCol->getPropertySetInfo(); diff --git a/svx/source/form/fmdmod.cxx b/svx/source/form/fmdmod.cxx index a11a99eaaa1d..3b980e493c45 100644 --- a/svx/source/form/fmdmod.cxx +++ b/svx/source/form/fmdmod.cxx @@ -62,27 +62,27 @@ SAL_WNOUNREACHABLE_CODE_POP ::com::sun::star::uno::Sequence< OUString > SAL_CALL SvxFmMSFactory::getAvailableServiceNames() throw( ::com::sun::star::uno::RuntimeException, std::exception ) { - static const OUString aSvxComponentServiceNameList[] = + static const OUStringLiteral aSvxComponentServiceNameList[] = { - OUString(FM_SUN_COMPONENT_TEXTFIELD), - OUString(FM_SUN_COMPONENT_FORM), - OUString(FM_SUN_COMPONENT_LISTBOX), - OUString(FM_SUN_COMPONENT_COMBOBOX), - OUString(FM_SUN_COMPONENT_RADIOBUTTON), - OUString(FM_SUN_COMPONENT_GROUPBOX), - OUString(FM_SUN_COMPONENT_FIXEDTEXT), - OUString(FM_SUN_COMPONENT_COMMANDBUTTON), - OUString(FM_SUN_COMPONENT_CHECKBOX), - OUString(FM_SUN_COMPONENT_GRIDCONTROL), - OUString(FM_SUN_COMPONENT_IMAGEBUTTON), - OUString(FM_SUN_COMPONENT_FILECONTROL), - OUString(FM_SUN_COMPONENT_TIMEFIELD), - OUString(FM_SUN_COMPONENT_DATEFIELD), - OUString(FM_SUN_COMPONENT_NUMERICFIELD), - OUString(FM_SUN_COMPONENT_CURRENCYFIELD), - OUString(FM_SUN_COMPONENT_PATTERNFIELD), - OUString(FM_SUN_COMPONENT_HIDDENCONTROL), - OUString(FM_SUN_COMPONENT_IMAGECONTROL) + OUStringLiteral(FM_SUN_COMPONENT_TEXTFIELD), + OUStringLiteral(FM_SUN_COMPONENT_FORM), + OUStringLiteral(FM_SUN_COMPONENT_LISTBOX), + OUStringLiteral(FM_SUN_COMPONENT_COMBOBOX), + OUStringLiteral(FM_SUN_COMPONENT_RADIOBUTTON), + OUStringLiteral(FM_SUN_COMPONENT_GROUPBOX), + OUStringLiteral(FM_SUN_COMPONENT_FIXEDTEXT), + OUStringLiteral(FM_SUN_COMPONENT_COMMANDBUTTON), + OUStringLiteral(FM_SUN_COMPONENT_CHECKBOX), + OUStringLiteral(FM_SUN_COMPONENT_GRIDCONTROL), + OUStringLiteral(FM_SUN_COMPONENT_IMAGEBUTTON), + OUStringLiteral(FM_SUN_COMPONENT_FILECONTROL), + OUStringLiteral(FM_SUN_COMPONENT_TIMEFIELD), + OUStringLiteral(FM_SUN_COMPONENT_DATEFIELD), + OUStringLiteral(FM_SUN_COMPONENT_NUMERICFIELD), + OUStringLiteral(FM_SUN_COMPONENT_CURRENCYFIELD), + OUStringLiteral(FM_SUN_COMPONENT_PATTERNFIELD), + OUStringLiteral(FM_SUN_COMPONENT_HIDDENCONTROL), + OUStringLiteral(FM_SUN_COMPONENT_IMAGECONTROL) }; static const sal_uInt16 nSvxComponentServiceNameListCount = SAL_N_ELEMENTS(aSvxComponentServiceNameList); diff --git a/svx/source/form/fmundo.cxx b/svx/source/form/fmundo.cxx index db6162f7d1ac..22476b5e6a46 100644 --- a/svx/source/form/fmundo.cxx +++ b/svx/source/form/fmundo.cxx @@ -535,13 +535,13 @@ void SAL_CALL FmXUndoEnvironment::propertyChange(const PropertyChangeEvent& evt) return; // if it's a "default value" property of a control model, set the according "value" property - static const OUString pDefaultValueProperties[] = { - OUString(FM_PROP_DEFAULT_TEXT), OUString(FM_PROP_DEFAULTCHECKED), OUString(FM_PROP_DEFAULT_DATE), OUString(FM_PROP_DEFAULT_TIME), - OUString(FM_PROP_DEFAULT_VALUE), OUString(FM_PROP_DEFAULT_SELECT_SEQ), OUString(FM_PROP_EFFECTIVE_DEFAULT) + static const OUStringLiteral pDefaultValueProperties[] = { + OUStringLiteral(FM_PROP_DEFAULT_TEXT), OUStringLiteral(FM_PROP_DEFAULTCHECKED), OUStringLiteral(FM_PROP_DEFAULT_DATE), OUStringLiteral(FM_PROP_DEFAULT_TIME), + OUStringLiteral(FM_PROP_DEFAULT_VALUE), OUStringLiteral(FM_PROP_DEFAULT_SELECT_SEQ), OUStringLiteral(FM_PROP_EFFECTIVE_DEFAULT) }; - const OUString aValueProperties[] = { - OUString(FM_PROP_TEXT), OUString(FM_PROP_STATE), OUString(FM_PROP_DATE), OUString(FM_PROP_TIME), - OUString(FM_PROP_VALUE), OUString(FM_PROP_SELECT_SEQ), OUString(FM_PROP_EFFECTIVE_VALUE) + static const OUStringLiteral aValueProperties[] = { + OUStringLiteral(FM_PROP_TEXT), OUStringLiteral(FM_PROP_STATE), OUStringLiteral(FM_PROP_DATE), OUStringLiteral(FM_PROP_TIME), + OUStringLiteral(FM_PROP_VALUE), OUStringLiteral(FM_PROP_SELECT_SEQ), OUStringLiteral(FM_PROP_EFFECTIVE_VALUE) }; sal_Int32 nDefaultValueProps = SAL_N_ELEMENTS(pDefaultValueProperties); OSL_ENSURE(SAL_N_ELEMENTS(aValueProperties) == nDefaultValueProps, |