Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-35512

Qt Quick Dialogs & FolderListModel on Android do not list directory content when a folder item is selected

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P5: Not important
    • None
    • 5.2.0 RC1
    • QPA
    • None
    • Android

    Description

      Qt Quick Dialogs & FolderListModel on Android do not list directory content when a folder item is selected and result in an error when a target file is selected. This is because the folder property is no longer a QString but is now a QUrl.

      The Dialogs FileDialog QML component on Android uses the Qt.labs.FolderListModel plugin and I think the issue comes from when the folder QUrl property is assigned from the filePath QString property.

      A workaround is possible using the "file:///" + prefix. This prefix is also needed when the item is selected as follows:

      function launch() {
      if (folders.isFolder(index))

      { down("file:///" + filePath); }

      else

      { itemSelected("file:///" + filePath); }

      }

      Attachments

        Issue Links

          No reviews matched the request. Check your Options in the drop-down menu of this sections header.

          Activity

            People

              rampe Rami Potinkara
              davered David Robinson
              Veli-Pekka Heinonen Veli-Pekka Heinonen
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes