Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / wpf / src / Framework / System / Windows / Automation / Peers / LabelAutomationPeer.cs / 1 / LabelAutomationPeer.cs
using System; using System.Runtime.InteropServices; using System.Security; using System.Text; using System.Windows; using System.Windows.Automation.Provider; using System.Windows.Controls; using System.Windows.Interop; using System.Windows.Media; using MS.Internal; using MS.Win32; namespace System.Windows.Automation.Peers { /// public class LabelAutomationPeer : FrameworkElementAutomationPeer { /// public LabelAutomationPeer(Label owner): base(owner) {} /// override protected string GetClassNameCore() { return "Text"; } /// override protected AutomationControlType GetAutomationControlTypeCore() { return AutomationControlType.Text; } /// override public object GetPattern(PatternInterface patternInterface) { return null; } // Return the base without the AccessKey character /// override protected string GetNameCore() { string result = base.GetNameCore(); if (!string.IsNullOrEmpty(result)) { Label label = (Label)Owner; if (label.Content is string) { return AccessText.RemoveAccessKeyMarker(result); } } return result; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. using System; using System.Runtime.InteropServices; using System.Security; using System.Text; using System.Windows; using System.Windows.Automation.Provider; using System.Windows.Controls; using System.Windows.Interop; using System.Windows.Media; using MS.Internal; using MS.Win32; namespace System.Windows.Automation.Peers { /// public class LabelAutomationPeer : FrameworkElementAutomationPeer { /// public LabelAutomationPeer(Label owner): base(owner) {} /// override protected string GetClassNameCore() { return "Text"; } /// override protected AutomationControlType GetAutomationControlTypeCore() { return AutomationControlType.Text; } /// override public object GetPattern(PatternInterface patternInterface) { return null; } // Return the base without the AccessKey character /// override protected string GetNameCore() { string result = base.GetNameCore(); if (!string.IsNullOrEmpty(result)) { Label label = (Label)Owner; if (label.Content is string) { return AccessText.RemoveAccessKeyMarker(result); } } return result; } } } // 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
- SQLCharsStorage.cs
- RegionIterator.cs
- RuntimeConfig.cs
- LinearGradientBrush.cs
- Effect.cs
- MatrixValueSerializer.cs
- ProfessionalColorTable.cs
- PropertyCollection.cs
- Events.cs
- ReverseInheritProperty.cs
- X509ServiceCertificateAuthentication.cs
- ClientRuntimeConfig.cs
- FullTrustAssemblyCollection.cs
- DbModificationCommandTree.cs
- RadioButtonBaseAdapter.cs
- ThemeInfoAttribute.cs
- OSEnvironmentHelper.cs
- CodeGeneratorOptions.cs
- SizeChangedInfo.cs
- Rect3D.cs
- KnownColorTable.cs
- ObjectListComponentEditor.cs
- DbConnectionClosed.cs
- MsmqIntegrationBindingCollectionElement.cs
- DataGridViewCellConverter.cs
- EffectiveValueEntry.cs
- ToolStripDropDownClosingEventArgs.cs
- WebPartManagerInternals.cs
- Size.cs
- GcHandle.cs
- CultureMapper.cs
- StreamGeometry.cs
- SafeSecurityHandles.cs
- cookiecollection.cs
- AutomationFocusChangedEventArgs.cs
- XsdCachingReader.cs
- GuidTagList.cs
- SRDisplayNameAttribute.cs
- StringUtil.cs
- File.cs
- UnionExpr.cs
- TreeIterators.cs
- WebConfigurationFileMap.cs
- CreateUserWizard.cs
- HttpCacheVaryByContentEncodings.cs
- DefaultValueMapping.cs
- StoreItemCollection.cs
- NonSerializedAttribute.cs
- ApplicationActivator.cs
- TypeConverterValueSerializer.cs
- WebPartUtil.cs
- Menu.cs
- _NegotiateClient.cs
- Geometry3D.cs
- TextServicesLoader.cs
- XPathNode.cs
- ForwardPositionQuery.cs
- ToolStripItemImageRenderEventArgs.cs
- CrossContextChannel.cs
- SiteMapProvider.cs
- DataListCommandEventArgs.cs
- DataMisalignedException.cs
- TreeNodeClickEventArgs.cs
- NameTable.cs
- PeerConnector.cs
- InvalidDataException.cs
- TypographyProperties.cs
- DictionaryItemsCollection.cs
- ByteStorage.cs
- KeyFrames.cs
- SizeAnimationBase.cs
- SignatureDescription.cs
- InvokeProviderWrapper.cs
- ContractBase.cs
- Native.cs
- SqlOuterApplyReducer.cs
- FlowNode.cs
- AppSettingsExpressionBuilder.cs
- WorkflowServiceBehavior.cs
- SchemaConstraints.cs
- TypeReference.cs
- CodeGeneratorOptions.cs
- ScrollBarAutomationPeer.cs
- BindableTemplateBuilder.cs
- GridItemCollection.cs
- XamlBrushSerializer.cs
- XslNumber.cs
- SmiGettersStream.cs
- NavigationHelper.cs
- DBParameter.cs
- DataSvcMapFile.cs
- SecurityUtils.cs
- SspiNegotiationTokenProvider.cs
- ObjectSecurity.cs
- AccessedThroughPropertyAttribute.cs
- MaskedTextBoxDesignerActionList.cs
- SelectionItemPattern.cs
- PolyBezierSegmentFigureLogic.cs
- XmlWriterSettings.cs
- securestring.cs