Finished implementing zoom button drag feature
[situare] / src / ui / panelcommon.h
index a4579ca..f39cc00 100644 (file)
 
 enum Side {LEFT, RIGHT};  ///< Enumerator for panel sideness
 
-const int SIDEBAR_WIDTH = 23;
-const int SIDEBAR_HEIGHT = 424;
+const int DRAG_INIT_TIME = 1000;    ///< How long buttons must be pressed to start drag mode
 
-const int SLIDINGBAR_WIDTH = 24;
-const int SLIDINGBAR_HEIGHT = 424;
+const int SIDEBAR_WIDTH = 23;       ///< Width of the sidebar
+const int SIDEBAR_HEIGHT = 424;     ///< Height of the sidebar
+
+const int SLIDINGBAR_WIDTH = 24;    ///< Width of the slidingbar
+const int SLIDINGBAR_HEIGHT = 424;  ///< Height of the slidingbar
 
 const int PANEL_PEEK_AMOUNT = 25; ///< Amount of pixels shown when panel is closed
 
@@ -48,16 +50,19 @@ const int PANEL_TOP_Y = 0; ///< Y coordinate for top of both panels
 const int TOP_CORNER_X = 0;  ///< X coordinate for top left corner
 
 const int FRIENDPANEL_CLOSED_X =
-        DEFAULT_SCREEN_WIDTH - PANEL_PEEK_AMOUNT - SLIDINGBAR_WIDTH; ///< X location of the friend list panel when closed
+        DEFAULT_SCREEN_WIDTH - PANEL_PEEK_AMOUNT
+        - SLIDINGBAR_WIDTH; ///< X location of the friend list panel when closed
 const int FRIENDPANEL_OPENED_X =
-        DEFAULT_SCREEN_WIDTH - FRIENDPANEL_WIDTH - SLIDINGBAR_WIDTH; ///< X location of the friend list panel when opened
+        DEFAULT_SCREEN_WIDTH - FRIENDPANEL_WIDTH
+        - SLIDINGBAR_WIDTH; ///< X location of the friend list panel when opened
 
 const int USERPANEL_CLOSED_X =
         2 - USERPANEL_WIDTH + PANEL_PEEK_AMOUNT;  ///< X location of the user panel when closed
 const int USERPANEL_OPENED_X = 0;     ///< X location of the user panel when opened
 
 
-const int ZOOM_BUTTON_PANEL_POSITION_X = 10 + PANEL_PEEK_AMOUNT; ///< Horizontal position of zoom panel
+const int ZOOM_BUTTON_PANEL_POSITION_X = 10
+                                         + PANEL_PEEK_AMOUNT; ///< Horizontal position of zoom panel
 const int ZOOM_BUTTON_PANEL_POSITION_Y = 10; ///< Vertical position of zoom panel
 const int ZOOM_BUTTON_PANEL_BUTTON_SPACING = 4; ///< Size of a zoom button spacing