diff options
author | Noel Grandin <noel@peralex.com> | 2014-10-14 09:36:33 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2014-10-15 10:13:04 +0000 |
commit | d9fa1247be9d3a3d559adbbf9e1ed12395744738 (patch) | |
tree | 20fb4e43af4c94760b290d62ad3a6ac581665bf1 /rsc | |
parent | d7a0916e68238d619d74cbab72e66980e24d2f48 (diff) |
fdo#84938: replace SYMBOL_TYPE constants with enum
Change-Id: Ib3763f20d74c22e28d519a9ac47f6f3ab4e31f51
Reviewed-on: https://gerrit.libreoffice.org/11983
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'rsc')
-rw-r--r-- | rsc/inc/rscdb.hxx | 2 | ||||
-rw-r--r-- | rsc/source/parser/rscicpx.cxx | 48 |
2 files changed, 26 insertions, 24 deletions
diff --git a/rsc/inc/rscdb.hxx b/rsc/inc/rscdb.hxx index 74e46e425eb7..c4bc2fe4ffc4 100644 --- a/rsc/inc/rscdb.hxx +++ b/rsc/inc/rscdb.hxx @@ -28,6 +28,7 @@ #include <rscstr.hxx> #include <rscarray.hxx> #include <rscdef.hxx> +#include <rsc/rsc-vcl-shared-types.hxx> #include <vector> #include <map> @@ -138,6 +139,7 @@ class RscTypCont void Init(); // Initialisiert Klassen und Tabelle void SETCONST( RscConst *, const char *, sal_uInt32 ); + inline void SETCONST( RscConst *p1, const char * p2, SymbolType p3 ) { SETCONST(p1, p2, static_cast<sal_uInt32>(p3)); } void SETCONST( RscConst *, Atom, sal_uInt32 ); RscEnum * InitLangType(); RscEnum * InitFieldUnitsType(); diff --git a/rsc/source/parser/rscicpx.cxx b/rsc/source/parser/rscicpx.cxx index 62561de065e4..a9034bcb255b 100644 --- a/rsc/source/parser/rscicpx.cxx +++ b/rsc/source/parser/rscicpx.cxx @@ -442,30 +442,30 @@ RscTop * RscTypCont::InitClassImageButton( RscTop * pSuper, aBaseLst.push_back( pSymbol = new RscEnum( pHS->getID( "EnumSymbolButton" ), RSC_NOTYPE ) ); - SETCONST( pSymbol, "IMAGEBUTTON_DONTKNOW", SYMBOL_DONTKNOW ); - SETCONST( pSymbol, "IMAGEBUTTON_IMAGE", SYMBOL_IMAGE ); - SETCONST( pSymbol, "IMAGEBUTTON_ARROW_UP", SYMBOL_ARROW_UP ); - SETCONST( pSymbol, "IMAGEBUTTON_ARROW_DOWN", SYMBOL_ARROW_DOWN ); - SETCONST( pSymbol, "IMAGEBUTTON_ARROW_LEFT", SYMBOL_ARROW_LEFT ); - SETCONST( pSymbol, "IMAGEBUTTON_ARROW_RIGHT", SYMBOL_ARROW_RIGHT ); - SETCONST( pSymbol, "IMAGEBUTTON_SPIN_UP", SYMBOL_SPIN_UP ); - SETCONST( pSymbol, "IMAGEBUTTON_SPIN_DOWN", SYMBOL_SPIN_DOWN ); - SETCONST( pSymbol, "IMAGEBUTTON_SPIN_LEFT", SYMBOL_SPIN_LEFT ); - SETCONST( pSymbol, "IMAGEBUTTON_SPIN_RIGHT", SYMBOL_SPIN_RIGHT ); - SETCONST( pSymbol, "IMAGEBUTTON_FIRST", SYMBOL_FIRST ); - SETCONST( pSymbol, "IMAGEBUTTON_LAST", SYMBOL_LAST ); - SETCONST( pSymbol, "IMAGEBUTTON_PREV", SYMBOL_PREV ); - SETCONST( pSymbol, "IMAGEBUTTON_NEXT", SYMBOL_NEXT ); - SETCONST( pSymbol, "IMAGEBUTTON_PAGEUP", SYMBOL_PAGEUP ); - SETCONST( pSymbol, "IMAGEBUTTON_PAGEDOWN", SYMBOL_PAGEDOWN ); - SETCONST( pSymbol, "IMAGEBUTTON_PLAY", SYMBOL_PLAY ); - SETCONST( pSymbol, "IMAGEBUTTON_REVERSEPLAY", SYMBOL_REVERSEPLAY ); - SETCONST( pSymbol, "IMAGEBUTTON_STOP", SYMBOL_STOP ); - SETCONST( pSymbol, "IMAGEBUTTON_PAUSE", SYMBOL_PAUSE ); - SETCONST( pSymbol, "IMAGEBUTTON_WINDSTART", SYMBOL_WINDSTART ); - SETCONST( pSymbol, "IMAGEBUTTON_WINDEND", SYMBOL_WINDEND ); - SETCONST( pSymbol, "IMAGEBUTTON_WINDBACKWARD", SYMBOL_WINDBACKWARD ); - SETCONST( pSymbol, "IMAGEBUTTON_WINDFORWARD", SYMBOL_WINDFORWARD ); + SETCONST( pSymbol, "IMAGEBUTTON_DONTKNOW", SymbolType::DONTKNOW ); + SETCONST( pSymbol, "IMAGEBUTTON_IMAGE", SymbolType::IMAGE ); + SETCONST( pSymbol, "IMAGEBUTTON_ARROW_UP", SymbolType::ARROW_UP ); + SETCONST( pSymbol, "IMAGEBUTTON_ARROW_DOWN", SymbolType::ARROW_DOWN ); + SETCONST( pSymbol, "IMAGEBUTTON_ARROW_LEFT", SymbolType::ARROW_LEFT ); + SETCONST( pSymbol, "IMAGEBUTTON_ARROW_RIGHT", SymbolType::ARROW_RIGHT ); + SETCONST( pSymbol, "IMAGEBUTTON_SPIN_UP", SymbolType::SPIN_UP ); + SETCONST( pSymbol, "IMAGEBUTTON_SPIN_DOWN", SymbolType::SPIN_DOWN ); + SETCONST( pSymbol, "IMAGEBUTTON_SPIN_LEFT", SymbolType::SPIN_LEFT ); + SETCONST( pSymbol, "IMAGEBUTTON_SPIN_RIGHT", SymbolType::SPIN_RIGHT ); + SETCONST( pSymbol, "IMAGEBUTTON_FIRST", SymbolType::FIRST ); + SETCONST( pSymbol, "IMAGEBUTTON_LAST", SymbolType::LAST ); + SETCONST( pSymbol, "IMAGEBUTTON_PREV", SymbolType::PREV ); + SETCONST( pSymbol, "IMAGEBUTTON_NEXT", SymbolType::NEXT ); + SETCONST( pSymbol, "IMAGEBUTTON_PAGEUP", SymbolType::PAGEUP ); + SETCONST( pSymbol, "IMAGEBUTTON_PAGEDOWN", SymbolType::PAGEDOWN ); + SETCONST( pSymbol, "IMAGEBUTTON_PLAY", SymbolType::PLAY ); + SETCONST( pSymbol, "IMAGEBUTTON_REVERSEPLAY", SymbolType::REVERSEPLAY ); + SETCONST( pSymbol, "IMAGEBUTTON_STOP", SymbolType::STOP ); + SETCONST( pSymbol, "IMAGEBUTTON_PAUSE", SymbolType::PAUSE ); + SETCONST( pSymbol, "IMAGEBUTTON_WINDSTART", SymbolType::WINDSTART ); + SETCONST( pSymbol, "IMAGEBUTTON_WINDEND", SymbolType::WINDEND ); + SETCONST( pSymbol, "IMAGEBUTTON_WINDBACKWARD", SymbolType::WINDBACKWARD ); + SETCONST( pSymbol, "IMAGEBUTTON_WINDFORWARD", SymbolType::WINDFORWARD ); // Variable einfuegen nVarId = aNmTb.Put( "Symbol", VARNAME ); |