Specifically, want to run this code for all DockManagers:
The thing is, I've got around 50 screens in my program and these dock managers are thrown on most of them, and I don't want to have to go around adding this line of code to each of them and then remember to do it every time I add a new one.
Is there some sort of Global OnDockManagerCreated event I can hook onto somewhere?
Thanks.
private void ultraDockManager1_BeforePaneButtonClick(object sender, CancelablePaneButtonEventArgs e) { if(e.Button == PaneButton.Close) { DockableControlPane p = e.Pane as DockableControlPane; if(p != null) { e.Pane.Dock(true); e.Pane.Unpin(); ultraDockManager1.FlyIn(false); e.Cancel = true; } } }
HELP ME!!!
Come on! Nobodies got anything?