2016-11-08 22:54:55 +00:00
|
|
|
<Window x:Class="WinUI.ToolbarItem"
|
|
|
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
|
|
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
|
|
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
|
|
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
|
|
|
|
xmlns:local="clr-namespace:WinUI"
|
|
|
|
xmlns:tb="http://www.hardcodet.net/taskbar"
|
2016-11-10 22:17:57 +00:00
|
|
|
xmlns:scm="clr-namespace:System.ComponentModel;assembly=WindowsBase"
|
2016-11-08 22:54:55 +00:00
|
|
|
mc:Ignorable="d"
|
2016-11-10 22:17:57 +00:00
|
|
|
Height="300" Width="300" Visibility="Hidden" Name="Toolbar">
|
|
|
|
|
|
|
|
<Window.Resources>
|
|
|
|
<CollectionViewSource Source="{Binding ElementName=Toolbar, Path=NetworkCollection}" x:Key="KnownNetworks">
|
|
|
|
<CollectionViewSource.SortDescriptions>
|
2016-11-17 22:13:05 +00:00
|
|
|
<scm:SortDescription PropertyName="Header" Direction="Ascending"/>
|
2016-11-10 22:17:57 +00:00
|
|
|
</CollectionViewSource.SortDescriptions>
|
|
|
|
</CollectionViewSource>
|
|
|
|
</Window.Resources>
|
|
|
|
|
2016-11-08 22:54:55 +00:00
|
|
|
<Grid>
|
|
|
|
<tb:TaskbarIcon x:Name="MyNotifyIcon"
|
|
|
|
IconSource="ZeroTierIcon.ico"
|
2017-02-15 00:31:11 +00:00
|
|
|
ToolTipText="ZeroTier One"
|
|
|
|
MenuActivation="LeftOrRightClick">
|
2016-11-08 22:54:55 +00:00
|
|
|
<tb:TaskbarIcon.ContextMenu>
|
|
|
|
<ContextMenu>
|
2017-02-15 00:31:11 +00:00
|
|
|
<ContextMenu.ItemsSource>
|
|
|
|
<CompositeCollection>
|
|
|
|
<MenuItem Header="Node ID: unknown"
|
2016-11-17 22:13:05 +00:00
|
|
|
Click="ToolbarItem_NodeIDClicked"
|
|
|
|
x:Name="nodeIdMenuItem"/>
|
2017-02-15 00:31:11 +00:00
|
|
|
<Separator/>
|
|
|
|
<MenuItem Header="Join Network..."
|
2016-11-17 22:13:05 +00:00
|
|
|
Click="ToolbarItem_JoinNetworkClicked"/>
|
2017-02-15 00:31:11 +00:00
|
|
|
<MenuItem Header="Show Networks..."
|
2016-11-17 22:13:05 +00:00
|
|
|
Click="ToolbarItem_ShowNetworksClicked"/>
|
2017-02-15 00:31:11 +00:00
|
|
|
<Separator/>
|
2016-11-17 22:13:05 +00:00
|
|
|
|
2017-02-15 00:31:11 +00:00
|
|
|
<CollectionContainer Collection="{Binding Source={StaticResource KnownNetworks}}">
|
2016-11-17 22:13:05 +00:00
|
|
|
|
2017-02-15 00:31:11 +00:00
|
|
|
</CollectionContainer>
|
|
|
|
|
|
|
|
<Separator/>
|
|
|
|
<MenuItem Header="About..."
|
2016-11-18 19:42:15 +00:00
|
|
|
Click="ToolbarItem_AboutClicked"/>
|
2017-02-15 00:31:11 +00:00
|
|
|
<MenuItem Header="Preferences..."
|
2016-11-18 19:42:15 +00:00
|
|
|
Click="ToolbarItem_PreferencesClicked"/>
|
2017-02-15 00:31:11 +00:00
|
|
|
<Separator/>
|
|
|
|
<MenuItem Header="Quit"
|
2016-11-18 20:09:08 +00:00
|
|
|
Click="ToolbarItem_QuitClicked"/>
|
2017-02-15 00:31:11 +00:00
|
|
|
|
|
|
|
</CompositeCollection>
|
|
|
|
</ContextMenu.ItemsSource>
|
|
|
|
</ContextMenu>
|
2016-11-08 22:54:55 +00:00
|
|
|
</tb:TaskbarIcon.ContextMenu>
|
|
|
|
|
|
|
|
</tb:TaskbarIcon>
|
|
|
|
</Grid>
|
|
|
|
</Window>
|