Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Framework / MS / Internal / Controls / WebBrowserNavigatingEventHandler.cs / 1 / WebBrowserNavigatingEventHandler.cs
//------------------------------------------------------------------------------
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//
// Description:
// WebBrowserNavigatingEventHandler is used to listen to the
// DWebBrowserEvent2.BeforeNavigate event of the webbrowser control
//
// Copied from WebBrowserNavigatingEventHandlers.cs in winforms
//
// History
// 04/17/05 [....] Created
//
//-----------------------------------------------------------------------------
using System;
using System.ComponentModel;
using System.Diagnostics;
using System.IO;
using System.Security.Permissions;
using System.Security;
using System.Runtime.InteropServices;
using System.Net;
namespace MS.Internal.Controls {
/// Delegate to the WebBrowser Navigating event.
internal delegate void WebBrowserNavigatingEventHandler(object sender, WebBrowserNavigatingEventArgs e);
/// Provides data for the event.
internal class WebBrowserNavigatingEventArgs : CancelEventArgs {
// Not a URI object - as the WEB OC gives this to us.
///
/// Critical: the uri can point to a loose content file in the ClickOnce cache
///
private SecurityCriticalData _browserUri ;
private string _targetFrameName;
/// Creates an instance of the class.
internal WebBrowserNavigatingEventArgs(string url, string targetFrameName) {
_browserUri = new SecurityCriticalData( new Uri(url) ) ;
_targetFrameName = targetFrameName;
}
/// Url the browser is navigating to.
///
/// Critical: Getter is critical because the uri can point to a loose content file in the ClickOnce cache
///
internal Uri Uri
{
[SecurityCritical]
get
{
//WebBrowser.EnsureUrlConnectPermission(url);
return _browserUri.Value;
}
}
// Commented out until it is needed to comply with FXCOP
///// In case an individual frame is about to be navigated, this contains the frame name.
//internal string TargetFrameName
//{
// get
// {
// //WebBrowser.EnsureUrlConnectPermission(url);
// return _targetFrameName;
// }
//}
}
}
// 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
- XmlNavigatorFilter.cs
- TransformCollection.cs
- _MultipleConnectAsync.cs
- SmiRecordBuffer.cs
- Interfaces.cs
- TextTreeInsertElementUndoUnit.cs
- StreamResourceInfo.cs
- PageParserFilter.cs
- PerformanceCountersElement.cs
- LoaderAllocator.cs
- SqlBulkCopy.cs
- DataServiceQueryProvider.cs
- Vector3DValueSerializer.cs
- TypeConverters.cs
- GenerateDerivedKeyRequest.cs
- AssociationTypeEmitter.cs
- TextEditorSelection.cs
- SecurityChannelFactory.cs
- brushes.cs
- MissingSatelliteAssemblyException.cs
- MetadataFile.cs
- Path.cs
- BamlLocalizationDictionary.cs
- BoundsDrawingContextWalker.cs
- HwndSubclass.cs
- QueuedDeliveryRequirementsMode.cs
- VirtualDirectoryMapping.cs
- TemplateControlBuildProvider.cs
- Tablet.cs
- Monitor.cs
- DbUpdateCommandTree.cs
- wgx_render.cs
- AutomationElement.cs
- Span.cs
- StorageInfo.cs
- SecurityRuntime.cs
- ConnectionManagementElementCollection.cs
- RawKeyboardInputReport.cs
- OracleInfoMessageEventArgs.cs
- ColumnHeader.cs
- SQLUtility.cs
- JumpTask.cs
- Aggregates.cs
- SqlUtil.cs
- _ServiceNameStore.cs
- _OSSOCK.cs
- CodeNamespace.cs
- GlyphRun.cs
- CancellationTokenRegistration.cs
- HtmlInputPassword.cs
- DataGridViewSortCompareEventArgs.cs
- NCryptSafeHandles.cs
- sqlser.cs
- RemoveFromCollection.cs
- Crypto.cs
- ParseChildrenAsPropertiesAttribute.cs
- XmlQueryType.cs
- CasesDictionary.cs
- ModelItemImpl.cs
- WindowsTooltip.cs
- JoinTreeSlot.cs
- TableHeaderCell.cs
- OperationExecutionFault.cs
- ListDataHelper.cs
- DataGridCell.cs
- FieldNameLookup.cs
- LocalizableResourceBuilder.cs
- COAUTHIDENTITY.cs
- TimeSpanSecondsOrInfiniteConverter.cs
- Site.cs
- MemberRelationshipService.cs
- KnownColorTable.cs
- SettingsBase.cs
- Terminate.cs
- HttpHandlerActionCollection.cs
- ProcessingInstructionAction.cs
- EmptyEnumerable.cs
- ByteAnimation.cs
- DbgCompiler.cs
- QueryOutputWriter.cs
- ForceCopyBuildProvider.cs
- ContainerAction.cs
- ParallelEnumerableWrapper.cs
- Transform3DCollection.cs
- ButtonBase.cs
- MultiBindingExpression.cs
- indexingfiltermarshaler.cs
- TextFormatterImp.cs
- XmlNotation.cs
- GridEntry.cs
- StdValidatorsAndConverters.cs
- StylusButtonCollection.cs
- XmlAnyElementAttribute.cs
- HttpBrowserCapabilitiesWrapper.cs
- SHA1.cs
- GlyphRun.cs
- HandlerBase.cs
- SynchronizationContext.cs
- BlockingCollection.cs
- WindowsBrush.cs