123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110 |
- using System;
- using System.Collections.Generic;
- using System.Windows;
- using System.Windows.Controls;
- using System.Windows.Input;
- using Aitex.Core.RT.Log;
- using VirgoUI.Controls.Parts;
- using MECF.Framework.Common.Equipment;
- using OpenSEMI.ClientBase;
- using OpenSEMI.Ctrlib.Controls;
- using Slot = OpenSEMI.Ctrlib.Controls.Slot;
- /// <summary>
- /// This view model is basic model used for machine part
- /// </summary>
- ///
- namespace VirgoUI.Client.Models
- {
- public class UnitModel : BaseModel
- {
- #region Property
- public ModuleInfo FOUPA { get; set; }
- public ModuleInfo FOUPB { get; set; }
- public ModuleInfo TM { get; set; }
- public ModuleInfo EFEM { get; set; }
- public ModuleInfo Aligner { get; set; }
- public ModuleInfo LLA { get; set; }
- public ModuleInfo LLB { get; set; }
- public ModuleInfo PM1 { get; set; }
- public ModuleInfo PM2 { get; set; }
- public ModuleInfo PM3 { get; set; }
- public ModuleInfo PM4 { get; set; }
- public ModuleInfo PM5 { get; set; }
- public ModuleInfo PM6 { get; set; }
- #endregion
- protected override void OnInitialize()
- {
- base.OnInitialize();
- }
- protected void InitTM()
- {
- TM = ModuleManager.ModuleInfos["TMRobot"];
- }
- protected void InitLL()
- {
- LLA = ModuleManager.ModuleInfos["LLA"];
- LLB = ModuleManager.ModuleInfos["LLB"];
- }
- protected void InitEFEM()
- {
- EFEM = ModuleManager.ModuleInfos["EfemRobot"];
- Aligner = ModuleManager.ModuleInfos["Aligner"];
- }
- protected void InitFOUP()
- {
- FOUPA = ModuleManager.ModuleInfos["LP1"];
- FOUPB = ModuleManager.ModuleInfos["LP2"];
- }
- protected void InitPM()
- {
- PM1 = ModuleManager.ModuleInfos["PM1"];
- PM2 = ModuleManager.ModuleInfos["PM2"];
- PM3 = ModuleManager.ModuleInfos["PM3"];
- PM4 = ModuleManager.ModuleInfos["PM4"];
- PM5 = ModuleManager.ModuleInfos["PM5"];
- PM6 = ModuleManager.ModuleInfos["PM6"];
- }
-
- /// <summary>
- /// support wafer transfer for slot
- /// </summary>
- public void OnWaferTransfer(DragDropEventArgs args)
- {
- try
- {
- WaferMoveManager.Instance.TransferWafer(args.TranferFrom, args.TranferTo, 0.0f);
- }
- catch (Exception ex)
- {
- LOG.Error(ex.Message, ex);
- }
- }
- /// <summary>
- /// support context menu
- /// </summary>
- public void OnMouseUp(object sender, MouseButtonEventArgs e)
- {
- if (e.ChangedButton == MouseButton.Right)
- {
- Slot slot = sender as Slot;
- ContextMenu cm = ContextMenuManager.Instance.GetSlotMenus(slot);
- if (cm != null)
- {
- ((FrameworkElement)e.Source).ContextMenu = cm;
- }
- }
- }
- }
- }
|