protected virtual void OnTabMouseUp(TabMouseEventArgs e) { if (TabMouseUp != null) { TabMouseUp(this, e); } if (e.TabPage == clickClose) { Rectangle closerect = GetTabCloseRect(e.TabPage, e.TabBounds); if (closerect.Contains(e.Location)) { TabClosingEventArgs tcea = new TabClosingEventArgs(e.TabPage); OnTabClosing(tcea); if (!tcea.Cancel) { OnTabClosed(tcea); } return; } } Rectangle bounds = GetTabContentRect(e.TabPage, e.TabBounds); e.TabPage.CallTabMouseUp(new TabMouseEventArgs(e.Button, e.Clicks, e.X, e.Y, e.Delta, e.TabPage, Bounds)); }
protected virtual void OnTabClosing(TabClosingEventArgs e) { if (TabClosing != null) { TabClosing(this, e); } }
protected virtual void OnTabClosing(TabClosingEventArgs e) { if (TabClosing != null) { TabClosing(this, e); } if (!e.Cancel) { e.TabPage.CallTabClosing(e); } }
internal void CallTabClosing(TabClosingEventArgs e) { OnTabClosing(e); }