From 84ba9fc25023e5907c94b7cfea1a3dc8e184eed2 Mon Sep 17 00:00:00 2001 From: Anthony Purchase Date: Sat, 24 Feb 2018 02:36:56 +0000 Subject: [PATCH] Support searching for tamed creatures by name Added a search box when showing tames. Results are highlighted on the map and in the creature list. Result list now requires items to be selected before they are highlighted on the map, but you can now select multiple creatures and have them stay highlighted. ISSUE: With many creatures in the results list, sometimes highlights are not shown immediately. Scrolling the list seems to fix it. The map highlights correctly. --- LarkatorGUI/DummyMainWindow.cs | 2 + LarkatorGUI/LarkatorGUI.csproj | 2 + LarkatorGUI/MainWindow.xaml | 28 +++++++++++-- LarkatorGUI/MainWindow.xaml.cs | 75 +++++++++++++++++++++++++++++++++- 4 files changed, 102 insertions(+), 5 deletions(-) diff --git a/LarkatorGUI/DummyMainWindow.cs b/LarkatorGUI/DummyMainWindow.cs index 3cb0388..659ce1c 100644 --- a/LarkatorGUI/DummyMainWindow.cs +++ b/LarkatorGUI/DummyMainWindow.cs @@ -9,6 +9,8 @@ public class DummyMainWindow { public string ApplicationVersion { get => "DUMMY"; } + public string SearchText { get; set; } = "search"; + public Collection ListSearches { get => searches; } public Collection ListResults { get => results; } diff --git a/LarkatorGUI/LarkatorGUI.csproj b/LarkatorGUI/LarkatorGUI.csproj index 321a131..4501ade 100644 --- a/LarkatorGUI/LarkatorGUI.csproj +++ b/LarkatorGUI/LarkatorGUI.csproj @@ -46,6 +46,7 @@ DEBUG;TRACE prompt 4 + latest AnyCPU @@ -55,6 +56,7 @@ TRACE prompt 4 + latest compass.ico diff --git a/LarkatorGUI/MainWindow.xaml b/LarkatorGUI/MainWindow.xaml index 6df370f..e0b2800 100644 --- a/LarkatorGUI/MainWindow.xaml +++ b/LarkatorGUI/MainWindow.xaml @@ -45,12 +45,19 @@ + + @@ -285,7 +292,22 @@ - + + + + +