Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. fetch items incrementally when canFetchMore() and fetchMode() are not implemented
Forum Updated to NodeBB v4.3 + New Features

fetch items incrementally when canFetchMore() and fetchMode() are not implemented

Scheduled Pinned Locked Moved Unsolved General and Desktop
5 Posts 3 Posters 339 Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • U Offline
    U Offline
    user4592357
    wrote on last edited by
    #1

    i'm using an existing model and view.
    the model doesn't implement canFetchMore() and fetchMode().
    can i still fetch items incrementally?

    1 Reply Last reply
    0
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi
      Not that i know of. fectchMore is for that.
      Cant you add it to the model ? Maybe subclass it.

      U 1 Reply Last reply
      0
      • mrjjM mrjj

        Hi
        Not that i know of. fectchMore is for that.
        Cant you add it to the model ? Maybe subclass it.

        U Offline
        U Offline
        user4592357
        wrote on last edited by
        #3

        @mrjj
        there are many hardcoded things and it's difficult to change even one thing there :(

        mrjjM JonBJ 2 Replies Last reply
        0
        • U user4592357

          @mrjj
          there are many hardcoded things and it's difficult to change even one thing there :(

          mrjjM Offline
          mrjjM Offline
          mrjj
          Lifetime Qt Champion
          wrote on last edited by
          #4

          @user4592357
          That sounds like a bad model :)

          I would still try as fetchMore might no require much change to the model.
          https://doc.qt.io/qt-5/qtwidgets-itemviews-fetchmore-example.html
          here it just calls beginInsertRows but i cant guess if that will work with your model if its oddly made.

          Its not an option to make a better model ?

          1 Reply Last reply
          0
          • U user4592357

            @mrjj
            there are many hardcoded things and it's difficult to change even one thing there :(

            JonBJ Offline
            JonBJ Offline
            JonB
            wrote on last edited by
            #5

            @user4592357
            This does not make sense. If you cannot implement canFetchMore() & fetchMore() for your model, then "by definition" your model does not support incremental fetching. If it does, then you must be able to implement these, easily.

            1 Reply Last reply
            1

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved