Results 1 to 3 of 3

Thread: Drag and Drop in a QTreeWidget subclass

  1. #1
    Join Date
    May 2008
    Posts
    2
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Drag and Drop in a QTreeWidget subclass

    I have two types of items (say A & B) in a tree widget. A button will separate these items.
    When I drop items of type A (which are present at the top of the Button), on to items of type B (which are present below the button), the type A items will be added to type B items as child items.

    Once all the type A items are dropped on to type B items, the Button will be moved to the top of the list.

    My requirement is when I drop type A items again on to the Button, they should be moved to the top of the list.

    But the problem here is, the drop event function is not getting called when I drop the items on to Button.

    This works fine on Windows. But on Mac this is not working!!

    Any ideas on how to implement this?

  2. #2
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,364
    Thanks
    3
    Thanked 5,013 Times in 4,791 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: Drag and Drop in a QTreeWidget subclass

    Drop event method of which widget is not called? The button or the tree widget?

  3. #3
    Join Date
    May 2008
    Posts
    2
    Qt products
    Qt4
    Platforms
    MacOS X Windows

    Default Re: Drag and Drop in a QTreeWidget subclass

    Button as well as the tree widget also!

Similar Threads

  1. QTreeWidget Drag and drop
    By zell99 in forum Newbie
    Replies: 15
    Last Post: 7th August 2010, 14:28
  2. Problem with a cursor during Drag and Drop
    By mtrpoland in forum Qt Programming
    Replies: 1
    Last Post: 28th December 2007, 16:46
  3. Drag an item from QTreeWidget and drop in TableView
    By steg90 in forum Qt Programming
    Replies: 8
    Last Post: 18th May 2007, 12:42
  4. Replies: 7
    Last Post: 8th September 2006, 17:19
  5. Drag and drop revisited
    By Big Duck in forum Newbie
    Replies: 2
    Last Post: 30th June 2006, 17:41

Tags for this Thread

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.