public void TransitPane(ViewPane newPane) { if (CurrentViewPane != newPane && CurrentViewPane != null) { CurrentViewPane.OnClose(); } CurrentViewPane = newPane; ViewPaneChanged(newPane); }
void OnViewPaneChanged(ViewPane newPane) { if (m_ToolbarExtension.IndexOf(m_ToolbarExtensionPane) != -1) { m_ToolbarExtension.Remove(m_ToolbarExtensionPane); } if (newPane == this) { m_ToolbarExtension.Add(m_ToolbarExtensionPane); } }