Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / TemplateBindingExpression.cs / 1305600 / TemplateBindingExpression.cs
/****************************************************************************\ * * File: TemplateBindingExpression.cs * * Expression to represent a TemplateBindingExtension during editing of a * template. * * Copyright (C) 2005 by Microsoft Corporation. All rights reserved. * \***************************************************************************/ using System; using System.ComponentModel; using System.Windows; using System.Windows.Data; using System.Windows.Markup; namespace System.Windows { ////// A TemplateBinding is used in templates (e.g. ControlTemplate). When the content of /// a template is instantiated for inspection, the template bindings are represented with /// a TemplateBindingExpression. (In this case, the expression returns the property's default /// value.) /// [TypeConverter(typeof(TemplateBindingExpressionConverter))] public class TemplateBindingExpression : Expression { private TemplateBindingExtension _templateBindingExtension; internal TemplateBindingExpression( TemplateBindingExtension templateBindingExtension ) { _templateBindingExtension = templateBindingExtension; } ////// Constructor for TemplateBindingExpression /// public TemplateBindingExtension TemplateBindingExtension { get { return _templateBindingExtension; } } ////// Called to evaluate the Expression value /// /// DependencyObject being queried /// Property being queried ///Computed value. Default (of the target) if unavailable. internal override object GetValue(DependencyObject d, DependencyProperty dp) { return dp.GetDefaultValue(d.DependencyObjectType); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. /****************************************************************************\ * * File: TemplateBindingExpression.cs * * Expression to represent a TemplateBindingExtension during editing of a * template. * * Copyright (C) 2005 by Microsoft Corporation. All rights reserved. * \***************************************************************************/ using System; using System.ComponentModel; using System.Windows; using System.Windows.Data; using System.Windows.Markup; namespace System.Windows { ////// A TemplateBinding is used in templates (e.g. ControlTemplate). When the content of /// a template is instantiated for inspection, the template bindings are represented with /// a TemplateBindingExpression. (In this case, the expression returns the property's default /// value.) /// [TypeConverter(typeof(TemplateBindingExpressionConverter))] public class TemplateBindingExpression : Expression { private TemplateBindingExtension _templateBindingExtension; internal TemplateBindingExpression( TemplateBindingExtension templateBindingExtension ) { _templateBindingExtension = templateBindingExtension; } ////// Constructor for TemplateBindingExpression /// public TemplateBindingExtension TemplateBindingExtension { get { return _templateBindingExtension; } } ////// Called to evaluate the Expression value /// /// DependencyObject being queried /// Property being queried ///Computed value. Default (of the target) if unavailable. internal override object GetValue(DependencyObject d, DependencyProperty dp) { return dp.GetDefaultValue(d.DependencyObjectType); } } } // 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
- SystemBrushes.cs
- InternalConfigEventArgs.cs
- GeneralTransform2DTo3DTo2D.cs
- _SingleItemRequestCache.cs
- securitycriticaldataformultiplegetandset.cs
- MetadataItem.cs
- VisualCollection.cs
- RowsCopiedEventArgs.cs
- ReadOnlyTernaryTree.cs
- GiveFeedbackEvent.cs
- Debug.cs
- Reference.cs
- PerfService.cs
- SqlUDTStorage.cs
- HwndTarget.cs
- SerializationException.cs
- StringUtil.cs
- AttributeCollection.cs
- SplineKeyFrames.cs
- Base64Encoder.cs
- RegexWorker.cs
- AppDomainGrammarProxy.cs
- IImplicitResourceProvider.cs
- PeerCustomResolverSettings.cs
- QueueProcessor.cs
- MemberCollection.cs
- EnumValAlphaComparer.cs
- RegexGroupCollection.cs
- InputChannelAcceptor.cs
- FormsAuthenticationConfiguration.cs
- FutureFactory.cs
- WebPartEditVerb.cs
- DbRetry.cs
- CompositeKey.cs
- ImageBrush.cs
- SimplePropertyEntry.cs
- PriorityQueue.cs
- HttpContextServiceHost.cs
- Native.cs
- SerializationBinder.cs
- HttpFileCollection.cs
- ReturnType.cs
- WebRequest.cs
- FrameAutomationPeer.cs
- ExpressionBuilder.cs
- ControlBuilder.cs
- HttpDebugHandler.cs
- FilteredDataSetHelper.cs
- CommandManager.cs
- errorpatternmatcher.cs
- XsltCompileContext.cs
- DefaultPropertyAttribute.cs
- PropertyEmitterBase.cs
- CqlIdentifiers.cs
- TextFindEngine.cs
- XpsImageSerializationService.cs
- PageWrapper.cs
- SvcMapFileSerializer.cs
- SystemIPInterfaceStatistics.cs
- ToolboxItemFilterAttribute.cs
- TextParagraphProperties.cs
- FormParameter.cs
- StackOverflowException.cs
- PropertyTabAttribute.cs
- MaskInputRejectedEventArgs.cs
- DataBindingExpressionBuilder.cs
- SubMenuStyleCollection.cs
- XmlHierarchicalDataSourceView.cs
- DesignerLinkAdapter.cs
- X509PeerCertificateAuthenticationElement.cs
- DebugManager.cs
- HttpCacheParams.cs
- SectionInput.cs
- PageSetupDialog.cs
- HandlerFactoryCache.cs
- CollaborationHelperFunctions.cs
- TypeNameConverter.cs
- NamespaceMapping.cs
- HandlerElementCollection.cs
- ContentPlaceHolder.cs
- RayHitTestParameters.cs
- XmlEncodedRawTextWriter.cs
- DataView.cs
- GroupBox.cs
- IconHelper.cs
- SessionPageStatePersister.cs
- ChannelServices.cs
- ToolStripDropDownButton.cs
- ByteStorage.cs
- XmlChildNodes.cs
- RetrieveVirtualItemEventArgs.cs
- TrackingLocation.cs
- uribuilder.cs
- EdmProperty.cs
- XmlnsPrefixAttribute.cs
- PersonalizableTypeEntry.cs
- HtmlTableRow.cs
- MetadataSource.cs
- MarginsConverter.cs
- InvokeHandlers.cs