Advertisement
Guest User

Untitled

a guest
Oct 12th, 2015
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.46 KB | None | 0 0
  1. #ifndef BUTTONCLICKEFFECT
  2. #define BUTTONCLICKEFFECT
  3.  
  4. #include <QtCore>
  5. #include <QPushButton>
  6. #include <QPainter>
  7. #include <QMouseEvent>
  8.  
  9. class ButtonClickEffect : public QObject
  10. {
  11.     Q_OBJECT
  12.  
  13. public:
  14.     explicit ButtonClickEffect(QObject *parent = 0);
  15.  
  16. protected:
  17.     virtual bool eventFilter(QObject *object, QEvent *event);
  18.  
  19. public slots:
  20.     void OnTick();
  21.  
  22. private:
  23.     QTimer *timer;
  24.  
  25.     float delta = -1.0f;
  26. };
  27.  
  28. #endif // BUTTONCLICK
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement