firefox/mozilla-1522780.patch
2019-02-04 14:31:04 +01:00

25 lines
1.2 KiB
Diff

diff -up firefox-65.0/toolkit/xre/nsAppRunner.cpp.1522780 firefox-65.0/toolkit/xre/nsAppRunner.cpp
--- firefox-65.0/toolkit/xre/nsAppRunner.cpp.1522780 2019-02-04 14:27:16.704591496 +0100
+++ firefox-65.0/toolkit/xre/nsAppRunner.cpp 2019-02-04 14:30:01.869913509 +0100
@@ -3839,12 +3839,14 @@ int XREMain::XRE_mainStartup(bool* aExit
bool disableWayland = true;
#if defined(MOZ_WAYLAND)
- // Make X11 backend the default one.
- // Enable Wayland backend only when GDK_BACKEND is set and
- // Gtk+ >= 3.22 where we can expect recent enough
- // compositor & libwayland interface.
- disableWayland = (PR_GetEnv("GDK_BACKEND") == nullptr) ||
- (gtk_check_version(3, 22, 0) != nullptr);
+ // Enable Wayland on Gtk+ >= 3.22 where we can expect recent enough
+ disableWayland = (gtk_check_version(3, 22, 0) != nullptr);
+ if (!disableWayland) {
+ // Make X11 backend the default one unless MOZ_ENABLE_WAYLAND or
+ // GDK_BACKEND are specified.
+ disableWayland = (PR_GetEnv("GDK_BACKEND") == nullptr) &&
+ (PR_GetEnv("MOZ_ENABLE_WAYLAND") == nullptr);
+ }
#endif
// On Wayland disabled builds read X11 DISPLAY env exclusively
// and don't care about different displays.