Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / CompMod / System / ComponentModel / DefaultEventAttribute.cs / 1 / DefaultEventAttribute.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//-----------------------------------------------------------------------------
/*
*/
namespace System.ComponentModel {
using System;
using System.Diagnostics;
using System.Security.Permissions;
///
/// Specifies the default event for a
/// component.
///
[AttributeUsage(AttributeTargets.Class)]
public sealed class DefaultEventAttribute : Attribute {
///
/// This is the default event name.
///
private readonly string name;
///
///
/// Initializes
/// a new instance of the class.
///
///
public DefaultEventAttribute(string name) {
this.name = name;
}
///
///
/// Gets the name of the default event for
/// the component this attribute is bound to.
///
///
public string Name {
get {
return name;
}
}
///
///
/// Specifies the default value for the , which is
/// .
/// This field is read-only.
///
///
public static readonly DefaultEventAttribute Default = new DefaultEventAttribute(null);
public override bool Equals(object obj) {
DefaultEventAttribute other = obj as DefaultEventAttribute;
return (other != null) && other.Name == name;
}
public override int GetHashCode() {
return base.GetHashCode();
}
}
}
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- LinearQuaternionKeyFrame.cs
- SignatureResourcePool.cs
- BoundField.cs
- BasicHttpMessageSecurityElement.cs
- UriPrefixTable.cs
- AlternateViewCollection.cs
- SqlCacheDependencySection.cs
- FixedLineResult.cs
- _ListenerAsyncResult.cs
- OracleConnectionString.cs
- TraceContextEventArgs.cs
- ColumnMap.cs
- PageContentAsyncResult.cs
- OrderedHashRepartitionEnumerator.cs
- ChtmlPhoneCallAdapter.cs
- MenuItemStyle.cs
- FrameworkReadOnlyPropertyMetadata.cs
- UnionExpr.cs
- GlyphRunDrawing.cs
- TogglePattern.cs
- LinqDataSourceStatusEventArgs.cs
- ReadOnlyActivityGlyph.cs
- PageThemeCodeDomTreeGenerator.cs
- DataExpression.cs
- Regex.cs
- GcHandle.cs
- IndexedString.cs
- ControlCachePolicy.cs
- WebEvents.cs
- ObjectPersistData.cs
- remotingproxy.cs
- Stylesheet.cs
- ActivationProxy.cs
- AdapterUtil.cs
- _SslState.cs
- FixedDocument.cs
- ArrayWithOffset.cs
- dtdvalidator.cs
- QueueSurrogate.cs
- MobileListItem.cs
- AutomationPattern.cs
- TdsParserStateObject.cs
- StorageSetMapping.cs
- IxmlLineInfo.cs
- AutomationProperties.cs
- FileVersion.cs
- ClientApiGenerator.cs
- LinqDataSourceHelper.cs
- AlternateViewCollection.cs
- TextFormatterContext.cs
- CustomCredentialPolicy.cs
- StringToken.cs
- XmlBindingWorker.cs
- AttributedMetaModel.cs
- UnionExpr.cs
- QilList.cs
- Quaternion.cs
- HatchBrush.cs
- QueueException.cs
- MemberBinding.cs
- DisplayInformation.cs
- ExpressionLink.cs
- WsdlInspector.cs
- TextRangeSerialization.cs
- SplashScreen.cs
- EmptyEnumerator.cs
- ACL.cs
- TextDecorationUnitValidation.cs
- WmlFormAdapter.cs
- BindingManagerDataErrorEventArgs.cs
- GridItemPatternIdentifiers.cs
- PublisherIdentityPermission.cs
- MethodRental.cs
- UriParserTemplates.cs
- TimeoutException.cs
- ElapsedEventArgs.cs
- RowUpdatingEventArgs.cs
- NodeInfo.cs
- ImageListStreamer.cs
- PeerNameRecordCollection.cs
- WebControl.cs
- Codec.cs
- Pens.cs
- EntitySqlQueryCacheEntry.cs
- ContainerControl.cs
- ApplicationDirectory.cs
- XmlILOptimizerVisitor.cs
- WebServiceEnumData.cs
- TableCellCollection.cs
- RowParagraph.cs
- ToolStripDropDownClosingEventArgs.cs
- GridViewUpdatedEventArgs.cs
- CounterSetInstance.cs
- PrintControllerWithStatusDialog.cs
- LinqToSqlWrapper.cs
- XmlSerializerNamespaces.cs
- DiagnosticsConfiguration.cs
- MaskedTextBox.cs
- SignatureGenerator.cs
- ZipIOExtraFieldPaddingElement.cs