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 drag an item from one ListView to another
QtWS25 Last Chance

How to drag an item from one ListView to another

Scheduled Pinned Locked Moved Unsolved QML and Qt Quick
4 Posts 2 Posters 1.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.
  • N Offline
    N Offline
    Nelly
    wrote on 18 Dec 2016, 10:02 last edited by
    #1

    Hi, everyone!
    I started to learn QML recently. And I faced the problem of dragging.
    I would like to know is it possible to drag an item from one ListView to another?
    I learnt Drag and Drop in the Documentation, but I didn’t understand how to implement it.```

    1 Reply Last reply
    0
    • M Offline
      M Offline
      mrjj
      Lifetime Qt Champion
      wrote on 18 Dec 2016, 10:05 last edited by mrjj
      #2

      Hi
      Just to make sure you saw this free book
      https://qmlbook.github.io/
      :)

      1 Reply Last reply
      0
      • N Offline
        N Offline
        Nelly
        wrote on 18 Dec 2016, 11:26 last edited by
        #3

        I have looked at this book, good book, but I didn't see something for my question

        M 1 Reply Last reply 18 Dec 2016, 11:52
        0
        • N Nelly
          18 Dec 2016, 11:26

          I have looked at this book, good book, but I didn't see something for my question

          M Offline
          M Offline
          mrjj
          Lifetime Qt Champion
          wrote on 18 Dec 2016, 11:52 last edited by mrjj
          #4

          @Nelly
          Ok, didn't read it yet ;)
          This tut
          http://doc.qt.io/qt-5/qtquick-tutorials-dynamicview-dynamicview1-example.html
          Goes into drag drop (inner)
          http://doc.qt.io/qt-5/qtquick-tutorials-dynamicview-dynamicview3-example.html
          maybe it will give info.

          Also
          http://doc.qt.io/qt-5/qtquick-draganddrop-example.html

          In c++, Views have default drag and drop if enabled. I wonder if QML somehow offer the same.
          Let me check it.
          http://stackoverflow.com/questions/26045587/using-drag-and-drop-with-listview-to-create-an-inventory-ui

          Is the closest sample that come up. (credits to wieland)

          Give it some days. Maybe others have more suggestions.

          1 Reply Last reply
          1

          3/4

          18 Dec 2016, 11:26

          • Login

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