Ejemplo n.º 1
0
        /// <inheritdoc />
        protected override void OnDispose(bool dispose)
        {
            try {
                OnDispose();

                for (int i = -1; ++i != _wizardPages.Count;)
                {
                    IWizardPage page = _wizardPages[i];
                    page.Wizard = null;
                    page.Dispose();
                }

                _wizardPages.Clear();
                _pageToCompositeMap.Clear();

                if (_currentWizardPage != null)
                {
                    _currentWizardPage.PropertyChanged -= OnPagePropertyChanged;
                    _currentWizardPage = null;
                }

                _btnFinish = null;
                _btnNext   = null;
                _btnPrev   = null;

                _dialog.SetContent(null);
                _dialog = null;
            } catch {
                // Does not matter
            }
        }