清理引用,将NavigatorServices更改为使用Message来实现导航的切换
This commit is contained in:
@@ -5,70 +5,70 @@
|
||||
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
|
||||
xmlns:ui="http://schemas.inkore.net/lib/ui/wpf/modern"
|
||||
xmlns:ikw="http://schemas.inkore.net/lib/ui/wpf"
|
||||
xmlns:local="clr-namespace:PMSWPF.Views"
|
||||
xmlns:dl="clr-namespace:PMSWPF.Views.Dialogs"
|
||||
xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
|
||||
xmlns:vm="clr-namespace:PMSWPF.ViewModels"
|
||||
xmlns:hc="https://handyorg.github.io/handycontrol"
|
||||
d:DataContext="{d:DesignInstance vm:DevicesViewModel}"
|
||||
mc:Ignorable="d"
|
||||
d:DesignHeight="300" d:DesignWidth="300">
|
||||
<UserControl.Resources>
|
||||
<DataTemplate x:Key="DeviceItemTemplate">
|
||||
<Border Background="#eee" CornerRadius="10" Margin="3" Padding="10" >
|
||||
<ikw:SimpleStackPanel Spacing="10" Width="300" Height="200">
|
||||
<DockPanel >
|
||||
<ui:ToggleSwitch
|
||||
DockPanel.Dock="Right"
|
||||
Margin="20 0 0 0 "
|
||||
IsOn="{Binding IsActive}"
|
||||
OffContent="停止" OnContent="启动"/>
|
||||
<Border Background="#eee" CornerRadius="10" Margin="3" Padding="10">
|
||||
<ikw:SimpleStackPanel Spacing="10" Width="300" Height="200">
|
||||
<DockPanel>
|
||||
<ui:ToggleSwitch
|
||||
DockPanel.Dock="Right"
|
||||
Margin="20 0 0 0 "
|
||||
IsOn="{Binding IsActive}"
|
||||
OffContent="停止" OnContent="启动" />
|
||||
<TextBlock FontSize="24" FontWeight="Bold" Text="{Binding Name }" />
|
||||
</DockPanel>
|
||||
|
||||
|
||||
<TextBlock Text="{Binding Description }" />
|
||||
<TextBlock Text="{Binding Ip }" />
|
||||
<ListBox ItemsSource="{Binding }">
|
||||
|
||||
<ListBox ItemsSource="{Binding VariableTables }">
|
||||
<ListBox.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<Button Content="{Binding Name}" />
|
||||
</DataTemplate>
|
||||
</ListBox.ItemTemplate>
|
||||
</ListBox>
|
||||
</ikw:SimpleStackPanel>
|
||||
</Border>
|
||||
|
||||
|
||||
</DataTemplate>
|
||||
</UserControl.Resources>
|
||||
|
||||
<StackPanel >
|
||||
|
||||
<StackPanel>
|
||||
|
||||
<ui:CommandBar x:Name="PrimaryCommandBar"
|
||||
DefaultLabelPosition="Right" IsOpen="False">
|
||||
<ui:AppBarButton x:Name="AddButton"
|
||||
Command="{Binding AddDeviceCommand}"
|
||||
Label="Add">
|
||||
Label="Add">
|
||||
<ui:AppBarButton.Icon>
|
||||
<ui:FontIcon Icon="{x:Static ui:SegoeFluentIcons.Add}"/>
|
||||
<ui:FontIcon Icon="{x:Static ui:SegoeFluentIcons.Add}" />
|
||||
</ui:AppBarButton.Icon>
|
||||
</ui:AppBarButton>
|
||||
<ui:AppBarButton x:Name="EditButton"
|
||||
Label="Edit">
|
||||
Label="Edit">
|
||||
<ui:AppBarButton.Icon>
|
||||
<ui:FontIcon Icon="{x:Static ui:SegoeFluentIcons.Edit}"/>
|
||||
<ui:FontIcon Icon="{x:Static ui:SegoeFluentIcons.Edit}" />
|
||||
</ui:AppBarButton.Icon>
|
||||
|
||||
</ui:AppBarButton>
|
||||
<ui:AppBarButton x:Name="ShareButton"
|
||||
Label="Share">
|
||||
Label="Share">
|
||||
<ui:AppBarButton.Icon>
|
||||
<ui:FontIcon Icon="{x:Static ui:SegoeFluentIcons.Share}"/>
|
||||
<ui:FontIcon Icon="{x:Static ui:SegoeFluentIcons.Share}" />
|
||||
</ui:AppBarButton.Icon>
|
||||
</ui:AppBarButton>
|
||||
<ui:CommandBar.SecondaryCommands>
|
||||
<ui:AppBarButton x:Name="SettingsButton"
|
||||
Icon="Setting" Label="Settings"
|
||||
/>
|
||||
|
||||
Icon="Setting" Label="Settings" />
|
||||
</ui:CommandBar.SecondaryCommands>
|
||||
</ui:CommandBar>
|
||||
|
||||
|
||||
|
||||
|
||||
<ui:GridView x:Name="BasicGridView"
|
||||
Margin="20"
|
||||
IsItemClickEnabled="True"
|
||||
@@ -76,7 +76,7 @@
|
||||
ItemsSource="{Binding Devices}"
|
||||
ItemTemplate="{StaticResource DeviceItemTemplate}"
|
||||
SelectionMode="Single" />
|
||||
|
||||
|
||||
</StackPanel>
|
||||
|
||||
</UserControl>
|
||||
|
||||
</UserControl>
|
||||
Reference in New Issue
Block a user