Code:
/ DotNET / DotNET / 8.0 / untmp / whidbey / REDBITS / ndp / fx / src / WinForms / Managed / System / WinForms / FlowLayoutPanel.cs / 1 / FlowLayoutPanel.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Windows.Forms { using System; using System.ComponentModel; using System.Diagnostics; using System.Drawing; using System.Windows.Forms.Layout; using System.Runtime.InteropServices; ///[ComVisible(true)] [ClassInterface(ClassInterfaceType.AutoDispatch)] [ProvideProperty("FlowBreak", typeof(Control))] [DefaultProperty("FlowDirection")] [Designer("System.Windows.Forms.Design.FlowLayoutPanelDesigner, " + AssemblyRef.SystemDesign)] [Docking(DockingBehavior.Ask)] [SRDescription(SR.DescriptionFlowLayoutPanel)] public class FlowLayoutPanel : Panel, IExtenderProvider { private FlowLayoutSettings _flowLayoutSettings; /// public FlowLayoutPanel() { _flowLayoutSettings = FlowLayout.CreateSettings(this); } /// public override LayoutEngine LayoutEngine { get { return FlowLayout.Instance; } } /// [SRDescription(SR.FlowPanelFlowDirectionDescr)] [DefaultValue(FlowDirection.LeftToRight)] [SRCategory(SR.CatLayout)] [Localizable(true)] public FlowDirection FlowDirection { get { return _flowLayoutSettings.FlowDirection; } set { _flowLayoutSettings.FlowDirection = value; Debug.Assert(FlowDirection == value, "FlowDirection should be the same as we set it"); } } /// [SRDescription(SR.FlowPanelWrapContentsDescr)] [DefaultValue(true)] [SRCategory(SR.CatLayout)] [Localizable(true)] public bool WrapContents { get { return _flowLayoutSettings.WrapContents; } set { _flowLayoutSettings.WrapContents = value; Debug.Assert(WrapContents == value, "WrapContents should be the same as we set it"); } } #region Provided properties /// /// bool IExtenderProvider.CanExtend(object obj) { Control control = obj as Control; return control != null && control.Parent == this; } [DefaultValue(false)] [DisplayName("FlowBreak")] public bool GetFlowBreak(Control control) { return _flowLayoutSettings.GetFlowBreak(control); } [DisplayName("FlowBreak")] public void SetFlowBreak(Control control, bool value) { _flowLayoutSettings.SetFlowBreak(control, value); } #endregion } } // 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
- DelegatedStream.cs
- SQLRoleProvider.cs
- LostFocusEventManager.cs
- FixedDSBuilder.cs
- ProfilePropertySettingsCollection.cs
- SafeLibraryHandle.cs
- WorkflowServiceAttributes.cs
- DbConnectionPoolCounters.cs
- ChtmlCommandAdapter.cs
- SplitterPanel.cs
- PriorityQueue.cs
- DecimalAnimationBase.cs
- ConfigurationLoaderException.cs
- PermissionSetEnumerator.cs
- UIElementParagraph.cs
- TranslateTransform.cs
- XmlSchemaObjectCollection.cs
- DataGridViewCellMouseEventArgs.cs
- MembershipUser.cs
- itemelement.cs
- GridEntryCollection.cs
- Serializer.cs
- WindowsToolbarItemAsMenuItem.cs
- SoapTransportImporter.cs
- NodeInfo.cs
- Pkcs7Recipient.cs
- ScrollItemPattern.cs
- ToolStripContextMenu.cs
- CodeArrayCreateExpression.cs
- TdsEnums.cs
- ContextStack.cs
- AuthenticationConfig.cs
- PerfProviderCollection.cs
- DataObjectEventArgs.cs
- WindowsPrincipal.cs
- TextServicesDisplayAttribute.cs
- CheckBoxFlatAdapter.cs
- Int64AnimationBase.cs
- Serializer.cs
- EnumMember.cs
- ConfigXmlWhitespace.cs
- HtmlElementErrorEventArgs.cs
- DurableInstanceManager.cs
- ISCIIEncoding.cs
- base64Transforms.cs
- FocusManager.cs
- UniqueEventHelper.cs
- AnnotationResource.cs
- MouseActionValueSerializer.cs
- ControlIdConverter.cs
- SafeNativeMethods.cs
- RepeatInfo.cs
- UiaCoreTypesApi.cs
- SurrogateSelector.cs
- MD5HashHelper.cs
- ISessionStateStore.cs
- PerspectiveCamera.cs
- WpfPayload.cs
- PageContentCollection.cs
- ElementsClipboardData.cs
- CaseStatementSlot.cs
- DesignTimeSiteMapProvider.cs
- SharedMemory.cs
- MetadataArtifactLoaderFile.cs
- BooleanExpr.cs
- TextBreakpoint.cs
- ValidatorCompatibilityHelper.cs
- TypeDelegator.cs
- DoubleLinkList.cs
- CursorConverter.cs
- ObjectSecurity.cs
- SvcMapFileLoader.cs
- DelegateCompletionCallbackWrapper.cs
- _Rfc2616CacheValidators.cs
- DayRenderEvent.cs
- Zone.cs
- RadioButtonBaseAdapter.cs
- CssStyleCollection.cs
- ExpressionDumper.cs
- RectAnimationUsingKeyFrames.cs
- RbTree.cs
- ServiceChannelProxy.cs
- VersionedStream.cs
- SimpleWorkerRequest.cs
- SiteMapPath.cs
- COM2IProvidePropertyBuilderHandler.cs
- Pair.cs
- ExternalFile.cs
- ActivationArguments.cs
- TemplateKeyConverter.cs
- KnownTypes.cs
- X500Name.cs
- MatchingStyle.cs
- WebEventTraceProvider.cs
- UnSafeCharBuffer.cs
- PeerNearMe.cs
- WebBrowserDesigner.cs
- ParenthesizePropertyNameAttribute.cs
- DeflateInput.cs
- HtmlGenericControl.cs