summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorAndrew Knight <andrew.knight@intopalo.com>2015-08-23 23:40:01 +0300
committerAndrew Knight <andrew.knight@intopalo.com>2015-08-25 04:47:33 +0000
commit5bbbd6cdfec885a1ecd88687ce7e5497df5ba09a (patch)
treebd61cbb7f36b4870d9b8afc92e1c4c81add6484e /examples
parent119db3c806220038ba3a10bc9dc0b4afb1e3bfbf (diff)
Add support for Windows Runtime
Now that WinRT uses XAML-based windows, it can support creating native WebView controls. Change-Id: I04361956eba9de5b5d41fcc6b57a9772b49f6a2b Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
Diffstat (limited to 'examples')
-rw-r--r--examples/webview/minibrowser/main.cpp6
-rw-r--r--examples/webview/minibrowser/minibrowser.pro2
2 files changed, 7 insertions, 1 deletions
diff --git a/examples/webview/minibrowser/main.cpp b/examples/webview/minibrowser/main.cpp
index 5daecc0..390d591 100644
--- a/examples/webview/minibrowser/main.cpp
+++ b/examples/webview/minibrowser/main.cpp
@@ -78,7 +78,11 @@ int main(int argc, char *argv[])
parser.addHelpOption();
parser.addVersionOption();
parser.addPositionalArgument("url", "The initial URL to open.");
- parser.process(app);
+ QStringList arguments = app.arguments();
+#ifdef Q_OS_WINRT
+ arguments.removeAt(1); // The launcher always passes in the -ServerName parameter, breaking the command line parser
+#endif
+ parser.process(arguments);
const QString initialUrl = parser.positionalArguments().isEmpty() ?
QStringLiteral("qt.io") : parser.positionalArguments().first();
diff --git a/examples/webview/minibrowser/minibrowser.pro b/examples/webview/minibrowser/minibrowser.pro
index c7ffb31..a9b3222 100644
--- a/examples/webview/minibrowser/minibrowser.pro
+++ b/examples/webview/minibrowser/minibrowser.pro
@@ -2,6 +2,8 @@ TEMPLATE = app
QT += qml quick webview
+winrt: WINRT_MANIFEST.capabilities += internetClient
+
SOURCES += main.cpp
RESOURCES += qml.qrc