mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2025-05-17 17:05:02 +00:00
Fix the "Open Update Folder" for folders ending with "-patch" (#2712)
* fix open update folder * Update gui_context_menus.h
This commit is contained in:
parent
be7d646e83
commit
df9151481c
1 changed files with 4 additions and 2 deletions
|
@ -141,14 +141,16 @@ public:
|
||||||
Common::FS::PathToQString(open_update_path, m_games[itemID].path);
|
Common::FS::PathToQString(open_update_path, m_games[itemID].path);
|
||||||
open_update_path += "-UPDATE";
|
open_update_path += "-UPDATE";
|
||||||
if (!std::filesystem::exists(Common::FS::PathFromQString(open_update_path))) {
|
if (!std::filesystem::exists(Common::FS::PathFromQString(open_update_path))) {
|
||||||
|
QDesktopServices::openUrl(QUrl::fromLocalFile(open_update_path));
|
||||||
|
} else {
|
||||||
Common::FS::PathToQString(open_update_path, m_games[itemID].path);
|
Common::FS::PathToQString(open_update_path, m_games[itemID].path);
|
||||||
open_update_path += "-patch";
|
open_update_path += "-patch";
|
||||||
if (!std::filesystem::exists(Common::FS::PathFromQString(open_update_path))) {
|
if (!std::filesystem::exists(Common::FS::PathFromQString(open_update_path))) {
|
||||||
|
QDesktopServices::openUrl(QUrl::fromLocalFile(open_update_path));
|
||||||
|
} else {
|
||||||
QMessageBox::critical(nullptr, tr("Error"),
|
QMessageBox::critical(nullptr, tr("Error"),
|
||||||
QString(tr("This game has no update folder to open!")));
|
QString(tr("This game has no update folder to open!")));
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
QDesktopServices::openUrl(QUrl::fromLocalFile(open_update_path));
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue