Due to !2056 the monitor config is 2 instead of 4 on the desktop.
However, the constant `Meta.MonitorSwitchConfigType.UNKNOWN` is fixed to
4, and may cause the initial selection to be out of index thus fail to
display the switcher. This replaces the above constant to the actual
length of the switcher items.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2451>
We have made good progress on object literals as well, although there
are still a lot that use the old style, given how ubiquitous object
literals are.
But the needed reindentation isn't overly intrusive, as changes are
limited to the object literals themselves (i.e. they don't affect
surrounding code).
And given that object literals account for quite a bit of the remaining
differences between regular and legacy rules, doing the transition now
is still worthwhile.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2200>
Clutter originally cluttered its namespace with key symbols, before
prefixing all symbols with KEY. We still use the unprefixed symbols
occasionally, replace them so mutter can drop the deprecated symbols.
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/808
Every since commit aa394754, StBoxLayout has supported ClutterActor's
expand/align properties in addition to the container-specific child
properties. Given that that's the only container left with a special
child meta, it's time to fully embrace the generic properties (and
eventually remove the child meta).
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/780
In GNOME-3.24, pressing Super+P or a similar function key would cause
a switch to the next available monitor configuration.
However, in GNOME-3.26, this was reimplemented in mutter and gnome-shell
and the behaviour is now different: pressing Super+P and releasing will
cause no change in montor configuration[1]. In this new design you have
to press Super+P and keep holding Super in order to keep the switcher
open, then press P again (or use the arrow keys or mouse) to
select the next one in the list.
This is incompatible with many Asus products such as Asus X530UN, where
pressing the presentation mode media key (Fn+F8) actually generates
the following keypress events from the keyboard controller:
Fn pressed: nothing
F8 pressed: nothing
F8 released: Super press, p press, p release, Super release (quick burst)
Fn released: nothing
With this firmware behaviour it's not possible to hold the keys and have
the dialog come up so that you can select another new mode.
To solve this, when the switcher is opened, select the next available
display config by default, which is more similar to the pre-GNOME-3.26
behaviour. Now pressing Fn+F8 on this laptop will result in the display
mode switch taking place.
[1]: The mentioned desired behaviour will at least happen after
https://gitlab.gnome.org/GNOME/mutter/issues/281 has been fixed
https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/208