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
- MenuItem.cs
- PageRequestManager.cs
- ProxyHelper.cs
- DesignerVerbCollection.cs
- SchemaDeclBase.cs
- SqlDataReader.cs
- Operand.cs
- XmlNodeList.cs
- IFlowDocumentViewer.cs
- EnumValidator.cs
- UseLicense.cs
- basecomparevalidator.cs
- PrePostDescendentsWalker.cs
- Message.cs
- WebPartZoneBase.cs
- DataSourceSerializationException.cs
- _PooledStream.cs
- DtdParser.cs
- ConnectionPointGlyph.cs
- QilTypeChecker.cs
- ChangeBlockUndoRecord.cs
- PropagationProtocolsTracing.cs
- CqlParserHelpers.cs
- HttpHandlerAction.cs
- Properties.cs
- SurrogateSelector.cs
- Odbc32.cs
- ImageSource.cs
- DefaultWorkflowTransactionService.cs
- HostProtectionPermission.cs
- UInt64.cs
- GuidConverter.cs
- DataViewManager.cs
- ListBoxAutomationPeer.cs
- NetStream.cs
- ADRoleFactory.cs
- DrawListViewColumnHeaderEventArgs.cs
- TaiwanLunisolarCalendar.cs
- ColorTransformHelper.cs
- HttpException.cs
- Internal.cs
- SerializationAttributes.cs
- DataGridViewTextBoxEditingControl.cs
- SchemaImporter.cs
- OutKeywords.cs
- DataComponentNameHandler.cs
- BaseDataList.cs
- PerformanceCounterCategory.cs
- PackWebRequest.cs
- ReversePositionQuery.cs
- _Rfc2616CacheValidators.cs
- ToolStripRendererSwitcher.cs
- FileDialog.cs
- BaseDataBoundControl.cs
- LayoutTableCell.cs
- WebControl.cs
- ContractMapping.cs
- TimeBoundedCache.cs
- WSDualHttpSecurity.cs
- ProjectedSlot.cs
- ListViewDeletedEventArgs.cs
- GridItemPattern.cs
- WorkflowServiceOperationListItem.cs
- ImmutableCollection.cs
- Documentation.cs
- GridViewCancelEditEventArgs.cs
- XmlBinaryReaderSession.cs
- AmbientLight.cs
- WMIInterop.cs
- ConfigurationElementProperty.cs
- VariableQuery.cs
- Int16AnimationUsingKeyFrames.cs
- RelatedView.cs
- InputMethod.cs
- PerformanceCounterPermission.cs
- OpacityConverter.cs
- TreeViewImageKeyConverter.cs
- XmlSchemaObjectCollection.cs
- PowerModeChangedEventArgs.cs
- OrderedHashRepartitionStream.cs
- EventLogEntry.cs
- ByteAnimationBase.cs
- Screen.cs
- iisPickupDirectory.cs
- NegationPusher.cs
- PartBasedPackageProperties.cs
- InheritanceContextChangedEventManager.cs
- FormatConvertedBitmap.cs
- RIPEMD160Managed.cs
- XamlStream.cs
- ConsumerConnectionPoint.cs
- InvalidAsynchronousStateException.cs
- RepeatBehavior.cs
- RepeatEnumerable.cs
- HttpProxyTransportBindingElement.cs
- RsaKeyGen.cs
- StringConcat.cs
- FrameworkContentElement.cs
- BitFlagsGenerator.cs
- SelectedPathEditor.cs