Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Are items out of listview visible area deleted ?
Forum Updated to NodeBB v4.3 + New Features

Are items out of listview visible area deleted ?

Scheduled Pinned Locked Moved QML and Qt Quick
2 Posts 2 Posters 805 Views 1 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.
  • W Offline
    W Offline
    wshn14
    wrote on last edited by
    #1

    I have a listview contains 10 items , but only 3 items visible at the same time .If I slide the view ,are the invisible item deleted in memory when the items from visible to invisible?

    1 Reply Last reply
    0
    • J Offline
      J Offline
      Jens
      wrote on last edited by
      #2

      Yes they are. Only as many items as you can see on screen are guaranteed to be alive at any given time, which is why you should be careful about relying on storing any state in the items themselves. You can set the cacheBuffer property to a higher value to keep more items alive in the view. This can sometimes improve scrolling performance at the cost of memory (and startup time).

      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