34 lines
1016 B
Diff
34 lines
1016 B
Diff
changeset: 659713:2cf85addfa7a
|
|
tag: tip
|
|
parent: 659711:25045b498bff
|
|
user: stransky <stransky@redhat.com>
|
|
date: Tue Apr 11 16:34:42 2023 +0200
|
|
files: widget/gtk/nsWindow.cpp
|
|
description:
|
|
Bug 1827429 [Wayland] Call NotifyOcclusionState(OcclusionState::VISIBLE) from nsWindow::OnExposeEvent() as we know the window is visible r?emilio
|
|
|
|
Differential Revision: https://phabricator.services.mozilla.com/D175138
|
|
|
|
|
|
diff --git a/widget/gtk/nsWindow.cpp b/widget/gtk/nsWindow.cpp
|
|
--- a/widget/gtk/nsWindow.cpp
|
|
+++ b/widget/gtk/nsWindow.cpp
|
|
@@ -3730,9 +3730,14 @@ void nsWindow::CreateCompositorVsyncDisp
|
|
|
|
gboolean nsWindow::OnExposeEvent(cairo_t* cr) {
|
|
// Send any pending resize events so that layout can update.
|
|
- // May run event loop.
|
|
+ // May run event loop and destroy us.
|
|
MaybeDispatchResized();
|
|
-
|
|
+ if (mIsDestroyed) {
|
|
+ return FALSE;
|
|
+ }
|
|
+
|
|
+ // This might destroy us.
|
|
+ NotifyOcclusionState(OcclusionState::VISIBLE);
|
|
if (mIsDestroyed) {
|
|
return FALSE;
|
|
}
|
|
|