Sailfish Pickers
API DocumentationMultiDownloadPickerDialog QML Type
A download picker for selecting multiple downloaded files. More...
Import Statement: | import Sailfish.Pickers 1.0 |
Detailed Description
Here is an example usage:
import QtQuick 2.2 import Sailfish.Silica 1.0 import Sailfish.Pickers 1.0 ApplicationWindow { initialPage: Component { Page { property string selectedFiles SilicaFlickable { contentHeight: column.height + Theme.paddingLarge*2 anchors.fill: parent VerticalScrollDecorator {} Column { id: column width: parent.width PageHeader { title: "Multi download picker example" } ValueButton { anchors.horizontalCenter: parent.horizontalCenter label: "Upload downloaded files" value: selectedFiles ? selectedFiles : "None" onClicked: pageStack.push(multiDownloadPickerDialog) } } } Component { id: multiDownloadPickerDialog MultiDownloadPickerDialog { onAccepted: { selectedFiles = "" var urls = [] for (var i = 0; i < selectedContent.count; ++i) { var url = selectedContent.get(i).url // Handle url upload urls.push(selectedContent.get(i).url) } selectedFiles = urls.join(", ") } onRejected: selectedFiles = "" } } } } }
Use DownloadPickerPage to select a single download.
See also MultiContentPickerDialog, MultiDocumentPickerDialog, MultiFilePickerDialog, MultiImagePickerDialog, MultiMusicPickerDialog, and MultiVideoPickerDialog.