window: Support GTK+'s hide-titlebar-when-maximized hint

For maximized windows, titlebars cannot be used to reposition or
scale the window, so if an application does not use it to convey
useful information (other than the application name), the screen
space occupied by titlebars could be put to better use.
To account for this use case, a setting for requesting that windows'
titlebars should be hidden during maximization has been added to
GTK+, add support for this in the window manager.

https://bugzilla.gnome.org/show_bug.cgi?id=665617
This commit is contained in:
Florian Müllner
2011-10-07 12:45:56 +02:00
parent d64c5bfc11
commit 9729a99ec5
5 changed files with 38 additions and 2 deletions

View File

@@ -10539,7 +10539,8 @@ meta_window_get_frame_type (MetaWindow *window)
/* can't add border if undecorated */
return META_FRAME_TYPE_LAST;
}
else if (window->border_only && base_type != META_FRAME_TYPE_ATTACHED)
else if ((window->border_only && base_type != META_FRAME_TYPE_ATTACHED) ||
(window->hide_titlebar_when_maximized && META_WINDOW_MAXIMIZED (window)))
{
/* override base frame type */
return META_FRAME_TYPE_BORDER;