[gnome-shell/wip/rewindow: 27/30] workspacesView: Add some spacing between the workspaces and thumbs
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/wip/rewindow: 27/30] workspacesView: Add some spacing between the workspaces and thumbs
- Date: Mon, 20 Aug 2012 21:32:18 +0000 (UTC)
commit ff7a5d8694176eaf20e034a3ecc0315d9f20e7f1
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Wed Aug 8 17:21:19 2012 -0300
workspacesView: Add some spacing between the workspaces and thumbs
Make it the same padding as between the overview and dash, too.
https://bugzilla.gnome.org/show_bug.cgi?id=582650
data/theme/gnome-shell.css | 2 +-
js/ui/overview.js | 16 +++++++++-------
js/ui/workspacesView.js | 14 +++++---------
3 files changed, 15 insertions(+), 17 deletions(-)
---
diff --git a/data/theme/gnome-shell.css b/data/theme/gnome-shell.css
index 1292f2b..0f4be8e 100644
--- a/data/theme/gnome-shell.css
+++ b/data/theme/gnome-shell.css
@@ -562,7 +562,7 @@ StButton.popup-menu-item:insensitive {
/* Overview */
#overview {
- spacing: 12px;
+ spacing: 40px;
}
.window-caption {
diff --git a/js/ui/overview.js b/js/ui/overview.js
index cb0ff67..e3d8ae5 100644
--- a/js/ui/overview.js
+++ b/js/ui/overview.js
@@ -116,7 +116,7 @@ const Overview = new Lang.Class({
this._desktopFade = new St.Bin();
global.overlay_group.add_actor(this._desktopFade);
- this._spacing = 0;
+ this.spacing = 0;
/* Translators: This is the main view to select
activities. See also note for "Activities" string. */
@@ -128,8 +128,8 @@ const Overview = new Lang.Class({
Lang.bind(this, function() {
let node = this._group.get_theme_node();
let spacing = node.get_length('spacing');
- if (spacing != this._spacing) {
- this._spacing = spacing;
+ if (spacing != this.spacing) {
+ this.spacing = spacing;
this._relayout();
}
}));
@@ -502,15 +502,17 @@ const Overview = new Lang.Class({
dashX = 0;
}
- let viewX = rtl ? 0 : dashWidth + this._spacing;
- let viewY = searchY + searchHeight + this._spacing;
- let viewWidth = primary.width - dashWidth - this._spacing;
- let viewHeight = contentHeight - this._spacing - viewY;
+ let viewX = rtl ? 0 : dashWidth + this.spacing;
+ let viewY = searchY + searchHeight + this.spacing;
+ let viewWidth = primary.width - dashWidth - this.spacing;
+ let viewHeight = contentHeight - 2 * this.spacing;
this._searchEntry.set_position(searchX, searchY);
this._dash.actor.set_position(dashX, dashY);
this._viewSelector.actor.set_position(viewX, viewY);
this._viewSelector.actor.set_size(viewWidth, viewHeight);
+
+ this._workspacesDisplay.actor.queue_relayout();
},
//// Public methods ////
diff --git a/js/ui/workspacesView.js b/js/ui/workspacesView.js
index 7d907c6..7314e41 100644
--- a/js/ui/workspacesView.js
+++ b/js/ui/workspacesView.js
@@ -869,15 +869,11 @@ const WorkspacesDisplay = new Lang.Class({
let clipX = rtl ? x + controlsVisible : x;
let clipY = y + (fullHeight - clipHeight) / 2;
- if (this._zoomOut) {
- width -= controlsNatural;
- if (rtl)
- x += controlsNatural;
- } else {
- width -= controlsVisible;
- if (rtl)
- x += controlsVisible;
- }
+ let widthAdjust = this._zoomOut ? controlsNatural : controlsVisible;
+ widthAdjust += Main.overview.spacing;
+ width -= widthAdjust;
+ if (rtl)
+ x += widthAdjust;
let monitors = Main.layoutManager.monitors;
let m = 0;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]