mirror of
https://github.com/AyuGram/AyuGramDesktop.git
synced 2025-06-05 06:33:57 +02:00
Use ExecutablePathForShortcuts in PortalAutostart
This commit is contained in:
parent
0df8864ae0
commit
296e8c1ab1
1 changed files with 3 additions and 2 deletions
|
@ -60,7 +60,8 @@ using namespace Platform;
|
||||||
using Platform::internal::WaylandIntegration;
|
using Platform::internal::WaylandIntegration;
|
||||||
|
|
||||||
void PortalAutostart(bool enabled, Fn<void(bool)> done) {
|
void PortalAutostart(bool enabled, Fn<void(bool)> done) {
|
||||||
if (cExeName().isEmpty()) {
|
const auto executable = ExecutablePathForShortcuts();
|
||||||
|
if (executable.isEmpty()) {
|
||||||
if (done) {
|
if (done) {
|
||||||
done(false);
|
done(false);
|
||||||
}
|
}
|
||||||
|
@ -149,7 +150,7 @@ void PortalAutostart(bool enabled, Fn<void(bool)> done) {
|
||||||
|
|
||||||
|
|
||||||
std::vector<std::string> commandline;
|
std::vector<std::string> commandline;
|
||||||
commandline.push_back(cExeName().toStdString());
|
commandline.push_back(executable.toStdString());
|
||||||
if (Core::Launcher::Instance().customWorkingDir()) {
|
if (Core::Launcher::Instance().customWorkingDir()) {
|
||||||
commandline.push_back("-workdir");
|
commandline.push_back("-workdir");
|
||||||
commandline.push_back(cWorkingDir().toStdString());
|
commandline.push_back(cWorkingDir().toStdString());
|
||||||
|
|
Loading…
Add table
Reference in a new issue