diff options
author | Noel Grandin <noel@peralex.com> | 2015-05-07 17:06:34 +0200 |
---|---|---|
committer | Noel Grandin <noelgrandin@gmail.com> | 2015-05-12 06:13:30 +0000 |
commit | 3fd5f8919ec2256c70ff26c14cb9f8065c5cb2f1 (patch) | |
tree | b1d9a0dbb11d23899ccf53b790ddd445b8585a38 /include | |
parent | 0c129aa3df35a056ec739579002b2fc958fb3a48 (diff) |
convert CURSOR_DIRECTION constants to scoped enum
Change-Id: I444c61d0073b12740b55e316b2bb6e34f59dfe21
Reviewed-on: https://gerrit.libreoffice.org/15675
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/vcl/cursor.hxx | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/include/vcl/cursor.hxx b/include/vcl/cursor.hxx index c56ef3c4b0d9..3a1127e7893b 100644 --- a/include/vcl/cursor.hxx +++ b/include/vcl/cursor.hxx @@ -31,9 +31,11 @@ namespace vcl { class Window; } // Cursor styles #define CURSOR_SHADOW ((sal_uInt16)0x0001) -#define CURSOR_DIRECTION_NONE ((unsigned char)0x00) -#define CURSOR_DIRECTION_LTR ((unsigned char)0x01) -#define CURSOR_DIRECTION_RTL ((unsigned char)0x02) + +enum class CursorDirection +{ + NONE, LTR, RTL +}; namespace vcl { @@ -49,7 +51,7 @@ private: short mnOrientation; sal_uInt16 mnStyle; bool mbVisible; - unsigned char mnDirection; + CursorDirection mnDirection; public: SAL_DLLPRIVATE void ImplDraw(); @@ -90,8 +92,8 @@ public: void SetOrientation( short nOrientation = 0 ); short GetOrientation() const { return mnOrientation; } - void SetDirection( unsigned char nDirection = 0 ); - unsigned char GetDirection() const { return mnDirection; } + void SetDirection( CursorDirection nDirection = CursorDirection::NONE ); + CursorDirection GetDirection() const { return mnDirection; } Cursor& operator=( const Cursor& rCursor ); bool operator==( const Cursor& rCursor ) const; |