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
- ProfileSettings.cs
- ComboBoxRenderer.cs
- ControlBuilderAttribute.cs
- WindowsUserNameSecurityTokenAuthenticator.cs
- PageParserFilter.cs
- IssuanceTokenProviderState.cs
- MergePropertyDescriptor.cs
- RequestBringIntoViewEventArgs.cs
- XmlSchemaAnnotated.cs
- DataGridViewToolTip.cs
- ScriptingWebServicesSectionGroup.cs
- FeedUtils.cs
- IntranetCredentialPolicy.cs
- Duration.cs
- WebPartDisplayModeCancelEventArgs.cs
- XmlElementAttributes.cs
- FileSecurity.cs
- JsonByteArrayDataContract.cs
- metadatamappinghashervisitor.cs
- ComplexBindingPropertiesAttribute.cs
- SqlBulkCopyColumnMapping.cs
- XmlSchemaDatatype.cs
- ToolStripContainer.cs
- PointConverter.cs
- Cursor.cs
- Transform.cs
- InkCanvasSelectionAdorner.cs
- InputLanguageManager.cs
- MenuItemBindingCollection.cs
- EventRecordWrittenEventArgs.cs
- DockPatternIdentifiers.cs
- RefType.cs
- ComNativeDescriptor.cs
- ToolStripSeparator.cs
- Calendar.cs
- FileStream.cs
- RuleAttributes.cs
- InstallerTypeAttribute.cs
- UmAlQuraCalendar.cs
- DecimalConstantAttribute.cs
- DocumentXPathNavigator.cs
- Item.cs
- InvokeSchedule.cs
- Opcode.cs
- coordinatorscratchpad.cs
- CodeCommentStatementCollection.cs
- ParallelQuery.cs
- GenericTypeParameterBuilder.cs
- TextDecoration.cs
- XmlSchemaRedefine.cs
- DbExpressionRules.cs
- exports.cs
- ListViewEditEventArgs.cs
- StatusStrip.cs
- PropertyGrid.cs
- RtfToXamlLexer.cs
- BitmapEffectDrawingContextWalker.cs
- GenericTypeParameterConverter.cs
- DoubleCollection.cs
- DocumentationServerProtocol.cs
- Directory.cs
- DrawingServices.cs
- SafeThemeHandle.cs
- ToolStripPanelRenderEventArgs.cs
- ISSmlParser.cs
- DataContractSet.cs
- WebHostScriptMappingsInstallComponent.cs
- TailCallAnalyzer.cs
- CommandArguments.cs
- AutoGeneratedFieldProperties.cs
- UiaCoreProviderApi.cs
- XmlChildNodes.cs
- EncryptedType.cs
- ControlCollection.cs
- keycontainerpermission.cs
- mil_sdk_version.cs
- EtwTrackingBehaviorElement.cs
- Content.cs
- Switch.cs
- CodeTypeMember.cs
- TableCellCollection.cs
- ThreadAbortException.cs
- RuleSetReference.cs
- DataGridCellEditEndingEventArgs.cs
- BoundPropertyEntry.cs
- WinEventHandler.cs
- PrePostDescendentsWalker.cs
- MultitargetingHelpers.cs
- UriTemplateLiteralQueryValue.cs
- BamlLocalizer.cs
- XmlSchemaIdentityConstraint.cs
- IisTraceWebEventProvider.cs
- ColumnWidthChangingEvent.cs
- AgileSafeNativeMemoryHandle.cs
- HelloMessageApril2005.cs
- AspNetPartialTrustHelpers.cs
- SharedStatics.cs
- Choices.cs
- Evidence.cs
- Page.cs