From 433779080548f2c51efb57eb70fd4f89a7596433 Mon Sep 17 00:00:00 2001 From: h3xds1nz Date: Mon, 30 Sep 2024 23:51:24 +0200 Subject: [PATCH] Final cleanup in AppSecurityManager --- .../Internal/AppModel/AppSecurityManager.cs | 35 +------------------ 1 file changed, 1 insertion(+), 34 deletions(-) diff --git a/src/Microsoft.DotNet.Wpf/src/PresentationFramework/MS/Internal/AppModel/AppSecurityManager.cs b/src/Microsoft.DotNet.Wpf/src/PresentationFramework/MS/Internal/AppModel/AppSecurityManager.cs index 789a4fe3a2a..ff20899e149 100644 --- a/src/Microsoft.DotNet.Wpf/src/PresentationFramework/MS/Internal/AppModel/AppSecurityManager.cs +++ b/src/Microsoft.DotNet.Wpf/src/PresentationFramework/MS/Internal/AppModel/AppSecurityManager.cs @@ -14,18 +14,10 @@ // using System; -using System.Collections; -using System.Diagnostics; -using System.Globalization; -using System.Security; -using Microsoft.Win32; -using System.IO.Packaging; +using MS.Win32; using System.Windows; -using System.Windows.Interop; using MS.Internal.Utility; -using MS.Win32; using System.Runtime.InteropServices; -using MS.Internal.Documents.Application; namespace MS.Internal.AppModel { @@ -38,9 +30,6 @@ enum LaunchResult internal static class AppSecurityManager { - #region Internal Methods - - /// /// Safely launch the browser if you can. /// If you can't demand unmanaged code permisison. @@ -149,27 +138,5 @@ the key used is (supposedly) HKCR\htmlfile\shell\opennew\ddeexec, and its value throw new InvalidOperationException(SR.FailToLaunchDefaultBrowser, new System.ComponentModel.Win32Exception(/*uses the last Win32 error*/)); } - - #endregion Internal Methods - - #region Private Methods - - [ComImport, ComVisible(false), Guid("7b8a2d94-0ac9-11d1-896c-00c04Fb6bfc4")] - internal class InternetSecurityManager { } - - - #endregion Private Methods - - #region Private Fields - - private const string RefererHeader = "Referer: "; - - private const string BrowserOpenCommandLookupKey = "htmlfile\\shell\\open\\command"; - - // Object to be used for locking. Using typeof(Util) causes an FxCop - // violation DoNotLockOnObjectsWithWeakIdentity - private static readonly object _lockObj = new object(); - - #endregion Private Fields } }