Fixes for linux

This commit is contained in:
boludoz 2023-10-04 02:58:45 -03:00
commit aec95e0200

View file

@ -3025,12 +3025,8 @@ void GMainWindow::OnGameListCreateShortcut(u64 program_id, const QString& game_p
#endif // __linux__ || __FreeBSD__ || _WIN32 #endif // __linux__ || __FreeBSD__ || _WIN32
#if defined(__linux__) || defined(__FreeBSD__) #if defined(__linux__) || defined(__FreeBSD__)
std::string arguments =
if (result == QMessageBox::Yes) { fmt::format("{}-g \"{:s}\"", (result == QMessageBox::Yes) ? "-f " : "", game_path);
const std::string arguments = fmt::format("-f -g \"{:s}\"", game_path);
} else {
const std::string arguments = fmt::format("-g \"{:s}\"", game_path);
}
const std::string comment = const std::string comment =
tr("Start %1 with the yuzu Emulator").arg(QString::fromStdString(title)).toStdString(); tr("Start %1 with the yuzu Emulator").arg(QString::fromStdString(title)).toStdString();
@ -4117,8 +4113,8 @@ bool GMainWindow::CreateShortcut(const std::string& shortcut_path, const std::st
#elif defined(_WIN32) #elif defined(_WIN32)
#include <filesystem> #include <filesystem>
#include <iostream> #include <iostream>
#include <ShlObj.h>
#include <Windows.h> #include <Windows.h>
#include <shobjidl.h>
bool GMainWindow::CreateShortcut(const std::filesystem::path& shortcut_path, bool GMainWindow::CreateShortcut(const std::filesystem::path& shortcut_path,
const std::u8string& comment, const std::u8string& comment,