Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Framework / System / Windows / Automation / Peers / NavigationWindowAutomationPeer.cs / 1 / NavigationWindowAutomationPeer.cs
using System;
using System.Windows;
using System.Windows.Automation;
using System.Windows.Navigation;
using System.Windows.Interop;
using System.Windows.Media;
using System.ComponentModel;
namespace System.Windows.Automation.Peers
{
///
public class NavigationWindowAutomationPeer : WindowAutomationPeer
{
///
public NavigationWindowAutomationPeer(NavigationWindow owner): base(owner)
{}
///
override protected string GetClassNameCore()
{
return "NavigationWindow";
}
//
[System.Runtime.CompilerServices.MethodImpl(System.Runtime.CompilerServices.MethodImplOptions.NoInlining)]
internal static void RaiseAsyncContentLoadedEvent(AutomationPeer peer, long bytesRead, long maxBytes)
{
double percentComplete = 0d;
AsyncContentLoadedState asyncContentState = AsyncContentLoadedState.Beginning;
if (bytesRead > 0)
{
if (bytesRead < maxBytes)
{
percentComplete = maxBytes > 0 ? (bytesRead * 100d / maxBytes) : 0;
asyncContentState = AsyncContentLoadedState.Progress;
}
else
{
percentComplete = 100d;
asyncContentState = AsyncContentLoadedState.Completed;
}
}
peer.RaiseAsyncContentLoadedEvent(new AsyncContentLoadedEventArgs(asyncContentState, percentComplete));
}
}
}
// 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
- GridViewRowPresenter.cs
- GregorianCalendar.cs
- DateTimeAutomationPeer.cs
- DataRelationCollection.cs
- DbCommandTree.cs
- ContractType.cs
- UpdateCommand.cs
- MailDefinition.cs
- PageWrapper.cs
- TextParagraphProperties.cs
- LinearGradientBrush.cs
- PropertyMap.cs
- ListItemParagraph.cs
- TranslateTransform.cs
- MultilineStringConverter.cs
- ContentTextAutomationPeer.cs
- SchemaImporter.cs
- SqlExpressionNullability.cs
- NetCodeGroup.cs
- Profiler.cs
- NumberSubstitution.cs
- ListViewCommandEventArgs.cs
- OpenTypeLayout.cs
- TypedDataSourceCodeGenerator.cs
- WebBrowserNavigatingEventHandler.cs
- TcpClientCredentialType.cs
- EntityDataSourceUtil.cs
- EventBookmark.cs
- FixedSOMElement.cs
- ObjectStateEntryDbDataRecord.cs
- DataGridColumnHeaderCollection.cs
- RoleGroupCollectionEditor.cs
- SQLDateTime.cs
- XmlSchemaComplexContentRestriction.cs
- Composition.cs
- ImageBrush.cs
- TcpTransportSecurity.cs
- BooleanKeyFrameCollection.cs
- UInt16Storage.cs
- SecondaryViewProvider.cs
- LookupBindingPropertiesAttribute.cs
- BorderGapMaskConverter.cs
- Point3DCollection.cs
- StrokeNode.cs
- Filter.cs
- ScriptingScriptResourceHandlerSection.cs
- WebServiceData.cs
- DLinqTableProvider.cs
- DataGridViewCheckBoxColumn.cs
- BufferedWebEventProvider.cs
- AtomPub10ServiceDocumentFormatter.cs
- MetadataItemEmitter.cs
- TextRangeProviderWrapper.cs
- SelectionItemPattern.cs
- RepeaterItemCollection.cs
- ContainerControl.cs
- CharacterBufferReference.cs
- TdsParser.cs
- precedingsibling.cs
- TypeForwardedFromAttribute.cs
- ResourceWriter.cs
- TextTreeUndoUnit.cs
- TypeSchema.cs
- handlecollector.cs
- ValidateNames.cs
- TargetInvocationException.cs
- ByteAnimation.cs
- ValidatingReaderNodeData.cs
- PropertyGridCommands.cs
- DateTimeEditor.cs
- PanelStyle.cs
- AttachmentCollection.cs
- HwndProxyElementProvider.cs
- TextTreeTextElementNode.cs
- MasterPageParser.cs
- SqlInternalConnection.cs
- DesignUtil.cs
- FrameworkContentElementAutomationPeer.cs
- ImageSource.cs
- SQLChars.cs
- PeerCollaboration.cs
- TTSEngineProxy.cs
- SkewTransform.cs
- IUnknownConstantAttribute.cs
- EdmSchemaError.cs
- DefaultExpressionVisitor.cs
- StateMachine.cs
- util.cs
- ColorBlend.cs
- CompilerGlobalScopeAttribute.cs
- MemberHolder.cs
- ExpressionBuilderCollection.cs
- TextChange.cs
- KoreanLunisolarCalendar.cs
- GridViewItemAutomationPeer.cs
- SurrogateSelector.cs
- SwitchAttribute.cs
- Animatable.cs
- SolidColorBrush.cs
- ParagraphVisual.cs