window: Don't try to auto-maximize when headless
Automatic maximization is done when a window is almost the size of the work area of a monitor. This makes no sense to try when there is no monitor available, so skip trying to do this when headless. https://bugzilla.gnome.org/show_bug.cgi?id=787637
This commit is contained in:
parent
39aae19ed7
commit
6dd819a61e
@ -2361,7 +2361,10 @@ meta_window_show (MetaWindow *window)
|
|||||||
|
|
||||||
if (!window->placed)
|
if (!window->placed)
|
||||||
{
|
{
|
||||||
if (meta_prefs_get_auto_maximize() && window->showing_for_first_time && window->has_maximize_func)
|
if (window->monitor &&
|
||||||
|
meta_prefs_get_auto_maximize() &&
|
||||||
|
window->showing_for_first_time &&
|
||||||
|
window->has_maximize_func)
|
||||||
{
|
{
|
||||||
MetaRectangle work_area;
|
MetaRectangle work_area;
|
||||||
meta_window_get_work_area_for_monitor (window, window->monitor->number, &work_area);
|
meta_window_get_work_area_for_monitor (window, window->monitor->number, &work_area);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user