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

FolderListModel 2.12: can't turn off caseSensitive property

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • 5.14.0 Alpha
    • 5.12.2
    • Quick: Other
    • None
    • macOS 10.13.6
    • macOS
    • 2b566231a6e35ee1646754cee09b30fc99240a80 (qt/qtdeclarative/5.14)

    Description

      FolderListModel (version 2.12, REVISION 12) works for me in all respects except that its caseSensitive property is always set to true and can't be turned off.  I don't see any coding error in folderlistmodel/qquickfolderlistmodel.{h,cpp} that would explain this problem.  The impact is that calls to its indexOf method can return -1 instead of the expected index of a case-insensitive file-URL match.

      import Qt.labs.folderlistmodel 2.12;

      FolderListModel {

        id: testModel;

        // This property doesn't seem to work as documented.

        caseSensitive: false;

        folder: "file:///path/to/folder";

        Component.onCompleted: {

          // Set a breakpoint here to watch the value *not* change.

          caseSensitive = false;

          caseSensitive = false;

          console.log(caseSensitive);  // logs "true"

      {

      {  }

      {{}

      Attachments

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

        Activity

          People

            w00t Robin Burchell
            barbicels- R Brown
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes