diff options
author | Maxim Monastirsky <momonasmon@gmail.com> | 2016-12-28 15:51:17 +0200 |
---|---|---|
committer | Maxim Monastirsky <momonasmon@gmail.com> | 2017-01-05 00:11:28 +0200 |
commit | a487e548a0e8c40320cd44b2c7779787e9c0f860 (patch) | |
tree | b2cc7340ad9a39aee08cda4136a0cd63e68fedfa | |
parent | 23a13694a5a70098b5ecd58b99d99618111f3ea5 (diff) |
Use command labels for the color popup title
Change-Id: I2f61e25ef4451775320f8fa1761a951ab94af7d5
-rw-r--r-- | include/svx/dialogs.hrc | 10 | ||||
-rw-r--r-- | svx/source/tbxctrls/extrusioncontrols.src | 5 | ||||
-rw-r--r-- | svx/source/tbxctrls/tbcontrl.cxx | 35 | ||||
-rw-r--r-- | svx/source/tbxctrls/tbcontrl.src | 30 |
4 files changed, 2 insertions, 78 deletions
diff --git a/include/svx/dialogs.hrc b/include/svx/dialogs.hrc index 437db0331745..64fee58d3e7b 100644 --- a/include/svx/dialogs.hrc +++ b/include/svx/dialogs.hrc @@ -243,16 +243,12 @@ // Strings of the ToolBox-Controls from tbcontrl.cxx #define RID_SVXSTR_FILLPATTERN (RID_SVX_START + 191) #define RID_SVXSTR_FRAME (RID_SVX_START + 192) -#define RID_SVXSTR_FRAME_COLOR (RID_SVX_START + 194) #define RID_SVXSTR_FRAME_STYLE (RID_SVX_START + 195) -#define RID_SVXSTR_EXTRAS_CHARBACKGROUND (RID_SVX_START + 196) #define RID_SVXSTR_CLEARFORM (RID_SVX_START + 197) #define RID_SVXSTR_MORE (RID_SVX_START + 198) #define RID_SVXSTR_CHARFONTNAME_NOTAVAILABLE (RID_SVX_START + 199) #define RID_SVXSTR_CHARFONTNAME (RID_SVX_START + 200) -#define RID_SVXSTR_LINECOLOR (RID_SVX_START + 201) #define RID_SVXSTR_MORE_STYLES (RID_SVX_START + 202) -#define RID_SVXSTR_FILLCOLOR (RID_SVX_START + 203) #define RID_SVXSTR_MORENUMBERING (RID_SVX_START + 204) #define RID_SVXSTR_MOREBULLETS (RID_SVX_START + 205) @@ -384,8 +380,6 @@ #define STR_INSERT_SOUND_TITLE (RID_SVX_START + 529) #define STR_INSERT_VIDEO_TITLE (RID_SVX_START + 530) -#define RID_SVXSTR_BACKGROUND (RID_SVX_START + 531) - #define RID_SVXIMG_WIRE_FRAME (RID_SVX_START + 532) #define RID_SVXIMG_MATTE (RID_SVX_START + 533) #define RID_SVXIMG_PLASTIC (RID_SVX_START + 534) @@ -885,8 +879,6 @@ #define RID_SVX_EXTRUSION_BAR (RID_SVX_START + 986) #define RID_SVX_FONTWORK_BAR (RID_SVX_START + 987) -#define RID_SVXSTR_EXTRUSION_COLOR (RID_SVX_START + 991) - #define RID_SVXSTR_DEPTH_0 (RID_SVX_START + 992) #define RID_SVXSTR_DEPTH_1 (RID_SVX_START + 993) #define RID_SVXSTR_DEPTH_2 (RID_SVX_START + 994) @@ -949,8 +941,6 @@ #define RID_SVXSTR_OUTLINENUM_DESCRIPTION_6 (RID_SVXSTR_OUTLINENUM_DESCRIPTIONS + 6)//? #define RID_SVXSTR_OUTLINENUM_DESCRIPTION_7 (RID_SVXSTR_OUTLINENUM_DESCRIPTIONS + 7)//? -#define RID_SVXSTR_TEXTCOLOR (RID_SVX_START + 1178) - #define RID_SVXSTR_FINDBAR_SEARCHFORMATTED (RID_SVX_START + 1188) #define RID_SVXSTR_FINDBAR_MATCHCASE (RID_SVX_START + 1189) #define RID_SVXSTR_FINDBAR_FIND (RID_SVX_START + 1190) diff --git a/svx/source/tbxctrls/extrusioncontrols.src b/svx/source/tbxctrls/extrusioncontrols.src index 7dfc57d99bda..8760914079e7 100644 --- a/svx/source/tbxctrls/extrusioncontrols.src +++ b/svx/source/tbxctrls/extrusioncontrols.src @@ -355,11 +355,6 @@ Image RID_SVXIMG_DEPTH_INFINITY ImageBitmap = Bitmap { File = "extrusioninfinity_16.bmp"; }; }; -String RID_SVXSTR_EXTRUSION_COLOR -{ - Text [ en-US ] = "Extrusion Color"; -}; - String RID_SVXSTR_DEPTH_0 { Text [ en-US ] = "~0 cm"; diff --git a/svx/source/tbxctrls/tbcontrl.cxx b/svx/source/tbxctrls/tbcontrl.cxx index fcbbd75ebdb2..bacad8901fd7 100644 --- a/svx/source/tbxctrls/tbcontrl.cxx +++ b/svx/source/tbxctrls/tbcontrl.cxx @@ -25,6 +25,7 @@ #include <svl/poolitem.hxx> #include <svl/eitem.hxx> #include <svl/itemset.hxx> +#include <vcl/commandinfoprovider.hxx> #include <vcl/toolbox.hxx> #include <vcl/bitmapaccess.hxx> #include <vcl/menubtn.hxx> @@ -1309,39 +1310,7 @@ SvxColorWindow::SvxColorWindow(const OUString& rCommand, } } - OUString aWindowTitle; - switch ( theSlotId ) - { - case SID_ATTR_CHAR_COLOR: - case SID_ATTR_CHAR_COLOR2: - aWindowTitle = SVX_RESSTR( RID_SVXSTR_TEXTCOLOR ); - break; - - case SID_ATTR_CHAR_COLOR_BACKGROUND: - case SID_ATTR_CHAR_BACK_COLOR: - aWindowTitle = SVX_RESSTR( RID_SVXSTR_EXTRAS_CHARBACKGROUND ); - break; - - case SID_BACKGROUND_COLOR: - aWindowTitle = SVX_RESSTR( RID_SVXSTR_BACKGROUND ); - break; - - case SID_FRAME_LINECOLOR: - aWindowTitle = SVX_RESSTR( RID_SVXSTR_FRAME_COLOR ); - break; - - case SID_EXTRUSION_3D_COLOR: - aWindowTitle = SVX_RESSTR( RID_SVXSTR_EXTRUSION_COLOR ); - break; - - case SID_ATTR_LINE_COLOR: - aWindowTitle = SVX_RESSTR( RID_SVXSTR_LINECOLOR ); - break; - - case SID_ATTR_FILL_COLOR: - aWindowTitle = SVX_RESSTR( RID_SVXSTR_FILLCOLOR ); - break; - } + OUString aWindowTitle = vcl::CommandInfoProvider::Instance().GetLabelForCommand( rCommand, rFrame ); SetText( aWindowTitle ); mpColorSet->SetAccessibleName( aWindowTitle ); diff --git a/svx/source/tbxctrls/tbcontrl.src b/svx/source/tbxctrls/tbcontrl.src index c8447b2562a0..f0c92ff10a46 100644 --- a/svx/source/tbxctrls/tbcontrl.src +++ b/svx/source/tbxctrls/tbcontrl.src @@ -119,21 +119,6 @@ String RID_SVXSTR_FRAME_STYLE Text [ en-US ] = "Border Style" ; }; -String RID_SVXSTR_FRAME_COLOR -{ - Text [ en-US ] = "Border Color" ; -}; - -String RID_SVXSTR_LINECOLOR -{ - Text [ en-US ] = "Line Color" ; -}; - -String RID_SVXSTR_FILLCOLOR -{ - Text [ en-US ] = "Fill Color" ; -}; - String RID_SVXSTR_MORENUMBERING { Text [ en-US ] = "More Numbering..." ; @@ -178,16 +163,6 @@ Menu RID_SVX_PRESET_MENU }; }; -String RID_SVXSTR_EXTRAS_CHARBACKGROUND -{ - Text [ en-US ] = "Highlight Color" ; -}; - -String RID_SVXSTR_BACKGROUND -{ - Text [ en-US ] = "Background"; -}; - String RID_SVXSTR_AUTOMATIC { Text [ en-US ] = "Automatic"; @@ -247,11 +222,6 @@ String RID_SVXSTR_MORE Text [ en-US ] = "More Options..."; }; -String RID_SVXSTR_TEXTCOLOR -{ - Text [ en-US ] = "Font color"; -}; - // This is duplicated in GenericCommands.xcu in officecfg. String RID_SVXSTR_CHARFONTNAME { |