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

Clarify handling of FileDialog.nameFilter on Android

XMLWordPrintable

    • Android
    • e44506750 (dev), 54ed65891 (6.9), c659fcc48 (6.8), 8af3c1f9b (tqtc/lts-6.5)

      It seems that, when FileDialog.nameFilter is set, the native Android file dialog doesn't show any files - regardless of whether some would match the current filter or not. See qtbug-114957.7z for a simple application that should be able to list an *.mp4 file.

      The QFileDialog::setNameFilter documentation actually mentions that Android file dialog by default doesn't allow suffix based filtering, but hints to a workaround:

      Note: With Android's native file dialog, the mime type matching the given name filter is used because only mime types are supported.

      Anyhow, it is unclear whether the same logic applies to QtQuick.Controls::FileDialog, and how a filter needs to be written so that it has a 'matching' mime type.

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

            nick_bennett Nicholas Bennett
            kkohne Kai Köhne
            Votes:
            3 Vote for this issue
            Watchers:
            6 Start watching this issue

              Created:
              Updated:
              Resolved: