[Qt] Add WebView.view attached property support for dialogs in QML
authorcaio.oliveira@openbossa.org <caio.oliveira@openbossa.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 21 Nov 2011 13:28:27 +0000 (13:28 +0000)
committercaio.oliveira@openbossa.org <caio.oliveira@openbossa.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Mon, 21 Nov 2011 13:28:27 +0000 (13:28 +0000)
commit16c9040e2847145b64f7aebebfef414c09bc6f0d
tree2409324fc5cb3e6fad012fe09a040cf3d5871923
parent4a1f7cfea06e171758ef073579cfd4160e2afd39
[Qt] Add WebView.view attached property support for dialogs in QML
https://bugs.webkit.org/show_bug.cgi?id=72825

Reviewed by Simon Hausmann.

.:

Export QQuickWebViewAttached.

* Source/qtwebkit-export.map:

Source/WebKit2:

When creating new dialogs, fill their WebView.view attached property
with the WebView that's creating them. This follows the same pattern
as QtQuick's ListView, enabling the usage of the same dialog component
for different WebViews.

* UIProcess/API/qt/qquickwebview.cpp:
(QQuickWebViewPrivate::runJavaScriptAlert):
(QQuickWebViewPrivate::runJavaScriptConfirm):
(QQuickWebViewPrivate::runJavaScriptPrompt):
(QQuickWebViewPrivate::setViewInAttachedProperties):
(QQuickWebViewAttached::QQuickWebViewAttached):
(QQuickWebViewAttached::setView):
(QQuickWebView::qmlAttachedProperties):
* UIProcess/API/qt/qquickwebview_p.h:
* UIProcess/API/qt/qquickwebview_p_p.h:
* UIProcess/API/qt/tests/qmltests/WebView/tst_javaScriptDialogs.qml:
* UIProcess/qt/QtDialogRunner.h:
(QtDialogRunner::dialog):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@100905 268f45cc-cd09-0410-ab3c-d52691b4dbfc
ChangeLog
Source/WebKit2/ChangeLog
Source/WebKit2/UIProcess/API/qt/qquickwebview.cpp
Source/WebKit2/UIProcess/API/qt/qquickwebview_p.h
Source/WebKit2/UIProcess/API/qt/qquickwebview_p_p.h
Source/WebKit2/UIProcess/API/qt/tests/qmltests/WebView/tst_javaScriptDialogs.qml
Source/WebKit2/UIProcess/qt/QtDialogRunner.h
Source/qtwebkit-export.map