Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Framework / System / Windows / Automation / Peers / TextBlockAutomationPeer.cs / 1 / TextBlockAutomationPeer.cs
//---------------------------------------------------------------------------- // // Copyright (C) Microsoft Corporation. All rights reserved. // // File: TextBlockAutomationPeer.cs // // Description: AutomationPeer associated with TextBlock. // //--------------------------------------------------------------------------- using System.Collections.Generic; // Listusing System.Windows.Controls; // TextBlock using System.Windows.Documents; // ITextContainer using MS.Internal.Documents; // TextContainerHelper namespace System.Windows.Automation.Peers { /// /// AutomationPeer associated with TextBlock. /// public class TextBlockAutomationPeer : FrameworkElementAutomationPeer { ////// Constructor. /// /// Owner of the AutomationPeer. public TextBlockAutomationPeer(TextBlock owner) : base(owner) { } ////// protected override List/// GetChildrenCore() { List peers = null; TextBlock owner = (TextBlock)Owner; // TextBlock has children only if it has complex content. if (owner.HasComplexContent) { peers = TextContainerHelper.GetAutomationPeersFromRange(owner.TextContainer.Start, owner.TextContainer.End, null); } return peers; } /// /// protected override AutomationControlType GetAutomationControlTypeCore() { return AutomationControlType.Text; } ////// /// ////// protected override string GetClassNameCore() { return "TextBlock"; } /// /// override protected bool IsControlElementCore() { // Return true if TextBlock is not part of the style return ((TextBlock)Owner).TemplatedParent == null; } } } // 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
- OutOfMemoryException.cs
- WmlTextViewAdapter.cs
- StorageMappingItemCollection.cs
- EncoderReplacementFallback.cs
- PathGeometry.cs
- Perspective.cs
- SiteMembershipCondition.cs
- CharacterMetricsDictionary.cs
- CurrencyManager.cs
- ZoneButton.cs
- MatrixCamera.cs
- CommandValueSerializer.cs
- ReadOnlyDictionary.cs
- RefreshEventArgs.cs
- CodeParameterDeclarationExpression.cs
- WorkflowViewManager.cs
- AlternateView.cs
- WebReferenceOptions.cs
- MessageHeaderDescription.cs
- CheckBox.cs
- CompositeControl.cs
- ToolStripComboBox.cs
- RequestStatusBarUpdateEventArgs.cs
- ListViewItemEventArgs.cs
- XmlTextReaderImpl.cs
- WebHttpBindingElement.cs
- XmlDeclaration.cs
- SelectionItemPattern.cs
- GroupByQueryOperator.cs
- XmlNamedNodeMap.cs
- Compress.cs
- DocumentCollection.cs
- AvTraceFormat.cs
- CustomCategoryAttribute.cs
- COSERVERINFO.cs
- VisualProxy.cs
- VirtualizingStackPanel.cs
- AxHost.cs
- WSMessageEncoding.cs
- PagesSection.cs
- MenuEventArgs.cs
- SettingsPropertyValueCollection.cs
- ContentElementAutomationPeer.cs
- CacheDependency.cs
- HexParser.cs
- IconConverter.cs
- WriterOutput.cs
- SymbolTable.cs
- PointAnimation.cs
- CheckedPointers.cs
- SetStateEventArgs.cs
- ListBoxItemAutomationPeer.cs
- DataGridViewCellMouseEventArgs.cs
- DateTimePicker.cs
- Matrix3DStack.cs
- ComplexBindingPropertiesAttribute.cs
- FrameworkContextData.cs
- BaseCollection.cs
- ColumnWidthChangingEvent.cs
- SafeThemeHandle.cs
- SplineQuaternionKeyFrame.cs
- SqlDataSourceCommandEventArgs.cs
- TypeDependencyAttribute.cs
- HttpGetProtocolImporter.cs
- ExpressionBuilderCollection.cs
- TimeSpanStorage.cs
- NameTable.cs
- SafeProcessHandle.cs
- RegistryConfigurationProvider.cs
- CodeDirectionExpression.cs
- EventLogPermissionEntry.cs
- AttachedAnnotationChangedEventArgs.cs
- invalidudtexception.cs
- DesignerVerb.cs
- SqlCharStream.cs
- InputLanguageProfileNotifySink.cs
- DbConnectionPoolIdentity.cs
- PerformanceCounterNameAttribute.cs
- DESCryptoServiceProvider.cs
- RC2CryptoServiceProvider.cs
- KeyPullup.cs
- ObjectMemberMapping.cs
- ScriptControlDescriptor.cs
- DirtyTextRange.cs
- DBDataPermission.cs
- CheckBox.cs
- DrawingBrush.cs
- RangeContentEnumerator.cs
- controlskin.cs
- RunClient.cs
- DesignerTransaction.cs
- DataGridViewSelectedRowCollection.cs
- DbProviderConfigurationHandler.cs
- __Filters.cs
- AnimatedTypeHelpers.cs
- QilList.cs
- SortedDictionary.cs
- Fault.cs
- GenericAuthenticationEventArgs.cs
- StateWorkerRequest.cs