private bool CheckCategoryUp(IToolboxCategory category) { var items = _service.GetToolboxItemSource().ToList(); if (!items.Contains(category)) { return(false); } var index = items.IndexOf(category); if (index <= 0) { return(false); } if (items.GetRange(0, index).Any(x => x.IsVisible)) { return(true); } return(false); }
protected override void ClearCurrentLayout() { _service.GetToolboxItemSource().ForEach(x => x.Items.Clear()); _service.StoreAndApplyLayout(new List <IToolboxCategory>()); }