Browse Source

Try styling all windows for Netsparkle

pull/2998/head
Christoph Wille 2 years ago
parent
commit
410e8132c2
  1. 2
      ILSpy/ILSpy.csproj
  2. 6
      ILSpy/MainWindow.xaml.cs

2
ILSpy/ILSpy.csproj

@ -45,7 +45,7 @@ @@ -45,7 +45,7 @@
<PackageReference Include="Microsoft.VisualStudio.Composition" Version="17.4.16" />
<PackageReference Include="DataGridExtensions" Version="2.5.14" />
<PackageReference Include="Microsoft.Xaml.Behaviors.Wpf" Version="1.1.39" />
<PackageReference Include="NetSparkleUpdater.UI.WPF" Version="2.3.0-preview20230606001" />
<PackageReference Include="NetSparkleUpdater.UI.WPF" Version="2.3.0-preview20230606002" />
<PackageReference Include="TomsToolbox.Wpf.Styles" Version="$(WpfStylesToolboxVersion)" />
</ItemGroup>

6
ILSpy/MainWindow.xaml.cs

@ -929,6 +929,7 @@ namespace ICSharpCode.ILSpy @@ -929,6 +929,7 @@ namespace ICSharpCode.ILSpy
if (RuntimeInformation.ProcessArchitecture != Architecture.X64)
return;
// This should update with UpdateTheme
bool isLightTheme = ThemeManager.Current.Theme.Contains("light", StringComparison.InvariantCultureIgnoreCase);
var extraHeadAdditionForReleaseNotes = "<style>";
@ -951,7 +952,10 @@ namespace ICSharpCode.ILSpy @@ -951,7 +952,10 @@ namespace ICSharpCode.ILSpy
) {
UIFactory = new UIFactory(Images.ILSpyIcon) {
UseStaticUpdateWindowBackgroundColor = false,
AdditionalReleaseNotesHeaderHTML = extraHeadAdditionForReleaseNotes
AdditionalReleaseNotesHeaderHTML = extraHeadAdditionForReleaseNotes,
ProcessWindowAfterInit = (w, f) => {
w.Style = (Style)Application.Current.FindResource("DialogWindow");
}
},
RelaunchAfterUpdate = false,
CustomInstallerArguments = "",

Loading…
Cancel
Save