internal virtual void MouseOver(GH_Canvas sender, GHCustomComponent customComponent, GH_CanvasMouseEvent e, ref GHMouseEventResult result) { if (this is IGHPanel) { ((IGHPanel)this).MouseOverChildren(sender, customComponent, e, ref result); if (result.HasFlag(GHMouseEventResult.Invalidated | GHMouseEventResult.Handled)) { return; } } if (ActiveZone.Contains(e.CanvasLocation)) { if (!isMouseIn) { isMouseIn = true; result = result | GHMouseEventResult.Invalidated | GHMouseEventResult.Handled; return; } } else { if (isMouseIn) { isMouseIn = false; result = result | GHMouseEventResult.Invalidated | GHMouseEventResult.Handled; } } }
public void AddActiveZone(string id, int color, bool visible, List <CustomVertex.TransformedColored> vertices) { lock (this) { if (!_active_zones.ContainsKey(id)) { _active_zones.Add(id, new ActiveZone(color, visible, vertices)); } else { _active_zones[id] = new ActiveZone(color, visible, vertices); } } }
public void AddActiveZone(string id, int color, bool visible, List<CustomVertex.TransformedColored> vertices) { lock (this) { if (!_active_zones.ContainsKey(id)) { _active_zones.Add(id, new ActiveZone(color, visible, vertices)); } else { _active_zones[id] = new ActiveZone(color, visible, vertices); } } }