diff options
Diffstat (limited to 'src/FbWinFrame.hh')
-rw-r--r-- | src/FbWinFrame.hh | 19 |
1 files changed, 11 insertions, 8 deletions
diff --git a/src/FbWinFrame.hh b/src/FbWinFrame.hh index 241b435..d128f23 100644 --- a/src/FbWinFrame.hh +++ b/src/FbWinFrame.hh | |||
@@ -96,20 +96,20 @@ public: | |||
96 | inline bool isVisible() const { return m_visible; } | 96 | inline bool isVisible() const { return m_visible; } |
97 | /// shade frame (ie resize to titlebar size) | 97 | /// shade frame (ie resize to titlebar size) |
98 | void shade(); | 98 | void shade(); |
99 | void move(int x, int y, int win_gravity=ForgetGravity); | 99 | void move(int x, int y); |
100 | void resize(unsigned int width, unsigned int height, int win_gravity=ForgetGravity); | 100 | void resize(unsigned int width, unsigned int height); |
101 | /// resize client to specified size and resize frame to it | 101 | /// resize client to specified size and resize frame to it |
102 | void resizeForClient(unsigned int width, unsigned int height, int win_gravity=ForgetGravity); | 102 | void resizeForClient(unsigned int width, unsigned int height, int win_gravity=ForgetGravity, unsigned int client_bw = 0); |
103 | 103 | ||
104 | // for when there needs to be an atomic move+resize operation | 104 | // for when there needs to be an atomic move+resize operation |
105 | void moveResizeForClient(int x, int y, | 105 | void moveResizeForClient(int x, int y, |
106 | unsigned int width, unsigned int height, | 106 | unsigned int width, unsigned int height, |
107 | bool move = true, bool resize = true, int win_gravity=ForgetGravity); | 107 | bool move = true, bool resize = true, int win_gravity=ForgetGravity, unsigned int client_bw = 0); |
108 | 108 | ||
109 | // can elect to ignore move or resize (mainly for use of move/resize individual functions | 109 | // can elect to ignore move or resize (mainly for use of move/resize individual functions |
110 | void moveResize(int x, int y, | 110 | void moveResize(int x, int y, |
111 | unsigned int width, unsigned int height, | 111 | unsigned int width, unsigned int height, |
112 | bool move = true, bool resize = true, int win_gravity=ForgetGravity); | 112 | bool move = true, bool resize = true); |
113 | 113 | ||
114 | // move without transparency or special effects (generally when dragging) | 114 | // move without transparency or special effects (generally when dragging) |
115 | void quietMoveResize(int x, int y, | 115 | void quietMoveResize(int x, int y, |
@@ -173,9 +173,8 @@ public: | |||
173 | 173 | ||
174 | // this function translates its arguments according to win_gravity | 174 | // this function translates its arguments according to win_gravity |
175 | // if win_gravity is negative, it does an inverse translation | 175 | // if win_gravity is negative, it does an inverse translation |
176 | void gravityTranslate(int &x, int &y, int win_gravity, bool move_frame = false); | 176 | void gravityTranslate(int &x, int &y, int win_gravity, unsigned int client_bw, bool move_frame = false); |
177 | //use width and height given instead of the real values, allows figuring out where to place a window before doing a moveResize | 177 | void setActiveGravity(int gravity, unsigned int orig_client_bw) { m_active_gravity = gravity; m_active_orig_client_bw = orig_client_bw; } |
178 | void gravityTranslate(int &x, int &y, unsigned int width, unsigned int height, int win_gravity, bool move_frame = false); | ||
179 | void setBorderWidth(unsigned int borderW); | 178 | void setBorderWidth(unsigned int borderW); |
180 | 179 | ||
181 | /** | 180 | /** |
@@ -369,6 +368,10 @@ private: | |||
369 | 368 | ||
370 | TabMode m_tabmode; | 369 | TabMode m_tabmode; |
371 | 370 | ||
371 | // last gravity that this window was *actively* placed with | ||
372 | int m_active_gravity; | ||
373 | unsigned int m_active_orig_client_bw; | ||
374 | |||
372 | bool m_need_render; | 375 | bool m_need_render; |
373 | int m_button_size; ///< size for all titlebar buttons | 376 | int m_button_size; ///< size for all titlebar buttons |
374 | unsigned int m_width_before_shade, ///< width before shade, so we can restore it when we unshade | 377 | unsigned int m_width_before_shade, ///< width before shade, so we can restore it when we unshade |