mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-09-11 13:25:53 -04:00
Set the drag-and-drop state after initiating the drag, not before (Fixes #3134)
This commit is contained in:
parent
cca75499ee
commit
f8690dcd20
@ -36,7 +36,6 @@ void DragAndDrop::startDrag (int index, SortFilterItemModel* sortModel, ItemMode
|
|||||||
mSourceModel = sourceModel;
|
mSourceModel = sourceModel;
|
||||||
mSourceView = sourceView;
|
mSourceView = sourceView;
|
||||||
mSourceSortModel = sortModel;
|
mSourceSortModel = sortModel;
|
||||||
mIsOnDragAndDrop = true;
|
|
||||||
|
|
||||||
// If picking up an item that isn't from the player's inventory, the item gets added to player inventory backend
|
// If picking up an item that isn't from the player's inventory, the item gets added to player inventory backend
|
||||||
// immediately, even though it's still floating beneath the mouse cursor. A bit counterintuitive,
|
// immediately, even though it's still floating beneath the mouse cursor. A bit counterintuitive,
|
||||||
@ -88,6 +87,8 @@ void DragAndDrop::startDrag (int index, SortFilterItemModel* sortModel, ItemMode
|
|||||||
sourceView->update();
|
sourceView->update();
|
||||||
|
|
||||||
MWBase::Environment::get().getWindowManager()->setDragDrop(true);
|
MWBase::Environment::get().getWindowManager()->setDragDrop(true);
|
||||||
|
|
||||||
|
mIsOnDragAndDrop = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void DragAndDrop::drop(ItemModel *targetModel, ItemView *targetView)
|
void DragAndDrop::drop(ItemModel *targetModel, ItemView *targetView)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user