using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Windows.Controls; namespace HeuristicLab.MainForm.WPF { public abstract class WPFToolBarItem : WPFUserInterfaceItem, IToolBarItem { private bool isVisible = true; public bool IsVisible { get { return isVisible; } set { if (value == isVisible) return; isVisible = value; OnIsVisibleChanged(); } } public event EventHandler IsVisibleChanged; protected void OnIsVisibleChanged() { EventHandler handler = IsVisibleChanged; if (handler != null) handler(this, EventArgs.Empty); } } }