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. How to check if a delegate is endmost in a ListView?
Forum Updated to NodeBB v4.3 + New Features

How to check if a delegate is endmost in a ListView?

Scheduled Pinned Locked Moved QML and Qt Quick
4 Posts 2 Posters 828 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
    qwasder
    wrote on last edited by
    #1

    Much like I can use index === 0 within a Delegate to check whether it's first, can I find out if a Delegate is last in a ListView?

    1 Reply Last reply
    0
    • p3c0P Offline
      p3c0P Offline
      p3c0
      Moderators
      wrote on last edited by
      #2

      Hi,

      index === listview.model.count-1, where listview being id of ListView.

      157

      1 Reply Last reply
      0
      • Q Offline
        Q Offline
        qwasder
        wrote on last edited by
        #3

        [quote author="p3c0" date="1424076108"]Hi,

        index === listview.model.count-1, where listview being id of ListView.[/quote]

        You're totally right, didn't think of this. Thank you very much!

        1 Reply Last reply
        0
        • p3c0P Offline
          p3c0P Offline
          p3c0
          Moderators
          wrote on last edited by
          #4

          You're Welcome :)
          You can mark the post as solved by editing the post title and prepending [solved].

          157

          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