Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Behind the Scenes
  3. Wiki Discussion
  4. Drag&Drop exec function documentation
Forum Updated to NodeBB v4.3 + New Features

Drag&Drop exec function documentation

Scheduled Pinned Locked Moved Unsolved Wiki Discussion
2 Posts 2 Posters 1.3k Views 1 Watching
  • 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.
  • V Offline
    V Offline
    van9petryk
    wrote on last edited by
    #1

    When drag&drop operation is performed between two apps and is started by calling exec() method with following parameters:

    drag->exec(Qt::MoveAction | Qt::CopyAction, Qt::MoveAction)
    

    the defaultDropAction (second parameter) which actually is Qt::MoveAction will be changed to Qt::CopyAction. I don't found any mention about it in documentation.

    Another thing. In the Fridge Magnets Example at the Dropping section it seems that following check is redundant:

    if (children().contains(event->source())) {
    

    Also same check is performed in dragMoveEvent(). I think it should be

    if (event->source() == this) {
    

    like in the dropEvent()

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi,

      What version of Qt are you using ?
      On what platform ?
      Do you have a minimal compilable example that shows that behaviour ?

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0

      • Login

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