public HistoryInfo(AeroNavigationBar Owner) { this.Owner = Owner; this.Owner.GoBack += delegate { if (GoBack.Count == 0) { throw new Exception("GoBack is empty"); } GoBack.Pop()(); }; this.Owner.GoForward += delegate { if (GoForward.Count == 0) { throw new Exception("GoForward is empty"); } GoForward.Pop()(); }; this.Owner.ButtonGoForward.Enabled = false; this.Owner.ButtonGoBack.Enabled = false; }