From 79ba85aa7af6bdd1be34ac6f99889c2240d53b3a Mon Sep 17 00:00:00 2001 From: Yoshi Askharoun Date: Mon, 19 Dec 2022 22:47:48 -0600 Subject: [PATCH] Added .NET Framework 4.0 build to host apps --- ZuneHost.Wpf/MainWindow.xaml.cs | 9 +++++++-- ZuneHost.Wpf/ZuneHost.Wpf.csproj | 3 ++- ZuneHost/ZuneHost.csproj | 3 ++- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/ZuneHost.Wpf/MainWindow.xaml.cs b/ZuneHost.Wpf/MainWindow.xaml.cs index c97df84..9198169 100644 --- a/ZuneHost.Wpf/MainWindow.xaml.cs +++ b/ZuneHost.Wpf/MainWindow.xaml.cs @@ -64,7 +64,9 @@ namespace ZuneHost.Wpf Directory.Delete(decompResultDir, true); Directory.CreateDirectory(decompResultDir); IrisApp.DebugSettings.DecompileResults.CollectionChanged += DecompileResults_CollectionChanged; +#if NET6_0_OR_GREATER || NETCOREAPP3_1_OR_GREATER IrisApp.DebugSettings.Bridge.InterpreterStep += Bridge_InterpreterStep; +#endif } IrisApp.DebugSettings.GenerateDataMappingModels = false; @@ -76,8 +78,11 @@ namespace ZuneHost.Wpf IrisApp.DebugSettings.DataMappingModels.CollectionChanged += DataMappingModels_CollectionChanged; } + // Set decompiler for marketplace track preview menu item + IrisApp.DebugSettings.Breakpoints.Add("res://ZuneMarketplaceResources!SelectionActions.uix (121, 14)"); + IntPtr hWnd = new System.Windows.Interop.WindowInteropHelper(this).Handle; - Thread zuneThread = new Thread(new ThreadStart(() => + Thread zuneThread = new(new ThreadStart(() => { IrisApp.Initialized += delegate { @@ -94,7 +99,7 @@ namespace ZuneHost.Wpf foreach (var result in e.NewItems.Cast()) { int count = 0; - string ctx = Path.GetFileName(result.Context[(result.Context.LastIndexOf('/') + 1)..]); + string ctx = Path.GetFileName(result.Context.Substring(result.Context.LastIndexOf('/') + 1)); FileInfo file = new(Path.Combine(decompResultDir, ctx + ".uix")); while (file.Exists) diff --git a/ZuneHost.Wpf/ZuneHost.Wpf.csproj b/ZuneHost.Wpf/ZuneHost.Wpf.csproj index 25cb6cb..afe3822 100644 --- a/ZuneHost.Wpf/ZuneHost.Wpf.csproj +++ b/ZuneHost.Wpf/ZuneHost.Wpf.csproj @@ -2,7 +2,8 @@ WinExe - net6.0-windows10.0.22000 + net6.0-windows10.0.22000;net40 + 11.0 true Assets\ZuneFluentGem.ico diff --git a/ZuneHost/ZuneHost.csproj b/ZuneHost/ZuneHost.csproj index e5bfe8a..1b5b0af 100644 --- a/ZuneHost/ZuneHost.csproj +++ b/ZuneHost/ZuneHost.csproj @@ -2,8 +2,9 @@ Exe - net6.0-windows10.0.22000;net6.0 + net6.0-windows10.0.22000;net6.0;net40 AnyCPU;x64;x86;ARM32 + 11.0