Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Automation / Peers / DataGridRowHeaderAutomationPeer.cs / 1305600 / DataGridRowHeaderAutomationPeer.cs
using System; using System.Collections.Generic; using System.Windows.Automation.Provider; using System.Windows.Controls; using System.Windows.Controls.Primitives; using MS.Internal; namespace System.Windows.Automation.Peers { ////// AutomationPeer for DataGridRowHeader /// public sealed class DataGridRowHeaderAutomationPeer : ButtonBaseAutomationPeer { #region Constructors ////// AutomationPeer for DataGridRowHeader /// /// DataGridRowHeader public DataGridRowHeaderAutomationPeer(DataGridRowHeader owner) : base(owner) { } #endregion #region AutomationPeer Overrides ////// Gets the control type for the element that is associated with the UI Automation peer. /// ///The control type. protected override AutomationControlType GetAutomationControlTypeCore() { return AutomationControlType.HeaderItem; } ////// Called by GetClassName that gets a human readable name that, in addition to AutomationControlType, /// differentiates the control represented by this AutomationPeer. /// ///The string that contains the name. protected override string GetClassNameCore() { return Owner.GetType().Name; } ////// Gets a value that specifies whether the element is a content element. /// ///true if the element is a content element; otherwise false protected override bool IsContentElementCore() { return false; } /// override protected bool IsOffscreenCore() { if (!Owner.IsVisible) return true; Rect boundingRect = CalculateVisibleBoundingRect(); return DoubleUtil.AreClose(boundingRect, Rect.Empty) || DoubleUtil.AreClose(boundingRect.Height, 0.0) || DoubleUtil.AreClose(boundingRect.Width, 0.0); } #endregion } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. using System; using System.Collections.Generic; using System.Windows.Automation.Provider; using System.Windows.Controls; using System.Windows.Controls.Primitives; using MS.Internal; namespace System.Windows.Automation.Peers { ////// AutomationPeer for DataGridRowHeader /// public sealed class DataGridRowHeaderAutomationPeer : ButtonBaseAutomationPeer { #region Constructors ////// AutomationPeer for DataGridRowHeader /// /// DataGridRowHeader public DataGridRowHeaderAutomationPeer(DataGridRowHeader owner) : base(owner) { } #endregion #region AutomationPeer Overrides ////// Gets the control type for the element that is associated with the UI Automation peer. /// ///The control type. protected override AutomationControlType GetAutomationControlTypeCore() { return AutomationControlType.HeaderItem; } ////// Called by GetClassName that gets a human readable name that, in addition to AutomationControlType, /// differentiates the control represented by this AutomationPeer. /// ///The string that contains the name. protected override string GetClassNameCore() { return Owner.GetType().Name; } ////// Gets a value that specifies whether the element is a content element. /// ///true if the element is a content element; otherwise false protected override bool IsContentElementCore() { return false; } /// override protected bool IsOffscreenCore() { if (!Owner.IsVisible) return true; Rect boundingRect = CalculateVisibleBoundingRect(); return DoubleUtil.AreClose(boundingRect, Rect.Empty) || DoubleUtil.AreClose(boundingRect.Height, 0.0) || DoubleUtil.AreClose(boundingRect.Width, 0.0); } #endregion } } // 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
- HWStack.cs
- BatchStream.cs
- DbConnectionStringCommon.cs
- DesignerTransactionCloseEvent.cs
- CoTaskMemUnicodeSafeHandle.cs
- KeyBinding.cs
- VisualTreeHelper.cs
- MsmqIntegrationBindingElement.cs
- RepeaterItem.cs
- TcpClientSocketManager.cs
- SubMenuStyleCollection.cs
- WebPartConnection.cs
- MarkupCompiler.cs
- CodeAttributeDeclarationCollection.cs
- UpdateInfo.cs
- FileNotFoundException.cs
- SecurityChannelFaultConverter.cs
- _NTAuthentication.cs
- ValidatorUtils.cs
- AudioException.cs
- bindurihelper.cs
- ValueOfAction.cs
- RectAnimationClockResource.cs
- TempFiles.cs
- XmlValidatingReaderImpl.cs
- CriticalHandle.cs
- XmlElementAttributes.cs
- FormViewModeEventArgs.cs
- MutexSecurity.cs
- DeliveryStrategy.cs
- BaseAsyncResult.cs
- _FtpDataStream.cs
- MemberAccessException.cs
- HelpProvider.cs
- XPathNodePointer.cs
- XmlSecureResolver.cs
- ObfuscateAssemblyAttribute.cs
- LogSwitch.cs
- ClientSettingsSection.cs
- DoubleAnimationBase.cs
- CacheMode.cs
- ProxyWebPartManager.cs
- ToolboxComponentsCreatingEventArgs.cs
- DataSourceXmlElementAttribute.cs
- PlainXmlDeserializer.cs
- GrammarBuilderPhrase.cs
- ApplicationException.cs
- BuildTopDownAttribute.cs
- TextEndOfParagraph.cs
- SecurityContext.cs
- VectorAnimation.cs
- TreeNodeStyle.cs
- ISFClipboardData.cs
- BoundPropertyEntry.cs
- WebPartExportVerb.cs
- RadioButtonList.cs
- XhtmlBasicControlAdapter.cs
- SqlGenerator.cs
- FileFormatException.cs
- ActivityTypeCodeDomSerializer.cs
- ExpressionBuilderCollection.cs
- WindowsComboBox.cs
- webproxy.cs
- Keywords.cs
- ElapsedEventArgs.cs
- Mappings.cs
- TcpServerChannel.cs
- HashStream.cs
- RootProfilePropertySettingsCollection.cs
- LinqDataSourceContextEventArgs.cs
- WebPartConnection.cs
- XmlParser.cs
- PhoneCall.cs
- ContextMenuStripGroup.cs
- ConnectionStringsExpressionBuilder.cs
- SpeechRecognitionEngine.cs
- ContentAlignmentEditor.cs
- SoapServerProtocol.cs
- ControlBindingsCollection.cs
- StateMachineHelpers.cs
- ZipIOBlockManager.cs
- SmtpNetworkElement.cs
- DataGridViewDataErrorEventArgs.cs
- StrongName.cs
- RoutedEventArgs.cs
- MemoryMappedFile.cs
- Imaging.cs
- GridPattern.cs
- Resources.Designer.cs
- SystemNetworkInterface.cs
- SessionKeyExpiredException.cs
- EntityConnection.cs
- XmlDictionaryWriter.cs
- InstalledFontCollection.cs
- ExpressionPrefixAttribute.cs
- DropDownList.cs
- LogEntryDeserializer.cs
- smtppermission.cs
- IIS7WorkerRequest.cs
- TextFormatterContext.cs