Skip to content

Commit c790723

Browse files
committed
Drag and Drop: Fixed an incorrect assert when dropping a source that is submitted after the target (bug introduced with 1.62 changes related to the addition of IsItemDeactivated()). (#1875, #143)
1 parent 89e2ddf commit c790723

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

CHANGELOG.txt

+2
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,8 @@ Other Changes:
4444
- ArrowButton: Setup current line text baseline so that ArrowButton() + SameLine() + Text() are aligned properly.
4545
- Window: Allow menu windows from ignoring the style.WindowMinSize values so short menus are not padded. (#1909)
4646
- Window: Added global io.OptResizeWindowsFromEdges option to enable resizing windows from their edges and from the lower-left corner. (#1495)
47+
- Drag and Drop: Fixed an incorrect assert when dropping a source that is submitted after the target (bug introduced with 1.62 changes
48+
related to the addition of IsItemDeactivated()). (#1875, #143)
4749
- Misc: Added ImGuiMouseCursor_Hand cursor enum + corresponding software cursor. (#1913, 1914) [@aiekick, @ocornut]
4850
- Misc: Tweaked software mouse cursor offset to match the offset of the corresponding Windows 10 cursors.
4951
- Fixed a include build issue for Cygwin in non-POSIX (Win32) mode. (#1917, #1319, #276)

imgui.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -2299,7 +2299,7 @@ void ImGui::MarkItemValueChanged(ImGuiID id)
22992299
// ActiveId might have been released by the time we call this (as in the typical press/release button behavior) but still need need to fill the data.
23002300
(void)id; // Avoid unused variable warnings when asserts are compiled out.
23012301
ImGuiContext& g = *GImGui;
2302-
IM_ASSERT(g.ActiveId == id || g.ActiveId == 0);
2302+
IM_ASSERT(g.ActiveId == id || g.ActiveId == 0 || g.DragDropActive);
23032303
g.ActiveIdValueChanged = true;
23042304
}
23052305

0 commit comments

Comments
 (0)