Load widget cache mode

This commit is contained in:
Martin Stransky 2019-09-18 08:35:58 +02:00
parent fb305223b0
commit 6072729df1

View File

@ -62,7 +62,7 @@ diff -up firefox-69.0/widget/gtk/nsWaylandDisplay.h.mozilla-1577024 firefox-69.0
void WaylandDispatchDisplays();
diff -up firefox-69.0/widget/gtk/WindowSurfaceWayland.cpp.mozilla-1577024 firefox-69.0/widget/gtk/WindowSurfaceWayland.cpp
--- firefox-69.0/widget/gtk/WindowSurfaceWayland.cpp.mozilla-1577024 2019-09-17 21:09:15.820764577 +0200
+++ firefox-69.0/widget/gtk/WindowSurfaceWayland.cpp 2019-09-17 21:09:15.822764568 +0200
+++ firefox-69.0/widget/gtk/WindowSurfaceWayland.cpp 2019-09-18 08:34:50.568111279 +0200
@@ -192,7 +192,7 @@ It owns wl_buffer object, owns WaylandDM
(which provides the DMA Buffer) and ties them together.
@ -72,14 +72,19 @@ diff -up firefox-69.0/widget/gtk/WindowSurfaceWayland.cpp.mozilla-1577024 firefo
*/
diff -up firefox-69.0/modules/libpref/init/all.js.old firefox-69.0/modules/libpref/init/all.js
--- firefox-69.0/modules/libpref/init/all.js.old 2019-09-17 21:14:06.794677172 +0200
+++ firefox-69.0/modules/libpref/init/all.js 2019-09-17 21:14:33.030571836 +0200
@@ -4807,6 +4807,7 @@ pref("widget.content.allow-gtk-dark-them
#endif
#ifdef MOZ_WAYLAND
pref("widget.wayland_dmabuf_backend.enabled", false);
+pref("widget.wayland_cache_mode", 0);
#endif
@@ -519,9 +519,11 @@ WindowSurfaceWayland::WindowSurfaceWayla
mBufferNeedsClear(false),
mIsMainThread(NS_IsMainThread()),
mNeedScaleFactorUpdate(true) {
- for (int i = 0; i < BACK_BUFFER_NUM; i++) mBackupBuffer[i] = nullptr;
- mRenderingCacheMode = CACHE_ALL;
-
+ for (int i = 0; i < BACK_BUFFER_NUM; i++) {
+ mBackupBuffer[i] = nullptr;
+ }
+ mRenderingCacheMode = static_cast<RenderingCacheMode>(
+ mWaylandDisplay->GetRenderingCacheModePref());
}
pref("widget.window-transforms.disabled", false);
WindowSurfaceWayland::~WindowSurfaceWayland() {
diff -up firefox-69.0/widget/gtk/WindowSurfaceWayland.h.mozilla-1577024 firefox-69.0/widget/gtk/WindowSurfaceWayland.h