Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Controls / DeferredRunTextReference.cs / 1305600 / DeferredRunTextReference.cs
//---------------------------------------------------------------------------- // // File: DeferredRunTextReference.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 DeferredRunTextReference : DeferredReference { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors internal DeferredRunTextReference(Run run) { _run = run; } #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(_run.ContentStart, _run.ContentEnd); } // Gets the type of the value it represents internal override Type GetValueType() { return typeof(string); } #endregion Internal Methods //------------------------------------------------------ // // Private Fields // //------------------------------------------------------ #region Private Fields // Run mapped to this object. private readonly Run _run; #endregion Private Fields } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //---------------------------------------------------------------------------- // // File: DeferredRunTextReference.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 DeferredRunTextReference : DeferredReference { //----------------------------------------------------- // // Constructors // //----------------------------------------------------- #region Constructors internal DeferredRunTextReference(Run run) { _run = run; } #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(_run.ContentStart, _run.ContentEnd); } // Gets the type of the value it represents internal override Type GetValueType() { return typeof(string); } #endregion Internal Methods //------------------------------------------------------ // // Private Fields // //------------------------------------------------------ #region Private Fields // Run mapped to this object. private readonly Run _run; #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
- TreeViewImageKeyConverter.cs
- SynchronizedInputPattern.cs
- ChangesetResponse.cs
- propertyentry.cs
- UIElementPropertyUndoUnit.cs
- EventSinkActivityDesigner.cs
- WebException.cs
- CustomAttribute.cs
- BulletDecorator.cs
- DesignerResources.cs
- BindingMAnagerBase.cs
- SingleQueryOperator.cs
- DbConnectionOptions.cs
- ReferenceConverter.cs
- DataPagerField.cs
- ArrangedElement.cs
- AssemblyBuilder.cs
- WebHttpSecurity.cs
- CheckBoxFlatAdapter.cs
- CommentAction.cs
- ButtonRenderer.cs
- Visual3D.cs
- SystemColorTracker.cs
- HttpResponse.cs
- DataColumnPropertyDescriptor.cs
- TypeCacheManager.cs
- Normalization.cs
- SafeFindHandle.cs
- RequestNavigateEventArgs.cs
- UriTemplateLiteralPathSegment.cs
- DataSourceControl.cs
- DesignerForm.cs
- WebEventCodes.cs
- ShutDownListener.cs
- BuildProvider.cs
- FullTrustAssemblyCollection.cs
- SourceFileBuildProvider.cs
- Menu.cs
- Line.cs
- EnumType.cs
- FormatterServices.cs
- ControlOperationInvoker.cs
- X509CertificateValidator.cs
- DateTimeOffset.cs
- ZipIOCentralDirectoryFileHeader.cs
- PagedDataSource.cs
- SchemaInfo.cs
- XmlCharacterData.cs
- RangeValuePatternIdentifiers.cs
- Exceptions.cs
- Vector3DCollection.cs
- ApplicationDirectory.cs
- DataGridViewUtilities.cs
- AdornerPresentationContext.cs
- Pointer.cs
- CompoundFileReference.cs
- ClickablePoint.cs
- SqlXmlStorage.cs
- ImmutableObjectAttribute.cs
- TileBrush.cs
- TextStore.cs
- DataRecord.cs
- ErasingStroke.cs
- HwndHostAutomationPeer.cs
- LayoutDump.cs
- RangeEnumerable.cs
- DataTable.cs
- LightweightCodeGenerator.cs
- ObjectCacheHost.cs
- ServerValidateEventArgs.cs
- XmlAggregates.cs
- FixedStringLookup.cs
- FactoryMaker.cs
- XslException.cs
- XmlNamespaceMappingCollection.cs
- ValidatingPropertiesEventArgs.cs
- BrowserCapabilitiesFactory.cs
- BinaryMessageEncodingBindingElement.cs
- DataGridViewRowContextMenuStripNeededEventArgs.cs
- DbCommandTree.cs
- TraceUtils.cs
- TransformerTypeCollection.cs
- BinarySerializer.cs
- LeftCellWrapper.cs
- BoolExpr.cs
- TextServicesDisplayAttribute.cs
- TransactionScope.cs
- MetadataItem.cs
- SigningDialog.cs
- DefaultParameterValueAttribute.cs
- IHttpResponseInternal.cs
- RecoverInstanceLocksCommand.cs
- SymbolMethod.cs
- PropertyEmitterBase.cs
- Lookup.cs
- AnnotationResourceChangedEventArgs.cs
- CertificateManager.cs
- COM2AboutBoxPropertyDescriptor.cs
- AuthenticatingEventArgs.cs
- MachineKeySection.cs