[gnome-shell/wip/jimmac/dash-icon-spacing: 10/72] workspacesView: Center workspaces of primary display
- From: Jakub Steiner <jimmac src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/jimmac/dash-icon-spacing: 10/72] workspacesView: Center workspaces of primary display
- Date: Tue, 2 Feb 2021 11:58:17 +0000 (UTC)
commit d9aa16f08cdca778f8e145c180184ecc3a5dc2ea
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Fri Dec 11 15:57:49 2020 -0300
workspacesView: Center workspaces of primary display
js/ui/workspacesView.js | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/js/ui/workspacesView.js b/js/ui/workspacesView.js
index 9fd99b7dc1..fa3987e226 100644
--- a/js/ui/workspacesView.js
+++ b/js/ui/workspacesView.js
@@ -118,10 +118,10 @@ class WorkspacesView extends WorkspacesViewBase {
if (rtl && !vertical)
index = nWorkspaces - index - 1;
- const x = vertical ? 0 : index * this.width;
- const y = vertical ? index * this.height : 0;
-
- child.allocate_available_size(x, y, box.get_width(), box.get_height());
+ box.set_origin(
+ vertical ? 0 : index * this.width,
+ vertical ? index * this.height : 0);
+ child.allocate_align_fill(box, 0.5, 0.5, false, false);
});
this._updateScrollPosition();
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]