Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / ndp / fx / src / DataWebControlsDesign / System / Data / WebControls / Design / Util / WizardPanel.cs / 1 / 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
- TextSpan.cs
- FocusWithinProperty.cs
- ControlParameter.cs
- SqlErrorCollection.cs
- PageCache.cs
- CompilerTypeWithParams.cs
- CalendarBlackoutDatesCollection.cs
- InvalidProgramException.cs
- WebBrowserPermission.cs
- ListViewGroup.cs
- Path.cs
- IssuedTokenServiceCredential.cs
- WebPartDescription.cs
- GeometryDrawing.cs
- StaticContext.cs
- EncodingInfo.cs
- XMLDiffLoader.cs
- Grid.cs
- Vector3DAnimationUsingKeyFrames.cs
- TextTreeUndo.cs
- HttpResponseInternalBase.cs
- ITextView.cs
- StreamWriter.cs
- OrderPreservingMergeHelper.cs
- RuntimeHelpers.cs
- RuleCache.cs
- util.cs
- ControlFilterExpression.cs
- ProfileSection.cs
- TransformPattern.cs
- TextTreeTextBlock.cs
- LeftCellWrapper.cs
- OrderingQueryOperator.cs
- DataGridHeaderBorder.cs
- ConfigXmlWhitespace.cs
- JpegBitmapDecoder.cs
- CodeAccessSecurityEngine.cs
- ComPersistableTypeElementCollection.cs
- ExtensionDataReader.cs
- ClassHandlersStore.cs
- WebPartEventArgs.cs
- HttpHandlerAction.cs
- ExpressionLexer.cs
- ThicknessAnimationBase.cs
- ExpressionEditorAttribute.cs
- DispatchWrapper.cs
- SHA512Managed.cs
- MarshalByRefObject.cs
- AuthenticatedStream.cs
- ContainerTracking.cs
- SizeConverter.cs
- CellParagraph.cs
- TextEndOfSegment.cs
- GridViewDeletedEventArgs.cs
- Image.cs
- WebPermission.cs
- RegexMatchCollection.cs
- Point4D.cs
- EventWaitHandle.cs
- HwndSourceKeyboardInputSite.cs
- PeerApplication.cs
- CompositeActivityCodeGenerator.cs
- CodeTypeDeclaration.cs
- Rect3DConverter.cs
- complextypematerializer.cs
- SafeMILHandleMemoryPressure.cs
- securestring.cs
- StructureChangedEventArgs.cs
- SqlFunctionAttribute.cs
- BufferedGraphicsManager.cs
- WebPartZoneBase.cs
- RealProxy.cs
- TextModifierScope.cs
- SystemEvents.cs
- NullExtension.cs
- RoutedEventConverter.cs
- AmbientLight.cs
- WindowPattern.cs
- MetadataArtifactLoaderFile.cs
- SoapHttpTransportImporter.cs
- Range.cs
- UrlMappingsModule.cs
- PriorityBindingExpression.cs
- Typography.cs
- ValidatedControlConverter.cs
- LogLogRecordEnumerator.cs
- COM2PropertyPageUITypeConverter.cs
- SqlBuilder.cs
- DataTableNewRowEvent.cs
- QuotedPrintableStream.cs
- LinkDescriptor.cs
- BulletedList.cs
- FormViewRow.cs
- PointKeyFrameCollection.cs
- ServiceHttpModule.cs
- SvcMapFile.cs
- StatusBarPanelClickEvent.cs
- FileEnumerator.cs
- PartEditor.cs
- SchemaNotation.cs