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

Make QAbstractListModel/QAbstractItemModel as Endless

    XMLWordPrintable

Details

    • Suggestion
    • Resolution: Unresolved
    • P5: Not important
    • None
    • 5.7.1
    • Widgets: Itemviews
    • None

    Description

      In QAbstractItemModel we can use fetchMore() and canFetchMore() for incremental loading model.
      But in order to better memory management and faster startup, we can clear earlier data elements and loads them whenever needed.
      Currently I implemented an simple Model based on QAbstractListModel with my own methods. Model loads more data elements whenever an threshold be reached and then removes old ones from opposite side. So total buffer size remains fixed. Also I chose threshold as 0.25 of total buffer size for less need to fetching more data. I guess that you can implement better strategy in a more efficient way.
      With millions of data elements which loads over time and unloads old data elements, memory usage is good, startup is fast and scrolling is smooth.
      So I suggest you to extend fetchMore() method/functionality of the QAbstractItemModel to support two direction loading data and furthermore remove old one.

      Attachments

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

        Activity

          People

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            seyed_m S.M.Mousavi
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes