summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorRobert Griebl <robert.griebl@nokia.com>2011-01-24 17:46:40 (GMT)
committerRobert Griebl <robert.griebl@nokia.com>2011-01-24 17:47:01 (GMT)
commit81492e56aba5b5761500543665012a85d6835513 (patch)
tree0367717e1611d902d63dd7607a1610e63bc2acc3 /examples
parent64ec011c6132496eb9555c1d09e7fd4ddf472837 (diff)
downloadQt-81492e56aba5b5761500543665012a85d6835513.zip
Qt-81492e56aba5b5761500543665012a85d6835513.tar.gz
Qt-81492e56aba5b5761500543665012a85d6835513.tar.bz2
Various small fixes for the QScroller examples
Reviewed-By: TrustMe
Diffstat (limited to 'examples')
-rw-r--r--examples/scroller/graphicsview/main.cpp12
-rw-r--r--examples/scroller/plot/main.cpp9
-rw-r--r--examples/scroller/plot/plot.pro5
-rw-r--r--examples/scroller/plot/plotwidget.cpp2
-rw-r--r--examples/scroller/plot/plotwidget.h2
-rw-r--r--examples/scroller/plot/settingswidget.cpp2
-rw-r--r--examples/scroller/plot/settingswidget.h2
-rw-r--r--examples/scroller/wheel/main.cpp16
-rw-r--r--examples/scroller/wheel/wheel.pro5
-rw-r--r--examples/scroller/wheel/wheelwidget.cpp2
-rw-r--r--examples/scroller/wheel/wheelwidget.h2
11 files changed, 28 insertions, 31 deletions
diff --git a/examples/scroller/graphicsview/main.cpp b/examples/scroller/graphicsview/main.cpp
index e28978f..77d00f0 100644
--- a/examples/scroller/graphicsview/main.cpp
+++ b/examples/scroller/graphicsview/main.cpp
@@ -279,14 +279,18 @@ protected:
int main(int argc, char *argv[])
{
- QApplication app(argc, argv);
- bool useTouch = (app.arguments().contains(QLatin1String("--touch")));
- MainWindow mw(useTouch);
+ QApplication a(argc, argv);
+ bool touch = (a.arguments().contains(QLatin1String("--touch")));
+ MainWindow mw(touch);
+#ifdef Q_WS_S60
+ mw.showMaximized();
+#else
mw.show();
+#endif
#ifdef Q_WS_MAC
mw.raise();
#endif
- return app.exec();
+ return a.exec();
}
#include "main.moc"
diff --git a/examples/scroller/plot/main.cpp b/examples/scroller/plot/main.cpp
index acf83ee..6166505 100644
--- a/examples/scroller/plot/main.cpp
+++ b/examples/scroller/plot/main.cpp
@@ -4,7 +4,7 @@
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the examples of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** No Commercial Usage
@@ -208,15 +208,14 @@ int main(int argc, char **argv)
if (a.arguments().contains(QLatin1String("--touch")))
touch = true;
- MainWindow *mw = new MainWindow(smallscreen, touch);
+ MainWindow mw(smallscreen, touch);
if (smallscreen)
- mw->showMaximized();
+ mw.showMaximized();
else
- mw->show();
+ mw.show();
#if defined(Q_WS_MAC)
mw->raise();
#endif
-
return a.exec();
}
diff --git a/examples/scroller/plot/plot.pro b/examples/scroller/plot/plot.pro
index 8c37b04..04fdf70 100644
--- a/examples/scroller/plot/plot.pro
+++ b/examples/scroller/plot/plot.pro
@@ -11,8 +11,3 @@ target.path = $$[QT_INSTALL_EXAMPLES]/scroller/plot
sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS plot.pro
sources.path = $$[QT_INSTALL_EXAMPLES]/scroller/plot
INSTALLS += target sources
-
-symbian {
- TARGET.UID3 = 0xA000CF66
- include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri)
-}
diff --git a/examples/scroller/plot/plotwidget.cpp b/examples/scroller/plot/plotwidget.cpp
index 5f0df67..a03f613 100644
--- a/examples/scroller/plot/plotwidget.cpp
+++ b/examples/scroller/plot/plotwidget.cpp
@@ -4,7 +4,7 @@
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the examples of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** No Commercial Usage
diff --git a/examples/scroller/plot/plotwidget.h b/examples/scroller/plot/plotwidget.h
index 4987ebc..c96ceac 100644
--- a/examples/scroller/plot/plotwidget.h
+++ b/examples/scroller/plot/plotwidget.h
@@ -4,7 +4,7 @@
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the examples of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** No Commercial Usage
diff --git a/examples/scroller/plot/settingswidget.cpp b/examples/scroller/plot/settingswidget.cpp
index 840e3fc..1929eb6 100644
--- a/examples/scroller/plot/settingswidget.cpp
+++ b/examples/scroller/plot/settingswidget.cpp
@@ -4,7 +4,7 @@
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the examples of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** No Commercial Usage
diff --git a/examples/scroller/plot/settingswidget.h b/examples/scroller/plot/settingswidget.h
index 0ea201d..13edbf4 100644
--- a/examples/scroller/plot/settingswidget.h
+++ b/examples/scroller/plot/settingswidget.h
@@ -4,7 +4,7 @@
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the examples of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** No Commercial Usage
diff --git a/examples/scroller/wheel/main.cpp b/examples/scroller/wheel/main.cpp
index 4264377..203c930 100644
--- a/examples/scroller/wheel/main.cpp
+++ b/examples/scroller/wheel/main.cpp
@@ -4,7 +4,7 @@
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the examples of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** No Commercial Usage
@@ -107,12 +107,16 @@ private:
int main(int argc, char **argv)
{
QApplication a(argc, argv);
-
bool touch = a.arguments().contains(QLatin1String("--touch"));
-
- MainWindow *mw = new MainWindow(touch);
- mw->show();
-
+ MainWindow mw(touch);
+#ifdef Q_WS_S60
+ mw.showMaximized();
+#else
+ mw.show();
+#endif
+#ifdef Q_WS_MAC
+ mw.raise();
+#endif
return a.exec();
}
diff --git a/examples/scroller/wheel/wheel.pro b/examples/scroller/wheel/wheel.pro
index 1f9b789..48fe171 100644
--- a/examples/scroller/wheel/wheel.pro
+++ b/examples/scroller/wheel/wheel.pro
@@ -9,8 +9,3 @@ target.path = $$[QT_INSTALL_EXAMPLES]/scroller/wheel
sources.files = $$SOURCES $$HEADERS $$RESOURCES $$FORMS wheel.pro
sources.path = $$[QT_INSTALL_EXAMPLES]/scroller/wheel
INSTALLS += target sources
-
-symbian {
- TARGET.UID3 = 0xA000CF66
- include($$QT_SOURCE_TREE/examples/symbianpkgrules.pri)
-}
diff --git a/examples/scroller/wheel/wheelwidget.cpp b/examples/scroller/wheel/wheelwidget.cpp
index 64a459b..0449f53 100644
--- a/examples/scroller/wheel/wheelwidget.cpp
+++ b/examples/scroller/wheel/wheelwidget.cpp
@@ -4,7 +4,7 @@
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the examples of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** No Commercial Usage
diff --git a/examples/scroller/wheel/wheelwidget.h b/examples/scroller/wheel/wheelwidget.h
index c50f951..8f49169 100644
--- a/examples/scroller/wheel/wheelwidget.h
+++ b/examples/scroller/wheel/wheelwidget.h
@@ -4,7 +4,7 @@
** All rights reserved.
** Contact: Nokia Corporation (qt-info@nokia.com)
**
-** This file is part of the QtGui module of the Qt Toolkit.
+** This file is part of the examples of the Qt Toolkit.
**
** $QT_BEGIN_LICENSE:LGPL$
** No Commercial Usage