]> git.lyx.org Git - lyx.git/blob - src/frontends/qt4/Action.h
get rid of QT3_SUPPORT and some cleanup
[lyx.git] / src / frontends / qt4 / Action.h
1 // -*- C++ -*-
2 /**
3  * \file Action.h
4  * This file is part of LyX, the document processor.
5  * Licence details can be found in the file COPYING.
6  *
7  * \author Abdelrazak Younes
8  *
9  * Full author contact details are available in file CREDITS.
10  */
11
12 #ifndef ACTION_H
13 #define ACTION_H
14
15 #include "frontends/LyXView.h"
16 #include "funcrequest.h"
17
18 #include <QAction>
19
20 //class FuncRequest;
21
22 //class string;
23
24 namespace lyx {
25 namespace frontend {
26
27 /**
28  * Action - Qt interface with LyX' FuncRequest.
29  *
30  * Action can be used in LyX menubar and/or toolbars.
31  */
32 class Action: public QAction {
33         Q_OBJECT
34 public:
35
36         Action(LyXView & lyxView, std::string const & text,
37                 FuncRequest const & func, std::string const & tooltip="");
38
39         Action(LyXView & lyxView, std::string const & icon, std::string const & text,
40                 FuncRequest const & func, std::string const & tooltip="");
41
42         void update();
43
44 //      void setAction(FuncRequest const & func);
45
46 private Q_SLOTS:
47         void action();
48
49 private:
50         FuncRequest const & func_ ;
51         //FuncRequest func_ ;
52         LyXView & lyxView_;
53 };
54
55
56 } // namespace frontend
57 } // namespace lyx
58
59 #endif // ACTION_H