public bool AddControl(Vector2D position) { ControlTransformer.isTransforming = false; controlAdder.AddControl(position, this); uiControl.isClicking = false; if (SelectedEntity2DList == null) { return(true); //ncrunch: no coverage } ControlProcessor.UpdateOutlines(SelectedEntity2DList); SetEntity2D((Control)ShownEntity2D); return(false); }
private void UpdateUIControlAndLists(Control control) { SelectedControlNamesInList.Add(control.Name); if (!SelectedEntity2DList.Contains(control)) { SelectedEntity2DList.Add(control); } IsSelectingControl = true; uiControl.SetMaterials(SelectedEntity2DList); Messenger.Default.Send(SelectedControlNamesInList, "SetSelectedName"); Messenger.Default.Send(uiControl.Index, "SetSelectedIndex"); ControlProcessor.UpdateOutlines(SelectedEntity2DList); controlChanger.SetControlLayer(control.RenderLayer, this); }
private void UpdateControlListAfterDelete() { uiControl.Index = -1; ControlProcessor.UpdateOutlines(SelectedEntity2DList); Messenger.Default.Send("", "DeleteSelectedContent"); if (SelectedEntity2DList.Count == 0) { return; } uiControl.Index = Scene.Controls.IndexOf(SelectedEntity2DList[SelectedEntity2DList.Count - 1]); SelectedControlNamesInList.Clear(); SelectedControlNamesInList.Add((Scene.Controls[uiControl.Index] as Control).Name); Messenger.Default.Send(SelectedControlNamesInList, "SetSelectedName"); Messenger.Default.Send(uiControl.Index, "SetSelectedIndex"); }
} //ncrunch: no coverage end public void UpdateOutLine(List <Entity2D> selectedEntity2D) { ControlProcessor.UpdateOutlines(selectedEntity2D); }