summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@nokia.com>2009-09-18 14:22:36 (GMT)
committerLars Knoll <lars.knoll@nokia.com>2009-09-18 14:22:36 (GMT)
commitaa469e92bf79e962ae3e0f2634237c75e6108e7c (patch)
tree6ea8fe32e7f00adcf13231727f2e063b0e1d08ae /tools
parent0e7e62eb6afbc1f20d08b837643009cec8eaacb9 (diff)
downloadQt-aa469e92bf79e962ae3e0f2634237c75e6108e7c.zip
Qt-aa469e92bf79e962ae3e0f2634237c75e6108e7c.tar.gz
Qt-aa469e92bf79e962ae3e0f2634237c75e6108e7c.tar.bz2
add a -fullscreen option.
Diffstat (limited to 'tools')
-rw-r--r--tools/qmlviewer/main.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/tools/qmlviewer/main.cpp b/tools/qmlviewer/main.cpp
index 87d1232..c5bf868 100644
--- a/tools/qmlviewer/main.cpp
+++ b/tools/qmlviewer/main.cpp
@@ -26,6 +26,7 @@ void usage()
qWarning(" options:");
qWarning(" -v, -version ............................. display version");
qWarning(" -frameless ............................... run with no window frame");
+ qWarning(" -fullscreen............................... run fullscreen");
qWarning(" -skin <qvfbskindir> ...................... run with a skin window frame");
qWarning(" \"list\" for a list of built-ins");
qWarning(" -resizeview .............................. resize the view, not the skin");
@@ -81,11 +82,14 @@ int main(int argc, char ** argv)
int cache = 0;
QString translationFile;
bool useGL = false;
+ bool fullScreen = false;
for (int i = 1; i < argc; ++i) {
QString arg = argv[i];
if (arg == "-frameless") {
frameless = true;
+ } else if (arg == "-fullscreen") {
+ fullScreen = true;
} else if (arg == "-skin") {
skin = QString(argv[++i]);
} else if (arg == "-resizeview") {
@@ -161,9 +165,9 @@ int main(int argc, char ** argv)
viewer.setRecordArgs(recordargs);
if (!fileName.isEmpty()) {
viewer.openQml(fileName);
- viewer.show();
+ fullScreen ? viewer.showFullScreen() : viewer.show();
} else {
- viewer.show();
+ fullScreen ? viewer.showFullScreen() : viewer.show();
viewer.open();
}
viewer.raise();