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
- QueryCacheKey.cs
- Package.cs
- ApplicationBuildProvider.cs
- LogicalExpressionTypeConverter.cs
- NamespaceQuery.cs
- WeakReference.cs
- ErrorHandler.cs
- DayRenderEvent.cs
- TrustLevelCollection.cs
- loginstatus.cs
- AssociatedControlConverter.cs
- TripleDESCryptoServiceProvider.cs
- CacheAxisQuery.cs
- SecurityUtils.cs
- RightsManagementManager.cs
- NativeObjectSecurity.cs
- DataGridViewCellStyleChangedEventArgs.cs
- UICuesEvent.cs
- DependencyObjectPropertyDescriptor.cs
- PassportAuthentication.cs
- SqlDuplicator.cs
- XmlWrappingReader.cs
- SubtreeProcessor.cs
- XmlSchemaComplexContentRestriction.cs
- StopRoutingHandler.cs
- CallbackHandler.cs
- SurrogateEncoder.cs
- EntityDataSourceDataSelection.cs
- DataGridViewColumn.cs
- Int16AnimationBase.cs
- MinimizableAttributeTypeConverter.cs
- VectorCollectionValueSerializer.cs
- MessageRpc.cs
- WebPartTransformerAttribute.cs
- ValidationErrorCollection.cs
- ProfileSection.cs
- BamlResourceSerializer.cs
- TextProperties.cs
- ParentUndoUnit.cs
- HMACMD5.cs
- ResourceIDHelper.cs
- ReadOnlyDataSourceView.cs
- StylusTip.cs
- LoadWorkflowByInstanceKeyCommand.cs
- XmlDataProvider.cs
- RowVisual.cs
- AnnotationResourceChangedEventArgs.cs
- CodeAssignStatement.cs
- ComponentConverter.cs
- HiddenFieldPageStatePersister.cs
- FamilyTypeface.cs
- ProgressChangedEventArgs.cs
- RewritingProcessor.cs
- XPathDocumentNavigator.cs
- RepeatInfo.cs
- PropertyValueUIItem.cs
- FileDialog.cs
- WebUtil.cs
- IPPacketInformation.cs
- IISMapPath.cs
- WebScriptEnablingElement.cs
- NullableIntSumAggregationOperator.cs
- LiteralControl.cs
- MetadataUtilsSmi.cs
- TableCellAutomationPeer.cs
- TdsParameterSetter.cs
- RelationshipWrapper.cs
- Overlapped.cs
- storepermission.cs
- MetadataSource.cs
- HealthMonitoringSectionHelper.cs
- DataMisalignedException.cs
- RelatedCurrencyManager.cs
- ExceptionUtil.cs
- RootProfilePropertySettingsCollection.cs
- DropDownButton.cs
- login.cs
- RegularExpressionValidator.cs
- BinaryFormatterSinks.cs
- HandlerFactoryCache.cs
- HtmlInputRadioButton.cs
- Menu.cs
- PKCS1MaskGenerationMethod.cs
- HttpHandler.cs
- IsolatedStorageFileStream.cs
- DayRenderEvent.cs
- Graphics.cs
- Rotation3D.cs
- MessageSecurityVersionConverter.cs
- Size3D.cs
- MetabaseServerConfig.cs
- SecurityTokenReferenceStyle.cs
- NativeMethods.cs
- GlobalizationSection.cs
- SerializationAttributes.cs
- ToolStripDropDown.cs
- WindowsGraphics2.cs
- ListView.cs
- VectorCollection.cs
- WebControlParameterProxy.cs