diff options
author | Mark Tiefenbruck <mark@fluxbox.org> | 2008-08-22 12:52:23 (GMT) |
---|---|---|
committer | Mark Tiefenbruck <mark@fluxbox.org> | 2008-08-22 12:52:23 (GMT) |
commit | 0ae3ca9e8a2a3398cf07789e0d141887d40dcb6f (patch) | |
tree | 4e4d66fc15fea3956106affb772ea28f3bc909dd /src/Window.hh | |
parent | 8681220f5361fef500d7eda28d9f22bbf0a006e4 (diff) | |
download | fluxbox_pavel-0ae3ca9e8a2a3398cf07789e0d141887d40dcb6f.zip fluxbox_pavel-0ae3ca9e8a2a3398cf07789e0d141887d40dcb6f.tar.bz2 |
move fullscreen and maximization handling to FbWinFrame
Diffstat (limited to 'src/Window.hh')
-rw-r--r-- | src/Window.hh | 25 |
1 files changed, 4 insertions, 21 deletions
diff --git a/src/Window.hh b/src/Window.hh index 5cf755e..16d5bc9 100644 --- a/src/Window.hh +++ b/src/Window.hh | |||
@@ -87,16 +87,6 @@ public: | |||
87 | MwmDecorMaximize = (1l << 6) /// maximize | 87 | MwmDecorMaximize = (1l << 6) /// maximize |
88 | }; | 88 | }; |
89 | 89 | ||
90 | /** | ||
91 | * Types of maximization | ||
92 | */ | ||
93 | enum MaximizeMode { | ||
94 | MAX_NONE = 0, ///< normal state | ||
95 | MAX_HORZ = 1, ///< maximize horizontal | ||
96 | MAX_VERT = 2, ///< maximize vertical | ||
97 | MAX_FULL = 3 ///< maximize full | ||
98 | }; | ||
99 | |||
100 | /// Different resize modes when resizing a window | 90 | /// Different resize modes when resizing a window |
101 | enum ResizeModel { | 91 | enum ResizeModel { |
102 | QUADRANTRESIZE, ///< resizes from one quadrant | 92 | QUADRANTRESIZE, ///< resizes from one quadrant |
@@ -222,7 +212,7 @@ public: | |||
222 | /// set fullscreen | 212 | /// set fullscreen |
223 | void setFullscreen(bool flag); | 213 | void setFullscreen(bool flag); |
224 | /// toggle maximize | 214 | /// toggle maximize |
225 | void maximize(int type = MAX_FULL); | 215 | void maximize(int type = FbWinFrame::MAX_FULL); |
226 | /// sets the maximized state | 216 | /// sets the maximized state |
227 | void setMaximizedState(int type); | 217 | void setMaximizedState(int type); |
228 | /// maximizes the window horizontal | 218 | /// maximizes the window horizontal |
@@ -383,9 +373,9 @@ public: | |||
383 | bool isIconic() const { return iconic; } | 373 | bool isIconic() const { return iconic; } |
384 | bool isShaded() const { return shaded; } | 374 | bool isShaded() const { return shaded; } |
385 | bool isFullscreen() const { return fullscreen; } | 375 | bool isFullscreen() const { return fullscreen; } |
386 | bool isMaximized() const { return maximized == MAX_FULL; } | 376 | bool isMaximized() const { return maximized == FbWinFrame::MAX_FULL; } |
387 | bool isMaximizedVert() const { return (bool)(maximized & MAX_VERT); } | 377 | bool isMaximizedVert() const { return (bool)(maximized & FbWinFrame::MAX_VERT); } |
388 | bool isMaximizedHorz() const { return (bool)(maximized & MAX_HORZ); } | 378 | bool isMaximizedHorz() const { return (bool)(maximized & FbWinFrame::MAX_HORZ); } |
389 | int maximizedState() const { return maximized; } | 379 | int maximizedState() const { return maximized; } |
390 | bool isIconifiable() const { return functions.iconify; } | 380 | bool isIconifiable() const { return functions.iconify; } |
391 | bool isMaximizable() const { return functions.maximize; } | 381 | bool isMaximizable() const { return functions.maximize; } |
@@ -435,11 +425,6 @@ public: | |||
435 | unsigned int width() const { return frame().width(); } | 425 | unsigned int width() const { return frame().width(); } |
436 | unsigned int height() const { return frame().height(); } | 426 | unsigned int height() const { return frame().height(); } |
437 | 427 | ||
438 | int normalX() const; | ||
439 | int normalY() const; | ||
440 | unsigned int normalWidth() const; | ||
441 | unsigned int normalHeight() const; | ||
442 | |||
443 | int xOffset() const { return frame().xOffset(); } | 428 | int xOffset() const { return frame().xOffset(); } |
444 | int yOffset() const { return frame().yOffset(); } | 429 | int yOffset() const { return frame().yOffset(); } |
445 | int widthOffset() const { return frame().widthOffset(); } | 430 | int widthOffset() const { return frame().widthOffset(); } |
@@ -587,8 +572,6 @@ private: | |||
587 | /// if the window is focused with EnterNotify | 572 | /// if the window is focused with EnterNotify |
588 | FbTk::DefaultValue<bool, BoolAcc> m_mouse_focus; | 573 | FbTk::DefaultValue<bool, BoolAcc> m_mouse_focus; |
589 | bool m_click_focus; ///< if the window is focused by clicking | 574 | bool m_click_focus; ///< if the window is focused by clicking |
590 | int m_old_pos_x, m_old_pos_y; ///< old position so we can restore from maximized | ||
591 | unsigned int m_old_width, m_old_height; ///< old size so we can restore from maximized state | ||
592 | int m_last_button_x, ///< last known x position of the mouse button | 575 | int m_last_button_x, ///< last known x position of the mouse button |
593 | m_last_button_y; ///< last known y position of the mouse button | 576 | m_last_button_y; ///< last known y position of the mouse button |
594 | 577 | ||