Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / Designer / WebForms / System / Web / UI / Design / Util / WizardPanel.cs / 1 / WizardPanel.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI.Design.Util { using System; using System.Collections; using System.ComponentModel; using System.ComponentModel.Design; using System.Diagnostics; using System.Drawing; using System.Windows.Forms; ////// Represents a single step in a wizard. /// WizardPanels are contained within a single WizardForm. /// internal class WizardPanel : UserControl { private WizardForm _parentWizard; private string _caption; private WizardPanel _nextPanel; private bool _needsToInvalidate; ////// Creates a new WizardPanel. /// public WizardPanel() { } ////// The caption to be shown on the WizardForm /// public string Caption { get { if (_caption == null) { return String.Empty; } return _caption; } set { _caption = value; if (_parentWizard != null) { _parentWizard.Invalidate(); } else { _needsToInvalidate = true; } } } ////// The panel to go to when the Next button is clicked. This can be set dynamically in /// the OnNext() event to customize the order in which panels are used. /// public WizardPanel NextPanel { get { return _nextPanel; } set { _nextPanel = value; Debug.Assert(_parentWizard != null); if (_parentWizard != null) { _parentWizard.RegisterPanel(_nextPanel); } } } ////// A reference to the WizardForm parenting this panel /// [ Browsable(false), ] public WizardForm ParentWizard { get { return _parentWizard; } } ////// The service provider for the wizard. /// protected IServiceProvider ServiceProvider { get { return ParentWizard.ServiceProvider; } } ////// This method is called when the wizard's Finish button is clicked. /// It is called once for each wizard panel on the panel stack, in the order from the first panel to the last (current) panel. /// protected internal virtual void OnComplete() { } ////// Runs when the next button is clicked while this panel is showing. /// Returns true if the wizard should proceed to the next panel. /// public virtual bool OnNext() { return true; } ////// Runs when the previous button of the parent wizard form is clicked while this panel is active /// public virtual void OnPrevious() { } ////// internal void SetParentWizard(WizardForm parent) { _parentWizard = parent; if ((_parentWizard != null) && _needsToInvalidate) { _parentWizard.Invalidate(); _needsToInvalidate = false; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- DateTimeParse.cs
- IPipelineRuntime.cs
- ExpressionVisitor.cs
- Thread.cs
- EndpointInfoCollection.cs
- DesignerActionItemCollection.cs
- ComponentCodeDomSerializer.cs
- ScrollBarAutomationPeer.cs
- SurrogateEncoder.cs
- DebuggerService.cs
- SQLMoneyStorage.cs
- QueryBranchOp.cs
- SubpageParagraph.cs
- AdRotatorDesigner.cs
- StatusBarDrawItemEvent.cs
- AutomationInteropProvider.cs
- CheckoutException.cs
- ValidationErrorInfo.cs
- PointLightBase.cs
- ConfigXmlAttribute.cs
- EventWaitHandle.cs
- Utils.cs
- ColorConvertedBitmapExtension.cs
- XmlSchemaDocumentation.cs
- TreeNodeStyleCollection.cs
- XPathNavigator.cs
- HGlobalSafeHandle.cs
- Oid.cs
- ThemeInfoAttribute.cs
- SqlClientWrapperSmiStream.cs
- Int32Animation.cs
- XmlSerializerSection.cs
- HttpCacheVaryByContentEncodings.cs
- ApplyImportsAction.cs
- SystemGatewayIPAddressInformation.cs
- StrokeSerializer.cs
- ToolBar.cs
- WindowsFormsHelpers.cs
- PerformanceCountersElement.cs
- DecoderReplacementFallback.cs
- JavaScriptString.cs
- MimeTypePropertyAttribute.cs
- TriggerBase.cs
- NotifyParentPropertyAttribute.cs
- SharedConnectionListener.cs
- IndentedWriter.cs
- ResumeStoryboard.cs
- SelectionItemProviderWrapper.cs
- _Connection.cs
- CodeTypeDelegate.cs
- TextBoxAutomationPeer.cs
- QuaternionAnimationUsingKeyFrames.cs
- ToolStripPanelRenderEventArgs.cs
- Transform3DGroup.cs
- FormViewCommandEventArgs.cs
- ConstructorBuilder.cs
- Graphics.cs
- Events.cs
- OdbcParameterCollection.cs
- ReflectPropertyDescriptor.cs
- ArrayWithOffset.cs
- AdRotator.cs
- CustomValidator.cs
- WebDescriptionAttribute.cs
- StringPropertyBuilder.cs
- SqlComparer.cs
- SimpleType.cs
- SchemaTableColumn.cs
- ClientBuildManager.cs
- HtmlTable.cs
- GridErrorDlg.cs
- AnimationClock.cs
- AstNode.cs
- AxisAngleRotation3D.cs
- hresults.cs
- SafePEFileHandle.cs
- InputReportEventArgs.cs
- EdmItemCollection.OcAssemblyCache.cs
- SmtpClient.cs
- IntSecurity.cs
- RuleDefinitions.cs
- SymbolMethod.cs
- CategoriesDocument.cs
- SequentialOutput.cs
- ToolStripItem.cs
- HttpGetServerProtocol.cs
- SpanIndex.cs
- LicenseProviderAttribute.cs
- MDIWindowDialog.cs
- SafeFileMapViewHandle.cs
- SQLCharsStorage.cs
- Repeater.cs
- DispatcherProcessingDisabled.cs
- TreeNodeMouseHoverEvent.cs
- BeginGetFileNameFromUserRequest.cs
- NamespaceMapping.cs
- SqlBuffer.cs
- Privilege.cs
- ProfileProvider.cs
- GrammarBuilderRuleRef.cs