Пример #1
0
        private void AddTemplatedWizardStep(WizardStepBase wizardStep)
        {
            TemplatedWizardStep item = wizardStep as TemplatedWizardStep;

            if (item != null)
            {
                this._wizard.TemplatedSteps.Add(item);
                this._wizard.RegisterCustomNavigationContainers(item);
            }
        }
Пример #2
0
        public void RemoveAt(int index)
        {
            WizardStepBase base2 = this.Views[index] as WizardStepBase;

            if (base2 != null)
            {
                base2.Owner = null;
                TemplatedWizardStep item = base2 as TemplatedWizardStep;
                if (item != null)
                {
                    this._wizard.TemplatedSteps.Remove(item);
                }
            }
            this.Views.RemoveAt(index);
            this.NotifyWizardStepsChanged();
        }
Пример #3
0
        public void Remove(WizardStepBase wizardStep)
        {
            if (wizardStep == null)
            {
                throw new ArgumentNullException("wizardStep");
            }
            this.Views.Remove(wizardStep);
            wizardStep.Owner = null;
            TemplatedWizardStep item = wizardStep as TemplatedWizardStep;

            if (item != null)
            {
                this._wizard.TemplatedSteps.Remove(item);
            }
            this.NotifyWizardStepsChanged();
        }
		internal override void InstantiateTemplateStep (TemplatedWizardStep step)
		{
			if (step is CreateUserWizardStep) {
				InstantiateCreateUserWizardStep ((CreateUserWizardStep) step);
			}
			else if (step is CompleteWizardStep) {
				InstantiateCompleteWizardStep ((CompleteWizardStep) step);
			}
			else {
				base.InstantiateTemplateStep (step);
			}
		}
Пример #5
0
        internal void InstantiateStepContentTemplate(TemplatedWizardStep step) {
            step.Controls.Clear();

            BaseContentTemplateContainer container = new BaseContentTemplateContainer(this, true);
            ITemplate contentTemplate = step.ContentTemplate;

            if (contentTemplate != null) {
                container.SetEnableTheming();
                contentTemplate.InstantiateIn(container.InnerCell);
            }

            step.ContentTemplateContainer = container;
            step.Controls.Add(container);
        }
Пример #6
0
        internal void RegisterCustomNavigationContainers(TemplatedWizardStep step) {
            // Instantiate the step's ContentTemplate
            InstantiateStepContentTemplate(step);

            if (!CustomNavigationContainers.ContainsKey(step)) {
                BaseNavigationTemplateContainer container = null;
                string id = GetCustomContainerID(WizardSteps.IndexOf(step));
                if (step.CustomNavigationTemplate != null) {
                    container = CreateBaseNavigationTemplateContainer(id);
                    step.CustomNavigationTemplate.InstantiateIn(container);
                    step.CustomNavigationTemplateContainer = container;
                    container.RegisterButtonCommandEvents();
                } else {
                    container = CreateBaseNavigationTemplateContainer(id);
                    container.RegisterButtonCommandEvents();
                }
                CustomNavigationContainers[step] = container;
            }
        }
Пример #7
0
		internal void RegisterCustomNavigation (TemplatedWizardStep step, BaseWizardNavigationContainer customNavigationTemplateContainer)
		{
			if (customNavigation == null)
				customNavigation = new Hashtable ();
			customNavigation [step] = customNavigationTemplateContainer;
		}
Пример #8
0
		internal virtual void InstantiateTemplateStep(TemplatedWizardStep step)
		{
			BaseWizardContainer contentTemplateContainer = new BaseWizardContainer ();

			if (step.ContentTemplate != null)
				step.ContentTemplate.InstantiateIn (contentTemplateContainer.InnerCell);

			step.ContentTemplateContainer = contentTemplateContainer;
			step.Controls.Clear ();
			step.Controls.Add (contentTemplateContainer);

			BaseWizardNavigationContainer customNavigationTemplateContainer = new BaseWizardNavigationContainer ();

			if (step.CustomNavigationTemplate != null) {
				step.CustomNavigationTemplate.InstantiateIn (customNavigationTemplateContainer);
				RegisterCustomNavigation (step, customNavigationTemplateContainer);
			}
			step.CustomNavigationTemplateContainer = customNavigationTemplateContainer;
		}
 private Table GetStyleTableForCustomizedStep(CreateUserWizard createUserWizard, TemplatedWizardStep step)
 {
     if (createUserWizard.LayoutTemplate == null)
     {
         return (Table) ((Table) step.Controls[0].Controls[0]).Rows[0].Cells[0].Controls[0];
     }
     return (Table) step.Controls[0].Controls[0];
 }