From fc82d9cd77224c458c05ce2fd749e58e9cee5299 Mon Sep 17 00:00:00 2001 From: alberth Date: Sun, 30 May 2010 10:36:32 +0000 Subject: (svn r19903) -Codechange: Use SpecialMouseMode enum as type of _special_mouse_mode. --- src/window.cpp | 2 +- src/window_gui.h | 11 ++++++----- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/src/window.cpp b/src/window.cpp index 9fa5655ae..117244988 100644 --- a/src/window.cpp +++ b/src/window.cpp @@ -59,7 +59,7 @@ byte _scroller_click_timeout; bool _scrolling_scrollbar; bool _scrolling_viewport; -byte _special_mouse_mode; +SpecialMouseMode _special_mouse_mode; ///< Mode of the mouse. /** Window description constructor. */ WindowDesc::WindowDesc(WindowPosition def_pos, int16 def_width, int16 def_height, diff --git a/src/window_gui.h b/src/window_gui.h index 55a223581..68fbfc90e 100644 --- a/src/window_gui.h +++ b/src/window_gui.h @@ -913,13 +913,14 @@ extern byte _scroller_click_timeout; extern bool _scrolling_scrollbar; extern bool _scrolling_viewport; -extern byte _special_mouse_mode; +/** Mouse modes. */ enum SpecialMouseMode { - WSM_NONE = 0, - WSM_DRAGDROP = 1, - WSM_SIZING = 2, - WSM_PRESIZE = 3, + WSM_NONE, ///< No special mouse mode. + WSM_DRAGDROP, ///< Dragging an object. + WSM_SIZING, ///< Sizing mode. + WSM_PRESIZE, ///< Presizing mode (docks, tunnels). }; +extern SpecialMouseMode _special_mouse_mode; Window *GetCallbackWnd(); -- cgit v1.2.3-70-g09d2