mirror of
https://github.com/aharabada/glitchy-engine-beef.git
synced 2026-09-05 21:01:52 +00:00
Fixed clear selection when navigating or clicking background
This commit is contained in:
@@ -208,6 +208,7 @@ namespace GlitchyEditor.EditWindows
|
|||||||
// Show History
|
// Show History
|
||||||
if (ImGui.Begin("Debug History"))
|
if (ImGui.Begin("Debug History"))
|
||||||
{
|
{
|
||||||
|
ImGui.CollapsingHeader("History");
|
||||||
for (String path in _directoryHistory.[Friend]_history)
|
for (String path in _directoryHistory.[Friend]_history)
|
||||||
{
|
{
|
||||||
if (_directoryHistory.CurrentDirectoryPath === StringView(path))
|
if (_directoryHistory.CurrentDirectoryPath === StringView(path))
|
||||||
@@ -218,6 +219,15 @@ namespace GlitchyEditor.EditWindows
|
|||||||
ImGui.Text(path);
|
ImGui.Text(path);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ImGui.CollapsingHeader("Selected Files");
|
||||||
|
|
||||||
|
for (String path in _selectedFiles)
|
||||||
|
{
|
||||||
|
ImGui.Text(path);
|
||||||
|
}
|
||||||
|
|
||||||
|
ImGui.CollapsingHeader("Selection Rect");
|
||||||
|
|
||||||
//if (!_selectionRectStart.X.IsNaN)
|
//if (!_selectionRectStart.X.IsNaN)
|
||||||
{
|
{
|
||||||
ImGui.TextUnformatted(_selectionRect.ToString(.. scope .()));
|
ImGui.TextUnformatted(_selectionRect.ToString(.. scope .()));
|
||||||
@@ -334,7 +344,7 @@ namespace GlitchyEditor.EditWindows
|
|||||||
|
|
||||||
ImGui.EndChild();
|
ImGui.EndChild();
|
||||||
|
|
||||||
if (ImGui.IsItemClicked(.Left | .Right))
|
if (ImGui.IsItemClicked(.Left) || ImGui.IsItemClicked(.Right))
|
||||||
{
|
{
|
||||||
_selectedFiles.ClearAndDeleteItems();
|
_selectedFiles.ClearAndDeleteItems();
|
||||||
}
|
}
|
||||||
@@ -595,6 +605,7 @@ namespace GlitchyEditor.EditWindows
|
|||||||
if (!ImGui.IsItemToggledOpen() && ImGui.IsItemClicked(.Left))
|
if (!ImGui.IsItemToggledOpen() && ImGui.IsItemClicked(.Left))
|
||||||
{
|
{
|
||||||
_directoryHistory.Navigate(tree->Path);
|
_directoryHistory.Navigate(tree->Path);
|
||||||
|
_selectedFiles.ClearAndDeleteItems();
|
||||||
}
|
}
|
||||||
|
|
||||||
if(isOpen)
|
if(isOpen)
|
||||||
@@ -1179,6 +1190,7 @@ namespace GlitchyEditor.EditWindows
|
|||||||
if (entry->IsDirectory)
|
if (entry->IsDirectory)
|
||||||
{
|
{
|
||||||
_directoryHistory.Navigate(entry->Path);
|
_directoryHistory.Navigate(entry->Path);
|
||||||
|
_selectedFiles.ClearAndDeleteItems();
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user