Bug 1600414 Use gdk_window_set_geometry_hints() to set geometry hints, r=jhorak

Use gdk_window_set_geometry_hints() instead of gtk_window_set_geometry_hints() as gdk_*
does not set base sizes which breaks KDE and other window managers.

Differential Revision: https://phabricator.services.mozilla.com/D61552

--HG--
extra : moz-landing-system : lando
This commit is contained in:
Martin Stransky 2020-02-05 09:16:44 +00:00
Родитель a205cfcd91
Коммит 638be9db98
2 изменённых файлов: 5 добавлений и 2 удалений

Просмотреть файл

@ -129,6 +129,7 @@ STUB(gdk_window_set_cursor)
STUB(gdk_window_set_debug_updates)
STUB(gdk_window_set_decorations)
STUB(gdk_window_set_events)
STUB(gdk_window_set_geometry_hints)
STUB(gdk_window_set_role)
STUB(gdk_window_set_urgency_hint)
STUB(gdk_window_set_user_data)
@ -525,7 +526,6 @@ STUB(gtk_window_set_accept_focus)
STUB(gtk_window_set_decorated)
STUB(gtk_window_set_deletable)
STUB(gtk_window_set_destroy_with_parent)
STUB(gtk_window_set_geometry_hints)
STUB(gtk_window_set_icon_name)
STUB(gtk_window_set_modal)
STUB(gtk_window_set_skip_taskbar_hint)

Просмотреть файл

@ -1012,7 +1012,10 @@ void nsWindow::ApplySizeConstraints(void) {
hints |= GDK_HINT_ASPECT;
}
gtk_window_set_geometry_hints(GTK_WINDOW(mShell), nullptr, &geometry,
// We use gdk_window_set_geometry_hints() instead of
// gtk_window_set_geometry_hints() as it sets GDK_HINT_BASE_SIZE
// and it breaks KDE and other window managers (Bug 1600414).
gdk_window_set_geometry_hints(gtk_widget_get_window(mShell), &geometry,
GdkWindowHints(hints));
}
}