mirror of
https://github.com/ClemensFischer/XAML-Map-Control.git
synced 2026-04-05 06:26:41 +00:00
Version 7.1.0: Added MapUiTools
This commit is contained in:
parent
731158c22d
commit
2ac4985c47
37 changed files with 437 additions and 463 deletions
146
MapUiTools/Shared/MapLayersMenuButton.cs
Normal file
146
MapUiTools/Shared/MapLayersMenuButton.cs
Normal file
|
|
@ -0,0 +1,146 @@
|
|||
// XAML Map Control - https://github.com/ClemensFischer/XAML-Map-Control
|
||||
// © 2022 Clemens Fischer
|
||||
// Licensed under the Microsoft Public License (Ms-PL)
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
#if WINUI
|
||||
using Microsoft.UI.Xaml;
|
||||
#elif UWP
|
||||
using Windows.UI.Xaml;
|
||||
#else
|
||||
using System.Windows;
|
||||
#endif
|
||||
|
||||
namespace MapControl.UiTools
|
||||
{
|
||||
public class MapLayersMenuButton : MenuButton
|
||||
{
|
||||
public MapLayersMenuButton()
|
||||
: base("\uE81E")
|
||||
{
|
||||
}
|
||||
|
||||
public static readonly DependencyProperty MapProperty = DependencyProperty.Register(
|
||||
nameof(Map), typeof(MapBase), typeof(MapLayersMenuButton),
|
||||
new PropertyMetadata(null, (o, e) => ((MapLayersMenuButton)o).InitializeMenu()));
|
||||
|
||||
public static readonly DependencyProperty MapLayersProperty = DependencyProperty.Register(
|
||||
nameof(MapLayers), typeof(IDictionary<string, UIElement>), typeof(MapLayersMenuButton),
|
||||
new PropertyMetadata(null, (o, e) => ((MapLayersMenuButton)o).InitializeMenu()));
|
||||
|
||||
public static readonly DependencyProperty MapOverlaysProperty = DependencyProperty.Register(
|
||||
nameof(MapOverlays), typeof(IDictionary<string, UIElement>), typeof(MapLayersMenuButton),
|
||||
new PropertyMetadata(null, (o, e) => ((MapLayersMenuButton)o).InitializeMenu()));
|
||||
|
||||
public MapBase Map
|
||||
{
|
||||
get { return (MapBase)GetValue(MapProperty); }
|
||||
set { SetValue(MapProperty, value); }
|
||||
}
|
||||
|
||||
public IDictionary<string, UIElement> MapLayers
|
||||
{
|
||||
get { return (IDictionary<string, UIElement>)GetValue(MapLayersProperty); }
|
||||
set { SetValue(MapLayersProperty, value); }
|
||||
}
|
||||
|
||||
public IDictionary<string, UIElement> MapOverlays
|
||||
{
|
||||
get { return (IDictionary<string, UIElement>)GetValue(MapOverlaysProperty); }
|
||||
set { SetValue(MapOverlaysProperty, value); }
|
||||
}
|
||||
|
||||
private void InitializeMenu()
|
||||
{
|
||||
if (Map != null && MapLayers != null)
|
||||
{
|
||||
var menu = CreateMenu();
|
||||
|
||||
foreach (var layer in MapLayers)
|
||||
{
|
||||
menu.Items.Add(CreateMenuItem(layer.Key, layer.Value, MapLayerClicked));
|
||||
}
|
||||
|
||||
var initialLayer = MapLayers.Values.FirstOrDefault();
|
||||
|
||||
if (MapOverlays != null && MapOverlays.Any())
|
||||
{
|
||||
if (initialLayer != null)
|
||||
{
|
||||
menu.Items.Add(CreateSeparator());
|
||||
}
|
||||
|
||||
foreach (var overlay in MapOverlays)
|
||||
{
|
||||
menu.Items.Add(CreateMenuItem(overlay.Key, overlay.Value, MapOverlayClicked));
|
||||
}
|
||||
}
|
||||
|
||||
if (initialLayer != null)
|
||||
{
|
||||
SetMapLayer(initialLayer);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void MapLayerClicked(object sender, RoutedEventArgs e)
|
||||
{
|
||||
var item = (FrameworkElement)sender;
|
||||
var layer = (UIElement)item.Tag;
|
||||
|
||||
SetMapLayer(layer);
|
||||
}
|
||||
|
||||
private void MapOverlayClicked(object sender, RoutedEventArgs e)
|
||||
{
|
||||
var item = (FrameworkElement)sender;
|
||||
var layer = (UIElement)item.Tag;
|
||||
|
||||
ToggleMapOverlay(layer);
|
||||
}
|
||||
|
||||
private void SetMapLayer(UIElement layer)
|
||||
{
|
||||
Map.MapLayer = layer;
|
||||
|
||||
UpdateCheckedStates();
|
||||
}
|
||||
|
||||
private void ToggleMapOverlay(UIElement layer)
|
||||
{
|
||||
if (Map.Children.Contains(layer))
|
||||
{
|
||||
Map.Children.Remove(layer);
|
||||
}
|
||||
else
|
||||
{
|
||||
int index = 1;
|
||||
|
||||
foreach (var overlay in MapOverlays.Values)
|
||||
{
|
||||
if (overlay == layer)
|
||||
{
|
||||
Map.Children.Insert(index, layer);
|
||||
break;
|
||||
}
|
||||
|
||||
if (Map.Children.Contains(overlay))
|
||||
{
|
||||
index++;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
UpdateCheckedStates();
|
||||
}
|
||||
|
||||
private void UpdateCheckedStates()
|
||||
{
|
||||
foreach (var item in GetMenuItems())
|
||||
{
|
||||
item.IsChecked = Map.Children.Contains((UIElement)item.Tag);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
82
MapUiTools/Shared/MapProjectionsMenuButton.cs
Normal file
82
MapUiTools/Shared/MapProjectionsMenuButton.cs
Normal file
|
|
@ -0,0 +1,82 @@
|
|||
// XAML Map Control - https://github.com/ClemensFischer/XAML-Map-Control
|
||||
// © 2022 Clemens Fischer
|
||||
// Licensed under the Microsoft Public License (Ms-PL)
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
#if WINUI
|
||||
using Microsoft.UI.Xaml;
|
||||
#elif UWP
|
||||
using Windows.UI.Xaml;
|
||||
#else
|
||||
using System.Windows;
|
||||
#endif
|
||||
|
||||
namespace MapControl.UiTools
|
||||
{
|
||||
public class MapProjectionsMenuButton : MenuButton
|
||||
{
|
||||
public MapProjectionsMenuButton()
|
||||
: base("\uE809")
|
||||
{
|
||||
}
|
||||
|
||||
public static readonly DependencyProperty MapProperty = DependencyProperty.Register(
|
||||
nameof(Map), typeof(MapBase), typeof(MapProjectionsMenuButton),
|
||||
new PropertyMetadata(null, (o, e) => ((MapProjectionsMenuButton)o).InitializeMenu()));
|
||||
|
||||
public static readonly DependencyProperty MapProjectionsProperty = DependencyProperty.Register(
|
||||
nameof(MapProjections), typeof(IDictionary<string, MapProjection>), typeof(MapProjectionsMenuButton),
|
||||
new PropertyMetadata(null, (o, e) => ((MapProjectionsMenuButton)o).InitializeMenu()));
|
||||
|
||||
public MapBase Map
|
||||
{
|
||||
get { return (MapBase)GetValue(MapProperty); }
|
||||
set { SetValue(MapProperty, value); }
|
||||
}
|
||||
|
||||
public IDictionary<string, MapProjection> MapProjections
|
||||
{
|
||||
get { return (IDictionary<string, MapProjection>)GetValue(MapProjectionsProperty); }
|
||||
set { SetValue(MapProjectionsProperty, value); }
|
||||
}
|
||||
|
||||
private void InitializeMenu()
|
||||
{
|
||||
if (Map != null && MapProjections != null)
|
||||
{
|
||||
var menu = CreateMenu();
|
||||
|
||||
foreach (var projection in MapProjections)
|
||||
{
|
||||
menu.Items.Add(CreateMenuItem(projection.Key, projection.Value, MapProjectionClicked));
|
||||
}
|
||||
|
||||
var initialProjection = MapProjections.Values.FirstOrDefault();
|
||||
|
||||
if (initialProjection != null)
|
||||
{
|
||||
SetMapProjection(initialProjection);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private void MapProjectionClicked(object sender, RoutedEventArgs e)
|
||||
{
|
||||
var item = (FrameworkElement)sender;
|
||||
var projection = (MapProjection)item.Tag;
|
||||
|
||||
SetMapProjection(projection);
|
||||
}
|
||||
|
||||
private void SetMapProjection(MapProjection projection)
|
||||
{
|
||||
Map.MapProjection = projection;
|
||||
|
||||
foreach (var item in GetMenuItems())
|
||||
{
|
||||
item.IsChecked = Map.MapProjection == (MapProjection)item.Tag;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
88
MapUiTools/UWP/MapUiTools.UWP.csproj
Normal file
88
MapUiTools/UWP/MapUiTools.UWP.csproj
Normal file
|
|
@ -0,0 +1,88 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="15.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||
<PropertyGroup>
|
||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
|
||||
<ProjectGuid>{DFFE8E49-AA07-457E-A459-99326B44F828}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>MapControl.UiTools</RootNamespace>
|
||||
<AssemblyName>MapUiTools.UWP</AssemblyName>
|
||||
<DefaultLanguage>en-US</DefaultLanguage>
|
||||
<TargetPlatformIdentifier>UAP</TargetPlatformIdentifier>
|
||||
<TargetPlatformVersion Condition=" '$(TargetPlatformVersion)' == '' ">10.0.19041.0</TargetPlatformVersion>
|
||||
<TargetPlatformMinVersion>10.0.17134.0</TargetPlatformMinVersion>
|
||||
<MinimumVisualStudioVersion>14</MinimumVisualStudioVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<ProjectTypeGuids>{A5A43C5B-DE2A-4C0C-9213-0A381AF9435A};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugSymbols>true</DebugSymbols>
|
||||
<DebugType>full</DebugType>
|
||||
<Optimize>false</Optimize>
|
||||
<OutputPath>bin\Debug\</OutputPath>
|
||||
<DefineConstants>DEBUG;UWP</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
|
||||
<PlatformTarget>AnyCPU</PlatformTarget>
|
||||
<DebugType>pdbonly</DebugType>
|
||||
<Optimize>true</Optimize>
|
||||
<OutputPath>bin\Release\</OutputPath>
|
||||
<DefineConstants>UWP</DefineConstants>
|
||||
<ErrorReport>prompt</ErrorReport>
|
||||
<WarningLevel>4</WarningLevel>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<RestoreProjectStyle>PackageReference</RestoreProjectStyle>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="..\Shared\MapLayersMenuButton.cs">
|
||||
<Link>MapLayersMenuButton.cs</Link>
|
||||
</Compile>
|
||||
<Compile Include="..\Shared\MapProjectionsMenuButton.cs">
|
||||
<Link>MapProjectionsMenuButton.cs</Link>
|
||||
</Compile>
|
||||
<Compile Include="..\WinUI\MenuButton.WinUI.cs">
|
||||
<Link>MenuButton.WinUI.cs</Link>
|
||||
</Compile>
|
||||
<Compile Include="Properties\AssemblyInfo.cs" />
|
||||
<EmbeddedResource Include="Properties\MapUiTools.UWP.rd.xml" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.NETCore.UniversalWindowsPlatform">
|
||||
<Version>6.2.13</Version>
|
||||
</PackageReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\MapControl\UWP\MapControl.UWP.csproj">
|
||||
<Project>{9545f73c-9c35-4cf6-baae-19a0baebd344}</Project>
|
||||
<Name>MapControl.UWP</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="..\..\MapControl.snk">
|
||||
<Link>MapControl.snk</Link>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<PropertyGroup Condition=" '$(VisualStudioVersion)' == '' or '$(VisualStudioVersion)' < '14.0' ">
|
||||
<VisualStudioVersion>14.0</VisualStudioVersion>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<SignAssembly>true</SignAssembly>
|
||||
</PropertyGroup>
|
||||
<PropertyGroup>
|
||||
<AssemblyOriginatorKeyFile>..\..\MapControl.snk</AssemblyOriginatorKeyFile>
|
||||
</PropertyGroup>
|
||||
<Import Project="$(MSBuildExtensionsPath)\Microsoft\WindowsXaml\v$(VisualStudioVersion)\Microsoft.Windows.UI.Xaml.CSharp.targets" />
|
||||
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
|
||||
Other similar extension points exist, see Microsoft.Common.targets.
|
||||
<Target Name="BeforeBuild">
|
||||
</Target>
|
||||
<Target Name="AfterBuild">
|
||||
</Target>
|
||||
-->
|
||||
</Project>
|
||||
13
MapUiTools/UWP/Properties/AssemblyInfo.cs
Normal file
13
MapUiTools/UWP/Properties/AssemblyInfo.cs
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
using System.Reflection;
|
||||
using System.Runtime.InteropServices;
|
||||
|
||||
[assembly: AssemblyTitle("XAML Map Control UI Tools Library for UWP")]
|
||||
[assembly: AssemblyProduct("XAML Map Control")]
|
||||
[assembly: AssemblyCompany("Clemens Fischer")]
|
||||
[assembly: AssemblyCopyright("Copyright © 2022 Clemens Fischer")]
|
||||
[assembly: AssemblyTrademark("")]
|
||||
[assembly: AssemblyVersion("7.1.0")]
|
||||
[assembly: AssemblyFileVersion("7.1.0")]
|
||||
[assembly: AssemblyConfiguration("")]
|
||||
[assembly: AssemblyCulture("")]
|
||||
[assembly: ComVisible(false)]
|
||||
5
MapUiTools/UWP/Properties/MapUiTools.UWP.rd.xml
Normal file
5
MapUiTools/UWP/Properties/MapUiTools.UWP.rd.xml
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Directives xmlns="http://schemas.microsoft.com/netfx/2013/01/metadata">
|
||||
<Library Name="MapUiTools.UWP">
|
||||
</Library>
|
||||
</Directives>
|
||||
28
MapUiTools/WPF/MapUiTools.WPF.csproj
Normal file
28
MapUiTools/WPF/MapUiTools.WPF.csproj
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<TargetFrameworks>net6.0-windows;net5.0-windows;netcoreapp3.1;net48;net462</TargetFrameworks>
|
||||
<UseWPF>true</UseWPF>
|
||||
<RootNamespace>MapControl.UiTools</RootNamespace>
|
||||
<AssemblyTitle>XAML Map Control UI Tools Library for WPF</AssemblyTitle>
|
||||
<Product>XAML Map Control</Product>
|
||||
<Version>7.1.0</Version>
|
||||
<Authors>Clemens Fischer</Authors>
|
||||
<Copyright>Copyright © 2022 Clemens Fischer</Copyright>
|
||||
<SignAssembly>true</SignAssembly>
|
||||
<AssemblyOriginatorKeyFile>..\..\MapControl.snk</AssemblyOriginatorKeyFile>
|
||||
<DelaySign>false</DelaySign>
|
||||
<DefineConstants></DefineConstants>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Include="..\..\MapControl.snk" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Compile Include="..\Shared\*.cs" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\MapControl\WPF\MapControl.WPF.csproj" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
47
MapUiTools/WPF/MenuButton.WPF.cs
Normal file
47
MapUiTools/WPF/MenuButton.WPF.cs
Normal file
|
|
@ -0,0 +1,47 @@
|
|||
// XAML Map Control - https://github.com/ClemensFischer/XAML-Map-Control
|
||||
// © 2022 Clemens Fischer
|
||||
// Licensed under the Microsoft Public License (Ms-PL)
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using System.Windows;
|
||||
using System.Windows.Controls;
|
||||
using System.Windows.Media;
|
||||
|
||||
namespace MapControl.UiTools
|
||||
{
|
||||
public class MenuButton : Button
|
||||
{
|
||||
protected MenuButton(string icon)
|
||||
{
|
||||
FontFamily = new FontFamily("Segoe MDL2 Assets");
|
||||
Content = icon;
|
||||
|
||||
Click += (s, e) => ContextMenu.IsOpen = true;
|
||||
}
|
||||
|
||||
protected ContextMenu CreateMenu()
|
||||
{
|
||||
var menu = new ContextMenu();
|
||||
ContextMenu = menu;
|
||||
return menu;
|
||||
}
|
||||
|
||||
protected IEnumerable<MenuItem> GetMenuItems()
|
||||
{
|
||||
return ContextMenu.Items.OfType<MenuItem>();
|
||||
}
|
||||
|
||||
protected static MenuItem CreateMenuItem(string text, object item, RoutedEventHandler click)
|
||||
{
|
||||
var menuItem = new MenuItem { Header = text, Tag = item };
|
||||
menuItem.Click += click;
|
||||
return menuItem;
|
||||
}
|
||||
|
||||
protected static Separator CreateSeparator()
|
||||
{
|
||||
return new Separator();
|
||||
}
|
||||
}
|
||||
}
|
||||
35
MapUiTools/WinUI/MapUiTools.WinUI.csproj
Normal file
35
MapUiTools/WinUI/MapUiTools.WinUI.csproj
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
<PropertyGroup>
|
||||
<TargetFramework>net6.0-windows10.0.19041.0</TargetFramework>
|
||||
<TargetPlatformMinVersion>10.0.17763.0</TargetPlatformMinVersion>
|
||||
<RuntimeIdentifiers>win10-x86;win10-x64;win10-arm64</RuntimeIdentifiers>
|
||||
<UseWinUI>true</UseWinUI>
|
||||
<RootNamespace>MapControl.UiTools</RootNamespace>
|
||||
<AssemblyTitle>XAML Map Control UI Tools Library for WinUI</AssemblyTitle>
|
||||
<Product>XAML Map Control</Product>
|
||||
<Version>7.1.0</Version>
|
||||
<Authors>Clemens Fischer</Authors>
|
||||
<Copyright>Copyright © 2022 Clemens Fischer</Copyright>
|
||||
<SignAssembly>true</SignAssembly>
|
||||
<AssemblyOriginatorKeyFile>..\..\MapControl.snk</AssemblyOriginatorKeyFile>
|
||||
<DelaySign>false</DelaySign>
|
||||
<DefineConstants>WINUI</DefineConstants>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<None Include="..\..\MapControl.snk" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Compile Include="..\Shared\*.cs" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.WindowsAppSDK" Version="1.0.0" />
|
||||
<PackageReference Include="Microsoft.Windows.SDK.BuildTools" Version="10.0.22000.196" />
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\MapControl\WinUI\MapControl.WinUI.csproj" />
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
54
MapUiTools/WinUI/MenuButton.WinUI.cs
Normal file
54
MapUiTools/WinUI/MenuButton.WinUI.cs
Normal file
|
|
@ -0,0 +1,54 @@
|
|||
// XAML Map Control - https://github.com/ClemensFischer/XAML-Map-Control
|
||||
// © 2022 Clemens Fischer
|
||||
// Licensed under the Microsoft Public License (Ms-PL)
|
||||
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
#if WINUI
|
||||
using Microsoft.UI.Xaml;
|
||||
using Microsoft.UI.Xaml.Controls;
|
||||
using Microsoft.UI.Xaml.Media;
|
||||
#elif UWP
|
||||
using Windows.UI.Xaml;
|
||||
using Windows.UI.Xaml.Controls;
|
||||
using Windows.UI.Xaml.Media;
|
||||
#endif
|
||||
|
||||
namespace MapControl.UiTools
|
||||
{
|
||||
public class MenuButton : Button
|
||||
{
|
||||
protected MenuButton(string icon)
|
||||
{
|
||||
Content = new FontIcon
|
||||
{
|
||||
FontFamily = new FontFamily("Segoe Fluent Icons"),
|
||||
Glyph = icon
|
||||
};
|
||||
}
|
||||
|
||||
protected MenuFlyout CreateMenu()
|
||||
{
|
||||
var menu = new MenuFlyout();
|
||||
Flyout = menu;
|
||||
return menu;
|
||||
}
|
||||
|
||||
protected IEnumerable<ToggleMenuFlyoutItem> GetMenuItems()
|
||||
{
|
||||
return ((MenuFlyout)Flyout).Items.OfType<ToggleMenuFlyoutItem>();
|
||||
}
|
||||
|
||||
protected static ToggleMenuFlyoutItem CreateMenuItem(string text, object item, RoutedEventHandler click)
|
||||
{
|
||||
var menuItem = new ToggleMenuFlyoutItem { Text = text, Tag = item };
|
||||
menuItem.Click += click;
|
||||
return menuItem;
|
||||
}
|
||||
|
||||
protected static MenuFlyoutSeparator CreateSeparator()
|
||||
{
|
||||
return new MenuFlyoutSeparator();
|
||||
}
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue