diff --git a/MapControl/Shared/MapItemsControl.cs b/MapControl/Shared/MapItemsControl.cs
index 1eb15978..5c5bae85 100644
--- a/MapControl/Shared/MapItemsControl.cs
+++ b/MapControl/Shared/MapItemsControl.cs
@@ -2,35 +2,23 @@
// © 2018 Clemens Fischer
// Licensed under the Microsoft Public License (Ms-PL)
+using System;
#if WINDOWS_UWP
+using Windows.Foundation;
using Windows.UI.Xaml;
using Windows.UI.Xaml.Controls;
-using KeyEventArgs = Windows.UI.Xaml.Input.KeyRoutedEventArgs;
#else
using System.Windows;
using System.Windows.Controls;
-using System.Windows.Input;
#endif
namespace MapControl
{
- ///
- /// Container class for an item in a MapItemsControl.
- ///
- public class MapItem : ListBoxItem
- {
- public MapItem()
- {
- DefaultStyleKey = typeof(MapItem);
-
- MapPanel.InitMapElement(this);
- }
- }
///
/// Manages a collection of selectable items on a Map.
///
- public class MapItemsControl : ListBox
+ public partial class MapItemsControl : ListBox
{
public MapItemsControl()
{
@@ -49,8 +37,102 @@ namespace MapControl
return item is MapItem;
}
- protected override void OnKeyDown(KeyEventArgs e)
+ public void SelectItems(Func