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. checked checkboxes Will be Unchecked when i scroll scrollview
Forum Updated to NodeBB v4.3 + New Features

checked checkboxes Will be Unchecked when i scroll scrollview

Scheduled Pinned Locked Moved Solved QML and Qt Quick
3 Posts 2 Posters 364 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.
  • Q Offline
    Q Offline
    qAminzzz
    wrote on last edited by qAminzzz
    #1

    hi, i found a bug, i have a scrollview and listview
    in each item there is a checkbox
    when i scroll any checkbox that i checked will be unchecked

    i checked here

    bug1.PNG

    now i scroll

    bug2.PNG

    now is unchecked |:

    please help me to solve this

    J.HilkJ 1 Reply Last reply
    0
    • Q qAminzzz

      hi, i found a bug, i have a scrollview and listview
      in each item there is a checkbox
      when i scroll any checkbox that i checked will be unchecked

      i checked here

      bug1.PNG

      now i scroll

      bug2.PNG

      now is unchecked |:

      please help me to solve this

      J.HilkJ Offline
      J.HilkJ Offline
      J.Hilk
      Moderators
      wrote on last edited by
      #2

      @qAminzzz it's not a bug.

      the elements are destroyed when you scroll them off screen and newly created when you scroll back.

      The solution is to store the checked state outside of the delegate. Probably in the model in this case


      Be aware of the Qt Code of Conduct, when posting : https://forum.qt.io/topic/113070/qt-code-of-conduct


      Q: What's that?
      A: It's blue light.
      Q: What does it do?
      A: It turns blue.

      Q 1 Reply Last reply
      2
      • J.HilkJ J.Hilk

        @qAminzzz it's not a bug.

        the elements are destroyed when you scroll them off screen and newly created when you scroll back.

        The solution is to store the checked state outside of the delegate. Probably in the model in this case

        Q Offline
        Q Offline
        qAminzzz
        wrote on last edited by
        #3
        This post is deleted!
        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