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

QSortFilterProxyModel not filtering properly

    XMLWordPrintable

Details

    • Bug
    • Resolution: Invalid
    • P1: Critical
    • None
    • 6.8.1
    • Core: Item Models
    • None
    • Windows

    Description

      Setting true/false values in filterAcceptsRow does not correctly set items visible.

      I have provided an example that shows the issue

      Simple list of items, each with a filename and rating. ratings are 0-5, 0 is unrated.

      RatingFilterProxyModel filter based on ratings with a QSet.  

       

      In main, use check box to select on or more rating to show.  If no ratings are checked, all items are displayed.

       

      filterAcceptsRow in RatingFilterProxyModel prints out return values

       

      Each items uses its row 0-5, for its rating. 

       

      Attachments

        1. Proxy.mp4
          69 kB
        2. ProxyTest.cpp
          8 kB
        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            dfaure_kdab David Faure
            doug_rogers Doug Rogers
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes