[Qt][WK2] Pages / resources cannot be loaded from qrc files.
authormichael.bruning@digia.com <michael.bruning@digia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 24 Jan 2013 12:25:19 +0000 (12:25 +0000)
committermichael.bruning@digia.com <michael.bruning@digia.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 24 Jan 2013 12:25:19 +0000 (12:25 +0000)
commit91b427b177825b5623e45002f893d402fa644e48
tree1a523c345c032032fc4c7e256bb65d12506e9b62
parent534c5ffa8c7c1a85566e04d41b384e31d09985da
[Qt][WK2] Pages / resources cannot be loaded from qrc files.
https://bugs.webkit.org/show_bug.cgi?id=107031

Reviewed by Jocelyn Turcotte.

Enables WebKit2 Qt applications to load files from the bundled
qrc files. This is achieved by adding a url scheme handler for
the "qrc" scheme using the application scheme handler and ignoring
all handlers for the qrc application scheme that the application might
set.

* UIProcess/API/qt/qquickurlschemedelegate.cpp:
(QQuickQrcSchemeDelegate::QQuickQrcSchemeDelegate):
(QQuickQrcSchemeDelegate::readResourceAndSend):
* UIProcess/API/qt/qquickurlschemedelegate_p.h:
(QQuickQrcSchemeDelegate):
* UIProcess/API/qt/qquickwebview.cpp:
(QQuickWebViewPrivate::initialize):
(QQuickWebViewExperimental::schemeDelegates_Append):
(QQuickWebViewExperimental::invokeApplicationSchemeHandler):
* UIProcess/API/qt/tests/qmltests/WebView/tst_applicationScheme.qml:
* UIProcess/API/qt/tests/qmltests/common/qrctest.html: Added.
* UIProcess/API/qt/tests/qmltests/resources.qrc:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@140676 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebKit2/ChangeLog
Source/WebKit2/UIProcess/API/qt/qquickurlschemedelegate.cpp
Source/WebKit2/UIProcess/API/qt/qquickurlschemedelegate_p.h
Source/WebKit2/UIProcess/API/qt/qquickwebview.cpp
Source/WebKit2/UIProcess/API/qt/tests/qmltests/WebView/tst_applicationScheme.qml
Source/WebKit2/UIProcess/API/qt/tests/qmltests/common/qrctest.html [new file with mode: 0644]
Source/WebKit2/UIProcess/API/qt/tests/qmltests/resources.qrc