Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / CompMod / System / ComponentModel / SettingsBindableAttribute.cs / 1 / SettingsBindableAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using System; using System.Diagnostics; using System.Security.Permissions; ////// Use this attribute to specify typical properties on components that can be bound /// to application settings. /// [AttributeUsage(AttributeTargets.Property)] public sealed class SettingsBindableAttribute : Attribute { ////// Specifies that a property is appropriate to bind settings to. /// public static readonly SettingsBindableAttribute Yes = new SettingsBindableAttribute(true); ////// Specifies that a property is not appropriate to bind settings to. /// public static readonly SettingsBindableAttribute No = new SettingsBindableAttribute(false); private bool _bindable = false; public SettingsBindableAttribute(bool bindable) { _bindable = bindable; } ////// Gets a value indicating whether a property is appropriate to bind settings to. /// public bool Bindable { get { return _bindable; } } public override bool Equals(object obj) { if (obj == this) { return true; } if (obj != null && obj is SettingsBindableAttribute) { return (((SettingsBindableAttribute)obj).Bindable == _bindable); } return false; } public override int GetHashCode() { return _bindable.GetHashCode(); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using System; using System.Diagnostics; using System.Security.Permissions; ////// Use this attribute to specify typical properties on components that can be bound /// to application settings. /// [AttributeUsage(AttributeTargets.Property)] public sealed class SettingsBindableAttribute : Attribute { ////// Specifies that a property is appropriate to bind settings to. /// public static readonly SettingsBindableAttribute Yes = new SettingsBindableAttribute(true); ////// Specifies that a property is not appropriate to bind settings to. /// public static readonly SettingsBindableAttribute No = new SettingsBindableAttribute(false); private bool _bindable = false; public SettingsBindableAttribute(bool bindable) { _bindable = bindable; } ////// Gets a value indicating whether a property is appropriate to bind settings to. /// public bool Bindable { get { return _bindable; } } public override bool Equals(object obj) { if (obj == this) { return true; } if (obj != null && obj is SettingsBindableAttribute) { return (((SettingsBindableAttribute)obj).Bindable == _bindable); } return false; } public override int GetHashCode() { return _bindable.GetHashCode(); } } } // 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
- TypeNameConverter.cs
- mansign.cs
- TrustManager.cs
- CaseStatement.cs
- SchemaContext.cs
- AnnotationAuthorChangedEventArgs.cs
- EditorZoneBase.cs
- XPathNode.cs
- AlgoModule.cs
- CompilerParameters.cs
- BulletChrome.cs
- EntryIndex.cs
- Constraint.cs
- EntityAdapter.cs
- InkSerializer.cs
- CompletionBookmark.cs
- ObjectSecurity.cs
- BamlStream.cs
- InputLanguageSource.cs
- BitmapMetadata.cs
- InvariantComparer.cs
- CodeDomConfigurationHandler.cs
- VariableQuery.cs
- EntityContainerEmitter.cs
- ArrangedElement.cs
- XamlInt32CollectionSerializer.cs
- PageFunction.cs
- GridViewRow.cs
- TimeSpan.cs
- CellLabel.cs
- CellTreeNodeVisitors.cs
- RoleGroup.cs
- HttpServerVarsCollection.cs
- BindingCollection.cs
- HttpRawResponse.cs
- DataControlFieldCollection.cs
- SettingsSection.cs
- RelationshipType.cs
- OleDbInfoMessageEvent.cs
- FixedPageAutomationPeer.cs
- MulticastNotSupportedException.cs
- TimeoutValidationAttribute.cs
- SoapIncludeAttribute.cs
- IsolatedStorageFileStream.cs
- ClientType.cs
- HandleTable.cs
- CompiledXpathExpr.cs
- TextContainer.cs
- QueryOperatorEnumerator.cs
- LinearGradientBrush.cs
- ViewCellSlot.cs
- HtmlProps.cs
- DynamicQueryStringParameter.cs
- WeakReference.cs
- ConfigXmlText.cs
- XmlLinkedNode.cs
- UnsafeNativeMethods.cs
- InternalTypeHelper.cs
- HtmlTitle.cs
- ResolveNameEventArgs.cs
- CqlBlock.cs
- WebServicesDescriptionAttribute.cs
- Parallel.cs
- HtmlObjectListAdapter.cs
- ImageFormatConverter.cs
- FlagsAttribute.cs
- ImplicitInputBrush.cs
- InteropEnvironment.cs
- SqlGatherConsumedAliases.cs
- Point3DIndependentAnimationStorage.cs
- SubstitutionDesigner.cs
- EventSourceCreationData.cs
- MatrixAnimationUsingKeyFrames.cs
- CacheMemory.cs
- EntitySqlException.cs
- ReflectionTypeLoadException.cs
- KeyedQueue.cs
- WorkflowDispatchContext.cs
- CodeDomSerializerBase.cs
- NumericUpDown.cs
- CustomAttributeBuilder.cs
- SamlAction.cs
- StreamWithDictionary.cs
- DataTableMapping.cs
- ObjectDataSourceChooseMethodsPanel.cs
- ConstrainedDataObject.cs
- UnsafeMethods.cs
- _LoggingObject.cs
- DetailsViewModeEventArgs.cs
- XmlAnyElementAttributes.cs
- SchemaCollectionPreprocessor.cs
- SqlInfoMessageEvent.cs
- BaseHashHelper.cs
- ImportCatalogPart.cs
- SqlExpressionNullability.cs
- GridViewColumnHeaderAutomationPeer.cs
- DispatcherSynchronizationContext.cs
- SecurityMessageProperty.cs
- ManipulationCompletedEventArgs.cs
- ISFTagAndGuidCache.cs