mirror of
https://github.com/Drezil/imgui.git
synced 2025-07-12 15:59:54 +02:00
Drag and Drop: made BeginDragDropSource() clear the IsItemHovered() by default, added a flag to keep it.
This commit is contained in:
@ -220,9 +220,12 @@ enum ImGuiSeparatorFlags_
|
||||
// Flags for ImGui::BeginDragDropSource(), ImGui::AcceptDragDropPayload()
|
||||
enum ImGuiDragDropFlags_
|
||||
{
|
||||
// BeginDragDropSource() flags
|
||||
ImGuiDragDropFlags_SourceNoAutoTooltip = 1 << 0,
|
||||
ImGuiDragDropFlags_AcceptBeforeDelivery = 1 << 1, // AcceptDragDropPayload() returns true even before the mouse button is released. You can then call IsDelivery() to test if the payload needs to be delivered.
|
||||
ImGuiDragDropFlags_AcceptNoDrawDefaultRect = 1 << 2, // Do not draw the default highlight rectangle when hovering over target.
|
||||
ImGuiDragDropFlags_SourceNoDisableHover = 1 << 1, // By default, when dragging we clear data so that IsItemHovered() will return true, to avoid subsequent user code submitting tooltips.
|
||||
// BeginDragDropTarget() flags
|
||||
ImGuiDragDropFlags_AcceptBeforeDelivery = 1 << 10, // AcceptDragDropPayload() returns true even before the mouse button is released. You can then call IsDelivery() to test if the payload needs to be delivered.
|
||||
ImGuiDragDropFlags_AcceptNoDrawDefaultRect = 1 << 11, // Do not draw the default highlight rectangle when hovering over target.
|
||||
ImGuiDragDropFlags_AcceptPeekOnly = ImGuiDragDropFlags_AcceptBeforeDelivery | ImGuiDragDropFlags_AcceptNoDrawDefaultRect // For peeking ahead and inspecting the payload before delivery.
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user