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

QPixmap is unable to construct QPixmap(url) in Android 7

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Not Evaluated Not Evaluated
    • None
    • 5.9.2
    • None
    • Android 7.1.1 MIUI 8.5
      build in windows 10 x64
      Qt 5.9.2

      On android I am trying to construct QPixmap from local storage (internal). It works fine on android below 7. But when doing same in Android 7.1.1 MIUI 8 the QPixmap(url.toLocalPath()) creates Null pixmap.
      The url is right.

      Q_INVOKABLE void setProfileImage(const QString &fileUrl) {
              QUrl url = fileUrl;
              setImgUrl(url.toLocalFile()); // debug del
              setProfileImage(QPixmap(url.toLocalFile()));
          }
      void setProfileImage(const QPixmap &t_profileImage) {
              chargeImageProvider(t_profileImage);
              m_worker->setProfileImage(t_profileImage); // TODO make it work in separate thread.
          }
      

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

            thiago Thiago Macieira
            kofr Konstantinr
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes