gdk_display_get_primary_monitor never returns NULL
Steps to reproduce
- Make sure no output is marked as primary (e.g. via
if (gdk_display_get_primary_monitor (gdk_display_get_default ()) == NULL) g_warning ("no primary display configured"); else g_warning ("yay, found a primary display.");
- Note that despite not having a primary output configured in xrandr, the call does not return NULL.
Despite the documentation saying otherwise, gdk_display_get_primary_monitor never returns NULL, even if no primary monitors are defined.
If no primary monitor is defined, NULL should be returned (so panel/dock-like applications know what to do).
None needed (I think everything is fairly clear).