Canorus  0.7
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
undotoolbutton.h
Go to the documentation of this file.
1 
8 #ifndef UNDOTOOLBUTTON_H_
9 #define UNDOTOOLBUTTON_H_
10 
11 #include "widgets/toolbutton.h"
12 
13 #include <QListWidget>
14 
15 class QUndoStack;
16 
18  Q_OBJECT
19 public:
23  };
24 
25  CAUndoToolButton( QIcon icon, CAUndoToolButtonType t, QWidget *parent );
27  void setDefaultAction( QAction* );
28 
29  inline CAUndoToolButtonType undoType() { return _type; }
30  inline void setUndoType( CAUndoToolButtonType type ) { _type = type; }
31  void showButtons();
32 
33 public slots:
34  void onListWidgetItemClicked( QListWidgetItem* );
35  void onListWidgetItemEntered( QListWidgetItem* );
36 
37 protected:
38  void wheelEvent(QWheelEvent*);
39 
40 private:
41  QListWidget *_listWidget;
43  QIcon _icon;
44 };
45 
46 #endif /* UNDOTOOLBUTTON_H_ */