TFLH/FeiYu/MainWindow.xaml
2026-08-07 12:38:01 +08:00

90 lines
5.9 KiB
XML

<mah:MetroWindow xmlns:Vision="clr-namespace:Views.Vision;assembly=Views"
x:Class="FeiYu.MainWindow"
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:mah="clr-namespace:MahApps.Metro.Controls;assembly=MahApps.Metro"
xmlns:MyNamespace="clr-namespace:Views;assembly=Views"
xmlns:Motion="clr-namespace:Views.Motion;assembly=Views"
xmlns:local="clr-namespace:FeiYu"
mc:Ignorable="d"
Title="{Binding SystemPar.MachineName}"
Name="mywd"
Height="1080" Width="1920"
WindowStartupLocation="CenterScreen"
Icon="Resources/logo1.ico"
WindowState="Maximized"
Closing="MetroWindow_Closing">
<mah:MetroWindow.Background>
<!--<ImageBrush ImageSource="Resources/3.jpg"/>-->
<ImageBrush ImageSource="{Binding SystemPar.SystemBackgroundPath}" />
</mah:MetroWindow.Background>
<!-- FontFamily="方正宋一繁体" -->
<mah:MetroWindow.RightWindowCommands>
<mah:WindowCommands>
<!--<CheckBox Content="空跑模式" IsChecked="{Binding RunningMode}"></CheckBox>-->
<Label Content="当前机种:" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Foreground="White">
</Label>
<Label Content="{Binding CurrentMachine.MachineName}" HorizontalContentAlignment="Center" VerticalContentAlignment="Center" Foreground="White">
</Label>
<Button Content="切换主题" Click="SubjectSwitch">
</Button>
<Button Content="切换背景" Click="BackgroundSwitch">
</Button>
<Menu Background="{x:Null}">
<MenuItem Header="帮助" FontFamily="楷体" Background="{x:Null}" Foreground="White">
<!--<MenuItem Header="用户登入" Name="SwitchUser" Background="AliceBlue" Foreground="Black" Click="SwitchUser_Click"></MenuItem>-->
<MenuItem Name="menSystemSet"
Header="{Binding PermissionButtonName}"
Click="menSystemSet_Click"
Background="AliceBlue"
Foreground="Black" />
<MenuItem Name="menPwdAlter"
Header="修改密码" Click="menPwdAlter_Click"
Background="AliceBlue"
Foreground="Black" />
<MenuItem Header="生产数据清零" Background="AliceBlue"
Foreground="Black"
Visibility="{Binding AllVis}"
Command="{Binding CountClearedCommand}" />
<!--<CheckBox Content="启用MES" Background="AliceBlue" IsChecked="{Binding ERPVM.ERP.Enableing}" FontFamily="楷体" Visibility="{Binding AllVis}"></CheckBox>-->
<!--<CheckBox Content="手动上传" Background="AliceBlue" IsChecked="{Binding CurrentMachine.MyPar.CheckUpload}" FontFamily="楷体" Visibility="{Binding AllVis}"></CheckBox>-->
<!--<CheckBox Content="空跑模式" Background="AliceBlue" IsChecked="{Binding CurrentMachine.RunningMode}" FontFamily="楷体" Visibility="{Binding AllVis}"></CheckBox>-->
<!--<CheckBox Content="启用第一层" Background="AliceBlue" IsChecked="{Binding Enable1}" FontFamily="楷体" Visibility="{Binding AllVis}"></CheckBox>
<CheckBox Content="启用第二层" Background="AliceBlue" IsChecked="{Binding Enable2}" FontFamily="楷体" Visibility="{Binding AllVis}"></CheckBox>
<CheckBox Content="启用第三层" Background="AliceBlue" IsChecked="{Binding Enable3}" FontFamily="楷体" Visibility="{Binding AllVis}"></CheckBox>
<CheckBox Content="启用第四层" Background="AliceBlue" IsChecked="{Binding Enable4}" FontFamily="楷体" Visibility="{Binding AllVis}"></CheckBox>
<CheckBox Content="启用第五层" Background="AliceBlue" IsChecked="{Binding Enable5}" FontFamily="楷体" Visibility="{Binding AllVis}"></CheckBox>-->
</MenuItem>
</Menu>
</mah:WindowCommands>
</mah:MetroWindow.RightWindowCommands>
<Grid>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="70*">
</ColumnDefinition>
<!--<ColumnDefinition Width="1"></ColumnDefinition >-->
<!--<ColumnDefinition Width="{Binding GridWidth}"></ColumnDefinition>-->
</Grid.ColumnDefinitions>
<TabControl Background="Transparent" ItemsSource="{Binding TabItemList}" SelectedItem="{Binding SelectTabItem}" SelectedIndex="{Binding SelectedIndex}">
</TabControl>
<!--<GridSplitter Grid.Column="1" Background="Transparent"></GridSplitter>-->
<!--<Border Grid.Column="2">
<MyNamespace:ControlPanel />
</Border>-->
</Grid>
<!--<Grid Height="42" VerticalAlignment="Top">
<Grid.ColumnDefinitions>
<ColumnDefinition></ColumnDefinition>
<ColumnDefinition></ColumnDefinition>
</Grid.ColumnDefinitions>
<Border Grid.Column="1" Height="42" Background="{Binding ShowStatu.StatusBackground}">
<TextBlock Text="{Binding ShowStatu.StatuInfo}" Tag="{Binding ShowStatu.StatuInfo}" FontSize="25" FontWeight="Bold" Foreground="{Binding ShowStatu.StatusForeground}" VerticalAlignment="Center" />
</Border>
</Grid>-->
</Grid>
</mah:MetroWindow>