From 7a61907a41fe411d7cd61a181c402ea9a7b782d4 Mon Sep 17 00:00:00 2001 From: kervala Date: Sun, 16 Oct 2016 17:22:51 +0200 Subject: [PATCH] Fixed: Display all executables under OS X and Linux --- .../client/ryzom_installer/src/profilesdialog.cpp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/code/ryzom/tools/client/ryzom_installer/src/profilesdialog.cpp b/code/ryzom/tools/client/ryzom_installer/src/profilesdialog.cpp index 4aa0b2f27..f15b44a45 100644 --- a/code/ryzom/tools/client/ryzom_installer/src/profilesdialog.cpp +++ b/code/ryzom/tools/client/ryzom_installer/src/profilesdialog.cpp @@ -269,7 +269,18 @@ void CProfilesDialog::onExecutableBrowseClicked() if (executable.isEmpty()) executable = defaultExecutable; - executable = QFileDialog::getOpenFileName(this, tr("Please choose Ryzom client executable to launch"), executable, tr("Executables (*.exe)")); + QString filter; + +#ifdef Q_OS_WIN32 + filter = tr("Executables (*.exe)"); +#else + filter = tr("Executables (*)"); +#endif + + QFileDialog open; + open.setFilter(QDir::Executable | QDir::NoDotAndDotDot | QDir::Files); + + executable = open.getOpenFileName(this, tr("Please choose Ryzom client executable to launch"), executable, filter); if (executable.isEmpty()) return;