summaryrefslogtreecommitdiff
path: root/rsc
diff options
context:
space:
mode:
authorNoel Grandin <noel@peralex.com>2014-11-01 14:50:30 +0200
committerNoel Grandin <noelgrandin@gmail.com>2014-11-01 14:53:39 +0000
commita7542d38ddeebd37ddea233fa1e4cf15b2e03c49 (patch)
tree07ec3f89a4487b42c8b8203fab9e4dbb6f394a9c /rsc
parentb812374174144e077bc3b08fe347626cb1a33eee (diff)
fdo#84938: replace MIB_ constants with enum
Change-Id: I58c1b4c9e4c4b3751b233d2fe10b9c953b945c4a Reviewed-on: https://gerrit.libreoffice.org/12179 Reviewed-by: Noel Grandin <noelgrandin@gmail.com> Tested-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'rsc')
-rw-r--r--rsc/inc/rscdb.hxx3
-rw-r--r--rsc/source/parser/rscicpx.cxx10
2 files changed, 8 insertions, 5 deletions
diff --git a/rsc/inc/rscdb.hxx b/rsc/inc/rscdb.hxx
index 137c9589d764..26e0a9ba0786 100644
--- a/rsc/inc/rscdb.hxx
+++ b/rsc/inc/rscdb.hxx
@@ -41,6 +41,7 @@ enum class ToolBoxItemBits;
enum class WindowBorderStyle : sal_Int16;
enum class TimeFieldFormat : sal_Int32;
enum class KeyFuncType : sal_Int32;
+enum class MenuItemBits : sal_Int16;
struct WriteRcContext
{
@@ -150,6 +151,8 @@ class RscTypCont
inline void SETCONST( RscConst *p1, const char * p2, KeyFuncType p3 ) { SETCONST(p1, p2, static_cast<sal_uInt32>(p3)); }
inline void SETCONST( RscConst *p1, Atom p2, TimeFieldFormat p3 ) { SETCONST(p1, p2, static_cast<sal_uInt32>(p3)); }
inline void SETCONST( RscConst *p1, const char * p2, TimeFieldFormat p3 ) { SETCONST(p1, p2, static_cast<sal_uInt32>(p3)); }
+ inline void SETCONST( RscConst *p1, const char * p2, MenuItemBits p3 ) { SETCONST(p1, p2, static_cast<sal_uInt32>(p3)); }
+ inline void SETCONST( RscConst *p1, Atom p2, MenuItemBits p3 ) { SETCONST(p1, p2, static_cast<sal_uInt32>(p3)); }
RscEnum * InitLangType();
RscEnum * InitFieldUnitsType();
RscEnum * InitTimeFieldFormat();
diff --git a/rsc/source/parser/rscicpx.cxx b/rsc/source/parser/rscicpx.cxx
index 78e19d6275d7..0d2276aa7c49 100644
--- a/rsc/source/parser/rscicpx.cxx
+++ b/rsc/source/parser/rscicpx.cxx
@@ -800,15 +800,15 @@ RscTop * RscTypCont::InitClassMenuItem( RscTop * pSuper,
// Konstanten in Tabelle stellen
nCheckableId = pHS->getID( "MIB_CHECKABLE" );
- SETCONST( pFlag, nCheckableId, MIB_CHECKABLE );
+ SETCONST( pFlag, nCheckableId, MenuItemBits::CHECKABLE );
nAutoCheckId = pHS->getID( "MIB_AUTOCHECK" );
- SETCONST( pFlag, nAutoCheckId, MIB_AUTOCHECK );
+ SETCONST( pFlag, nAutoCheckId, MenuItemBits::AUTOCHECK );
nRadioCheckId = pHS->getID( "MIB_RADIOCHECK" );
- SETCONST( pFlag, nRadioCheckId, MIB_RADIOCHECK );
+ SETCONST( pFlag, nRadioCheckId, MenuItemBits::RADIOCHECK );
nAboutId = pHS->getID( "MIB_ABOUT" );
- SETCONST( pFlag, nAboutId, MIB_ABOUT );
+ SETCONST( pFlag, nAboutId, MenuItemBits::ABOUT );
nHelpId = pHS->getID( "MIB_HELP" );
- SETCONST( pFlag, nHelpId, MIB_HELP );
+ SETCONST( pFlag, nHelpId, MenuItemBits::HELP );
// Variable einfuegen
nVarId = aNmTb.Put( "_MenuItemFlags", VARNAME );