Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / WinForms / Managed / System / WinForms / DockingAttribute.cs / 1305376 / DockingAttribute.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.Windows.Forms {
///
///
///
/// Specifies how a control should be docked by default when added through the designer.
///
///
[AttributeUsage(AttributeTargets.Class)]
public sealed class DockingAttribute : Attribute {
private DockingBehavior dockingBehavior;
///
///
///
/// Default constructor.
///
///
public DockingAttribute() {
this.dockingBehavior = DockingBehavior.Never;
}
///
///
///
/// Constructor.
///
///
public DockingAttribute(DockingBehavior dockingBehavior) {
this.dockingBehavior = dockingBehavior;
}
///
///
///
/// Specifies the default value for the .
/// This field is read-only.
///
///
public static readonly DockingAttribute Default = new DockingAttribute();
///
///
///
/// DockingBehavior property.
///
///
public DockingBehavior DockingBehavior {
get {
return dockingBehavior;
}
}
///
///
///
///
public override bool Equals(object obj) {
if (obj == this) {
return true;
}
DockingAttribute other = obj as DockingAttribute;
return (other != null) && other.DockingBehavior == this.dockingBehavior;
}
///
///
/// [To be supplied.]
///
public override int GetHashCode() {
return dockingBehavior.GetHashCode();
}
///
///
///
///
public override bool IsDefaultAttribute() {
return (this.Equals(Default));
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
namespace System.Windows.Forms {
///
///
///
/// Specifies how a control should be docked by default when added through the designer.
///
///
[AttributeUsage(AttributeTargets.Class)]
public sealed class DockingAttribute : Attribute {
private DockingBehavior dockingBehavior;
///
///
///
/// Default constructor.
///
///
public DockingAttribute() {
this.dockingBehavior = DockingBehavior.Never;
}
///
///
///
/// Constructor.
///
///
public DockingAttribute(DockingBehavior dockingBehavior) {
this.dockingBehavior = dockingBehavior;
}
///
///
///
/// Specifies the default value for the .
/// This field is read-only.
///
///
public static readonly DockingAttribute Default = new DockingAttribute();
///
///
///
/// DockingBehavior property.
///
///
public DockingBehavior DockingBehavior {
get {
return dockingBehavior;
}
}
///
///
///
///
public override bool Equals(object obj) {
if (obj == this) {
return true;
}
DockingAttribute other = obj as DockingAttribute;
return (other != null) && other.DockingBehavior == this.dockingBehavior;
}
///
///
/// [To be supplied.]
///
public override int GetHashCode() {
return dockingBehavior.GetHashCode();
}
///
///
///
///
public override bool IsDefaultAttribute() {
return (this.Equals(Default));
}
}
}
// 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
- SectionVisual.cs
- XmlQualifiedName.cs
- LineProperties.cs
- KoreanCalendar.cs
- InputScopeManager.cs
- TextSegment.cs
- DbSource.cs
- AffineTransform3D.cs
- EventNotify.cs
- X509Utils.cs
- KnownTypesProvider.cs
- ByteStack.cs
- UpdatePanelTriggerCollection.cs
- StorageMappingItemLoader.cs
- ResourceDescriptionAttribute.cs
- StrongName.cs
- CellQuery.cs
- sqlcontext.cs
- CodeTypeDelegate.cs
- CryptoConfig.cs
- InstanceCollisionException.cs
- HashCodeCombiner.cs
- PathSegment.cs
- ScrollBar.cs
- Variable.cs
- XPathNodeHelper.cs
- HostingEnvironment.cs
- UTF8Encoding.cs
- SQLInt16Storage.cs
- ProfileSettings.cs
- XmlSchemaSimpleContentExtension.cs
- EdmSchemaError.cs
- ContractMapping.cs
- TCEAdapterGenerator.cs
- TextTabProperties.cs
- QuaternionRotation3D.cs
- Helper.cs
- MDIWindowDialog.cs
- GPPOINT.cs
- ProfessionalColors.cs
- SqlReorderer.cs
- SemaphoreSecurity.cs
- CommandManager.cs
- EmbeddedMailObjectCollectionEditor.cs
- DaylightTime.cs
- WhileDesigner.cs
- StorageModelBuildProvider.cs
- TypeLibConverter.cs
- BitmapInitialize.cs
- HtmlTableCell.cs
- TypedTableBase.cs
- ObjectViewListener.cs
- PropertyChangingEventArgs.cs
- ExceptionRoutedEventArgs.cs
- GrabHandleGlyph.cs
- TextPatternIdentifiers.cs
- CodePropertyReferenceExpression.cs
- PasswordRecoveryAutoFormat.cs
- IConvertible.cs
- TrustExchangeException.cs
- ButtonBaseAdapter.cs
- AggregateNode.cs
- SystemDiagnosticsSection.cs
- EventProviderBase.cs
- Assert.cs
- _NetRes.cs
- TypePresenter.xaml.cs
- Int32Converter.cs
- ObjectItemLoadingSessionData.cs
- HMACRIPEMD160.cs
- PathParser.cs
- LinearQuaternionKeyFrame.cs
- MergeFilterQuery.cs
- FontWeights.cs
- CommentAction.cs
- PasswordBoxAutomationPeer.cs
- ISAPIWorkerRequest.cs
- formatter.cs
- CalendarItem.cs
- SizeChangedEventArgs.cs
- WsatConfiguration.cs
- LinkDescriptor.cs
- ListViewDeleteEventArgs.cs
- LogicalExpr.cs
- DispatcherOperation.cs
- ModelUtilities.cs
- ScriptReferenceBase.cs
- NativeMsmqMessage.cs
- ProfileGroupSettings.cs
- MemberListBinding.cs
- SemaphoreSecurity.cs
- TrimSurroundingWhitespaceAttribute.cs
- ResourceWriter.cs
- TargetParameterCountException.cs
- UnsupportedPolicyOptionsException.cs
- StandardRuntimeEnumValidatorAttribute.cs
- SmtpClient.cs
- DataSourceBooleanViewSchemaConverter.cs
- safex509handles.cs
- ping.cs