private void RedrawIfNeeded() { bool isRedrawNeeded = NodeInfoFactory.Timestamp != FLastTimestamp || !CurrentPatchWindow.Equals(FLastPatchWindow); if (isRedrawNeeded) { if (FTagPanel.Visible) { FTagPanel.Redraw(); } else { FTagPanel.PendingRedraw = true; } if (FCategoryPanel.Visible) { FCategoryPanel.Redraw(); } else { FCategoryPanel.PendingRedraw = true; } } FLastTimestamp = NodeInfoFactory.Timestamp; FLastPatchWindow = CurrentPatchWindow; }
void FHDEHost_WindowSelectionChanged(object sender, WindowEventArgs args) { FActiveWindow = args.Window; //remove it from the index it is now FWindowLIFO.Remove(FActiveWindow); //insert it at index 0 FWindowLIFO.Insert(0, FActiveWindow); }
private void RedrawIfNeeded() { bool isRedrawNeeded = NodeInfoFactory.Timestamp != FLastTimestamp || !CurrentPatchWindow.Equals(FLastPatchWindow); if (isRedrawNeeded) { UpdatePanels(); } FLastTimestamp = NodeInfoFactory.Timestamp; FLastPatchWindow = CurrentPatchWindow; }
public WindowSwitcherNode(IHDEHost host) { // The InitializeComponent() call is required for Windows Forms designer support. InitializeComponent(); FHDEHost = host; FHDEHost.WindowAdded += FHDEHost_WindowAdded; FHDEHost.WindowRemoved += FHDEHost_WindowRemoved; FHDEHost.WindowSelectionChanged += FHDEHost_WindowSelectionChanged; FActiveWindow = FHDEHost.ActivePatchWindow; var mappingRegistry = new MappingRegistry(); mappingRegistry.RegisterDefaultMapping<INamed, DefaultNameProvider>(); FHierarchyViewer.Registry = mappingRegistry; }
public void SetActiveWindow(IWindow2 window) { FLastActiveWindow = window; if (window.Equals(FNode.Window)) { IsActive = true; } else { IsActive = false; } foreach (var nodeView in FChildNodes) { nodeView.SetActiveWindow(window); } }
public ComponentModeEventArgs(IWindow2 window, ComponentMode componentMode) { ComponentMode = componentMode; Window = window; }
public WindowEventArgs(IWindow2 window) { Window = window; }
public bool Equals(IWindow2 other) { return(base.Equals(other)); }