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

FileDialog on Android returns "content:" url scheme which is unusable with QFile/QImage

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Incomplete
    • Icon: P1: Critical P1: Critical
    • None
    • 6.6.1
    • Quick: Widget
    • None
    • Ubuntu 22.04, Android 9, Qt 6.6.1, NDK 25.1.89..., Android API 34
    • Android
    • 2024wk08FOQtforAndroid, 2024wk10FOQtforAndroid, 2024wk12FOQtforAndroid, 2024wk14FOQtforAndroid, 2024wk16FOQtforAndroid

      import QtCore
      import QtQuick
      import QtQuick.Dialogs
      
      FileDialog {
          id: root
          nameFilters: ["Image files (*.jpg *.jpeg *.png *.bmp *.gif *.pbm *.pgm *.ppm *.xbm *.xpm)"]
          currentFolder: StandardPaths.standardLocations(
                             StandardPaths.PicturesLocation)[0]
          fileMode: FileDialog.OpenFile
      }
      

      After picking a file returns URl of scheme "content:" "content://com.android.providers.media.documents/document/image%3A620513"
      which is unusable with QFile/QImage.
      It must be usable.

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

            lapohjan Lauri Pohjanheimo
            kofr Konstantinr
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes