PDA

View Full Version : Help on QListWidget InternalMove item signal



tho97
4th February 2009, 20:35
I need help on QListWidget InternalMove item signal.
I have a QList keeps track of all items in a QListWidget. So when I drag and drop an item in a same QListWidget I need a signal to rearrange the items in the QList. How can I get that signal? I try to use dragEnterEvent() and dropEvent() but didn't work. I can't use currentRowChanged() or itemPressed() signal because they are used for other things.

tho97
6th February 2009, 18:27
Can anyone help me to get the signal in drag and drop of InternalMove mode?

Lykurg
6th February 2009, 19:07
Hi,

maybe QListView::indexesMoved(...) could help you.

Lykurg

tho97
14th February 2009, 02:13
QListView::indexesMoved(...) signal does not work, so I use eventFilter() to catch the event for internalmove in QListWidget. Whenever I drag and drop within QListWidget it will send QEvent::ChildRemoved event.