forked from AuroraMiddleware/gtk
csd: Implement hide-titlebar-when-maximized
This commit is contained in:
parent
acf56b6cb3
commit
e47689d9ea
@ -4998,13 +4998,19 @@ static void
|
|||||||
update_window_buttons (GtkWindow *window)
|
update_window_buttons (GtkWindow *window)
|
||||||
{
|
{
|
||||||
GtkWindowPrivate *priv = window->priv;
|
GtkWindowPrivate *priv = window->priv;
|
||||||
|
GdkWindow *win;
|
||||||
|
gboolean maximized = FALSE;
|
||||||
|
|
||||||
if (priv->custom_title)
|
if (priv->custom_title)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
win = gtk_widget_get_window (GTK_WIDGET (window));
|
||||||
|
if (win != NULL)
|
||||||
|
maximized = gdk_window_get_state (win) & GDK_WINDOW_STATE_MAXIMIZED;
|
||||||
if (priv->decorated &&
|
if (priv->decorated &&
|
||||||
priv->client_decorated &&
|
priv->client_decorated &&
|
||||||
!priv->fullscreen &&
|
!priv->fullscreen &&
|
||||||
|
!(maximized && priv->hide_titlebar_when_maximized) &&
|
||||||
priv->title_box != NULL)
|
priv->title_box != NULL)
|
||||||
{
|
{
|
||||||
gchar *layout_desc;
|
gchar *layout_desc;
|
||||||
|
Loading…
Reference in New Issue
Block a user