Test handle Windows Explorer drag'n'drop in ImGui

This commit is contained in:
Simon Lübeß
2025-06-17 16:46:05 +02:00
parent 9b6bb2b8d8
commit 60482059a4
4 changed files with 60 additions and 6 deletions
@@ -187,6 +187,25 @@ namespace GlitchyEditor.EditWindows
}
ImGui.EndTable();
if (ImGui.BeginDragDropTarget())
{
ImGui.Payload* peekPayload = ImGui.AcceptDragDropPayload(.ExternFiles, .AcceptBeforeDelivery);
if (peekPayload != null)
{
if (peekPayload.IsDelivery())
{
Log.EngineLogger.Info("Buup!");
}
else
{
EditorLayer.SetDropEffect(.Copy);
}
}
ImGui.EndDragDropTarget();
}
}
ImGui.PopStyleVar(1);