Пример #1
0
        protected override void Dispose(bool disposing)
        {
            if (disposing)
            {
                // IMPORTANT: avoid nested call into this method on Mono.
                // https://github.com/dockpanelsuite/dockpanelsuite/issues/16
                if (Win32Helper.IsRunningOnMono)
                {
                    if (m_isDisposing)
                    {
                        return;
                    }

                    m_isDisposing = true;
                }

                m_dockState = DockState.Unknown;

                if (NestedPanesContainer != null)
                {
                    NestedPanesContainer.NestedPanes.Remove(this);
                }

                if (DockPanel != null)
                {
                    DockPanel.RemovePane(this);
                    m_dockPanel = null;
                }

                Splitter.Dispose();
                if (m_autoHidePane != null)
                {
                    m_autoHidePane.Dispose();
                }
            }
            base.Dispose(disposing);
        }