Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Base / MS / Internal / ComponentModel / PropertyChangeTracker.cs / 1305600 / PropertyChangeTracker.cs
namespace MS.Internal.ComponentModel { using System; using System.Collections.Generic; using System.ComponentModel; using System.Diagnostics; using System.Globalization; using System.Reflection; using System.Security.Permissions; using System.Windows; ////// A change tracking expression that is used to raise property change events. /// internal class PropertyChangeTracker : Expression { internal PropertyChangeTracker(DependencyObject obj, DependencyProperty property) : base(ExpressionMode.NonSharable | ExpressionMode.ForwardsInvalidations) { Debug.Assert(obj != null && property != null); _object = obj; _property = property; ChangeSources(_object, _property, new DependencySource[] { new DependencySource(obj, property) }); } internal override void OnPropertyInvalidation(DependencyObject d, DependencyPropertyChangedEventArgs args) { DependencyProperty dp = args.Property; if (_object == d && _property == dp && Changed != null) { Changed(_object, EventArgs.Empty); } } internal void Close() { _object = null; _property = null; ChangeSources(null, null, null); } internal bool CanClose { get { return Changed == null; } } internal EventHandler Changed; private DependencyObject _object; private DependencyProperty _property; } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- LoginView.cs
- storepermissionattribute.cs
- HandlerFactoryCache.cs
- SingleConverter.cs
- BuilderInfo.cs
- UrlPath.cs
- PointAnimationUsingPath.cs
- __ConsoleStream.cs
- Char.cs
- XmlSchemaSet.cs
- ObjectHandle.cs
- PrintDocument.cs
- Block.cs
- BitmapImage.cs
- XmlSchemaInclude.cs
- DBParameter.cs
- CompModHelpers.cs
- WindowsListViewGroupSubsetLink.cs
- XmlSchemaGroup.cs
- MemberProjectionIndex.cs
- TimeoutException.cs
- RemotingConfigParser.cs
- KeyTimeConverter.cs
- COSERVERINFO.cs
- Int32EqualityComparer.cs
- MgmtResManager.cs
- AuthenticationException.cs
- ParserStreamGeometryContext.cs
- UnauthorizedWebPart.cs
- TemplateBuilder.cs
- BoundPropertyEntry.cs
- Timer.cs
- CompositeCollection.cs
- ModulesEntry.cs
- PointCollection.cs
- ReadOnlyAttribute.cs
- CipherData.cs
- OdbcHandle.cs
- KeyTime.cs
- AdapterUtil.cs
- Vector.cs
- KnownAssembliesSet.cs
- MoveSizeWinEventHandler.cs
- ServiceDesigner.xaml.cs
- InternalDispatchObject.cs
- Button.cs
- PerfCounters.cs
- ColumnMapProcessor.cs
- ColorEditor.cs
- TextEffectResolver.cs
- CompilerInfo.cs
- AsmxEndpointPickerExtension.cs
- SecureStringHasher.cs
- Bidi.cs
- SqlProvider.cs
- ServiceSecurityAuditBehavior.cs
- DesignerContextDescriptor.cs
- MimeWriter.cs
- XmlSchemaSimpleType.cs
- ConfigPathUtility.cs
- AccessDataSourceDesigner.cs
- NotifyCollectionChangedEventArgs.cs
- DataGridViewRowCancelEventArgs.cs
- XmlReaderSettings.cs
- HwndSourceParameters.cs
- RadioButton.cs
- EncryptedReference.cs
- ActivityDesignerResources.cs
- SpeechEvent.cs
- CompilationLock.cs
- DataQuery.cs
- XmlDataImplementation.cs
- TextTrailingWordEllipsis.cs
- AppSettingsExpressionBuilder.cs
- DomainConstraint.cs
- DataBindingCollection.cs
- Tablet.cs
- OleDbError.cs
- SettingsPropertyWrongTypeException.cs
- UseManagedPresentationElement.cs
- WindowInteractionStateTracker.cs
- ViewEvent.cs
- VerticalAlignConverter.cs
- DeviceFilterEditorDialog.cs
- DataListCommandEventArgs.cs
- ThreadAttributes.cs
- HtmlControlPersistable.cs
- SystemSounds.cs
- InheritanceContextChangedEventManager.cs
- SqlNodeAnnotation.cs
- Atom10FormatterFactory.cs
- StylusPointPropertyId.cs
- ReferencedCollectionType.cs
- CreateUserWizard.cs
- TableLayoutPanelCellPosition.cs
- NTAccount.cs
- Block.cs
- ServicePoint.cs
- ArraySegment.cs
- ColumnMapProcessor.cs