summaryrefslogtreecommitdiffstats
path: root/examples/calc/main.cpp
blob: 181b792089ba3f7695d26777e152097b52bab547 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15

#include <QtGui/QApplication>
#include "calc.h"
#include "qscxml.h"
int main(int argc, char *argv[])
{
    QApplication a(argc, argv);
    QScxml *sm = QScxml::load(":/calc.scxml");
    CalcWidget w;
    sm->registerObject(&w,"",true);
    QObject::connect (&w, SIGNAL(command(QString)), sm, SLOT(postNamedEvent(QString)));
    w.show();
    sm->start();
    return a.exec();
}