public void MakeLayerActive(PLayer l) { if (Layers.Contains(l)) { ActiveLayerIndex = Layers.IndexOf(l); } }
public LayerManager(ContextManager manager) { _manager = manager; _temp = manager.ActiveKernel.Get <PLayer>(); _layers = new List <PLayer>(); AddNewLayer(); IsDrawingTemp = true; }
public bool IsActive(PLayer l) { if (Layers.Contains(l)) { if (Layers.IndexOf(l) == ActiveLayerIndex) { return(true); } } return(false); }
public void RemoveLayer(PLayer l) { if (_layers.Contains(l)) { if (_layers.Count == 1) { AddNewLayer(); _layers.Remove(l); } ChangeActiveLayerAutomatically(); } }