respecting DoDragDrop flags like CopyOnly
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@35258 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
6db6bfd1ce
commit
525ae3fe38
@ -301,7 +301,7 @@ wxDropSource::~wxDropSource()
|
||||
}
|
||||
|
||||
|
||||
wxDragResult wxDropSource::DoDragDrop(int WXUNUSED(flags))
|
||||
wxDragResult wxDropSource::DoDragDrop(int flags)
|
||||
{
|
||||
wxASSERT_MSG( m_data, wxT("Drop source: no data") );
|
||||
|
||||
@ -416,7 +416,12 @@ wxDragResult wxDropSource::DoDragDrop(int WXUNUSED(flags))
|
||||
gTrackingGlobals.m_currentSource = NULL ;
|
||||
|
||||
bool optionDown = GetCurrentKeyModifiers() & optionKey ;
|
||||
wxDragResult dndresult = optionDown ? wxDragCopy : wxDragMove;
|
||||
wxDragResult dndresult = wxDragCopy ;
|
||||
if ( flags != wxDrag_CopyOnly )
|
||||
{
|
||||
// on mac the option key is always the indication for copy
|
||||
dndresult = optionDown ? wxDragCopy : wxDragMove;
|
||||
}
|
||||
return dndresult;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user