[Qt][WK2] Support multi-file upload
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 27 Mar 2012 02:29:41 +0000 (02:29 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Tue, 27 Mar 2012 02:29:41 +0000 (02:29 +0000)
commit10c4f2ee8d61ae0f47cd4bdffe8971e5e01cb4b1
tree382dff514b5a6b3a97ae5ca69c05aa172fc401a6
parent0fd20e9a822962c6c17769b67988673f04566cf0
[Qt][WK2] Support multi-file upload
https://bugs.webkit.org/show_bug.cgi?id=81589

Patch by Dinu Jacob <dinu.jacob@nokia.com> on 2012-03-26
Reviewed by Simon Hausmann.

Source/WebKit2:

Added 'allowMutipleFiles' property to filePicker context property to indicate whether to allow
multiple file selections.

* UIProcess/API/qt/qquickwebview.cpp:
(QQuickWebViewPrivate::chooseFiles):
* UIProcess/API/qt/tests/qmltests/DesktopBehavior.pro:
* UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_multiFileUpload.qml: Added.
* UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_singleFileUpload.qml:
* UIProcess/API/qt/tests/qmltests/common/multifileupload.html: Added.
* UIProcess/API/qt/tests/qmltests/common/singlefileupload.html:
* UIProcess/API/qt/tests/qmltests/common/titleupdate.js: Added.
(updateTitle):
* UIProcess/qt/QtDialogRunner.cpp:
(FilePickerContextObject):
(FilePickerContextObject::FilePickerContextObject):
(FilePickerContextObject::allowMultipleFiles):
(FilePickerContextObject::accept):
(QtDialogRunner::initForFilePicker):
* UIProcess/qt/QtDialogRunner.h:
(QtDialogRunner):

Tools:

Modified filePicker to support multi-file upload.

* MiniBrowser/qt/MiniBrowser.qrc:
* MiniBrowser/qt/icons/checkbox_checked.png: Added.
* MiniBrowser/qt/icons/checkbox_unchecked.png: Added.
* MiniBrowser/qt/js/MultiSelect.js: Added.
(values):
(isSelected):
(removeValue):
* MiniBrowser/qt/qml/CheckBox.qml: Added.
* MiniBrowser/qt/qml/FilePicker.qml:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@112195 268f45cc-cd09-0410-ab3c-d52691b4dbfc
17 files changed:
Source/WebKit2/ChangeLog
Source/WebKit2/UIProcess/API/qt/qquickwebview.cpp
Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopBehavior.pro
Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_multiFileUpload.qml [new file with mode: 0644]
Source/WebKit2/UIProcess/API/qt/tests/qmltests/DesktopBehavior/tst_singleFileUpload.qml
Source/WebKit2/UIProcess/API/qt/tests/qmltests/common/multifileupload.html [new file with mode: 0644]
Source/WebKit2/UIProcess/API/qt/tests/qmltests/common/singlefileupload.html
Source/WebKit2/UIProcess/API/qt/tests/qmltests/common/titleupdate.js [new file with mode: 0644]
Source/WebKit2/UIProcess/qt/QtDialogRunner.cpp
Source/WebKit2/UIProcess/qt/QtDialogRunner.h
Tools/ChangeLog
Tools/MiniBrowser/qt/MiniBrowser.qrc
Tools/MiniBrowser/qt/icons/checkbox_checked.png [new file with mode: 0644]
Tools/MiniBrowser/qt/icons/checkbox_unchecked.png [new file with mode: 0644]
Tools/MiniBrowser/qt/js/MultiSelect.js [new file with mode: 0644]
Tools/MiniBrowser/qt/qml/CheckBox.qml [new file with mode: 0644]
Tools/MiniBrowser/qt/qml/FilePicker.qml