diff options
author | Caolán McNamara <caolanm@redhat.com> | 2017-04-30 14:58:50 +0100 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2017-04-30 15:18:10 +0100 |
commit | 59676b310bc0eba154f323f5d32ed697fcbb227a (patch) | |
tree | fc38ce10f44b21031902862d3ab2da44966903c9 /basctl | |
parent | 00052c1c4f7285a58a8854d34a9b6b3fd2d5991a (diff) |
untranslated strings are just strings
Change-Id: Ic7247a6d0e702572ca304bb048bfabfafcbf7505
Diffstat (limited to 'basctl')
-rw-r--r-- | basctl/inc/strings.hxx | 41 | ||||
-rw-r--r-- | basctl/source/dlged/dlgedobj.cxx | 55 | ||||
-rw-r--r-- | basctl/source/dlged/dlgresid.src | 95 | ||||
-rw-r--r-- | basctl/source/dlged/propbrw.cxx | 51 | ||||
-rw-r--r-- | basctl/source/inc/dlgresid.hrc | 25 |
5 files changed, 94 insertions, 173 deletions
diff --git a/basctl/inc/strings.hxx b/basctl/inc/strings.hxx new file mode 100644 index 000000000000..ec06daaef937 --- /dev/null +++ b/basctl/inc/strings.hxx @@ -0,0 +1,41 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4; fill-column: 100 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + */ + +#ifndef INCLUDED_BASCTL_INC_STRINGS_HRC +#define INCLUDED_BASCTL_INC_STRINGS_HRC + +// Dialog Controls --------------------------------------------------------------- + +#define RID_STR_CLASS_CONTROL "Control" +#define RID_STR_CLASS_DIALOG "Dialog" +#define RID_STR_CLASS_BUTTON "CommandButton" +#define RID_STR_CLASS_RADIOBUTTON "OptionButton" +#define RID_STR_CLASS_CHECKBOX "CheckBox" +#define RID_STR_CLASS_LISTBOX "ListBox" +#define RID_STR_CLASS_COMBOBOX "ComboBox" +#define RID_STR_CLASS_GROUPBOX "FrameControl" +#define RID_STR_CLASS_EDIT "TextField" +#define RID_STR_CLASS_FIXEDTEXT "Label" +#define RID_STR_CLASS_IMAGECONTROL "ImageControl" +#define RID_STR_CLASS_PROGRESSBAR "ProgressBar" +#define RID_STR_CLASS_SCROLLBAR "ScrollBar" +#define RID_STR_CLASS_FIXEDLINE "FixedLine" +#define RID_STR_CLASS_DATEFIELD "DateField" +#define RID_STR_CLASS_TIMEFIELD "TimeField" +#define RID_STR_CLASS_NUMERICFIELD "NumericField" +#define RID_STR_CLASS_CURRENCYFIELD "CurrencyField" +#define RID_STR_CLASS_FORMATTEDFIELD "FormattedField" +#define RID_STR_CLASS_PATTERNFIELD "PatternField" +#define RID_STR_CLASS_FILECONTROL "FileControl" +#define RID_STR_CLASS_TREECONTROL "TreeControl" +#define RID_STR_CLASS_SPINCONTROL "SpinButton" + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */ diff --git a/basctl/source/dlged/dlgedobj.cxx b/basctl/source/dlged/dlgedobj.cxx index b02f73d7043b..c1ddd5672d51 100644 --- a/basctl/source/dlged/dlgedobj.cxx +++ b/basctl/source/dlged/dlgedobj.cxx @@ -31,6 +31,7 @@ #include "localizationmgr.hxx" #include "dlgresid.hrc" +#include "strings.hxx" #include <com/sun/star/beans/NamedValue.hpp> #include <com/sun/star/form/binding/XBindableValue.hpp> @@ -636,105 +637,103 @@ bool DlgEdObj::supportsService( OUString const & serviceName ) const OUString DlgEdObj::GetDefaultName() const { - sal_uInt16 nResId = 0; + OUString sResId; OUString aDefaultName; if ( supportsService( "com.sun.star.awt.UnoControlDialogModel" ) ) { - nResId = RID_STR_CLASS_DIALOG; + sResId = RID_STR_CLASS_DIALOG; } else if ( supportsService( "com.sun.star.awt.UnoControlButtonModel" ) ) { - nResId = RID_STR_CLASS_BUTTON; + sResId = RID_STR_CLASS_BUTTON; } else if ( supportsService( "com.sun.star.awt.UnoControlRadioButtonModel" ) ) { - nResId = RID_STR_CLASS_RADIOBUTTON; + sResId = RID_STR_CLASS_RADIOBUTTON; } else if ( supportsService( "com.sun.star.awt.UnoControlCheckBoxModel" ) ) { - nResId = RID_STR_CLASS_CHECKBOX; + sResId = RID_STR_CLASS_CHECKBOX; } else if ( supportsService( "com.sun.star.awt.UnoControlListBoxModel" ) ) { - nResId = RID_STR_CLASS_LISTBOX; + sResId = RID_STR_CLASS_LISTBOX; } else if ( supportsService( "com.sun.star.awt.UnoControlComboBoxModel" ) ) { - nResId = RID_STR_CLASS_COMBOBOX; + sResId = RID_STR_CLASS_COMBOBOX; } else if ( supportsService( "com.sun.star.awt.UnoControlGroupBoxModel" ) ) { - nResId = RID_STR_CLASS_GROUPBOX; + sResId = RID_STR_CLASS_GROUPBOX; } else if ( supportsService( "com.sun.star.awt.UnoControlEditModel" ) ) { - nResId = RID_STR_CLASS_EDIT; + sResId = RID_STR_CLASS_EDIT; } else if ( supportsService( "com.sun.star.awt.UnoControlFixedTextModel" ) ) { - nResId = RID_STR_CLASS_FIXEDTEXT; + sResId = RID_STR_CLASS_FIXEDTEXT; } else if ( supportsService( "com.sun.star.awt.UnoControlImageControlModel" ) ) { - nResId = RID_STR_CLASS_IMAGECONTROL; + sResId = RID_STR_CLASS_IMAGECONTROL; } else if ( supportsService( "com.sun.star.awt.UnoControlProgressBarModel" ) ) { - nResId = RID_STR_CLASS_PROGRESSBAR; + sResId = RID_STR_CLASS_PROGRESSBAR; } else if ( supportsService( "com.sun.star.awt.UnoControlScrollBarModel" ) ) { - nResId = RID_STR_CLASS_SCROLLBAR; + sResId = RID_STR_CLASS_SCROLLBAR; } else if ( supportsService( "com.sun.star.awt.UnoControlFixedLineModel" ) ) { - nResId = RID_STR_CLASS_FIXEDLINE; + sResId = RID_STR_CLASS_FIXEDLINE; } else if ( supportsService( "com.sun.star.awt.UnoControlDateFieldModel" ) ) { - nResId = RID_STR_CLASS_DATEFIELD; + sResId = RID_STR_CLASS_DATEFIELD; } else if ( supportsService( "com.sun.star.awt.UnoControlTimeFieldModel" ) ) { - nResId = RID_STR_CLASS_TIMEFIELD; + sResId = RID_STR_CLASS_TIMEFIELD; } else if ( supportsService( "com.sun.star.awt.UnoControlNumericFieldModel" ) ) { - nResId = RID_STR_CLASS_NUMERICFIELD; + sResId = RID_STR_CLASS_NUMERICFIELD; } else if ( supportsService( "com.sun.star.awt.UnoControlCurrencyFieldModel" ) ) { - nResId = RID_STR_CLASS_CURRENCYFIELD; + sResId = RID_STR_CLASS_CURRENCYFIELD; } else if ( supportsService( "com.sun.star.awt.UnoControlFormattedFieldModel" ) ) { - nResId = RID_STR_CLASS_FORMATTEDFIELD; + sResId = RID_STR_CLASS_FORMATTEDFIELD; } else if ( supportsService( "com.sun.star.awt.UnoControlPatternFieldModel" ) ) { - nResId = RID_STR_CLASS_PATTERNFIELD; + sResId = RID_STR_CLASS_PATTERNFIELD; } else if ( supportsService( "com.sun.star.awt.UnoControlFileControlModel" ) ) { - nResId = RID_STR_CLASS_FILECONTROL; + sResId = RID_STR_CLASS_FILECONTROL; } else if ( supportsService( "com.sun.star.awt.tree.TreeControlModel" ) ) { - nResId = RID_STR_CLASS_TREECONTROL; + sResId = RID_STR_CLASS_TREECONTROL; } else if ( supportsService( "com.sun.star.awt.UnoControlSpinButtonModel" ) ) { - nResId = RID_STR_CLASS_SPINCONTROL; + sResId = RID_STR_CLASS_SPINCONTROL; } else { - nResId = RID_STR_CLASS_CONTROL; + sResId = RID_STR_CLASS_CONTROL; } - if (nResId) - { - aDefaultName = IDE_RESSTR(nResId); - } + if (!sResId.isEmpty()) + aDefaultName = sResId; return aDefaultName; } diff --git a/basctl/source/dlged/dlgresid.src b/basctl/source/dlged/dlgresid.src index c4c6601ddc27..445250513f53 100644 --- a/basctl/source/dlged/dlgresid.src +++ b/basctl/source/dlged/dlgresid.src @@ -19,101 +19,6 @@ #include "dlgresid.hrc" -// Dialog Controls --------------------------------------------------------------- - -String RID_STR_CLASS_CONTROL -{ - Text = "Control" ; -}; -String RID_STR_CLASS_DIALOG -{ - Text = "Dialog" ; -}; -String RID_STR_CLASS_BUTTON -{ - Text = "CommandButton" ; -}; -String RID_STR_CLASS_RADIOBUTTON -{ - Text = "OptionButton" ; -}; -String RID_STR_CLASS_CHECKBOX -{ - Text = "CheckBox" ; -}; -String RID_STR_CLASS_LISTBOX -{ - Text = "ListBox" ; -}; -String RID_STR_CLASS_COMBOBOX -{ - Text = "ComboBox" ; -}; -String RID_STR_CLASS_GROUPBOX -{ - Text = "FrameControl" ; -}; -String RID_STR_CLASS_EDIT -{ - Text = "TextField" ; -}; -String RID_STR_CLASS_FIXEDTEXT -{ - Text = "Label" ; -}; -String RID_STR_CLASS_IMAGECONTROL -{ - Text = "ImageControl" ; -}; -String RID_STR_CLASS_PROGRESSBAR -{ - Text = "ProgressBar" ; -}; -String RID_STR_CLASS_SCROLLBAR -{ - Text = "ScrollBar" ; -}; -String RID_STR_CLASS_FIXEDLINE -{ - Text = "FixedLine" ; -}; -String RID_STR_CLASS_DATEFIELD -{ - Text = "DateField" ; -}; -String RID_STR_CLASS_TIMEFIELD -{ - Text = "TimeField" ; -}; -String RID_STR_CLASS_NUMERICFIELD -{ - Text = "NumericField" ; -}; -String RID_STR_CLASS_CURRENCYFIELD -{ - Text = "CurrencyField" ; -}; -String RID_STR_CLASS_FORMATTEDFIELD -{ - Text = "FormattedField" ; -}; -String RID_STR_CLASS_PATTERNFIELD -{ - Text = "PatternField" ; -}; -String RID_STR_CLASS_FILECONTROL -{ - Text = "FileControl" ; -}; -String RID_STR_CLASS_TREECONTROL -{ - Text = "TreeControl" ; -}; -String RID_STR_CLASS_SPINCONTROL -{ - Text = "SpinButton" ; -}; - // Property Browser Headline ---------------------------------------------------------------- String RID_STR_BRWTITLE_PROPERTIES diff --git a/basctl/source/dlged/propbrw.cxx b/basctl/source/dlged/propbrw.cxx index c4b5d3d34756..ab46f11eda50 100644 --- a/basctl/source/dlged/propbrw.cxx +++ b/basctl/source/dlged/propbrw.cxx @@ -25,6 +25,7 @@ #include "baside3.hxx" #include "dlgresid.hrc" +#include "strings.hxx" #include <svx/svxids.hrc> #include <com/sun/star/awt/PosSize.hpp> @@ -312,101 +313,101 @@ OUString PropBrw::GetHeadlineName( const Reference< XPropertySet >& _rxObject ) if (xServiceInfo.is()) // single selection { - sal_uInt16 nResId = 0; + OUString sResId; aName = IDE_RESSTR(RID_STR_BRWTITLE_PROPERTIES); if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlDialogModel" ) ) { - nResId = RID_STR_CLASS_DIALOG; + sResId = RID_STR_CLASS_DIALOG; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlButtonModel" ) ) { - nResId = RID_STR_CLASS_BUTTON; + sResId = RID_STR_CLASS_BUTTON; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlRadioButtonModel" ) ) { - nResId = RID_STR_CLASS_RADIOBUTTON; + sResId = RID_STR_CLASS_RADIOBUTTON; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlCheckBoxModel" ) ) { - nResId = RID_STR_CLASS_CHECKBOX; + sResId = RID_STR_CLASS_CHECKBOX; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlListBoxModel" ) ) { - nResId = RID_STR_CLASS_LISTBOX; + sResId = RID_STR_CLASS_LISTBOX; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlComboBoxModel" ) ) { - nResId = RID_STR_CLASS_COMBOBOX; + sResId = RID_STR_CLASS_COMBOBOX; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlGroupBoxModel" ) ) { - nResId = RID_STR_CLASS_GROUPBOX; + sResId = RID_STR_CLASS_GROUPBOX; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlEditModel" ) ) { - nResId = RID_STR_CLASS_EDIT; + sResId = RID_STR_CLASS_EDIT; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlFixedTextModel" ) ) { - nResId = RID_STR_CLASS_FIXEDTEXT; + sResId = RID_STR_CLASS_FIXEDTEXT; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlImageControlModel" ) ) { - nResId = RID_STR_CLASS_IMAGECONTROL; + sResId = RID_STR_CLASS_IMAGECONTROL; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlProgressBarModel" ) ) { - nResId = RID_STR_CLASS_PROGRESSBAR; + sResId = RID_STR_CLASS_PROGRESSBAR; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlScrollBarModel" ) ) { - nResId = RID_STR_CLASS_SCROLLBAR; + sResId = RID_STR_CLASS_SCROLLBAR; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlFixedLineModel" ) ) { - nResId = RID_STR_CLASS_FIXEDLINE; + sResId = RID_STR_CLASS_FIXEDLINE; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlDateFieldModel" ) ) { - nResId = RID_STR_CLASS_DATEFIELD; + sResId = RID_STR_CLASS_DATEFIELD; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlTimeFieldModel" ) ) { - nResId = RID_STR_CLASS_TIMEFIELD; + sResId = RID_STR_CLASS_TIMEFIELD; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlNumericFieldModel" ) ) { - nResId = RID_STR_CLASS_NUMERICFIELD; + sResId = RID_STR_CLASS_NUMERICFIELD; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlCurrencyFieldModel" ) ) { - nResId = RID_STR_CLASS_CURRENCYFIELD; + sResId = RID_STR_CLASS_CURRENCYFIELD; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlFormattedFieldModel" ) ) { - nResId = RID_STR_CLASS_FORMATTEDFIELD; + sResId = RID_STR_CLASS_FORMATTEDFIELD; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlPatternFieldModel" ) ) { - nResId = RID_STR_CLASS_PATTERNFIELD; + sResId = RID_STR_CLASS_PATTERNFIELD; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.UnoControlFileControlModel" ) ) { - nResId = RID_STR_CLASS_FILECONTROL; + sResId = RID_STR_CLASS_FILECONTROL; } else if ( xServiceInfo->supportsService( "com.sun.star.awt.tree.TreeControlModel" ) ) { - nResId = RID_STR_CLASS_TREECONTROL; + sResId = RID_STR_CLASS_TREECONTROL; } else { - nResId = RID_STR_CLASS_CONTROL; + sResId = RID_STR_CLASS_CONTROL; } - if (nResId) + if (!sResId.isEmpty()) { - aName += IDE_RESSTR(nResId); + aName += sResId; } } else if (!_rxObject.is()) // no properties diff --git a/basctl/source/inc/dlgresid.hrc b/basctl/source/inc/dlgresid.hrc index a6b1fc9829ef..3dc8a184920b 100644 --- a/basctl/source/inc/dlgresid.hrc +++ b/basctl/source/inc/dlgresid.hrc @@ -22,33 +22,8 @@ #include <svl/solar.hrc> -// Dialog Control Id's ----------------------------------------------------------- - -#define RID_STR_CLASS_CONTROL ( RID_DLG_START + 0 ) -#define RID_STR_CLASS_DIALOG ( RID_DLG_START + 1 ) -#define RID_STR_CLASS_BUTTON ( RID_DLG_START + 2 ) -#define RID_STR_CLASS_RADIOBUTTON ( RID_DLG_START + 3 ) -#define RID_STR_CLASS_CHECKBOX ( RID_DLG_START + 4 ) -#define RID_STR_CLASS_LISTBOX ( RID_DLG_START + 5 ) -#define RID_STR_CLASS_COMBOBOX ( RID_DLG_START + 6 ) -#define RID_STR_CLASS_GROUPBOX ( RID_DLG_START + 7 ) -#define RID_STR_CLASS_EDIT ( RID_DLG_START + 8 ) -#define RID_STR_CLASS_FIXEDTEXT ( RID_DLG_START + 9 ) -#define RID_STR_CLASS_IMAGECONTROL ( RID_DLG_START + 10 ) -#define RID_STR_CLASS_PROGRESSBAR ( RID_DLG_START + 11 ) -#define RID_STR_CLASS_SCROLLBAR ( RID_DLG_START + 12 ) -#define RID_STR_CLASS_FIXEDLINE ( RID_DLG_START + 13 ) -#define RID_STR_CLASS_DATEFIELD ( RID_DLG_START + 14 ) -#define RID_STR_CLASS_TIMEFIELD ( RID_DLG_START + 15 ) -#define RID_STR_CLASS_NUMERICFIELD ( RID_DLG_START + 16 ) -#define RID_STR_CLASS_CURRENCYFIELD ( RID_DLG_START + 17 ) -#define RID_STR_CLASS_FORMATTEDFIELD ( RID_DLG_START + 18 ) -#define RID_STR_CLASS_PATTERNFIELD ( RID_DLG_START + 19 ) -#define RID_STR_CLASS_FILECONTROL ( RID_DLG_START + 20 ) #define RID_STR_TRANSLATION_NOTLOCALIZED ( RID_DLG_START + 21 ) #define RID_STR_TRANSLATION_DEFAULT ( RID_DLG_START + 22 ) -#define RID_STR_CLASS_TREECONTROL ( RID_DLG_START + 23 ) -#define RID_STR_CLASS_SPINCONTROL ( RID_DLG_START + 24 ) #define RID_STR_DEF_LANG ( RID_DLG_START + 25 ) #define RID_STR_CREATE_LANG ( RID_DLG_START + 26 ) |