citra-emu
/
citra-canary
Archived
1
0
Fork 0

Merge pull request #4877 from B3n30/fix_user_dir_on_osx

citra_qt: on osx chdir to bundle dir to allow detection of user folder
This commit is contained in:
James Rowe 2019-08-12 22:59:05 -06:00 committed by GitHub
commit bc945fefec
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 6 additions and 0 deletions

View File

@ -15,6 +15,7 @@
#include <QtGui> #include <QtGui>
#include <QtWidgets> #include <QtWidgets>
#include <fmt/format.h> #include <fmt/format.h>
#include <unistd.h>
#include "citra_qt/aboutdialog.h" #include "citra_qt/aboutdialog.h"
#include "citra_qt/applets/mii_selector.h" #include "citra_qt/applets/mii_selector.h"
#include "citra_qt/applets/swkbd.h" #include "citra_qt/applets/swkbd.h"
@ -1889,6 +1890,11 @@ int main(int argc, char* argv[]) {
QCoreApplication::setOrganizationName("Citra team"); QCoreApplication::setOrganizationName("Citra team");
QCoreApplication::setApplicationName("Citra"); QCoreApplication::setApplicationName("Citra");
#ifdef __APPLE__
std::string bin_path = FileUtil::GetBundleDirectory() + DIR_SEP + "..";
chdir(bin_path.c_str());
#endif
QApplication app(argc, argv); QApplication app(argc, argv);
// Qt changes the locale and causes issues in float conversion using std::to_string() when // Qt changes the locale and causes issues in float conversion using std::to_string() when