workspace: Properly handle zero spacing in the WorkspaceLayout
It should be allowed to set this._spacing to 0 and thus pass 0 as rowSpacing or colSpacing to this._adjustSpacingAndPadding(). The current if-condition there won't add the oversize to the spacing in case 0 is passed though. So change that if-condition and explicitely check for null instead. Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1698>
This commit is contained in:
parent
adc5f2d81f
commit
51348c6020
@ -463,9 +463,9 @@ var WorkspaceLayout = GObject.registerClass({
|
|||||||
const [topOversize, bottomOversize] = window.chromeHeights();
|
const [topOversize, bottomOversize] = window.chromeHeights();
|
||||||
const [leftOversize, rightOversize] = window.chromeWidths();
|
const [leftOversize, rightOversize] = window.chromeWidths();
|
||||||
|
|
||||||
if (rowSpacing)
|
if (rowSpacing !== null)
|
||||||
rowSpacing += topOversize + bottomOversize;
|
rowSpacing += topOversize + bottomOversize;
|
||||||
if (colSpacing)
|
if (colSpacing !== null)
|
||||||
colSpacing += Math.max(leftOversize, rightOversize);
|
colSpacing += Math.max(leftOversize, rightOversize);
|
||||||
|
|
||||||
if (containerBox) {
|
if (containerBox) {
|
||||||
|
Loading…
Reference in New Issue
Block a user