C00225155-02/C00225155/MegaRobo.C00225155/Common/AlarmPopUpWindow.xaml

41 lines
1.8 KiB
Plaintext
Raw Normal View History

2026-04-13 09:12:49 +00:00
<Window x:Class="Common.AlarmPopUpWindow"
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:Common"
mc:Ignorable="d" ResizeMode="NoResize" Topmost="True" WindowStartupLocation="CenterScreen"
Title="系统报警" Height="450" Width="800">
<Grid Margin="10">
<Grid.RowDefinitions>
<RowDefinition Height="Auto"/>
<RowDefinition Height="*"/>
<RowDefinition Height="Auto"/>
</Grid.RowDefinitions>
<!-- 标题区域 -->
<StackPanel Grid.Row="0" Orientation="Horizontal" Margin="0,0,0,10">
<TextBlock Text="PLC报警信息" FontSize="16" FontWeight="Bold" Foreground="Red"/>
</StackPanel>
<!-- 报警信息列表 -->
<ScrollViewer Grid.Row="1" Margin="20,5,10,0">
<ItemsControl x:Name="AlarmItems">
<ItemsControl.ItemTemplate>
<DataTemplate>
<StackPanel Margin="5">
<TextBlock Text="{Binding Key}"/>
<TextBlock Text="{Binding Value}" FontWeight="Bold" Margin="10,5,0,0"/>
<Separator Margin="0,5"/>
</StackPanel>
</DataTemplate>
</ItemsControl.ItemTemplate>
</ItemsControl>
</ScrollViewer>
<!-- 按钮区域 -->
<Button Grid.Row="2" Content="确认" Width="100" Height="30"
HorizontalAlignment="Center" Click="OkButton_Click" Style="{StaticResource okBtnStyle}"/>
</Grid>
</Window>