зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1740897 [X11] Make parent container of D&D popup transparent to avoid flickering, r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D131252
This commit is contained in:
Родитель
a1427f1f0b
Коммит
664251da5a
|
@ -5252,13 +5252,22 @@ void nsWindow::ConfigureGdkWindow() {
|
|||
}
|
||||
#endif
|
||||
|
||||
if (mIsDragPopup && GdkIsWaylandDisplay()) {
|
||||
GtkWidget* parent = gtk_widget_get_parent(mShell);
|
||||
if (parent) {
|
||||
GtkWidgetDisableUpdates(parent);
|
||||
if (mIsDragPopup) {
|
||||
if (GdkIsWaylandDisplay()) {
|
||||
// Disable painting to the widget on Wayland as we paint directly to the
|
||||
// widget. Wayland compositors does not paint wl_subsurface
|
||||
// of D&D widget.
|
||||
if (GtkWidget* parent = gtk_widget_get_parent(mShell)) {
|
||||
GtkWidgetDisableUpdates(parent);
|
||||
}
|
||||
GtkWidgetDisableUpdates(mShell);
|
||||
GtkWidgetDisableUpdates(GTK_WIDGET(mContainer));
|
||||
} else {
|
||||
// Disable rendering of parent container on X11 to avoid flickering.
|
||||
if (GtkWidget* parent = gtk_widget_get_parent(mShell)) {
|
||||
gtk_window_set_opacity(GTK_WINDOW(parent), 0.0);
|
||||
}
|
||||
}
|
||||
GtkWidgetDisableUpdates(mShell);
|
||||
GtkWidgetDisableUpdates(GTK_WIDGET(mContainer));
|
||||
}
|
||||
|
||||
if (mWindowType == eWindowType_popup) {
|
||||
|
|
Загрузка…
Ссылка в новой задаче