Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / wpf / src / Framework / System / Windows / TemplateBindingExpression.cs / 1 / 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
- AsymmetricCryptoHandle.cs
- CalendarModeChangedEventArgs.cs
- GACMembershipCondition.cs
- RightsManagementManager.cs
- CapabilitiesAssignment.cs
- followingquery.cs
- Pair.cs
- ClientFormsAuthenticationMembershipProvider.cs
- InstancePersistence.cs
- DataGridViewMethods.cs
- PtsPage.cs
- CompilerCollection.cs
- TimelineClockCollection.cs
- ObjectIDGenerator.cs
- ToolStripSeparatorRenderEventArgs.cs
- DispatcherProcessingDisabled.cs
- OracleInfoMessageEventArgs.cs
- StringAnimationUsingKeyFrames.cs
- ObjectListShowCommandsEventArgs.cs
- CancellableEnumerable.cs
- TranslateTransform3D.cs
- DomainConstraint.cs
- ClickablePoint.cs
- PeerDefaultCustomResolverClient.cs
- EmissiveMaterial.cs
- EncryptedPackageFilter.cs
- OperationFormatUse.cs
- BatchParser.cs
- _KerberosClient.cs
- FixedPageProcessor.cs
- SpeechRecognizer.cs
- ExtensionQuery.cs
- ImageAutomationPeer.cs
- CompositeDesignerAccessibleObject.cs
- TraceEventCache.cs
- ToggleProviderWrapper.cs
- InvokeHandlers.cs
- StyleBamlTreeBuilder.cs
- TreeViewHitTestInfo.cs
- IisNotInstalledException.cs
- CodeValidator.cs
- ListMarkerLine.cs
- OleDbRowUpdatedEvent.cs
- UITypeEditors.cs
- SoapSchemaImporter.cs
- ResourceExpressionBuilder.cs
- TextTreeNode.cs
- TextTrailingWordEllipsis.cs
- DesignTimeVisibleAttribute.cs
- TextParaClient.cs
- HtmlButton.cs
- DllNotFoundException.cs
- SqlProviderServices.cs
- MetafileHeader.cs
- DataGridViewLinkCell.cs
- CodeRemoveEventStatement.cs
- ListDictionaryInternal.cs
- WebPartUtil.cs
- UriParserTemplates.cs
- HttpCachePolicyElement.cs
- DataControlFieldsEditor.cs
- ParseElementCollection.cs
- RectangleGeometry.cs
- BrushMappingModeValidation.cs
- PartBasedPackageProperties.cs
- DelayDesigner.cs
- EncoderParameters.cs
- SchemaNamespaceManager.cs
- ClientSideProviderDescription.cs
- LinearGradientBrush.cs
- TextEffectCollection.cs
- StateMachineTimers.cs
- UmAlQuraCalendar.cs
- SafeBitVector32.cs
- XmlAnyAttributeAttribute.cs
- CheckBoxBaseAdapter.cs
- SetterBaseCollection.cs
- JoinTreeNode.cs
- AvTraceFormat.cs
- WorkflowMarkupSerializationException.cs
- Closure.cs
- CommonDialog.cs
- CompoundFileIOPermission.cs
- ItemDragEvent.cs
- FastEncoder.cs
- ToolboxComponentsCreatedEventArgs.cs
- ArgumentDesigner.xaml.cs
- DataBindingHandlerAttribute.cs
- EventLogException.cs
- Control.cs
- _DisconnectOverlappedAsyncResult.cs
- SqlDeflator.cs
- _SingleItemRequestCache.cs
- EntityDataSourceColumn.cs
- DataBinder.cs
- GridLength.cs
- GroupItemAutomationPeer.cs
- ObjectStateEntry.cs
- NameValuePair.cs
- FactoryMaker.cs