linuxmint/muffin — pull request #149 by mtwebster (2014-05-21 04:48:31+00:00)
Title: constraints.c: Invert some of the logic used to detect a legacy fullscreen window.

This should be checked against as many programs as possible... I'm still trying to figure out if this makes sense or not.

This is to mainly fix Chrome windows going fullscreen. They're normally
self-decorated (there is an option to turn on wm decorations, but irrelevant),
but they don't currently report custom frame extents like gtk3 apps can now.
So they are undecorated (officially, to turn off wm decos), but they don't use
GTK client-side-decorations, or pretend to.

Before client side decorations in GTK, we only checked if the window was decorated.
Chrome failed this check, so the legacy code was skipped, and fullscreen worked fine.

But now currently we have:

if the window is EITHER decorated OR it's not gtk c-s-decorated
treat the window like a legacy app

So it fails the decorated check, but passes the not-gtk-c-s-decorated check,
and gets into the legacy code, breaking the window.

This patch reverses the logic:

if window is NEITHER undecorated NOR gtk-c-s-decorated
treat the window like a legacy app

This grabs windows that pass a decorated check, or a non-gtk-c-s-decorated
check (which is the same as current behavior), but kicks out an undecorated,
non-gtk-c-s-decorated window (like chrome).