X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/a19f29f4e5f4f942713502f56f5266937722be96..579eadeb6ddffb03e8043090a330c6dba0717299:/src/main.cpp diff --git a/src/main.cpp b/src/main.cpp index a45083e40..a9b85dbcc 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -35,6 +35,14 @@ #include #include +#if HAVE_X11 +#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) +#include +#else +#include +#endif +#endif + #ifndef Q_OS_WIN #include #endif @@ -181,6 +189,10 @@ int main(int argc, char **argv) if (KWindowSystem::isPlatformWayland()) { token = qEnvironmentVariable("XDG_ACTIVATION_TOKEN"); qunsetenv("XDG_ACTIVATION_TOKEN"); + } else if (KWindowSystem::isPlatformX11()) { +#if HAVE_X11 + token = QX11Info::nextStartupId(); +#endif } if (Dolphin::attachToExistingInstance(urls, openFiles, splitView, QString(), token)) {