diff options
author | Noel Grandin <noel@peralex.com> | 2015-05-19 08:05:39 +0200 |
---|---|---|
committer | Noel Grandin <noel@peralex.com> | 2015-05-20 09:52:08 +0200 |
commit | 662700703bebad38ca7ad74ca4eb040fe8b5b676 (patch) | |
tree | 8e693319a485837c4b621244ced161b19c193302 /include/vcl/outdev.hxx | |
parent | convert IMAGE_DRAW_ constants to scoped enum (diff) | |
download | core-662700703bebad38ca7ad74ca4eb040fe8b5b676.tar.gz core-662700703bebad38ca7ad74ca4eb040fe8b5b676.zip |
convert GRID constants to scoped enum
Change-Id: I73ae63bc5f41f38d1a4e396152808b22e88681d8
Diffstat (limited to 'include/vcl/outdev.hxx')
-rw-r--r-- | include/vcl/outdev.hxx | 26 |
1 files changed, 17 insertions, 9 deletions
diff --git a/include/vcl/outdev.hxx b/include/vcl/outdev.hxx index e72631c5fd82..21f36153b4ed 100644 --- a/include/vcl/outdev.hxx +++ b/include/vcl/outdev.hxx @@ -201,11 +201,19 @@ namespace o3tl template<> struct typed_flags<DrawImageFlags> : is_typed_flags<DrawImageFlags, 0x001f> {}; } -// Grid -#define GRID_DOTS ((sal_uLong)0x00000001) -#define GRID_HORZLINES ((sal_uLong)0x00000002) -#define GRID_VERTLINES ((sal_uLong)0x00000004) -#define GRID_LINES (GRID_HORZLINES | GRID_VERTLINES) +// Flags for DrawGrid() +enum class DrawGridFlags +{ + NONE = 0x0000, + Dots = 0x0001, + HorzLines = 0x0002, + VertLines = 0x0004, + Lines = HorzLines | VertLines, +}; +namespace o3tl +{ + template<> struct typed_flags<DrawGridFlags> : is_typed_flags<DrawGridFlags, 0x0007> {}; +} // DrawModes #define DRAWMODE_DEFAULT ((sal_uLong)0x00000000) @@ -405,12 +413,12 @@ public: protected: /// release all references to other objects. - virtual void dispose(); + virtual void dispose(); public: /// call the dispose() method if we have not already been disposed. - void disposeOnce(); - bool isDisposed() const { return mbDisposed; } + void disposeOnce(); + bool isDisposed() const { return mbDisposed; } public: @@ -719,7 +727,7 @@ public: Color aStart = Color(COL_WHITE), Color aEnd = Color(COL_BLACK)); - void DrawGrid( const Rectangle& rRect, const Size& rDist, sal_uLong nFlags ); + void DrawGrid( const Rectangle& rRect, const Size& rDist, DrawGridFlags nFlags ); ///@} |