Results 1 to 2 of 2

Thread: QlistWidget Missing signal for Drop action

  1. #1
    Join Date
    Mar 2009
    Posts
    1
    Qt products
    Qt4
    Platforms
    Windows

    Question QlistWidget Missing signal for Drop action

    Hi "bonjour"
    I went to know if its possible to be informed when an item is added by drag&drop action in a QlisWidget.
    To explain my need :
    I have two QlisWidget. The first one contain a list of simple strings. The user can drag & drop from this list to the second items.
    Problem is that with the standard behaviour of QlisWidget I can have duplicate items in my second list.
    One functional solution could be : a drag&move behaviour (but i don't know how to code this.
    other one is to have a signal after the drop and i will then remove the duplicate item

    Last information :
    I am using Qt creator with ui and I don't went to have my own QlisWidget class.

    So is-it possible and how
    Thanks all of you in advance ;-)

  2. #2
    Join Date
    Oct 2006
    Location
    New Delhi, India
    Posts
    2,467
    Thanks
    8
    Thanked 334 Times in 317 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11 Windows

    Default Re: QlistWidget Missing signal for Drop action

    You will need to override QAbstractItemView::startDragand set the option to Qt::MoveAction. I guess you can try and check...

Similar Threads

  1. Help on QListWidget InternalMove item signal
    By tho97 in forum Qt Programming
    Replies: 3
    Last Post: 14th February 2009, 01:13
  2. pthread instead QThread
    By brevleq in forum Qt Programming
    Replies: 8
    Last Post: 23rd December 2008, 07:16
  3. Connection of custon signals/slots
    By brevleq in forum Qt Programming
    Replies: 2
    Last Post: 23rd December 2008, 07:04

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.