Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / System / Windows / Automation / Peers / FlowDocumentPageViewerAutomationPeer.cs / 1305600 / FlowDocumentPageViewerAutomationPeer.cs
//---------------------------------------------------------------------------- // // Copyright (C) Microsoft Corporation. All rights reserved. // // File: FlowDocumentPageViewerAutomationPeer.cs // // Description: AutomationPeer associated with FlowDocumentPageViewer. // //--------------------------------------------------------------------------- using System.Collections.Generic; // Listusing System.Windows.Controls; // FlowDocumentPageViewer using MS.Internal.Documents; // IFlowDocumentView namespace System.Windows.Automation.Peers { /// /// AutomationPeer associated with FlowDocumentPageViewer. /// public class FlowDocumentPageViewerAutomationPeer : DocumentViewerBaseAutomationPeer { ////// Constructor. /// /// Owner of the AutomationPeer. public FlowDocumentPageViewerAutomationPeer(FlowDocumentPageViewer owner) : base(owner) { } ////// ////// /// AutomationPeer associated with DocumentViewerBase returns an AutomationPeer /// for hosted Document and for elements in the style. /// protected override ListGetChildrenCore() { // Get children for all elements in the style. List children = base.GetChildrenCore(); // If the owner is IFlowDocumentViewer, it means that it is embedded inside // FlowDocumentReaer. In this case DocumentAutumationPeer is already exposed. // Hence need to remove it from children collection. if (Owner is IFlowDocumentViewer && children != null && children.Count > 0) { if (children[children.Count-1] is DocumentAutomationPeer) { children.RemoveAt(children.Count - 1); if (children.Count == 0) { children = null; } } } return children; } /// /// protected override string GetClassNameCore() { return "FlowDocumentPageViewer"; } } } // 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
- FormClosingEvent.cs
- TableSectionStyle.cs
- SessionStateModule.cs
- DirectoryNotFoundException.cs
- WebPartConnectionsConfigureVerb.cs
- TdsParserHelperClasses.cs
- Logging.cs
- DynamicValidatorEventArgs.cs
- BufferModesCollection.cs
- SimpleBitVector32.cs
- ProtocolViolationException.cs
- SourceFileBuildProvider.cs
- BinaryConverter.cs
- documentation.cs
- ComponentDispatcherThread.cs
- ColorTransformHelper.cs
- GridViewDeleteEventArgs.cs
- RowToFieldTransformer.cs
- EventProxy.cs
- BufferedReadStream.cs
- ViewStateException.cs
- Bind.cs
- CodeCompileUnit.cs
- TreeNodeCollection.cs
- SkinBuilder.cs
- BooleanKeyFrameCollection.cs
- XmlSchemaObjectCollection.cs
- OdbcCommandBuilder.cs
- DockEditor.cs
- EntityUtil.cs
- Win32MouseDevice.cs
- XamlPathDataSerializer.cs
- ObjectViewFactory.cs
- KeyInstance.cs
- DataGridViewCellFormattingEventArgs.cs
- TransactionProxy.cs
- Group.cs
- TraceUtility.cs
- StructureChangedEventArgs.cs
- XmlTextAttribute.cs
- SqlCacheDependency.cs
- XmlSchemaValidationException.cs
- MatchingStyle.cs
- SmiXetterAccessMap.cs
- ContentValidator.cs
- WebPartCatalogCloseVerb.cs
- OAVariantLib.cs
- CaseInsensitiveHashCodeProvider.cs
- AssociationTypeEmitter.cs
- SocketElement.cs
- WindowsAltTab.cs
- TogglePattern.cs
- HTTPNotFoundHandler.cs
- OdbcCommand.cs
- GlyphRunDrawing.cs
- ParserHooks.cs
- DataGridRowsPresenter.cs
- ColumnCollection.cs
- ManagementPath.cs
- XmlNode.cs
- Tuple.cs
- TextMessageEncodingBindingElement.cs
- XmlSchemaAnyAttribute.cs
- FtpWebRequest.cs
- SqlDependencyUtils.cs
- Exceptions.cs
- TaskFileService.cs
- VolatileResourceManager.cs
- UserMapPath.cs
- AliasedSlot.cs
- CredentialCache.cs
- DataColumnCollection.cs
- DbConnectionPoolGroup.cs
- PageCatalogPart.cs
- ToolZoneDesigner.cs
- ForceCopyBuildProvider.cs
- EventEntry.cs
- RoutedUICommand.cs
- ServiceBehaviorElementCollection.cs
- DetailsViewDeleteEventArgs.cs
- DisplayMemberTemplateSelector.cs
- Quad.cs
- CategoryAttribute.cs
- EditorAttribute.cs
- OracleCommandBuilder.cs
- ProfileSettingsCollection.cs
- DynamicPropertyHolder.cs
- TokenBasedSet.cs
- DataServiceHostFactory.cs
- DataBindingExpressionBuilder.cs
- InterleavedZipPartStream.cs
- RecipientInfo.cs
- TrustManagerPromptUI.cs
- DrawTreeNodeEventArgs.cs
- OracleString.cs
- ToolStrip.cs
- DeclarationUpdate.cs
- QuestionEventArgs.cs
- RadioButton.cs
- ProcessHost.cs