123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449 |
- <wnd:CustomWnd x:Class="EfemDualUI.MainView"
- xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
- xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
- xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
- xmlns:cal="http://www.caliburn.org"
- WindowState="Maximized"
- WindowStartupLocation="CenterScreen"
- xmlns:wnd="http://OpenSEMI.Ctrlib.com/presentation"
- xmlns:converter="clr-namespace:MECF.Framework.UI.Client.Ctrlib.Converter;assembly=MECF.Framework.UI.Client"
- xmlns:deviceControl="clr-namespace:Aitex.Core.UI.DeviceControl;assembly=MECF.Framework.UI.Core"
- xmlns:efemDualUi="clr-namespace:EfemDualUI"
- Title="MainView" Height="1060" Width="1920">
- <Window.Resources>
- <efemDualUi:DateTimeToTextConverter x:Key="dateTimeToTextConverter"/>
- <efemDualUi:CollectionLastIndexConverter x:Key="collectionLastIndexConverter" />
- <converter:UnitOnlineBorderColorConverter x:Key="UnitOnlineBorderColorConverter"/>
- <converter:BoolReverseConverter x:Key="BoolReverseConverter"></converter:BoolReverseConverter>
- </Window.Resources>
- <Grid Background="{DynamicResource MainArea_BG}">
- <Grid x:Name="LoginPart" Background="{StaticResource Login_BG}">
- <Ellipse MaxWidth="1000" MaxHeight="800" Fill="{DynamicResource Login_BG_Highlight}"/>
- <Grid Width="590" Height="465">
- <Grid.Effect>
- <DropShadowEffect Color="#FF0B1E5A" BlurRadius="30" ShadowDepth="0"/>
- </Grid.Effect>
- <Border BorderBrush="{DynamicResource LoginPanel_BD}" BorderThickness="1" CornerRadius="3" Background="{DynamicResource LoginPanel_BG}">
- <Grid>
- <Path Data="M0,0 L0.67857742,0.054499656 C95.091171,7.7605554 387.09985,38.266688 589.03564,132.3875 L590,132.84716 590,249.338 C590,250.99486 588.65686,252.338 587,252.338 L441.29346,252.338 440.83957,252.18517 C350.99802,222.35816 203.01686,189.00345 6.2653065,198.4652 L0,198.80318 z" Stretch="Fill" Height="252.338" VerticalAlignment="Bottom" Width="590" Fill="{DynamicResource LoginPanel_InnerGrow}"/>
- <Grid Margin="60,40">
- <Grid.RowDefinitions>
- <RowDefinition Height="70"/>
- <RowDefinition Height="10"/>
- <RowDefinition/>
- <RowDefinition Height="Auto"/>
- </Grid.RowDefinitions>
- <StackPanel HorizontalAlignment="Left" Orientation="Horizontal">
- <TextBlock TextWrapping="Wrap" Text="Login" FontWeight="Bold" FontFamily="Arial" FontSize="50" Foreground="White" VerticalAlignment="Bottom" Margin="0,0,0,5"/>
- <TextBlock TextWrapping="Wrap" Text="登录" FontFamily="SimHei" FontSize="32" Foreground="White" Opacity="0.5" Margin="10,0,0,12" VerticalAlignment="Bottom" FontWeight="Bold"/>
- </StackPanel>
- <StackPanel Grid.Row="1" Orientation="Horizontal" Margin="-20,0">
- <Rectangle Fill="#19FFFFFF" Width="10" Height="10"/>
- <Rectangle Fill="#7FFFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#33FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#66FFFFFF" Width="10" Height="10" Margin="50,0,0,0"/>
- <Rectangle Fill="#7FFFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#4CFFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#33FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#66FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#99FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#7FFFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#99FFFFFF" Width="10" Height="10" Margin="20,0,0,0"/>
- <Rectangle Fill="#B2FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#CCFFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#CCFFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#B2FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#19FFFFFF" Width="10" Height="10" Margin="50,0,0,0"/>
- <Rectangle Fill="#4CFFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#19FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#4CFFFFFF" Width="10" Height="10" Margin="30,0,0,0"/>
- <Rectangle Fill="#66FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#33FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#33FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#66FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#7FFFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#4CFFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- <Rectangle Fill="#33FFFFFF" Width="10" Height="10" Margin="3,0,0,0"/>
- </StackPanel>
- <Grid Margin="40" Grid.Row="2">
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="130"/>
- <ColumnDefinition/>
- </Grid.ColumnDefinitions>
- <Grid.RowDefinitions>
- <RowDefinition/>
- <RowDefinition/>
- <RowDefinition/>
- </Grid.RowDefinitions>
- <TextBox x:Name="tbLoginName" Grid.Column="1" Text="" TabIndex="0" TextWrapping="Wrap" Height="45" VerticalAlignment="Center" Style="{DynamicResource Login_TextBox}"/>
- <PasswordBox x:Name="pdbPassword" Grid.Column="1" Grid.Row="1" TabIndex="1" Height="45" Style="{DynamicResource Login_PasswordBox}">
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="KeyDown">
- <cal:ActionMessage MethodName="Enter">
- <cal:Parameter Value="$eventargs" />
- <cal:Parameter Value="{Binding ElementName=tbLoginName, Path=Text}" />
- <cal:Parameter Value="{Binding ElementName=pdbPassword}" />
- <cal:Parameter Value="{Binding ElementName=cbRole, Path=SelectedValue}" />
- </cal:ActionMessage>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </PasswordBox>
- <ComboBox x:Name="cbRole" Style="{DynamicResource Login_ComboBox}" Grid.Column="1" Grid.Row="2" Height="45" ItemsSource="{Binding Roles}" DisplayMemberPath="RoleName" SelectedIndex="0" TabIndex="2">
- </ComboBox>
- <TextBlock TextWrapping="Wrap" Text="User Name" Foreground="{DynamicResource FG_White}" FontSize="16" FontFamily="Arial" FontWeight="Bold" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0,0,20,0"/>
- <TextBlock TextWrapping="Wrap" Text="Password" Foreground="{DynamicResource FG_White}" FontSize="16" FontFamily="Arial" FontWeight="Bold" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0,0,20,0" Grid.Row="1"/>
- <TextBlock TextWrapping="Wrap" Text="Role" Foreground="{DynamicResource FG_White}" FontSize="16" FontFamily="Arial" FontWeight="Bold" HorizontalAlignment="Right" VerticalAlignment="Center" Margin="0,0,20,0" Grid.Row="2"/>
- </Grid>
- <Button Style="{StaticResource Login_Button}" Content="Login" Grid.Row="3" FontFamily="Arial" FontSize="18" FontWeight="Bold" HorizontalAlignment="Center" VerticalAlignment="Center" Height="55" Width="160">
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="Click">
- <cal:ActionMessage MethodName="Login">
- <cal:Parameter Value="{Binding ElementName=tbLoginName, Path=Text}" />
- <cal:Parameter Value="{Binding ElementName=pdbPassword}" />
- <cal:Parameter Value="{Binding ElementName=cbRole, Path=SelectedValue}" />
- </cal:ActionMessage>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </Button>
- </Grid>
- </Grid>
- </Border>
- </Grid>
- <Grid.Style>
- <Style>
- <Style.Triggers>
- <DataTrigger Binding="{Binding IsLogin}" Value="True">
- <Setter Property="Grid.Visibility" Value="Collapsed"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </Grid.Style>
- </Grid>
- <Border BorderBrush="LightCyan" BorderThickness="2" Margin="3,1" CornerRadius="4" Padding="1" >
- <Grid x:Name="MainPage">
- <Grid.RowDefinitions>
- <RowDefinition Height="120"/>
- <RowDefinition />
- <RowDefinition Height="30"/>
- <RowDefinition Height="70"/>
- </Grid.RowDefinitions>
- <Grid x:Name="Top_Frame">
- <Grid.RowDefinitions>
- <RowDefinition Height="30*" />
- </Grid.RowDefinitions>
- <Border Style="{DynamicResource TopFrame_Style}">
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="200"/>
- <ColumnDefinition/>
- <ColumnDefinition Width="250"/>
- <ColumnDefinition Width="Auto"/>
- <ColumnDefinition Width="100"/>
- </Grid.ColumnDefinitions>
- <StackPanel Orientation="Vertical" Grid.Row="0" Grid.Column="0">
- <Image Source="/Resources/Images/jetplasmalogo.png" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="0,30,0,0" />
- <TextBlock Text="{Binding SoftwareVersion}" Foreground="white" FontSize="18" Margin="80,-20,0,0"/>
- </StackPanel>
-
- <StackPanel VerticalAlignment="Bottom" HorizontalAlignment="Left" Orientation="Horizontal" Margin="10,0,0,5">
- <TextBlock Text="Time:" Foreground="white" FontSize="13" Padding="5,0" />
- <TextBlock Text="{Binding RunTime}" Foreground="white" FontSize="13" Padding="5,0" />
- </StackPanel>
- <!--<StackPanel VerticalAlignment="Bottom" HorizontalAlignment="Left" Orientation="Horizontal" Margin="10,0,0,5">
- <TextBlock Text="Ver:" Foreground="white" FontSize="13" Padding="5,0" />
- <TextBlock Text="{Binding SoftwareVersion}" Foreground="white" FontSize="13" Padding="5,0" />
- </StackPanel>-->
- <Grid Grid.Column="1" Margin="10,8,0,8">
- <Grid.RowDefinitions>
- <RowDefinition/>
- <RowDefinition/>
- <RowDefinition/>
- </Grid.RowDefinitions>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="80" />
- <ColumnDefinition MinWidth="65"/>
- <ColumnDefinition Width="80"/>
- <ColumnDefinition MinWidth="65"/>
- <ColumnDefinition Width="80"/>
- <ColumnDefinition MinWidth="65"/>
- </Grid.ColumnDefinitions>
- <Label Style="{DynamicResource TopLable_LeftTop}" BorderBrush="Gray" Content="System" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
- <Label Grid.Column="2" Style="{DynamicResource TopLable}" BorderBrush="Gray" Content="EFEM" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
- <Label Grid.Column="4" Style="{DynamicResource TopLable}" BorderBrush="Gray" Content="TM" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
- <Label Grid.Row="1" Grid.Column="0" Visibility="{Binding PMAVisibility}" BorderBrush="{Binding IsOnlinePMA, Converter={StaticResource UnitOnlineBorderColorConverter}}" Style="{DynamicResource TopLable}" Content="PMA" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
- <Label.ContextMenu>
- <ContextMenu>
- <MenuItem Header="Put PMA Online" IsEnabled="{Binding IsOnlinePMA, Converter={StaticResource BoolReverseConverter}}" >
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="Click">
- <cal:ActionMessage MethodName="PutModuleOnline">
- <cal:Parameter Value="PMA"></cal:Parameter>
- </cal:ActionMessage>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </MenuItem>
- <MenuItem Header="Put PMA Offline" IsEnabled="{Binding IsOnlinePMA }" >
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="Click">
- <cal:ActionMessage MethodName="PutModuleOffline">
- <cal:Parameter Value="PMA"></cal:Parameter>
- </cal:ActionMessage>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </MenuItem>
- </ContextMenu>
- </Label.ContextMenu>
- </Label>
- <Label Grid.Row="1" Grid.Column="2" Visibility="{Binding PMBVisibility}" BorderBrush="{Binding IsOnlinePMB, Converter={StaticResource UnitOnlineBorderColorConverter}}" Style="{DynamicResource TopLable}" Content="PMB" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
- <Label.ContextMenu>
- <ContextMenu>
- <MenuItem Header="Put PMB Online" IsEnabled="{Binding IsOnlinePMB, Converter={StaticResource BoolReverseConverter}}" >
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="Click">
- <cal:ActionMessage MethodName="PutModuleOnline">
- <cal:Parameter Value="PMB"></cal:Parameter>
- </cal:ActionMessage>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </MenuItem>
- <MenuItem Header="Put PMB Offline" IsEnabled="{Binding IsOnlinePMB }" >
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="Click">
- <cal:ActionMessage MethodName="PutModuleOffline">
- <cal:Parameter Value="PMB"></cal:Parameter>
- </cal:ActionMessage>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </MenuItem>
- </ContextMenu>
- </Label.ContextMenu>
- </Label>
- <Label Grid.Row="1" Grid.Column="4" BorderBrush="Gray" Style="{DynamicResource TopLable}" Content="Host" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
- <Label Grid.Row="2" Grid.Column="0" BorderBrush="Gray" Style="{DynamicResource TopLable_LeftBottom}" Content="Log" HorizontalContentAlignment="Center" VerticalContentAlignment="Center"/>
- <TextBox Grid.Column="1" TextWrapping="Wrap" IsReadOnly="True" Text="{Binding RtStatus}" Background="{Binding RtStatusBackground}" Style="{StaticResource TextBox_Top}" VerticalContentAlignment="Center"/>
- <TextBox Grid.Column="3" TextWrapping="Wrap" IsReadOnly="True" Text="{Binding EfemStatus}" Background="{Binding EfemStatusBackground}" Style="{StaticResource TextBox_Top}" VerticalContentAlignment="Center"/>
- <TextBox Grid.Column="5" TextWrapping="Wrap" IsReadOnly="True" Text="{Binding TMStatus}" Background="{Binding TMStatusBackground}" Style="{StaticResource TextBox_RightTop}" VerticalContentAlignment="Center"/>
- <TextBox Grid.Row="1" Grid.Column="1" TextWrapping="Wrap" IsReadOnly="True" Text="{Binding PMAStatus}" Visibility="{Binding PMAVisibility}" Background="{Binding PMAStatusBackground}" Style="{StaticResource TextBox_Top}" VerticalContentAlignment="Center"/>
- <TextBox Grid.Row="1" Visibility="{Binding PMBVisibility}" Grid.Column="3" TextWrapping="Wrap" IsReadOnly="True" Text="{Binding PMBStatus}" Background="{Binding PMBStatusBackground}" Style="{StaticResource TextBox_Top}" VerticalContentAlignment="Center"/>
- <TextBox Grid.Row="1" Grid.Column="5" TextWrapping="Wrap" IsReadOnly="True" Text="{Binding HostStatus}" Background="{Binding HostStatusBackground}" Style="{StaticResource TextBox_Top}" VerticalContentAlignment="Center"/>
- <Grid Grid.Column="1" Grid.Row="2" Grid.ColumnSpan="5">
- <Grid.ColumnDefinitions>
- <ColumnDefinition />
- <ColumnDefinition Width="Auto"/>
- </Grid.ColumnDefinitions>
- <ComboBox Style="{DynamicResource Top_ComboBox}" ItemsSource="{Binding EventLogList}" Visibility="{Binding AllEventsVisibility}" SelectedIndex="{Binding EventLogList.Count,Mode=OneWay,Converter={StaticResource collectionLastIndexConverter}}" VerticalContentAlignment="Center" FontSize="15" Height="Auto">
- <ComboBox.ItemTemplate>
- <DataTemplate>
- <ContentControl>
- <ContentControl.Style>
- <Style TargetType="ContentControl">
- <Setter Property="Background" Value="{StaticResource MessagesInformationBackgroundBrush}"/>
- <Style.Triggers>
- <DataTrigger Binding="{Binding Level}" Value="Alarm">
- <Setter Property="Foreground" Value="{StaticResource MessagesErrorForegroundBrush}"/>
- </DataTrigger>
- <DataTrigger Binding="{Binding Level}" Value="Warning">
- <Setter Property="Foreground" Value="{StaticResource MessagesWarningForegroundBrush}"/>
- </DataTrigger>
- <DataTrigger Binding="{Binding Level}" Value="Information">
- <Setter Property="Foreground" Value="{StaticResource MessagesInformationForegroundBrush}"/>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </ContentControl.Style>
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="100"/>
- <ColumnDefinition Width="100"/>
- <ColumnDefinition Width="0"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <TextBlock Margin="8,0,0,0" Grid.Column="0" Text="{Binding OccuringTime, Converter={StaticResource dateTimeToTextConverter}}" />
- <TextBlock Grid.Column="2" Text="{Binding Id}" Margin="8,0,0,0"/>
- <TextBlock Grid.Column="1" Text="{Binding Source}" Margin="8,0,0,0" />
- <TextBlock Grid.Column="3" Text="{Binding Description}" Margin="8,0,0,0"/>
- </Grid>
- </ContentControl>
- </DataTemplate>
- </ComboBox.ItemTemplate>
- </ComboBox>
- <ComboBox Style="{DynamicResource Top_ComboBox}" ItemsSource="{Binding WarnEventLogList}" Visibility="{Binding WarnEventsVisibility}" SelectedIndex="{Binding WarnEventLogList.Count,Mode=OneWay,Converter={StaticResource collectionLastIndexConverter}}" VerticalContentAlignment="Center" FontSize="15" Height="Auto" SelectionChanged="ComboBox_SelectionChanged">
- <ComboBox.ItemTemplate>
- <DataTemplate>
- <ContentControl>
- <ContentControl.Style>
- <Style TargetType="ContentControl">
- <Setter Property="Background" Value="{StaticResource MessagesInformationBackgroundBrush}"/>
- <Style.Triggers>
- <DataTrigger Binding="{Binding Level}" Value="Alarm">
- <Setter Property="Foreground" Value="{StaticResource MessagesErrorForegroundBrush}"/>
- </DataTrigger>
- <DataTrigger Binding="{Binding Level}" Value="Warning">
- <Setter Property="Foreground" Value="{StaticResource MessagesWarningForegroundBrush}"/>
- </DataTrigger>
- <DataTrigger Binding="{Binding Level}" Value="Information">
- <Setter Property="Foreground" Value="{StaticResource MessagesInformationForegroundBrush}"/>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </ContentControl.Style>
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="100"/>
- <ColumnDefinition Width="100"/>
- <ColumnDefinition Width="0"/>
- <ColumnDefinition Width="*"/>
- </Grid.ColumnDefinitions>
- <TextBlock Margin="2,0,0,0" Grid.Column="0" Text="{Binding OccuringTime, Converter={StaticResource dateTimeToTextConverter}}" />
- <TextBlock Grid.Column="2" Text="{Binding Id}" Margin="8,0,0,0"/>
- <TextBlock Grid.Column="1" Text="{Binding Source}" Margin="8,0,0,0" />
- <TextBlock Grid.Column="3" Text="{Binding Description}" Margin="2,0,0,0"/>
- </Grid>
- </ContentControl>
- </DataTemplate>
- </ComboBox.ItemTemplate>
- </ComboBox>
- <Label Grid.Row="2" Grid.Column="6" Style="{DynamicResource TopLable_RightBottom}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
- <CheckBox Content="Alarm" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="{DynamicResource FG_Black}" FontFamily="Arial" FontSize="16">
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="Checked">
- <cal:ActionMessage MethodName="ShowAlarmEvents">
- </cal:ActionMessage>
- </i:EventTrigger>
- <i:EventTrigger EventName="Unchecked">
- <cal:ActionMessage MethodName="ShowAllEvents">
- </cal:ActionMessage>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </CheckBox>
- </Label>
- </Grid>
- </Grid>
- <Grid Grid.Column="2" Margin="8,10" IsEnabled="{Binding IsPermission}">
- <Grid.RowDefinitions>
- <RowDefinition/>
- <RowDefinition/>
- </Grid.RowDefinitions>
- <Grid.ColumnDefinitions>
- <ColumnDefinition />
- <ColumnDefinition />
- </Grid.ColumnDefinitions>
- <Button Content="FA Enable" Margin="2,4" Style="{DynamicResource TopButton}" IsEnabled="{Binding IsEnableFAEnable}">
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="Click">
- <cal:ActionMessage MethodName="FAEnable"/>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </Button>
- <Button Grid.Column="1" Content="FA Disable" Margin="2,4" Style="{DynamicResource TopButton}" IsEnabled="{Binding IsDisableFAEnable}">
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="Click">
- <cal:ActionMessage MethodName="FADisable"/>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </Button>
- <Button Grid.Row="1" Content="Reset" Margin="2,4" Style="{DynamicResource TopButton}" Visibility="Collapsed">
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="Click">
- <cal:ActionMessage MethodName="Reset">
- </cal:ActionMessage>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </Button>
- <Button Grid.Row="1" Grid.Column="0" Content="Buzzer Off" Margin="2,4" Style="{DynamicResource TopButton}">
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="Click">
- <cal:ActionMessage MethodName="BuzzerOff">
- </cal:ActionMessage>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </Button>
- </Grid>
- <Label Grid.Column="3" Style="{DynamicResource TopLable_SignalTower}" Margin="0,5" Width="50" VerticalAlignment="Stretch" HorizontalContentAlignment="Center" VerticalContentAlignment="Center">
- <Viewbox Width="45" Height="80">
- <deviceControl:AITSignalTower Width="45" Height="110" DeviceData="{Binding SignalTowerData}"></deviceControl:AITSignalTower>
- </Viewbox>
- </Label>
- <Grid Grid.Column="4" Margin="5,10">
- <Grid.RowDefinitions>
- <RowDefinition />
- <RowDefinition />
- </Grid.RowDefinitions>
- <Border Margin="2,4" Background="{DynamicResource TopFrame_UserInfoBG}" BorderBrush="{DynamicResource TopFrame_UserInfoBD}" BorderThickness="1" CornerRadius="5" SnapsToDevicePixels="True">
- <TextBlock TextWrapping="NoWrap" Text="{Binding User.LoginName}" HorizontalAlignment="Center" VerticalAlignment="Center" Foreground="{DynamicResource TopFrame_TextColor}" FontFamily="Arial" FontSize="16"/>
- </Border>
- <Button Grid.Row="1" Style="{DynamicResource Logout_Button}" Margin="2,4" Content="Logout">
- <i:Interaction.Triggers>
- <i:EventTrigger EventName="Click">
- <cal:ActionMessage MethodName="Logout">
- </cal:ActionMessage>
- </i:EventTrigger>
- </i:Interaction.Triggers>
- </Button>
- </Grid>
- </Grid>
- </Border>
- </Grid>
- <Grid Grid.Row="1" Background="{DynamicResource MainArea_BG}">
- <Rectangle Fill="{DynamicResource MainArea_InnerBG}" Margin="20,8" RadiusX="5" RadiusY="5">
- <Rectangle.Effect>
- <BlurEffect Radius="40"/>
- </Rectangle.Effect>
- </Rectangle>
- <ContentControl x:Name="ActiveItem" cal:View.Context="{Binding Context}" cal:View.Model="{Binding ActiveItem}" Margin="10">
- </ContentControl>
- </Grid>
- <Border x:Name="Sub_Menu_Bar" Grid.Row="2" Style="{DynamicResource Sub_Menu_BarStyle}">
- <Menu ItemsSource="{Binding Path=SubMenuItems}" Grid.Row="0" Background="{x:Null}" ItemContainerStyle="{DynamicResource BottomSubMenu}" Margin="3,0">
- <Menu.ItemTemplate>
- <DataTemplate>
- <TextBlock Margin="1" Text="{Binding Path=ResKey}"/>
- </DataTemplate>
- </Menu.ItemTemplate>
- </Menu>
- </Border>
- <Border x:Name="Bottom_Frame" Grid.Row="3" Style="{DynamicResource Bottom_FrameStyle}">
- <Grid>
- <Grid.ColumnDefinitions>
- <ColumnDefinition Width="150"/>
- <ColumnDefinition Width="*"/>
- <ColumnDefinition Width="150"/>
- </Grid.ColumnDefinitions>
- <!--<TextBlock HorizontalAlignment="Center" TextWrapping="Wrap" Text="LOGO" VerticalAlignment="Center" FontFamily="Arial" Foreground="White" FontSize="50" FontWeight="Bold" Margin="9,10,1743,2" FontStyle="Italic" RenderTransformOrigin="-5.298,-0.284"/>-->
- <Menu ItemsSource="{Binding Path=MenuItems}" Grid.Row="0" Grid.Column="1" Background="{x:Null}" HorizontalAlignment="Left" VerticalAlignment="Center" Margin="10,0" ItemContainerStyle="{DynamicResource MainMenu}">
- <Menu.ItemTemplate>
- <DataTemplate>
- <TextBlock Margin="1" Text="{Binding Path=ResKey}"/>
- </DataTemplate>
- </Menu.ItemTemplate>
- </Menu>
- <TextBlock Grid.Column="2" Opacity="0.2" HorizontalAlignment="Center" Text="Mars" VerticalAlignment="Center" FontFamily="Arial" Foreground="White" FontSize="50" FontWeight="Bold" Margin="10,0" FontStyle="Italic">
- <TextBlock.Effect>
- <DropShadowEffect/>
- </TextBlock.Effect>
- </TextBlock>
- </Grid>
- </Border>
- <Grid.Style>
- <Style>
- <Style.Triggers>
- <DataTrigger Binding="{Binding IsLogin}" Value="False">
- <Setter Property="Grid.Visibility" Value="Collapsed"></Setter>
- </DataTrigger>
- </Style.Triggers>
- </Style>
- </Grid.Style>
- </Grid>
- </Border>
- </Grid>
- </wnd:CustomWnd>
|