Files
Shrlalgo.RvKits/ShrlAlgoToolkit.RevitAddins/Windows/NavigateViewWin.xaml
2025-04-24 20:56:44 +08:00

27 lines
1.3 KiB
XML

<ui:FluentWindowEx
Height="200"
Title="选择视图"
Width="300"
d:DataContext="{d:DesignInstance Type=sControls3:NavigateViewViewModel}"
mc:Ignorable="d"
x:Class="ShrlAlgoToolkit.RevitAddins.Windows.NavigateViewWin"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:b="http://schemas.microsoft.com/xaml/behaviors"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:sControls3="clr-namespace:ShrlAlgoToolkit.RevitAddins.Windows"
xmlns:ui="https://github.com/ShrlAlgo/WPFluent"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<Window.Resources>
<ResourceDictionary Source="pack://application:,,,/ShrlAlgoToolkit.RevitAddins;component/WPFUI.xaml" />
</Window.Resources>
<Grid>
<ListBox DisplayMemberPath="Name" ItemsSource="{Binding Views}">
<b:Interaction.Triggers>
<b:EventTrigger EventName="MouseDoubleClick">
<b:InvokeCommandAction Command="{Binding NavigateViewCommand}" CommandParameter="{Binding SelectedItem, RelativeSource={RelativeSource FindAncestor, AncestorType=ListBox}}" />
</b:EventTrigger>
</b:Interaction.Triggers>
</ListBox>
</Grid>
</ui:FluentWindowEx>