зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1693460 [Linux] Always check GTK_CSD variable and use client decorations on Elementary OS, r=jhorak
Differential Revision: https://phabricator.services.mozilla.com/D107253
This commit is contained in:
Родитель
f95c55540b
Коммит
7ae7603cfa
|
@ -8171,12 +8171,10 @@ nsWindow::GtkWindowDecoration nsWindow::GetSystemGtkWindowDecoration() {
|
|||
// GTK_CSD forces CSD mode - use also CSD because window manager
|
||||
// decorations does not work with CSD.
|
||||
// We check GTK_CSD as well as gtk_window_should_use_csd() does.
|
||||
if (sGtkWindowDecoration == GTK_DECORATION_SYSTEM) {
|
||||
const char* csdOverride = getenv("GTK_CSD");
|
||||
if (csdOverride && atoi(csdOverride)) {
|
||||
sGtkWindowDecoration = GTK_DECORATION_CLIENT;
|
||||
return sGtkWindowDecoration;
|
||||
}
|
||||
const char* csdOverride = getenv("GTK_CSD");
|
||||
if (csdOverride && atoi(csdOverride)) {
|
||||
sGtkWindowDecoration = GTK_DECORATION_CLIENT;
|
||||
return sGtkWindowDecoration;
|
||||
}
|
||||
|
||||
const char* currentDesktop = getenv("XDG_CURRENT_DESKTOP");
|
||||
|
@ -8212,7 +8210,7 @@ nsWindow::GtkWindowDecoration nsWindow::GetSystemGtkWindowDecoration() {
|
|||
sGtkWindowDecoration = GTK_DECORATION_SYSTEM;
|
||||
// Elementary OS
|
||||
} else if (strstr(currentDesktop, "Pantheon") != nullptr) {
|
||||
sGtkWindowDecoration = GTK_DECORATION_SYSTEM;
|
||||
sGtkWindowDecoration = GTK_DECORATION_CLIENT;
|
||||
} else if (strstr(currentDesktop, "LXQt") != nullptr) {
|
||||
sGtkWindowDecoration = GTK_DECORATION_SYSTEM;
|
||||
} else if (strstr(currentDesktop, "Deepin") != nullptr) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче