Thank you very much for your help.

Even if it's a very silly question, I have to ask it (sorry 'bout that):

Whats the "correct" way to implement the dragEnterEvent and dragMoveEvent functions - is this the way?


Qt Code:
  1. void myQTTreeWidget::dragEnterEvent(QDragEnterEvent *e)
  2. {
  3. // always call base class implementation
  4. QTreeWidget::dragEnterEvent(e);
  5.  
  6. if ( isDragEnterPossible(e) )
  7. {
  8. e->accept();
  9. }
  10. else
  11. {
  12. e->ignore();
  13. }
  14. }
  15.  
  16. void myQTTreeWidget::dragMoveEvent(QDragMoveEvent *e)
  17. {
  18. // always call base class implementation
  19. QTreeWidget::dragMoveEvent(e);
  20.  
  21. if ( isDragMovePossible(e) )
  22. {
  23. e->accept();
  24. }
  25. else
  26. {
  27. e->ignore();
  28. }
  29. }
To copy to clipboard, switch view to plain text mode 

isDragMovePossible and isDragEnterPossible are member functions, returning a bool value and telling us if dropping is possible.