summaryrefslogtreecommitdiffstats
path: root/src/qscxmlgui.h
blob: 2560ad7eec9141eb89b02e4df76338e80c0915b4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#ifndef QSSMGUIINVOKERS_P_H
#define QSSMGUIINVOKERS_P_H

#include "qscxml.h"
class QMenu;
class QMessageBox;

class QScxmlMenuInvoker: public QScxmlInvoker
{
    Q_OBJECT

    public:
        QScxmlMenuInvoker(QScxmlEvent* ievent, QScxml* p) : QScxmlInvoker(ievent,p),menu(0)
        {
        }
        static void initInvokerFactory(QScxml*);
        static bool isTypeSupported (const QString & s) { return s== "q-menu"; }
    public Q_SLOTS:
        void activate ();
        void cancel ();

    private:
        QMenu* menu;
};


class QScxmlMessageBoxInvoker: public QScxmlInvoker
{
    Q_OBJECT

    public:
        QScxmlMessageBoxInvoker(QScxmlEvent* ievent, QScxml* p) : QScxmlInvoker(ievent,p),messageBox(0)
        {
        }

        static void initInvokerFactory(QScxml*);
        static bool isTypeSupported (const QString & s) { return s== "q-messagebox"; }
    public Q_SLOTS:
        void activate ();
        void cancel ();

    private Q_SLOTS:
        void onFinished (int);
    private:
        QMessageBox* messageBox;
};

#endif // QSSMGUIINVOKERS_P_H