Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Framework / MS / Internal / AppModel / NavigationHelper.cs / 1305600 / NavigationHelper.cs
using System; using System.Windows; using System.Windows.Navigation; using System.Windows.Controls; using System.Windows.Automation; using System.Windows.Media; using System.Globalization; using System.Diagnostics; using MS.Internal; namespace MS.Internal.AppModel { internal static class NavigationHelper { ////// See INavigatorImpl.FindRootViewer(). /// internal static Visual FindRootViewer(ContentControl navigator, string contentPresenterName) { object content = navigator.Content; if (content == null || content is Visual) return content as Visual; ContentPresenter cp = null; if (navigator.Template != null) { cp = (ContentPresenter)navigator.Template.FindName(contentPresenterName, navigator); } // If null, eitheris not defined in the current template or the template // has not been applied yet. if (cp == null || cp.InternalVisualChildrenCount == 0/*Layout not done yet*/) return null; Visual v = cp.InternalGetVisualChild(0); return v; } }; } // 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
- DataChangedEventManager.cs
- TypeDescriptorFilterService.cs
- FixedTextPointer.cs
- Deflater.cs
- Dispatcher.cs
- UnmanagedMemoryStream.cs
- AutomationProperty.cs
- WaitHandleCannotBeOpenedException.cs
- ValidatorCompatibilityHelper.cs
- X509AudioLogo.cs
- ListBindingConverter.cs
- FixedSOMTable.cs
- sapiproxy.cs
- HttpListenerResponse.cs
- CategoryNameCollection.cs
- MobileContainerDesigner.cs
- DBSqlParserTable.cs
- Input.cs
- ThreadInterruptedException.cs
- UIPermission.cs
- UInt64Converter.cs
- SectionUpdates.cs
- WorkflowItemsPresenter.cs
- Marshal.cs
- SmiXetterAccessMap.cs
- UInt32Storage.cs
- AppAction.cs
- ContentControl.cs
- PriorityQueue.cs
- ColumnMapProcessor.cs
- DelegatingTypeDescriptionProvider.cs
- ObjectHelper.cs
- PanelStyle.cs
- LoginCancelEventArgs.cs
- TextEditorLists.cs
- ColorInterpolationModeValidation.cs
- InternalTypeHelper.cs
- MobileControlsSectionHandler.cs
- XsdCachingReader.cs
- XappLauncher.cs
- IPAddressCollection.cs
- safelink.cs
- AutomationEvent.cs
- AmbientLight.cs
- RouteTable.cs
- altserialization.cs
- WebPartTracker.cs
- WebPartEditorCancelVerb.cs
- XComponentModel.cs
- PlaceHolder.cs
- DiffuseMaterial.cs
- PageEventArgs.cs
- CachingParameterInspector.cs
- SecurityCriticalDataForSet.cs
- VectorAnimationBase.cs
- MasterPageBuildProvider.cs
- DataSourceCache.cs
- SemanticValue.cs
- FlowThrottle.cs
- CipherData.cs
- PeerNode.cs
- BodyWriter.cs
- MsmqIntegrationProcessProtocolHandler.cs
- HttpHeaderCollection.cs
- DriveNotFoundException.cs
- TokenBasedSet.cs
- FormsAuthenticationCredentials.cs
- FileDialog_Vista_Interop.cs
- WebPartConnectionsCloseVerb.cs
- XmlQueryTypeFactory.cs
- ExcCanonicalXml.cs
- ConnectionManagementElement.cs
- RoleManagerSection.cs
- EntityModelSchemaGenerator.cs
- HtmlElement.cs
- SplitterEvent.cs
- ResXResourceReader.cs
- PowerStatus.cs
- StickyNoteHelper.cs
- HandlerBase.cs
- DbConnectionHelper.cs
- GenericWebPart.cs
- ActivationArguments.cs
- ContextMenu.cs
- TabItemWrapperAutomationPeer.cs
- TemplateXamlTreeBuilder.cs
- DynamicResourceExtension.cs
- ToolboxItemAttribute.cs
- AutomationElementCollection.cs
- PolicyException.cs
- TypeUtils.cs
- PointCollection.cs
- OleDbError.cs
- PathFigureCollection.cs
- PopOutPanel.cs
- DesignerSerializationManager.cs
- XomlCompiler.cs
- UriParserTemplates.cs
- ToolStripStatusLabel.cs
- Timeline.cs