aboutsummaryrefslogtreecommitdiff
path: root/src/Window.hh
diff options
context:
space:
mode:
authorfluxgen <fluxgen>2006-06-11 13:09:44 (GMT)
committerfluxgen <fluxgen>2006-06-11 13:09:44 (GMT)
commit331a52115dfa5c681b065d226ee796e52b48fed0 (patch)
tree1bd1282d6374431369e5b1fabda314f7ae7298ec /src/Window.hh
parent9699cda56e0877d361a0a79df3a8ebeea5b36f33 (diff)
downloadfluxbox_pavel-331a52115dfa5c681b065d226ee796e52b48fed0.zip
fluxbox_pavel-331a52115dfa5c681b065d226ee796e52b48fed0.tar.bz2
support for _NET_WM_MOVERESIZE
Diffstat (limited to 'src/Window.hh')
-rw-r--r--src/Window.hh54
1 files changed, 40 insertions, 14 deletions
diff --git a/src/Window.hh b/src/Window.hh
index db3e285..27e8138 100644
--- a/src/Window.hh
+++ b/src/Window.hh
@@ -134,13 +134,18 @@ public:
134 DECORM_LAST = (1<<11) // useful for getting "All" 134 DECORM_LAST = (1<<11) // useful for getting "All"
135 }; 135 };
136 136
137 enum ResizeCorner { 137
138 NOCORNER, 138 enum ResizeDirection {
139 LEFTTOP, 139 NOCORNER = -1,
140 LEFTBOTTOM, 140 LEFTTOP = 0,
141 RIGHTBOTTOM, 141 TOP = 1,
142 RIGHTTOP, 142 RIGHTTOP = 2,
143 ALLCORNERS 143 RIGHT = 3,
144 RIGHTBOTTOM = 4,
145 BOTTOM = 5,
146 LEFTBOTTOM = 6,
147 LEFT = 7,
148 ALLCORNERS = 8
144 }; 149 };
145 150
146 typedef struct _blackbox_hints { 151 typedef struct _blackbox_hints {
@@ -274,6 +279,26 @@ public:
274 279
275 unsigned int decorationMask() const; 280 unsigned int decorationMask() const;
276 void setDecorationMask(unsigned int mask); 281 void setDecorationMask(unsigned int mask);
282 /**
283 * Start moving process, grabs the pointer and draws move rectangle
284 * @param x position of pointer
285 * @param y position of pointer
286 */
287 void startMoving(int x, int y);
288 /**
289 * Stop moving process
290 * @param interrupted whether the move was interrupted by hide or destroy
291 */
292 void stopMoving(bool interrupted = false);
293 /**
294 * Starts resizing process
295 * @param x start position
296 * @param y start position
297 * @param dir the resize direction
298 */
299 void startResizing(int x, int y, ResizeDirection dir);
300 /// stops the resizing
301 void stopResizing(bool interrupted = false);
277 302
278 /** 303 /**
279 @name accessors 304 @name accessors
@@ -410,10 +435,6 @@ private:
410 void updateClientLeftWindow(); 435 void updateClientLeftWindow();
411 void grabButtons(); 436 void grabButtons();
412 437
413 void startMoving(Window win);
414 void stopMoving(bool interrupted = false);
415 void startResizing(Window win, int x, int y);
416 void stopResizing(bool interrupted = false);
417 /// try to attach current attaching client to a window at pos x, y 438 /// try to attach current attaching client to a window at pos x, y
418 void attachTo(int x, int y, bool interrupted = false); 439 void attachTo(int x, int y, bool interrupted = false);
419 440
@@ -452,8 +473,13 @@ private:
452 void associateClient(WinClient &client); 473 void associateClient(WinClient &client);
453 474
454 // state and hint signals 475 // state and hint signals
455 WinSubject m_hintsig, m_statesig, m_layersig, m_workspacesig, 476 WinSubject m_hintsig,
456 m_diesig, m_focussig, m_titlesig, m_attentionsig; 477 m_statesig,
478 m_layersig,
479 m_workspacesig,
480 m_diesig, m_focussig,
481 m_titlesig,
482 m_attentionsig;
457 483
458 class ThemeListener: public FbTk::Observer { 484 class ThemeListener: public FbTk::Observer {
459 public: 485 public:
@@ -524,7 +550,7 @@ private:
524 550
525 FbTk::FbWindow &m_parent; ///< window on which we draw move/resize rectangle (the "root window") 551 FbTk::FbWindow &m_parent; ///< window on which we draw move/resize rectangle (the "root window")
526 552
527 ResizeCorner m_resize_corner; 553 ResizeDirection m_resize_corner;
528 554
529 static int s_num_grabs; ///< number of XGrabPointer's 555 static int s_num_grabs; ///< number of XGrabPointer's
530}; 556};