Ejemplo n.º 1
0
        public new void ShowPage(IWizardPage page)
        {
            int requiredHeight = page.CreatePageControl().Height + m_ExcessWizardHeight;

            base.ShowPage(page);

            if (requiredHeight > m_BaseWizardHeight)
            {
                // Realign the center
                this.Top += (this.Height - requiredHeight) / 2;

                this.Height = requiredHeight;
            }
            else if(this.Height != m_BaseWizardHeight)
            {
                // Realign the center
                this.Top += (this.Height - m_BaseWizardHeight) / 2;

                // Set back to our default value
                this.Height = m_BaseWizardHeight;
            }

            this.Invalidate();
        }