当前位置: 首页>>代码示例>>C#>>正文


C# PageLoadedDirection类代码示例

本文整理汇总了C#中PageLoadedDirection的典型用法代码示例。如果您正苦于以下问题:C# PageLoadedDirection类的具体用法?C# PageLoadedDirection怎么用?C# PageLoadedDirection使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


PageLoadedDirection类属于命名空间,在下文中一共展示了PageLoadedDirection类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: PageLoaded

        public override void PageLoaded(PageLoadedDirection direction)
        {
            base.PageLoaded(direction);
            VM template = SelectedTemplate;
            bool installMethodIsNetwork = SelectedInstallMethod == InstallMethod.Network;

            if (template == Template && InstallMethodIsNetwork == installMethodIsNetwork)
                return;

            Template = template;

            InstallMethodIsNetwork = installMethodIsNetwork;
            if ((!Template.DefaultTemplate && !Template.HasAtLeastOneDisk)
                || (Template.IsHVM && InstallMethodIsNetwork)) // CA-46213 The default should be "diskless" if the install method is "boot from network"
            {
                DisklessVMRadioButton.Checked = true;
            }
            else
                DisksRadioButton.Checked = true;
            DisksGridView.Rows.Clear();
            LoadDisks();
            UpdateEnablement();
            UpdateCloneCheckboxEnablement(true);
            DisksGridView.Select();
        }
开发者ID:agimofcarmen,项目名称:xenadmin,代码行数:25,代码来源:Page_Storage.cs

示例2: PageLoaded

		public override void PageLoaded(PageLoadedDirection direction)
		{
			base.PageLoaded(direction);
			SetAddButtonEnabledState();
			SetRemoveButtonEnabledState();
			SetViewButtonEnabledState();
		}
开发者ID:huizh,项目名称:xenadmin,代码行数:7,代码来源:ExportEulaPage.cs

示例3: PageLoaded

        public override void PageLoaded(PageLoadedDirection direction)
        {
            base.PageLoaded(direction);
            int alwaysRestartHighPriority = 0, alwaysRestart = 0, bestEffort = 0, doNotRestart = 0;
            foreach (VM.HA_Restart_Priority priority in RestartPriorities)
            {
                switch (priority)
                {
                    case VM.HA_Restart_Priority.AlwaysRestartHighPriority:
                        alwaysRestartHighPriority++;
                        break;
                    case VM.HA_Restart_Priority.AlwaysRestart:
                    case VM.HA_Restart_Priority.Restart:
                        alwaysRestart++;
                        break;
                    case VM.HA_Restart_Priority.BestEffort:
                        bestEffort++;
                        break;
                    case VM.HA_Restart_Priority.DoNotRestart:
                        doNotRestart++;
                        break;
                }
            }
            labelSummary.Text = String.Format(Messages.HAWIZ_SUMMARY_NEW,
                                                HeartbeatSrName.Ellipsise(50),
                                                Ntol,
                                                GetVmNumber(alwaysRestart),
                                                GetVmNumber(bestEffort),
                                                GetVmNumber(doNotRestart));

            // If the user hasn't protected any VMs, show a warning.
            labelNoVmsProtected.Visible = (bestEffort + alwaysRestart + alwaysRestartHighPriority == 0) && doNotRestart > 0;
            labelNoHaGuaranteed.Visible = Ntol == 0;
            pictureBox1.Visible = labelNoVmsProtected.Visible || labelNoHaGuaranteed.Visible;
        }
开发者ID:robhoes,项目名称:xenadmin,代码行数:35,代码来源:HAFinishPage.cs

示例4: PageLoaded

        public override void PageLoaded(PageLoadedDirection direction)
        {
            base.PageLoaded(direction);

            VM template = SelectedTemplate;
            
            if (!template.Equals(_template))
            {
                _template = template;
                ServersGridView.Rows.Clear();

                if (Helpers.MidnightRideOrGreater(Connection) && template.DefaultTemplate)
                {
                    List<Host> hosts = new List<Host>(Connection.Cache.Hosts);
                    hosts.Sort();
                    foreach (Host host in hosts)
                    {
                        ServerGridRow row = new ServerGridRow(host, false);
                        ServersGridView.Rows.Add(row);

                        if (host == _affinity)
                        {
                            row.Selected = true;
                        }
                    }
                }
                ServersGridView.Enabled = template.DefaultTemplate;
            }
        }
开发者ID:agimofcarmen,项目名称:xenadmin,代码行数:29,代码来源:Page_CopyBiosStrings.cs

示例5: PageLoaded

        public override void PageLoaded(PageLoadedDirection direction)
        {
            base.PageLoaded(direction);

            if (direction == PageLoadedDirection.Forward)
                RunAction(CapabilityList, SelectedHosts);
        }
开发者ID:huizh,项目名称:xenadmin,代码行数:7,代码来源:BugToolPageRetrieveData.cs

示例6: PageLeave

        public override void PageLeave(PageLoadedDirection direction, ref bool cancel)
        {
            if (direction == PageLoadedDirection.Forward)
            {
                if (!AllSelectedHostsConnected())
                {
                    dataGridView1.Invalidate();
                    cancel = true;
                    return;
                }

                foreach (var selectedMaster in SelectedMasters)
                {
                    if (!(selectedMaster.Connection.Session.IsLocalSuperuser || selectedMaster.Connection.Session.Roles.Any(role => role.name_label == Role.MR_ROLE_POOL_ADMIN)))
                    {
                        new ThreeButtonDialog(
                            new ThreeButtonDialog.Details(SystemIcons.Warning, string.Format(Messages.RBAC_UPGRADE_WIZARD_MESSAGE, selectedMaster.Connection.Username,
                                selectedMaster.Name), Messages.ROLLING_POOL_UPGRADE)).ShowDialog(this);
                        DeselectMaster(selectedMaster);
                        cancel = true;
                        return;
                    }
                }
            }
            base.PageLeave(direction, ref cancel);
        }
开发者ID:agimofcarmen,项目名称:xenadmin,代码行数:26,代码来源:RollingUpgradeWizardSelectPool.cs

示例7: PageLoaded

        public override void PageLoaded(PageLoadedDirection direction)
        {
            base.PageLoaded(direction);
            
            canUpload = true;
            canDownload = true;
            UpdateButtons();

            if (SelectedUpdateType == UpdateType.Existing)
                _patch = SelectedExistingPatch;

            if (direction == PageLoadedDirection.Forward)           
            {
                flickerFreeListBox1.Items.Clear();
                var selectedPatch = SelectedUpdateAlert != null ? ((XenServerPatchAlert)SelectedUpdateAlert).Patch : null;
                if (selectedPatch != null && String.IsNullOrEmpty(SelectedNewPatchPath) &&
                    (!AllDownloadedPatches.Any(kvp => kvp.Key == selectedPatch.Uuid)
                        || String.IsNullOrEmpty(AllDownloadedPatches[selectedPatch.Uuid]) 
                        || !File.Exists(AllDownloadedPatches[selectedPatch.Uuid])))
                {
                    DownloadFile();
                    label2.Text = Messages.PATCHINGWIZARD_UPLOADPAGE_MESSAGE_DOWNLOAD_AND_UPLOAD;
                    pageTitle = Messages.PATCHINGWIZARD_UPLOADPAGE_TITLE_DOWNLOAD_AND_UPLOAD; 
                }
                else
                {
                    label2.Text = Messages.PATCHINGWIZARD_UPLOADPAGE_MESSAGE_ONLY_UPLOAD;
                    pageTitle = Messages.PATCHINGWIZARD_UPLOADPAGE_TITLE_ONLY_UPLOAD; 
                    if (selectedPatch != null && AllDownloadedPatches.ContainsKey(selectedPatch.Uuid))
                        SelectedNewPatchPath = AllDownloadedPatches[selectedPatch.Uuid];
                    PrepareUploadActions();
                    TryUploading();
                }
            }
        }
开发者ID:robhoes,项目名称:xenadmin,代码行数:35,代码来源:PatchingWizard_UploadPage.cs

示例8: PageLoaded

 public override void PageLoaded(PageLoadedDirection direction)
 {
     base.PageLoaded(direction);
     
     if (direction == PageLoadedDirection.Forward)
         SetupLabels();
 }
开发者ID:huizh,项目名称:xenadmin,代码行数:7,代码来源:DRFailoverWizardFirstPage.cs

示例9: PageLoaded

        public override void PageLoaded(PageLoadedDirection direction)
        {
            base.PageLoaded(direction);

            textBoxLog.Clear();

            switch (SelectedUpdateType)
            {
                case UpdateType.NewRetail:
                case UpdateType.Existing:
                    textBoxLog.Text = PatchingWizardModeGuidanceBuilder.ModeRetailPatch(SelectedServers, Patch);
                    AutomaticRadioButton.Enabled = true;
                    AutomaticRadioButton.Checked = true;
                    break;
                case UpdateType.NewSuppPack:
                    AutomaticRadioButton.Enabled = true;
                    AutomaticRadioButton.Checked = true;
                    textBoxLog.Text = PatchingWizardModeGuidanceBuilder.ModeSuppPack(SelectedServers);
                    break;
            }

            if (SelectedUpdateType == UpdateType.NewSuppPack || SelectedServers.Exists(server => !Helpers.ClearwaterOrGreater(server)))
            {
                removeUpdateFileCheckBox.Checked = false;
                removeUpdateFileCheckBox.Visible = false;
            }
        }
开发者ID:robhoes,项目名称:xenadmin,代码行数:27,代码来源:PatchingWizard_ModePage.cs

示例10: PageLeave

 public override void PageLeave(PageLoadedDirection direction, ref bool cancel)
 {
     if (direction == PageLoadedDirection.Forward)
         cancel = !Scan();
     
     base.PageLeave(direction, ref cancel);
 }
开发者ID:huizh,项目名称:xenadmin,代码行数:7,代码来源:FilerDetails.cs

示例11: PageLoaded

        public override void PageLoaded(PageLoadedDirection direction)
        {
            base.PageLoaded(direction);

            // if not using CD, use selected template storage host
            // if using CD use CD or template storage host);
           
           if (SelectedInstallMethod != InstallMethod.CD || SelectedCD == null)
            {
                if (SelectedTemplate == Template && CdAffinity == null)
                    return;

                CdAffinity = null;
                Template = SelectedTemplate;
                affinityPicker1.SetAffinity(Connection, Affinity, Template.GetStorageHost(true));
            }
            else
            {
                SR sr = Connection.Resolve(SelectedCD.SR);
                if (sr == null)
                    return;

                Host cdAffinity = sr.GetStorageHost();

                if (SelectedTemplate == Template && cdAffinity == CdAffinity)
                    return;

                Template = SelectedTemplate;
                CdAffinity = cdAffinity;

                affinityPicker1.SetAffinity(Connection, Affinity,
                                           CdAffinity ?? Template.GetStorageHost(false));
            }
            affinityPicker1.Select();
        }
开发者ID:huizh,项目名称:xenadmin,代码行数:35,代码来源:Page_HomeServer.cs

示例12: PageLoaded

 public override void PageLoaded(PageLoadedDirection direction)
 {
     if (direction == PageLoadedDirection.Back)
     {
         RefreshRechecks();
         return;
     }
     var selectedMasters = new List<Host>(SelectedMasters);
     ManualUpgrade = ManualModeSelected;
     RemoveEventHandlersToMasters();
     SelectedServers.Clear();
     foreach (Host selectedMaster in selectedMasters)
     {
         Host master = selectedMaster;
         if (master != null)
         {
             Pool pool = Helpers.GetPoolOfOne(master.Connection);
             if (pool != null)
                 SelectedServers.AddRange(pool.HostsToUpgrade);
             else
                 SelectedServers.Add(master);
         }
     }
     AddEventHandlersToMasters();
     labelPrechecksFirstLine.Text = Messages.ROLLINGUPGRADE_PRECHECKS;
     RefreshRechecks();
     return;
 }
开发者ID:huizh,项目名称:xenadmin,代码行数:28,代码来源:RollingUpgradeWizardPrecheckPage.cs

示例13: PageLoaded

		public override void PageLoaded(PageLoadedDirection direction)
		{
			base.PageLoaded(direction);//call first so the page gets populated

			if (direction == PageLoadedDirection.Forward)
				SetButtonNextEnabled(OkToProceed());
		}
开发者ID:huizh,项目名称:xenadmin,代码行数:7,代码来源:ImportSecurityPage.cs

示例14: PageLeave

        public override void PageLeave(PageLoadedDirection direction, ref bool cancel)
        {
            if (direction == PageLoadedDirection.Forward)
                CheckUniqueName(txtName.Text);

            base.PageLeave(direction, ref cancel);
        }
开发者ID:huizh,项目名称:xenadmin,代码行数:7,代码来源:NetWName.cs

示例15: PageLoaded

        public override void PageLoaded(PageLoadedDirection direction)
        {
            base.PageLoaded(direction);

            if (direction == PageLoadedDirection.Forward)
                HelpersGUI.FocusFirstControl(Controls);
        }
开发者ID:robhoes,项目名称:xenadmin,代码行数:7,代码来源:NewSrWizardNamePage.cs


注:本文中的PageLoadedDirection类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。