mirror of
https://github.com/keepassxreboot/keepassxc.git
synced 2024-12-27 08:19:47 -05:00
Prevent use of wayland theme on Linux
* Wayland theme is buggy yet enforced by default on Qt 5.11+ on Gnome desktop environment * Resolves #2006
This commit is contained in:
parent
7e1b16250c
commit
f446774605
@ -51,6 +51,13 @@ int main(int argc, char** argv)
|
||||
#if QT_VERSION >= QT_VERSION_CHECK(5, 6, 0)
|
||||
QApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
||||
#endif
|
||||
#ifdef Q_OS_LINUX
|
||||
if (qgetenv("XDG_SESSION_TYPE") == QByteArrayLiteral("wayland")) {
|
||||
qWarning() << "Warning: disregarding XDG_SESSION_TYPE=wayland";
|
||||
qWarning() << "To use wayland anyway, please set QT_QPA_PLATFORM=wayland";
|
||||
qunsetenv("XDG_SESSION_TYPE");
|
||||
}
|
||||
#endif
|
||||
|
||||
Application app(argc, argv);
|
||||
Application::setApplicationName("keepassxc");
|
||||
|
Loading…
Reference in New Issue
Block a user