From 4f699afe7a481828cf0ff54217117020cf262a11 Mon Sep 17 00:00:00 2001 From: Evan Husted Date: Sun, 29 Dec 2024 19:13:06 -0600 Subject: [PATCH] misc: Move shortcut files into Avalonia project --- src/Ryujinx.UI.Common/Ryujinx.UI.Common.csproj | 9 --------- src/Ryujinx/Ryujinx.csproj | 9 +++++++++ src/Ryujinx/Utilities/ShortcutHelper.cs | 6 +++--- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/Ryujinx.UI.Common/Ryujinx.UI.Common.csproj b/src/Ryujinx.UI.Common/Ryujinx.UI.Common.csproj index 0a28fddf3..01efe04ba 100644 --- a/src/Ryujinx.UI.Common/Ryujinx.UI.Common.csproj +++ b/src/Ryujinx.UI.Common/Ryujinx.UI.Common.csproj @@ -21,15 +21,6 @@ - - - - - - - - - diff --git a/src/Ryujinx/Ryujinx.csproj b/src/Ryujinx/Ryujinx.csproj index 998257dff..3ddd807e6 100644 --- a/src/Ryujinx/Ryujinx.csproj +++ b/src/Ryujinx/Ryujinx.csproj @@ -128,6 +128,15 @@ + + Assets\ShortcutFiles\shortcut-template.desktop + + + Assets\ShortcutFiles\shortcut-launch-script.sh + + + Assets\ShortcutFiles\shortcut-template.plist + diff --git a/src/Ryujinx/Utilities/ShortcutHelper.cs b/src/Ryujinx/Utilities/ShortcutHelper.cs index a0fb5599a..4923d2598 100644 --- a/src/Ryujinx/Utilities/ShortcutHelper.cs +++ b/src/Ryujinx/Utilities/ShortcutHelper.cs @@ -32,7 +32,7 @@ namespace Ryujinx.Ava.Utilities private static void CreateShortcutLinux(string applicationFilePath, string applicationId, byte[] iconData, string iconPath, string desktopPath, string cleanedAppName) { string basePath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Ryujinx.sh"); - var desktopFile = EmbeddedResources.ReadAllText("Ryujinx.UI.Common/shortcut-template.desktop"); + var desktopFile = EmbeddedResources.ReadAllText("Ryujinx/Assets/ShortcutFiles/shortcut-template.desktop"); iconPath += ".png"; var image = SKBitmap.Decode(iconData); @@ -48,8 +48,8 @@ namespace Ryujinx.Ava.Utilities private static void CreateShortcutMacos(string appFilePath, string applicationId, byte[] iconData, string desktopPath, string cleanedAppName) { string basePath = Path.Combine(AppDomain.CurrentDomain.BaseDirectory, "Ryujinx"); - var plistFile = EmbeddedResources.ReadAllText("Ryujinx.UI.Common/shortcut-template.plist"); - var shortcutScript = EmbeddedResources.ReadAllText("Ryujinx.UI.Common/shortcut-launch-script.sh"); + var plistFile = EmbeddedResources.ReadAllText("Ryujinx/Assets/ShortcutFiles/shortcut-template.plist"); + var shortcutScript = EmbeddedResources.ReadAllText("Ryujinx/Assets/ShortcutFiles/shortcut-launch-script.sh"); // Macos .App folder string contentFolderPath = Path.Combine("/Applications", cleanedAppName + ".app", "Contents"); string scriptFolderPath = Path.Combine(contentFolderPath, "MacOS");