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

Add an API for programmatically getting a path to external storage devices

    XMLWordPrintable

Details

    • Android
    • Next

    Description

      (This suggestion was triggered by a customer's desire for an easier way to get to the SD card from Android; hopefully the solution would benefit other platforms too)

      Currently, programmatically finding the path to the SD card on Android requires QJniObject and QJniEnvironment: https://forum.qt.io/topic/133123/write-access-to-sd-card-in-android

      It would be nice to have a simpler API to get this path without the JNI or requiring the user to pick it via the native Picker dialog.

      Perhaps a new enum, QStandardPaths::ExternalDataLocation, QStandardPaths::SecondaryDataLocation, or similar? This can return, say, the path to the SD card on a mobile device (if the required permissions have been obtained), or the path(s) to the external hard drive(s) on a PC. Admittedly, these aren't very "standard" paths and would require scanning, so QStandardPaths might not be suitable.

      Attachments

        Issue Links

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

          Activity

            People

              qtandroidteam Qt Android Team
              skoh-qt Sze Howe Koh
              Vladimir Minenko Vladimir Minenko
              Votes:
              1 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:

                Gerrit Reviews

                  There are no open Gerrit changes