Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Automation / Peers / DataGridColumnHeaderAutomationPeer.cs / 1305600 / DataGridColumnHeaderAutomationPeer.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 DataGridColumnHeader
///
public sealed class DataGridColumnHeaderAutomationPeer : ButtonBaseAutomationPeer
{
#region Constructors
///
/// AutomationPeer for DataGridColumnHeader
///
/// DataGridColumnHeader
public DataGridColumnHeaderAutomationPeer(DataGridColumnHeader 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;
}
///
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 DataGridColumnHeader
///
public sealed class DataGridColumnHeaderAutomationPeer : ButtonBaseAutomationPeer
{
#region Constructors
///
/// AutomationPeer for DataGridColumnHeader
///
/// DataGridColumnHeader
public DataGridColumnHeaderAutomationPeer(DataGridColumnHeader 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;
}
///
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
- RectangleGeometry.cs
- UInt16.cs
- InteropBitmapSource.cs
- MexBindingElement.cs
- ActionMessageFilterTable.cs
- GenericEnumerator.cs
- WebPartManager.cs
- Parameter.cs
- UTF7Encoding.cs
- CannotUnloadAppDomainException.cs
- EpmSyndicationContentSerializer.cs
- TypedDataSourceCodeGenerator.cs
- BuildManagerHost.cs
- AppDomainAttributes.cs
- LZCodec.cs
- TextElement.cs
- StreamWithDictionary.cs
- oledbmetadatacolumnnames.cs
- tabpagecollectioneditor.cs
- TextServicesContext.cs
- ServicesUtilities.cs
- MatrixCamera.cs
- Substitution.cs
- TextTabProperties.cs
- WorkflowDesignerMessageFilter.cs
- AnonymousIdentificationModule.cs
- PolyLineSegment.cs
- DataRowCollection.cs
- OperationAbortedException.cs
- LocalizedNameDescriptionPair.cs
- TagNameToTypeMapper.cs
- _CacheStreams.cs
- EdmProviderManifest.cs
- ExtractorMetadata.cs
- Profiler.cs
- Utilities.cs
- MethodBuilder.cs
- StdRegProviderWrapper.cs
- LinqTreeNodeEvaluator.cs
- ResourceIDHelper.cs
- DesignerActionHeaderItem.cs
- Automation.cs
- TableStyle.cs
- Console.cs
- UpdatePanelTriggerCollection.cs
- WithStatement.cs
- DeferredElementTreeState.cs
- ExclusiveNamedPipeTransportManager.cs
- DataGridView.cs
- BuildProvidersCompiler.cs
- PrePrepareMethodAttribute.cs
- RuntimeConfig.cs
- CompilationUnit.cs
- TextBreakpoint.cs
- MatrixTransform3D.cs
- Context.cs
- CodeCommentStatementCollection.cs
- WebPartConnectionsCancelEventArgs.cs
- Command.cs
- TransactionsSectionGroup.cs
- MessageDirection.cs
- RegexCapture.cs
- TextFragmentEngine.cs
- _SafeNetHandles.cs
- documentsequencetextcontainer.cs
- HttpHandlerAction.cs
- PreProcessInputEventArgs.cs
- KeyInterop.cs
- DataGridViewCellLinkedList.cs
- FrameworkContentElementAutomationPeer.cs
- BitmapEffectDrawing.cs
- IUnknownConstantAttribute.cs
- CharConverter.cs
- SamlConstants.cs
- __Filters.cs
- ByteConverter.cs
- DockPattern.cs
- Config.cs
- MailMessage.cs
- DesignerEditorPartChrome.cs
- GridProviderWrapper.cs
- Classification.cs
- XsdValidatingReader.cs
- ParameterReplacerVisitor.cs
- ReferenceConverter.cs
- BindStream.cs
- IntegerValidatorAttribute.cs
- CompoundFileIOPermission.cs
- FileDialog.cs
- UpdatePanelTriggerCollection.cs
- DocumentPaginator.cs
- EventProviderWriter.cs
- BinaryOperationBinder.cs
- XmlTextReaderImpl.cs
- SafeMILHandleMemoryPressure.cs
- AccessDataSourceView.cs
- TextElementEnumerator.cs
- JsonReaderDelegator.cs
- CompilerGlobalScopeAttribute.cs
- BulletedListDesigner.cs