From 94a73e76fdf5b2b4dd10af45caad77ba8fa4a6c4 Mon Sep 17 00:00:00 2001 From: haven1433 Date: Mon, 31 Oct 2022 13:22:54 -0500 Subject: [PATCH] escape actually deselects tools --- src/HexManiac.Core/ViewModels/Map/MapEditorViewModel.cs | 2 +- src/HexManiac.WPF/Controls/SelectedBlockEditor.xaml | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/HexManiac.Core/ViewModels/Map/MapEditorViewModel.cs b/src/HexManiac.Core/ViewModels/Map/MapEditorViewModel.cs index dd17b523..c7941fa3 100644 --- a/src/HexManiac.Core/ViewModels/Map/MapEditorViewModel.cs +++ b/src/HexManiac.Core/ViewModels/Map/MapEditorViewModel.cs @@ -96,7 +96,7 @@ namespace HavenSoft.HexManiac.Core.ViewModels.Map { set { Set(ref drawBlockIndex, value, old => { DrawMultipleTiles = false; - BlockEditorVisible = true; + if (drawBlockIndex >= 0) BlockEditorVisible = true; PrimaryMap.BlockEditor.BlockIndex = drawBlockIndex; drawBlockIndex = Math.Min(drawBlockIndex, PrimaryMap.BlockEditor.BlockIndex); selectionFromBlock = false; diff --git a/src/HexManiac.WPF/Controls/SelectedBlockEditor.xaml b/src/HexManiac.WPF/Controls/SelectedBlockEditor.xaml index ab4c87c5..64a2593b 100644 --- a/src/HexManiac.WPF/Controls/SelectedBlockEditor.xaml +++ b/src/HexManiac.WPF/Controls/SelectedBlockEditor.xaml @@ -5,7 +5,6 @@ xmlns:res="clr-namespace:HavenSoft.HexManiac.WPF.Resources" > -