<UserControl x:Class="CyberX8_Themes.UserControls.RobotFrontView"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             xmlns:local="clr-namespace:CyberX8_Themes.UserControls"
             xmlns:ctrl="http://OpenSEMI.Ctrlib.com/presentation"
             xmlns:i="http://schemas.microsoft.com/expression/2010/interactivity"
             xmlns:cal="http://www.caliburn.org" x:Name="self"    
             mc:Ignorable="d" 
             >
    <Grid HorizontalAlignment="Center" VerticalAlignment="Center">

        <Grid.RowDefinitions>
            <RowDefinition Height="Auto"/>
            <RowDefinition />
        </Grid.RowDefinitions>
        <Canvas x:Name="canvas"  PreviewDrop="Canvas_Drop" AllowDrop="True" Background="Transparent" Grid.RowSpan="2"/>

        <TextBlock Text="{Binding ElementName=self,Path=Title1}" FontFamily="Arial" FontSize="14" Foreground="{DynamicResource FG_Black}" VerticalAlignment="Center" HorizontalAlignment="Center">
            <TextBlock.Style>
                <Style>
                    <Style.Triggers>
                        <DataTrigger Binding="{Binding ShowTitle1,RelativeSource={RelativeSource FindAncestor, AncestorType={x:Type UserControl}}}" Value="False">
                            <Setter Property="TextBlock.Visibility" Value="Collapsed" />
                        </DataTrigger>
                    </Style.Triggers>
                </Style>
            </TextBlock.Style>
        </TextBlock>
        <Border Grid.Row="1" BorderThickness="1" BorderBrush="{DynamicResource FOUP_OuterBD}" Background="{DynamicResource FOUP_OuterBG}" HorizontalAlignment="Center" VerticalAlignment="Center" Width="150"  CornerRadius="4" Height="35">
            <Grid Height="33">
                <Rectangle Fill="{DynamicResource FOUP_InnerBG}" Margin="3,3,3,3" RadiusX="2" RadiusY="2"/>

                <Grid Margin="0,5">
                    <Grid.RowDefinitions>
                        <RowDefinition Height="30"/>
                    </Grid.RowDefinitions>
                    <Grid.ColumnDefinitions>
                        <ColumnDefinition Width="47"/>
                        <ColumnDefinition />
                    </Grid.ColumnDefinitions>
                    <TextBlock Text="Robot" FontFamily="Arial" FontSize="12" Foreground="{DynamicResource FG_Black}" HorizontalAlignment="Right" VerticalAlignment="Top" Margin="0,5,5,0"/>
                    <StackPanel Grid.Column="1" VerticalAlignment="Top" Margin="0,5,5,0">
                        <ctrl:Slot ViewType="Front" AllowDrop="True" Cursor="Hand" DataContext="{Binding UnitData.WaferManager.Wafers[0], ElementName=self}" WaferStatus="{Binding WaferStatus}" SlotID="{Binding SlotID}" ModuleID="{Binding ModuleID}" SourceName="{Binding SourceName}" SlotMouseButtonDown="Slot_SlotMouseButtonDown" WaferTransferStarted="Slot_WaferTransferStarted"/>
                    </StackPanel>

                </Grid>
            </Grid>
        </Border>

    </Grid>
</UserControl>