Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / DataWebControlsDesign / System / Data / WebControls / Design / Util / WizardPanel.cs / 1305376 / WizardPanel.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // // // @owner [....] // @backupOwner [....] //----------------------------------------------------------------------------- using System; using System.Collections; using System.ComponentModel; using System.ComponentModel.Design; using System.Diagnostics; using System.Drawing; using System.Windows.Forms; namespace System.Web.UI.Design.WebControls.Util { ////// Represents a single step in a wizard. /// WizardPanels are contained within a single WizardForm. /// internal class WizardPanel : System.Windows.Forms.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); } } } ////// 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. // // // @owner [....] // @backupOwner [....] //----------------------------------------------------------------------------- using System; using System.Collections; using System.ComponentModel; using System.ComponentModel.Design; using System.Diagnostics; using System.Drawing; using System.Windows.Forms; namespace System.Web.UI.Design.WebControls.Util { ////// Represents a single step in a wizard. /// WizardPanels are contained within a single WizardForm. /// internal class WizardPanel : System.Windows.Forms.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); } } } ////// 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.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- NativeMethods.cs
- EntityDataSourceEntitySetNameItem.cs
- TextElement.cs
- TreeIterators.cs
- JapaneseLunisolarCalendar.cs
- FormView.cs
- RegistrationServices.cs
- ComplexBindingPropertiesAttribute.cs
- HtmlInputFile.cs
- CodeSnippetCompileUnit.cs
- BehaviorService.cs
- Descriptor.cs
- CompoundFileStorageReference.cs
- RemoteWebConfigurationHostServer.cs
- ServiceMetadataBehavior.cs
- Pipe.cs
- InkCanvasSelectionAdorner.cs
- BitmapEncoder.cs
- StorageModelBuildProvider.cs
- METAHEADER.cs
- AttributeData.cs
- MouseGestureValueSerializer.cs
- Encoder.cs
- CharacterMetrics.cs
- XmlRawWriter.cs
- WebPartMenu.cs
- TextTreeTextNode.cs
- XmlArrayItemAttribute.cs
- BamlRecords.cs
- OutputWindow.cs
- UInt64Converter.cs
- StrongNamePublicKeyBlob.cs
- SplayTreeNode.cs
- DataKeyCollection.cs
- XPathArrayIterator.cs
- MatrixAnimationUsingPath.cs
- PageMediaSize.cs
- MimeMapping.cs
- AggregateNode.cs
- DataGridViewBand.cs
- ExitEventArgs.cs
- SmiRecordBuffer.cs
- PropertyPathWorker.cs
- WindowsMenu.cs
- RangeValidator.cs
- DataRelation.cs
- EasingFunctionBase.cs
- PropertySegmentSerializationProvider.cs
- TagPrefixAttribute.cs
- ResolveDuplex11AsyncResult.cs
- BufferedStream.cs
- LiteralControl.cs
- WebDisplayNameAttribute.cs
- Ray3DHitTestResult.cs
- SqlConnectionString.cs
- SpanIndex.cs
- NativeStructs.cs
- TabItemWrapperAutomationPeer.cs
- UnsafeNativeMethodsCLR.cs
- ToolStripProfessionalLowResolutionRenderer.cs
- RuntimeConfigurationRecord.cs
- ReachVisualSerializer.cs
- CompensationToken.cs
- QueryResultOp.cs
- remotingproxy.cs
- NotFiniteNumberException.cs
- SimpleHandlerFactory.cs
- DigitShape.cs
- StrokeFIndices.cs
- AdornerLayer.cs
- sitestring.cs
- ParseChildrenAsPropertiesAttribute.cs
- FixedStringLookup.cs
- Triangle.cs
- UmAlQuraCalendar.cs
- GatewayIPAddressInformationCollection.cs
- CompilationSection.cs
- AddressAccessDeniedException.cs
- Repeater.cs
- RijndaelManaged.cs
- MenuItemBindingCollection.cs
- QueryableDataSourceHelper.cs
- HtmlFormAdapter.cs
- PreProcessor.cs
- EditorZone.cs
- Path.cs
- HttpModule.cs
- CodeComment.cs
- InternalBase.cs
- Utils.cs
- Popup.cs
- ToolStripDropDownClosedEventArgs.cs
- BitArray.cs
- VersionedStreamOwner.cs
- BaseParser.cs
- FormViewUpdateEventArgs.cs
- UmAlQuraCalendar.cs
- WebPartEditorCancelVerb.cs
- DateTimeConstantAttribute.cs
- HandlerFactoryWrapper.cs