Inserimento README
[qmemory] / crazybutton.h
1 #ifndef CRAZYBUTTON_H
2 #define CRAZYBUTTON_H
3
4 #include <QPushButton>
5 #include <QMouseEvent>
6
7
8 class CrazyButton : public QPushButton
9 {
10     Q_OBJECT
11 public:
12     CrazyButton(QWidget *parent=0);
13
14 public slots:
15      void changeColor();
16      bool getStateColor(){return col;}
17 protected:
18      void mousePressEvent(QMouseEvent *e);
19      void mouseReleaseEvent(QMouseEvent *e);
20      /*
21      void focusInEvent(QFocusEvent *);
22      void focusOutEvent(QFocusEvent *);
23      */
24 private:
25      bool col;
26
27 };
28
29 #endif // CRAZYBUTTON_H