From 3358806d229588607f2749e6b22c53c3248cbfcd Mon Sep 17 00:00:00 2001 From: Prasanth Ullattil Date: Fri, 20 Nov 2009 11:51:55 +0100 Subject: Incorrect DropAction returned by QDrag::exec() on Cocoa. The action performed by the latest drag and drop operation is stored in the global DnDParams structure. The QDrag::exec() return value has to be fetcted from this global variable instead of the temporary copy on stack. Commit 0d231c32cc7670d356d486b13648cb5bd471ffef broke this. Task-number: QTBUG-6001 Reviewed-by: Denis (cherry picked from commit a222302ca45e33306dacae0aa16a572c13abc483) --- src/gui/kernel/qcocoaview_mac.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gui/kernel/qcocoaview_mac.mm b/src/gui/kernel/qcocoaview_mac.mm index 7bd8128..d02cf94 100644 --- a/src/gui/kernel/qcocoaview_mac.mm +++ b/src/gui/kernel/qcocoaview_mac.mm @@ -1451,7 +1451,7 @@ Qt::DropAction QDragManager::drag(QDrag *o) [image release]; dragPrivate()->executed_action = Qt::IgnoreAction; object = 0; - Qt::DropAction performedAction(qt_mac_mapNSDragOperation(dndParams.performedAction)); + Qt::DropAction performedAction(qt_mac_mapNSDragOperation(qMacDnDParams()->performedAction)); // do post drag processing, if required. if(performedAction != Qt::IgnoreAction) { // check if the receiver points us to a file location. -- cgit v0.12