Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / WinForms / Managed / System / WinForms / FlowLayoutPanel.cs / 1305376 / 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.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ReliabilityContractAttribute.cs
- ConnectionConsumerAttribute.cs
- SafeFileMapViewHandle.cs
- WaitHandleCannotBeOpenedException.cs
- Repeater.cs
- DeviceFiltersSection.cs
- MappingSource.cs
- XmlFileEditor.cs
- MemberHolder.cs
- ValueQuery.cs
- Matrix.cs
- UpdatableGenericsFeature.cs
- ModulesEntry.cs
- DataFormat.cs
- ETagAttribute.cs
- InplaceBitmapMetadataWriter.cs
- BinaryReader.cs
- SelectingProviderEventArgs.cs
- MeshGeometry3D.cs
- InvalidBodyAccessException.cs
- ColumnCollectionEditor.cs
- TextTreeTextNode.cs
- StopStoryboard.cs
- LinqDataSourceDisposeEventArgs.cs
- AutomationIdentifier.cs
- ColorTransformHelper.cs
- DocumentViewerBaseAutomationPeer.cs
- RelationshipConverter.cs
- RoleGroupCollection.cs
- SmtpException.cs
- HttpConfigurationContext.cs
- ProxyWebPart.cs
- Rotation3D.cs
- ObjectView.cs
- ListDictionaryInternal.cs
- TextTreeTextNode.cs
- DataGridViewColumnStateChangedEventArgs.cs
- CodeObject.cs
- ELinqQueryState.cs
- XmlArrayItemAttribute.cs
- Soap.cs
- DataGridViewDataConnection.cs
- NameSpaceExtractor.cs
- DriveInfo.cs
- BamlRecordWriter.cs
- ArraySubsetEnumerator.cs
- AsnEncodedData.cs
- _NtlmClient.cs
- DnsPermission.cs
- DataKey.cs
- SoapHeaderAttribute.cs
- ServiceNameElement.cs
- Event.cs
- HtmlInputText.cs
- PeerNearMe.cs
- ByteStorage.cs
- TextFormatterContext.cs
- SchemaNotation.cs
- MetadataSerializer.cs
- WbmpConverter.cs
- GroupStyle.cs
- FacetDescription.cs
- NameScope.cs
- StrongNameUtility.cs
- ColorContextHelper.cs
- DbgUtil.cs
- TypeExtensionConverter.cs
- Cursor.cs
- InstanceDataCollectionCollection.cs
- PropertyConverter.cs
- TemplateBindingExtensionConverter.cs
- HtmlFormAdapter.cs
- UrlPath.cs
- TextBlockAutomationPeer.cs
- Vector3DKeyFrameCollection.cs
- TransformerInfo.cs
- ChangeProcessor.cs
- XPathNavigatorReader.cs
- DbProviderConfigurationHandler.cs
- BaseHashHelper.cs
- HtmlLinkAdapter.cs
- SamlAuthorizationDecisionStatement.cs
- ProgressPage.cs
- Padding.cs
- PrintDialog.cs
- FtpCachePolicyElement.cs
- Compilation.cs
- MediaScriptCommandRoutedEventArgs.cs
- PropertyPushdownHelper.cs
- SymmetricAlgorithm.cs
- EventDescriptor.cs
- MimeParameter.cs
- LifetimeServices.cs
- InstanceKeyCompleteException.cs
- ValidatingPropertiesEventArgs.cs
- CompilationUtil.cs
- DocumentXPathNavigator.cs
- Win32.cs
- EmptyControlCollection.cs
- PrinterUnitConvert.cs