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
- ListBase.cs
- GridViewRow.cs
- filewebresponse.cs
- TdsParserStaticMethods.cs
- DetailsViewCommandEventArgs.cs
- CodeNamespaceCollection.cs
- TriggerAction.cs
- TdsRecordBufferSetter.cs
- RestClientProxyHandler.cs
- StylusPointPropertyInfoDefaults.cs
- ScriptReferenceEventArgs.cs
- SHA384Managed.cs
- EncoderBestFitFallback.cs
- NativeMethods.cs
- SqlEnums.cs
- BindableAttribute.cs
- DocumentPageTextView.cs
- SslStream.cs
- SelectionEditor.cs
- ActivitiesCollection.cs
- ImportContext.cs
- Section.cs
- XNodeNavigator.cs
- HttpCookie.cs
- DataGridViewRowsAddedEventArgs.cs
- DataBoundLiteralControl.cs
- XmlQualifiedNameTest.cs
- AccessDataSource.cs
- HashSet.cs
- TreePrinter.cs
- VirtualPathUtility.cs
- StylusLogic.cs
- SubtreeProcessor.cs
- ClientSession.cs
- PolicyException.cs
- InputReferenceExpression.cs
- XmlNamespaceMappingCollection.cs
- AuthenticationModuleElement.cs
- BooleanFunctions.cs
- SHA256Managed.cs
- StickyNoteContentControl.cs
- SimpleApplicationHost.cs
- ConsoleTraceListener.cs
- TransformerConfigurationWizardBase.cs
- figurelength.cs
- ChangeInterceptorAttribute.cs
- SymmetricAlgorithm.cs
- BitmapMetadataEnumerator.cs
- LinkButton.cs
- AssemblyCache.cs
- ImportOptions.cs
- SerTrace.cs
- EdmFunctionAttribute.cs
- AffineTransform3D.cs
- WsdlHelpGeneratorElement.cs
- SecurityState.cs
- ScriptServiceAttribute.cs
- TableLayoutColumnStyleCollection.cs
- DesignerValidationSummaryAdapter.cs
- DEREncoding.cs
- DetailsViewDeleteEventArgs.cs
- ActivityDesignerHighlighter.cs
- CheckBoxField.cs
- FilteredDataSetHelper.cs
- SiteMapSection.cs
- InteropDesigner.xaml.cs
- SecuritySessionSecurityTokenAuthenticator.cs
- Button.cs
- SpecularMaterial.cs
- ErasingStroke.cs
- StoreItemCollection.cs
- CodeEventReferenceExpression.cs
- XsltSettings.cs
- Accessors.cs
- WindowsScrollBarBits.cs
- WebPartEditorCancelVerb.cs
- SerializationAttributes.cs
- DockAndAnchorLayout.cs
- CheckBoxRenderer.cs
- PointF.cs
- X509AsymmetricSecurityKey.cs
- ConvertBinder.cs
- PageCatalogPart.cs
- ConfigXmlWhitespace.cs
- TakeOrSkipWhileQueryOperator.cs
- storagemappingitemcollection.viewdictionary.cs
- ProvidePropertyAttribute.cs
- ColorConvertedBitmapExtension.cs
- Matrix.cs
- XmlConvert.cs
- LayoutInformation.cs
- ModelTypeConverter.cs
- _NativeSSPI.cs
- XmlElementList.cs
- SingleResultAttribute.cs
- TransformerConfigurationWizardBase.cs
- ExcCanonicalXml.cs
- SequenceQuery.cs
- CrossSiteScriptingValidation.cs
- EdmScalarPropertyAttribute.cs