FoupItemPro3.xaml 5.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576
  1. <UserControl x:Class="EfemUI.Controls.FoupItemPro3"
  2. xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  3. xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  4. xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
  5. xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
  6. xmlns:local="clr-namespace:EfemUI.Controls"
  7. xmlns:local1="clr-namespace:Aitex.Sorter.UI.Controls;assembly=Aitex.Sorter.UI"
  8. mc:Ignorable="d"
  9. d:DesignHeight="300" d:DesignWidth="300" PreviewKeyDown="UserControl_PreviewKeyDown">
  10. <UserControl.Resources>
  11. <local1:FoupModeConverter x:Key="FoupModeConverter" />
  12. <local:ItemIndexConverter5 x:Key="ItemIndexConverter5" />
  13. <local:ShowSlotItemConverter5 x:Key="ShowSlotItemConverter5" />
  14. <local:ItemIndexConverter6 x:Key="ItemIndexConverter6" />
  15. <local:ShowSlotItemConverter6 x:Key="ShowSlotItemConverter6" />
  16. </UserControl.Resources>
  17. <Border x:Name="root" Height="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ActualHeight}" Width="{Binding RelativeSource={RelativeSource TemplatedParent}, Path=ActualWidth}" Background="{Binding CarrierMode,Converter={StaticResource FoupModeConverter}}">
  18. <Grid>
  19. <Grid.RowDefinitions>
  20. <RowDefinition Height="25" />
  21. <RowDefinition Height="*" />
  22. <RowDefinition Height="8" />
  23. </Grid.RowDefinitions>
  24. <TextBlock Grid.Row="0" Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Center" Text="{Binding Title}" FontSize="20" />
  25. <ItemsControl Grid.Column="1" Grid.Row="1" x:Name="Slot" ItemsSource="{Binding Slots}" AlternationCount="26">
  26. <ItemsControl.Resources>
  27. <Style TargetType="{x:Type local1:WaferPro}">
  28. <EventSetter Event="local1:WaferPro.PreviewMouseLeftButtonDown" Handler="lbItem_PreviewMouseLeftButtonDown"/>
  29. <EventSetter Event="local1:WaferPro.PreviewMouseMove" Handler="lbItem_PreviewMouseMove"/>
  30. <EventSetter Event="Drop" Handler="Slot_Drop"/>
  31. </Style>
  32. </ItemsControl.Resources>
  33. <ItemsControl.ItemTemplate>
  34. <DataTemplate>
  35. <Grid>
  36. <Grid.ColumnDefinitions>
  37. <ColumnDefinition Width="175"/>
  38. <ColumnDefinition Width="9"/>
  39. </Grid.ColumnDefinitions>
  40. <local1:WaferPro IsEnableTextMenu1="{Binding ElementName=Slot,Path=DataContext.IsEnableTextMenu1}" Height="9.5" Margin="0" Padding="0" Grid.Row="0" Grid.Column="0" ShowSlotIndex="{Binding ElementName=Slot,Path=DataContext.ShowSlotsIndex}" WaferIDDisplayMode="WaferOrigin" WaferItem="{Binding}" Station="{Binding ElementName=Slot, Path=DataContext.Station}" WaferTransferCommand ="{Binding ElementName=Slot, Path=DataContext.WaferTransferCommand}" WaferTransferOptionCommand="{Binding ElementName=Slot, Path=DataContext.WaferTransferOptionCommand}" ShowControl="{Binding ElementName=Slot,Path=DataContext.ShowControl}">
  41. <local1:WaferPro.Slot>
  42. <MultiBinding Converter="{StaticResource ItemIndexConverter5 }">
  43. <Binding RelativeSource="{RelativeSource TemplatedParent}" Path="(ItemsControl.AlternationIndex)"/>
  44. <Binding ElementName="Slot" Path="DataContext.SlotCount" />
  45. </MultiBinding>
  46. </local1:WaferPro.Slot>
  47. <local1:WaferPro.ShowSlot>
  48. <MultiBinding Converter="{StaticResource ShowSlotItemConverter5 }">
  49. <Binding RelativeSource="{RelativeSource TemplatedParent}" Path="(ItemsControl.AlternationIndex)"/>
  50. <Binding ElementName="Slot" Path="DataContext.SlotCount" />
  51. </MultiBinding>
  52. </local1:WaferPro.ShowSlot>
  53. <!--<local:Wafer.Slot>
  54. <MultiBinding Converter="{StaticResource waferIDConverter }">
  55. <Binding/>
  56. <Binding ElementName="Slot" Path="ItemsSource"/>
  57. </MultiBinding>
  58. </local:Wafer.Slot>-->
  59. </local1:WaferPro>
  60. <TextBlock Grid.Row="0" Grid.Column="1" HorizontalAlignment="Center" VerticalAlignment="Center" Text="{Binding RelativeSource={RelativeSource TemplatedParent},Path=(ItemsControl.AlternationIndex), Converter={StaticResource ItemIndexConverter6}}" FontSize="8" FontWeight="Bold">
  61. <TextBlock.Visibility>
  62. <MultiBinding Converter="{StaticResource ShowSlotItemConverter6}">
  63. <Binding RelativeSource="{RelativeSource TemplatedParent}" Path="(ItemsControl.AlternationIndex)"/>
  64. <Binding ElementName="Slot" Path="DataContext.SlotCount" />
  65. </MultiBinding>
  66. </TextBlock.Visibility>
  67. </TextBlock>
  68. </Grid>
  69. </DataTemplate>
  70. </ItemsControl.ItemTemplate>
  71. </ItemsControl>
  72. </Grid>
  73. </Border>
  74. </UserControl>