aboutsummaryrefslogtreecommitdiff
path: root/src/FbWinFrame.hh
diff options
context:
space:
mode:
authorMark Tiefenbruck <mark@fluxbox.org>2008-08-15 11:09:15 (GMT)
committerMark Tiefenbruck <mark@fluxbox.org>2008-08-15 11:09:15 (GMT)
commit6053ecc1b573e437dd0d1752670748c5c3679669 (patch)
treeccbc036526b17ec536775614e6514d83665d2781 /src/FbWinFrame.hh
parent4fa3773267362f8ca9f653bb8ee7c98baa09d5fd (diff)
downloadfluxbox-6053ecc1b573e437dd0d1752670748c5c3679669.zip
fluxbox-6053ecc1b573e437dd0d1752670748c5c3679669.tar.bz2
move size hint code to methods in size hint struct, restructure them a little
Diffstat (limited to 'src/FbWinFrame.hh')
-rw-r--r--src/FbWinFrame.hh16
1 files changed, 6 insertions, 10 deletions
diff --git a/src/FbWinFrame.hh b/src/FbWinFrame.hh
index d2a27c9..70f0a4c 100644
--- a/src/FbWinFrame.hh
+++ b/src/FbWinFrame.hh
@@ -96,6 +96,11 @@ public:
96 }; 96 };
97 97
98 typedef struct SizeHints { 98 typedef struct SizeHints {
99 void apply(unsigned int &w, unsigned int &h,
100 bool maximizing = false) const;
101 bool valid(unsigned int width, unsigned int height) const;
102 void displaySize(int &i, int &j,
103 unsigned int width, unsigned int height) const;
99 unsigned int min_width; 104 unsigned int min_width;
100 unsigned int max_width; 105 unsigned int max_width;
101 unsigned int min_height; 106 unsigned int min_height;
@@ -200,16 +205,7 @@ public:
200 /// remove any handler for the windows 205 /// remove any handler for the windows
201 void removeEventHandler(); 206 void removeEventHandler();
202 207
203 /** 208 const SizeHints &sizeHints() const { return m_size_hints; }
204 * Changes width and height to the nearest (lower) value
205 * that conforms to it's size hints.
206 *
207 * display_* give the values that would be displayed
208 * to the user when resizing.
209 * We use pointers for display_* since they are optional.
210 */
211 void applySizeHints(int &width, int &height, int *display_width = 0,
212 int *display_height = 0, bool maximizing = false);
213 void setSizeHints(const SizeHints &hint) { m_size_hints = hint; } 209 void setSizeHints(const SizeHints &hint) { m_size_hints = hint; }
214 210
215 void setDecorationMask(unsigned int mask) { m_decoration_mask = mask; } 211 void setDecorationMask(unsigned int mask) { m_decoration_mask = mask; }