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. Model-view display progress
Forum Updated to NodeBB v4.3 + New Features

Model-view display progress

Scheduled Pinned Locked Moved General and Desktop
4 Posts 2 Posters 959 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.
  • N Offline
    N Offline
    NewQtGuy
    wrote on last edited by
    #1

    Hello,

    I have a model-view(N) setup where some of the rows represent a folder where the user can double-click into. The double click hooks into code that sets the current view's new root index. The current view then auto-majically calls the model's data() function to populate the view.

    I would like to post a progress bar to show progress of the view population. The population can be lengthy due to some app specific work being done. Can anyone suggest a strategy for this? I would like to keep any UI code out of the model code if possible.

    TIA,

    newguy

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

      Hi,

      Are you using a QFileSystemModel ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      N 1 Reply Last reply
      0
      • SGaistS SGaist

        Hi,

        Are you using a QFileSystemModel ?

        N Offline
        N Offline
        NewQtGuy
        wrote on last edited by
        #3

        @SGaist No, I have a custom model derived from QAbstractItemModel.

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Then you should add at least one signal that your GUI can use to know when loading is finished

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0

          • Login

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