aboutsummaryrefslogtreecommitdiff
path: root/src/WinButton.hh
diff options
context:
space:
mode:
authorfluxgen <fluxgen>2003-04-25 17:29:58 (GMT)
committerfluxgen <fluxgen>2003-04-25 17:29:58 (GMT)
commitc31a8b5290eb4968b1be38e01cf37ca68e59e46e (patch)
treeddf8d4e9b832b747005e71ac17aeb88fe6e07ea2 /src/WinButton.hh
parentc955d69323bb343c4921ac5017c2f40563fac9d1 (diff)
downloadfluxbox-c31a8b5290eb4968b1be38e01cf37ca68e59e46e.zip
fluxbox-c31a8b5290eb4968b1be38e01cf37ca68e59e46e.tar.bz2
fixed listen to window state
Diffstat (limited to 'src/WinButton.hh')
-rw-r--r--src/WinButton.hh16
1 files changed, 10 insertions, 6 deletions
diff --git a/src/WinButton.hh b/src/WinButton.hh
index 49504e5..207ecb9 100644
--- a/src/WinButton.hh
+++ b/src/WinButton.hh
@@ -19,25 +19,29 @@
19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER 19// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20// DEALINGS IN THE SOFTWARE. 20// DEALINGS IN THE SOFTWARE.
21 21
22/// $Id: WinButton.hh,v 1.2 2003/03/22 11:38:24 fluxgen Exp $ 22/// $Id: WinButton.hh,v 1.3 2003/04/25 17:29:58 fluxgen Exp $
23 23
24#include "Button.hh" 24#include "Button.hh"
25#include "Observer.hh"
26
27class FluxboxWindow;
25 28
26/// draws and handles basic window button graphic 29/// draws and handles basic window button graphic
27/** 30class WinButton:public FbTk::Button, public FbTk::Observer {
28 window button
29 */
30class WinButton:public FbTk::Button {
31public: 31public:
32 /// draw type for the button 32 /// draw type for the button
33 enum Type {MAXIMIZE, MINIMIZE, SHADE, STICK, CLOSE}; 33 enum Type {MAXIMIZE, MINIMIZE, SHADE, STICK, CLOSE};
34 WinButton(Type buttontype, const FbTk::FbWindow &parent, int x, int y, 34 WinButton(const FluxboxWindow &listen_to,
35 Type buttontype, const FbTk::FbWindow &parent, int x, int y,
35 unsigned int width, unsigned int height); 36 unsigned int width, unsigned int height);
36 /// override for drawing 37 /// override for drawing
37 void exposeEvent(XExposeEvent &event); 38 void exposeEvent(XExposeEvent &event);
39 void buttonReleaseEvent(XButtonEvent &event);
38 /// override for redrawing 40 /// override for redrawing
39 void clear(); 41 void clear();
42 void update(FbTk::Subject *subj);
40private: 43private:
41 void drawType(); 44 void drawType();
42 Type m_type; ///< the button type 45 Type m_type; ///< the button type
46 const FluxboxWindow &m_listen_to;
43}; 47};