summaryrefslogtreecommitdiffstats
path: root/examples/statemachine
diff options
context:
space:
mode:
authorKent Hansen <khansen@trolltech.com>2009-05-20 15:34:11 +0200
committerKent Hansen <khansen@trolltech.com>2009-05-20 15:34:11 +0200
commitac5fceafb00a2f007239f9b0fc89fe01a2064d62 (patch)
treedbce8727cf7599c07e8151e7993b59cd5f3e40a6 /examples/statemachine
parent5504a102e9f608fed7377332b8de7b823cf22b85 (diff)
compile with -qtnamespace, clean up the example .pro files
Diffstat (limited to 'examples/statemachine')
-rw-r--r--examples/statemachine/eventtransitions/eventtransitions.pro12
-rw-r--r--examples/statemachine/factorial/factorial.pro11
-rw-r--r--examples/statemachine/pingpong/pingpong.pro13
-rw-r--r--examples/statemachine/tankgame/gameitem.h2
-rw-r--r--examples/statemachine/tankgame/mainwindow.h3
-rw-r--r--examples/statemachine/tankgame/plugin.h4
-rw-r--r--examples/statemachine/tankgame/tankgame.pro30
-rw-r--r--examples/statemachine/trafficlight/trafficlight.pro7
-rw-r--r--examples/statemachine/twowaybutton/twowaybutton.pro12
9 files changed, 53 insertions, 41 deletions
diff --git a/examples/statemachine/eventtransitions/eventtransitions.pro b/examples/statemachine/eventtransitions/eventtransitions.pro
index 6a976cbbf9..7e92cf2cff 100644
--- a/examples/statemachine/eventtransitions/eventtransitions.pro
+++ b/examples/statemachine/eventtransitions/eventtransitions.pro
@@ -1,7 +1,7 @@
-TEMPLATE = app
-TARGET =
-DEPENDPATH += .
-INCLUDEPATH += .
+SOURCES = main.cpp
-# Input
-SOURCES += main.cpp
+# install
+target.path = $$[QT_INSTALL_EXAMPLES]/statemachine/eventtransitions
+sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS eventtransitions.pro
+sources.path = $$[QT_INSTALL_EXAMPLES]/statemachine/eventtransitions
+INSTALLS += target sources
diff --git a/examples/statemachine/factorial/factorial.pro b/examples/statemachine/factorial/factorial.pro
index ac79117e91..14a6833f08 100644
--- a/examples/statemachine/factorial/factorial.pro
+++ b/examples/statemachine/factorial/factorial.pro
@@ -1,10 +1,11 @@
-TEMPLATE = app
-TARGET =
QT = core
win32: CONFIG += console
mac:CONFIG -= app_bundle
-DEPENDPATH += .
-INCLUDEPATH += .
-# Input
SOURCES += main.cpp
+
+# install
+target.path = $$[QT_INSTALL_EXAMPLES]/statemachine/factorial
+sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS factorial.pro
+sources.path = $$[QT_INSTALL_EXAMPLES]/statemachine/factorial
+INSTALLS += target sources
diff --git a/examples/statemachine/pingpong/pingpong.pro b/examples/statemachine/pingpong/pingpong.pro
index bff9cb890f..42eab6c2cf 100644
--- a/examples/statemachine/pingpong/pingpong.pro
+++ b/examples/statemachine/pingpong/pingpong.pro
@@ -1,10 +1,11 @@
QT = core
-TEMPLATE = app
-TARGET =
win32: CONFIG += console
mac:CONFIG -= app_bundle
-DEPENDPATH += .
-INCLUDEPATH += .
-# Input
-SOURCES += main.cpp
+SOURCES = main.cpp
+
+# install
+target.path = $$[QT_INSTALL_EXAMPLES]/statemachine/pingpong
+sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS pingpong.pro
+sources.path = $$[QT_INSTALL_EXAMPLES]/statemachine/pingpong
+INSTALLS += target sources
diff --git a/examples/statemachine/tankgame/gameitem.h b/examples/statemachine/tankgame/gameitem.h
index 43b8785f16..33caf71360 100644
--- a/examples/statemachine/tankgame/gameitem.h
+++ b/examples/statemachine/tankgame/gameitem.h
@@ -3,7 +3,9 @@
#include <QGraphicsItem>
+QT_BEGIN_NAMESPACE
class QLineF;
+QT_END_NAMESPACE
class GameItem: public QObject, public QGraphicsItem
{
Q_OBJECT
diff --git a/examples/statemachine/tankgame/mainwindow.h b/examples/statemachine/tankgame/mainwindow.h
index 40e1595b94..391ab77903 100644
--- a/examples/statemachine/tankgame/mainwindow.h
+++ b/examples/statemachine/tankgame/mainwindow.h
@@ -4,11 +4,14 @@
#include <QMainWindow>
#include <QTime>
+QT_BEGIN_NAMESPACE
class QGraphicsScene;
class QStateMachine;
class QState;
+QT_END_NAMESPACE
class GameOverTransition;
class TankItem;
+
class MainWindow: public QMainWindow
{
Q_OBJECT
diff --git a/examples/statemachine/tankgame/plugin.h b/examples/statemachine/tankgame/plugin.h
index 2b48d4309f..006ad78402 100644
--- a/examples/statemachine/tankgame/plugin.h
+++ b/examples/statemachine/tankgame/plugin.h
@@ -3,7 +3,9 @@
#include <QtPlugin>
+QT_BEGIN_NAMESPACE
class QState;
+QT_END_NAMESPACE
class Plugin
{
public:
@@ -12,6 +14,8 @@ public:
virtual QState *create(QState *parentState, QObject *tank) = 0;
};
+QT_BEGIN_NAMESPACE
Q_DECLARE_INTERFACE(Plugin, "TankPlugin")
+QT_END_NAMESPACE
#endif
diff --git a/examples/statemachine/tankgame/tankgame.pro b/examples/statemachine/tankgame/tankgame.pro
index 46cfe2e3ed..59415be2f6 100644
--- a/examples/statemachine/tankgame/tankgame.pro
+++ b/examples/statemachine/tankgame/tankgame.pro
@@ -1,13 +1,19 @@
-######################################################################
-# Automatically generated by qmake (2.01a) on 22. apr 14:11:33 2009
-######################################################################
-
-TEMPLATE = app
-TARGET =
-DEPENDPATH += .
-INCLUDEPATH += C:/dev/kinetic/examples/statemachine/tankgame/. .
-
-# Input
-HEADERS += mainwindow.h plugin.h tankitem.h rocketitem.h gameitem.h gameovertransition.h
-SOURCES += main.cpp mainwindow.cpp tankitem.cpp rocketitem.cpp gameitem.cpp gameovertransition.cpp
+HEADERS += mainwindow.h \
+ plugin.h \
+ tankitem.h \
+ rocketitem.h \
+ gameitem.h \
+ gameovertransition.h
+SOURCES += main.cpp \
+ mainwindow.cpp \
+ tankitem.cpp \
+ rocketitem.cpp \
+ gameitem.cpp \
+ gameovertransition.cpp
CONFIG += console
+
+# install
+target.path = $$[QT_INSTALL_EXAMPLES]/statemachine/tankgame
+sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS tankgame.pro
+sources.path = $$[QT_INSTALL_EXAMPLES]/statemachine/tankgame
+INSTALLS += target sources
diff --git a/examples/statemachine/trafficlight/trafficlight.pro b/examples/statemachine/trafficlight/trafficlight.pro
index 730bd75286..684575ac1f 100644
--- a/examples/statemachine/trafficlight/trafficlight.pro
+++ b/examples/statemachine/trafficlight/trafficlight.pro
@@ -1,9 +1,4 @@
-TEMPLATE = app
-TARGET =
-DEPENDPATH += .
-INCLUDEPATH += .
-
-SOURCES += main.cpp
+SOURCES = main.cpp
# install
target.path = $$[QT_INSTALL_EXAMPLES]/statemachine/trafficlight
diff --git a/examples/statemachine/twowaybutton/twowaybutton.pro b/examples/statemachine/twowaybutton/twowaybutton.pro
index 6a976cbbf9..f6cbc57533 100644
--- a/examples/statemachine/twowaybutton/twowaybutton.pro
+++ b/examples/statemachine/twowaybutton/twowaybutton.pro
@@ -1,7 +1,7 @@
-TEMPLATE = app
-TARGET =
-DEPENDPATH += .
-INCLUDEPATH += .
+SOURCES = main.cpp
-# Input
-SOURCES += main.cpp
+# install
+target.path = $$[QT_INSTALL_EXAMPLES]/statemachine/twowaybutton
+sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS twowaybutton.pro
+sources.path = $$[QT_INSTALL_EXAMPLES]/statemachine/twowaybutton
+INSTALLS += target sources