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. [Solved] Vertical ListView in horizontal ListView
QtWS25 Last Chance

[Solved] Vertical ListView in horizontal ListView

Scheduled Pinned Locked Moved QML and Qt Quick
5 Posts 3 Posters 5.2k Views
  • 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.
  • M Offline
    M Offline
    mario
    wrote on last edited by
    #1

    I wonder if there are any nice solutions to my problem?

    For example:

    I have a horizontal ListView which contains vertical ListViews, one for each day of the week. There's no problem panning the vertical ListView for one day but I'm not able to pan to another day since it seems that the vertical ListView eats the horizontal panning gestures.

    Any ideas?

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

      I was solving the same problem as you and it works for me. Please see "this topic.":http://developer.qt.nokia.com/forums/viewthread/1832/

      1 Reply Last reply
      0
      • M Offline
        M Offline
        mario
        wrote on last edited by
        #3

        I solved it!

        In my delegate I had:
        @
        ListView { id: view; ... }

        Component {
            id: dayDelegate
        
            Item {
                id: wrapper
                width: parent.width
                height: parent.height
                ...
        

        @

        but I should have used:
        @
        ListView { id: view; ... }

        Component {
            id: dayDelegate
        
            Item {
                id: wrapper
                width: view.width
                height: view.height
                ...
        

        @

        In other words, I have to use the id of the list view and not parent.

        1 Reply Last reply
        0
        • H Offline
          H Offline
          Hassan Kassem
          wrote on last edited by
          #4

          can you flick now in two directions ( horizontal and vertical)?

          1 Reply Last reply
          0
          • J Offline
            J Offline
            jech
            wrote on last edited by
            #5

            Yes, it works for me.

            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