Ejemplo n.º 1
0
 protected override void WizardProgress_EnteringStep(object sender, WizardProgressEventArgs e)
 {
     if (base.wizardProgress.CurrentStepTabPage == this.CredentialWizardPage)
     {
         this.CredentialWizardPage.OnPageShow(e);
     }
     else if (base.wizardProgress.CurrentStepTabPage == this.VMSelectionWizardPage)
     {
         this.VMSelectionWizardPage.OnPageShow(e);
         if (this.CredentialWizardPage.LabelError.Visible)
         {
             base.wizardProgress.PreviousStep();
         }
     }
     else if (base.wizardProgress.CurrentStepTabPage == this.SRSelectionWizardPage)
     {
         this.SRSelectionWizardPage.OnPageShow(e);
         if (this.CredentialWizardPage.LabelError.Visible)
         {
             base.wizardProgress.PreviousStep();
         }
     }
     else if (base.wizardProgress.CurrentStepTabPage == this.SummaryWizardPage)
     {
         this.SummaryWizardPage.OnPageShow(e);
     }
     base.xenTabControlBody.SelectedTab = base.wizardProgress.CurrentStepTabPage;
     base.labelWizard.Text = base.xenTabControlBody.SelectedTab.AccessibleDescription;
     base.FocusFirstControl(base.wizardProgress.CurrentStepTabPage.Controls);
     this.UpdateButtons();
 }
Ejemplo n.º 2
0
        private void OnEnteringStep(bool isForwardsTransition)
        {
            WizardProgressEventArgs e = new WizardProgressEventArgs(isForwardsTransition);

            if (this.EnteringStep != null)
            {
                this.EnteringStep(this, e);
            }
        }
Ejemplo n.º 3
0
        private bool OnLeavingStep(bool isForwardsTransition)
        {
            WizardProgressEventArgs e = new WizardProgressEventArgs(isForwardsTransition);

            if (this.LeavingStep != null)
            {
                this.LeavingStep(this, e);
            }
            return(e.Cancelled);
        }
Ejemplo n.º 4
0
 public void OnPageShow(WizardProgressEventArgs e)
 {
     this._updateWizardButtons();
 }
Ejemplo n.º 5
0
 public void OnPageExit(WizardProgressEventArgs e)
 {
 }
Ejemplo n.º 6
0
 protected override void WizardProgress_LeavingStep(object sender, WizardProgressEventArgs e)
 {
     try
     {
         if (base.wizardProgress.CurrentStepTabPage == this.CredentialWizardPage)
         {
             this.CredentialWizardPage.HideAllStatusErrorFields();
             this.Refresh();
             this._userName                      = this.CredentialWizardPage.Username;
             this._password                      = this.CredentialWizardPage.Password;
             this._hostname                      = this.CredentialWizardPage.Hostname;
             this._vmwareCredInfo                = new ServerInfo();
             this._vmwareCredInfo.ServerType     = 2;
             this._vmwareCredInfo.Hostname       = this._hostname;
             this._vmwareCredInfo.Username       = this._userName;
             this._vmwareCredInfo.Password       = this._password;
             this.VMSelectionWizardPage.Username = this._userName;
             this.VMSelectionWizardPage.Password = this._password;
             this.VMSelectionWizardPage.Hostname = this._hostname;
             this.CredentialWizardPage.SaveToSettings();
             this.VMSelectionWizardPage.AvailableVirtualMachines     = this.CredentialWizardPage.AvailableVirtualMachines;
             this.SRSelectionWizardPage.DefaultStorageRepository     = this.CredentialWizardPage.DefaultStorageRepository;
             this.SRSelectionWizardPage.AvailableStorageRepositories = this.CredentialWizardPage.AvailableStorageRepositories;
             this.SRSelectionWizardPage.OtherUsedDiskSpaceDict       = this.CredentialWizardPage.OtherUsedDiskSpaceDict;
             this.NetworkOptionsWizardPage.VMwareNetworks            = this.CredentialWizardPage.VMwareNetworks;
             this.NetworkOptionsWizardPage.XenServerNetworks         = this.CredentialWizardPage.XenServerNetworks;
             this.NetworkOptionsWizardPage.DefaultXenServerNetwork   = this.CredentialWizardPage.DefaultXenServerNetwork;
         }
         else if (base.wizardProgress.CurrentStepTabPage == this.SRSelectionWizardPage)
         {
             this.VMSelectionWizardPage.SelectedSR         = this.SRSelectionWizardPage.SelectedSR;
             this.VMSelectionWizardPage.OtherUsedDiskSpace = this.SRSelectionWizardPage.OtherUsedDiskSpace;
             if (this.VMSelectionWizardPage.SelectedSR != null)
             {
                 this.VMSelectionWizardPage.UpdatePieChart();
             }
         }
         else if (base.wizardProgress.CurrentStepTabPage == this.VMSelectionWizardPage)
         {
             this.VMSelectionWizardPage.OnPageExit(e);
         }
         else if (base.wizardProgress.CurrentStepTabPage == this.NetworkOptionsWizardPage)
         {
             this.SummaryWizardPage.VMwareHostname             = this.CredentialWizardPage.Hostname;
             this.SummaryWizardPage.XenServerHostname          = Program.ClientConnection.HostInfo.Hostname;
             this.SummaryWizardPage.SelectedSR                 = this.SRSelectionWizardPage.SelectedSR;
             this.SummaryWizardPage.SelectedVMsToConvert       = this.VMSelectionWizardPage.SelectedVMsToConvert;
             this.SummaryWizardPage.FreeSpaceDisplayString     = this.VMSelectionWizardPage.FreeSpaceDisplayString;
             this.SummaryWizardPage.UsedSpaceDisplayString     = this.VMSelectionWizardPage.UsedSpaceDisplayString;
             this.SummaryWizardPage.SelectedSpaceDisplayString = this.VMSelectionWizardPage.SelectedSpaceDisplayString;
             this.SummaryWizardPage.PreserveMAC                = this.NetworkOptionsWizardPage.PreserveMAC;
             this.SummaryWizardPage.NetworkMappings            = this.NetworkOptionsWizardPage.NetworkMappings;
             this.SummaryWizardPage.Build();
         }
     }
     catch
     {
     }
     finally
     {
         this.Cursor = Cursors.Default;
     }
 }
Ejemplo n.º 7
0
 protected virtual void WizardProgress_LeavingStep(object sender, WizardProgressEventArgs e)
 {
     this.wizardProgress.CurrentStepTabPage.PageLeave(e.IsForwardsTransition ? PageLoadedDirection.Forward : PageLoadedDirection.Back, ref e.Cancelled);
     this.UpdateWizard();
 }
Ejemplo n.º 8
0
 protected virtual void WizardProgress_EnteringStep(object sender, WizardProgressEventArgs e)
 {
     this.xenTabControlBody.SelectedTab = this.wizardProgress.CurrentStepTabPage;
     this.wizardProgress.CurrentStepTabPage.PageLoaded(e.IsForwardsTransition ? PageLoadedDirection.Forward : PageLoadedDirection.Back);
     this.UpdateWizard();
 }