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
- ViewStateModeByIdAttribute.cs
- ISAPIApplicationHost.cs
- EnvelopedPkcs7.cs
- CaretElement.cs
- ListItem.cs
- FontDialog.cs
- WebExceptionStatus.cs
- EventManager.cs
- IdnMapping.cs
- CompilerLocalReference.cs
- Separator.cs
- PipeConnection.cs
- ByteStreamMessageUtility.cs
- TextFormatterContext.cs
- _NegoStream.cs
- RelAssertionDirectKeyIdentifierClause.cs
- HttpHandler.cs
- SinglePageViewer.cs
- DetailsViewInsertEventArgs.cs
- ReflectionServiceProvider.cs
- QueryInterceptorAttribute.cs
- VirtualDirectoryMapping.cs
- TogglePattern.cs
- NavigationProperty.cs
- ForeignKeyFactory.cs
- GuidConverter.cs
- cookieexception.cs
- GZipDecoder.cs
- SHA384.cs
- InboundActivityHelper.cs
- Empty.cs
- SafeHandles.cs
- UIElementIsland.cs
- FixedSOMFixedBlock.cs
- ImageButton.cs
- SqlInternalConnectionTds.cs
- FactoryGenerator.cs
- AdPostCacheSubstitution.cs
- CodeAssignStatement.cs
- _HeaderInfoTable.cs
- Parser.cs
- QuaternionIndependentAnimationStorage.cs
- DbConnectionHelper.cs
- SrgsSemanticInterpretationTag.cs
- BaseInfoTable.cs
- XmlProcessingInstruction.cs
- XPathMessageFilter.cs
- XmlSchemaSubstitutionGroup.cs
- OverloadGroupAttribute.cs
- ConnectionsZone.cs
- IIS7UserPrincipal.cs
- FixUpCollection.cs
- Point3DCollection.cs
- TransformCollection.cs
- JpegBitmapDecoder.cs
- ToolBarButtonDesigner.cs
- SyntaxCheck.cs
- ChameleonKey.cs
- PrimitiveType.cs
- ButtonFlatAdapter.cs
- DrawListViewColumnHeaderEventArgs.cs
- ListSourceHelper.cs
- ProfileParameter.cs
- ObjectTag.cs
- RenderCapability.cs
- ComponentConverter.cs
- regiisutil.cs
- SolidColorBrush.cs
- PictureBox.cs
- BookmarkInfo.cs
- UnicodeEncoding.cs
- DataSet.cs
- StandardCommandToolStripMenuItem.cs
- CommandValueSerializer.cs
- ParentQuery.cs
- ValueOfAction.cs
- PersonalizableTypeEntry.cs
- IisTraceWebEventProvider.cs
- ToolStripPanelSelectionGlyph.cs
- BitmapEffectGeneralTransform.cs
- BamlLocalizableResource.cs
- ContentValidator.cs
- X509CertificateClaimSet.cs
- WinFormsComponentEditor.cs
- WebPartsPersonalizationAuthorization.cs
- SQLBytes.cs
- ArrayElementGridEntry.cs
- LocalValueEnumerator.cs
- SqlDeflator.cs
- DirectionalLight.cs
- AnnotationComponentManager.cs
- SubstitutionResponseElement.cs
- Label.cs
- XamlSerializerUtil.cs
- ControlParameter.cs
- Int64Converter.cs
- MemberAssignmentAnalysis.cs
- TransformerTypeCollection.cs
- PassportPrincipal.cs
- ParentQuery.cs