Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / wpf / src / Framework / System / Windows / Controls / DeferredTextReference.cs / 1 / DeferredTextReference.cs
//---------------------------------------------------------------------------- // // File: DeferredTextReference.cs // // Copyright (C) Microsoft Corporation. All rights reserved. // // Description: Proxy object passed to the property system to delay load // TextProperty values. // //--------------------------------------------------------------------------- namespace System.Windows.Controls { using System.Windows.Documents; // Proxy object passed to the property system to delay load TextProperty // values. internal class DeferredTextReference : DeferredReference { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors internal DeferredTextReference(ITextContainer textContainer) { _textContainer = textContainer; } #endregion Constructors //------------------------------------------------------ // // Internal Methods // //----------------------------------------------------- #region Internal Methods // Does the real work to calculate the current TextProperty value. internal override object GetValue(BaseValueSourceInternal valueSource) { return TextRangeBase.GetTextInternal(_textContainer.Start, _textContainer.End); } // Gets the type of the value it represents internal override Type GetValueType() { return typeof(string); } #endregion Internal Methods //------------------------------------------------------ // // Private Fields // //------------------------------------------------------ #region Private Fields // TextContainer mapped to this object. private readonly ITextContainer _textContainer; #endregion Private Fields } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // // File: DeferredTextReference.cs // // Copyright (C) Microsoft Corporation. All rights reserved. // // Description: Proxy object passed to the property system to delay load // TextProperty values. // //--------------------------------------------------------------------------- namespace System.Windows.Controls { using System.Windows.Documents; // Proxy object passed to the property system to delay load TextProperty // values. internal class DeferredTextReference : DeferredReference { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors internal DeferredTextReference(ITextContainer textContainer) { _textContainer = textContainer; } #endregion Constructors //------------------------------------------------------ // // Internal Methods // //----------------------------------------------------- #region Internal Methods // Does the real work to calculate the current TextProperty value. internal override object GetValue(BaseValueSourceInternal valueSource) { return TextRangeBase.GetTextInternal(_textContainer.Start, _textContainer.End); } // Gets the type of the value it represents internal override Type GetValueType() { return typeof(string); } #endregion Internal Methods //------------------------------------------------------ // // Private Fields // //------------------------------------------------------ #region Private Fields // TextContainer mapped to this object. private readonly ITextContainer _textContainer; #endregion Private Fields } } // 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
- ObfuscateAssemblyAttribute.cs
- SystemWebExtensionsSectionGroup.cs
- WebHttpElement.cs
- DecoderReplacementFallback.cs
- Documentation.cs
- TextDecorations.cs
- CollectionViewSource.cs
- MissingFieldException.cs
- StylusShape.cs
- ResolveRequestResponseAsyncResult.cs
- FileRegion.cs
- PeerContact.cs
- SQLDoubleStorage.cs
- ParallelDesigner.cs
- InputLanguageSource.cs
- DecoderExceptionFallback.cs
- AssociationEndMember.cs
- CustomError.cs
- DbProviderSpecificTypePropertyAttribute.cs
- Pool.cs
- COSERVERINFO.cs
- RepeatButton.cs
- figurelength.cs
- XsltLoader.cs
- SecurityTokenParameters.cs
- SignerInfo.cs
- ClientBase.cs
- TypeUnloadedException.cs
- Type.cs
- Regex.cs
- CodeDelegateCreateExpression.cs
- RegexTree.cs
- DecoratedNameAttribute.cs
- uribuilder.cs
- TreeViewItem.cs
- X509CertificateChain.cs
- DbReferenceCollection.cs
- SessionStateUtil.cs
- ColorMap.cs
- EndpointDispatcher.cs
- ViewManagerAttribute.cs
- DataGridPagerStyle.cs
- __Error.cs
- TrackingServices.cs
- ReadOnlyCollectionBuilder.cs
- FixedTextPointer.cs
- LexicalChunk.cs
- QilVisitor.cs
- TypeReference.cs
- CategoryGridEntry.cs
- MSAAEventDispatcher.cs
- HandlerFactoryWrapper.cs
- PeerEndPoint.cs
- TextBoxView.cs
- OdbcError.cs
- ServerIdentity.cs
- Control.cs
- FixUpCollection.cs
- CLRBindingWorker.cs
- SafeFindHandle.cs
- Vector.cs
- Schema.cs
- Crc32.cs
- DebugView.cs
- WebRequestModuleElement.cs
- RowUpdatedEventArgs.cs
- ContentWrapperAttribute.cs
- SettingsProperty.cs
- KeysConverter.cs
- TreeNodeMouseHoverEvent.cs
- UrlMapping.cs
- TextFormatterContext.cs
- ProbeMatchesApril2005.cs
- TargetFrameworkAttribute.cs
- BitmapCacheBrush.cs
- Wildcard.cs
- HttpRequestCacheValidator.cs
- PresentationUIStyleResources.cs
- ConditionalWeakTable.cs
- DetailsViewUpdateEventArgs.cs
- DataGridViewCell.cs
- MetabaseSettingsIis7.cs
- storepermissionattribute.cs
- WebPartConnectionCollection.cs
- InputReferenceExpression.cs
- XamlRtfConverter.cs
- DropTarget.cs
- METAHEADER.cs
- ReflectPropertyDescriptor.cs
- Composition.cs
- _NetRes.cs
- PriorityItem.cs
- InheritanceAttribute.cs
- Classification.cs
- NonClientArea.cs
- UTF7Encoding.cs
- Rotation3DAnimation.cs
- Rules.cs
- SchemaNamespaceManager.cs
- BamlLocalizerErrorNotifyEventArgs.cs