overviewControls: Don't update work area box when headless
When headless, we don't have a monitor we can derive a size from, so don't even try, just let it be updated when we actually have a monitor that will show stuff. Closes: https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/5831 Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2478>
This commit is contained in:
parent
5548f98afc
commit
fe9c2b8df6
@ -55,6 +55,9 @@ class ControlsManagerLayout extends Clutter.BoxLayout {
|
|||||||
|
|
||||||
_updateWorkAreaBox() {
|
_updateWorkAreaBox() {
|
||||||
const monitor = Main.layoutManager.primaryMonitor;
|
const monitor = Main.layoutManager.primaryMonitor;
|
||||||
|
if (!monitor)
|
||||||
|
return;
|
||||||
|
|
||||||
const workArea = Main.layoutManager.getWorkAreaForMonitor(monitor.index);
|
const workArea = Main.layoutManager.getWorkAreaForMonitor(monitor.index);
|
||||||
const startX = workArea.x - monitor.x;
|
const startX = workArea.x - monitor.x;
|
||||||
const startY = workArea.y - monitor.y;
|
const startY = workArea.y - monitor.y;
|
||||||
|
Loading…
Reference in New Issue
Block a user