Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / Orcas / QFE / wpf / src / Framework / System / Windows / Automation / Peers / ItemsControlAutomationPeer.cs / 1 / ItemsControlAutomationPeer.cs
using System;
using System.Collections;
using System.Collections.ObjectModel;
using System.Collections.Generic;
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.Controls.Primitives;
using System.Windows.Data;
using System.Windows.Interop;
using System.Windows.Media;
using MS.Internal;
using MS.Internal.Hashing.PresentationFramework; // HashHelper
using MS.Win32;
namespace System.Windows.Automation.Peers
{
///
public abstract class ItemsControlAutomationPeer : FrameworkElementAutomationPeer
{
///
protected ItemsControlAutomationPeer(ItemsControl owner): base(owner)
{}
///
override public object GetPattern(PatternInterface patternInterface)
{
if(patternInterface == PatternInterface.Scroll)
{
ItemsControl owner = (ItemsControl)Owner;
if(owner.ScrollHost != null)
{
AutomationPeer scrollPeer = UIElementAutomationPeer.CreatePeerForElement(owner.ScrollHost);
if(scrollPeer != null && scrollPeer is IScrollProvider)
{
scrollPeer.EventsSource = this;
return (IScrollProvider)scrollPeer;
}
}
}
return base.GetPattern(patternInterface);
}
///
protected override List GetChildrenCore()
{
ItemsControl owner = (ItemsControl)Owner;
ItemCollection items = owner.Items;
ItemPeersStorage oldChildren = _dataChildren; //cache the old ones for possible reuse
_dataChildren = new ItemPeersStorage();
if (owner.IsGrouping)
{
CollectionView cv = owner.Items.CollectionView;
ReadOnlyObservableCollection
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- XsdBuilder.cs
- DrawListViewSubItemEventArgs.cs
- SplitContainer.cs
- ConfigurationErrorsException.cs
- TableDetailsCollection.cs
- PasswordDeriveBytes.cs
- TrustManagerMoreInformation.cs
- DateTimeAutomationPeer.cs
- ErrorFormatterPage.cs
- QualifierSet.cs
- TableItemStyle.cs
- ExtensionElement.cs
- DocumentScope.cs
- Point3DCollection.cs
- PersistenceTypeAttribute.cs
- MdiWindowListStrip.cs
- Type.cs
- Event.cs
- SqlDataAdapter.cs
- DbConnectionFactory.cs
- DataGridAddNewRow.cs
- UriTemplateTrieNode.cs
- CompileLiteralTextParser.cs
- ContextMenuStrip.cs
- ThousandthOfEmRealPoints.cs
- PropertyDescriptor.cs
- DbConvert.cs
- EventLogPermissionEntry.cs
- HttpRequestCacheValidator.cs
- WebPartDisplayModeEventArgs.cs
- DelayedRegex.cs
- UniqueConstraint.cs
- OrthographicCamera.cs
- SizeF.cs
- JavaScriptObjectDeserializer.cs
- MessageCredentialType.cs
- NTAccount.cs
- PointLight.cs
- PropertyPath.cs
- XmlSchemaSimpleContentRestriction.cs
- ISessionStateStore.cs
- WindowsListViewItemStartMenu.cs
- EntityConnectionStringBuilder.cs
- BaseEntityWrapper.cs
- TypeElementCollection.cs
- WebPartsPersonalization.cs
- WorkflowServiceHostFactory.cs
- precedingsibling.cs
- HttpBrowserCapabilitiesWrapper.cs
- RelationshipNavigation.cs
- ObjectViewFactory.cs
- FontEmbeddingManager.cs
- controlskin.cs
- ClickablePoint.cs
- RoleManagerEventArgs.cs
- XmlUtf8RawTextWriter.cs
- RelatedCurrencyManager.cs
- ContainerVisual.cs
- TileBrush.cs
- CurrentTimeZone.cs
- OleDbReferenceCollection.cs
- XAMLParseException.cs
- StrokeCollectionConverter.cs
- CapabilitiesAssignment.cs
- TableLayoutColumnStyleCollection.cs
- TrackBarDesigner.cs
- XhtmlBasicValidationSummaryAdapter.cs
- ToggleButton.cs
- XmlLanguage.cs
- SplitContainer.cs
- WorkflowMarkupSerializerMapping.cs
- CompilationAssemblyInstallComponent.cs
- DataAccessor.cs
- _Events.cs
- ClosureBinding.cs
- WorkflowDesigner.cs
- ReachDocumentPageSerializerAsync.cs
- DocumentSequenceHighlightLayer.cs
- OptimizedTemplateContent.cs
- RepeatInfo.cs
- FormParameter.cs
- FlagsAttribute.cs
- ReflectionServiceProvider.cs
- OperationPickerDialog.cs
- Label.cs
- _CookieModule.cs
- ISSmlParser.cs
- ADRoleFactory.cs
- BuilderPropertyEntry.cs
- ParameterBuilder.cs
- AuthenticationException.cs
- ExpressionTextBoxAutomationPeer.cs
- PageSetupDialog.cs
- CodeGen.cs
- WindowsTab.cs
- CodeExpressionStatement.cs
- Utility.cs
- SkewTransform.cs
- GatewayIPAddressInformationCollection.cs
- LinkedList.cs