Update new workspace previews
The previews changed slightly after upstream design feedback. Resolves: RHEL-25016
This commit is contained in:
parent
8679f53289
commit
7d66743a12
@ -1,7 +1,92 @@
|
||||
From ba93ee43c6521f0bdde8b21fb49a2906a5e36290 Mon Sep 17 00:00:00 2001
|
||||
From c4fafbcf01fc3c3846e5fe7d60d9aac623afdd9f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 18 Apr 2024 18:09:40 +0200
|
||||
Subject: [PATCH 01/29] prefs: Fix loading custom CSS
|
||||
|
||||
GTK changed the annotation of `gtk_css_provider_load_from_data()`,
|
||||
and as a result the `length` parameter is no longer interpreted
|
||||
as an implicit array length, but has to be specified explicitly.
|
||||
---
|
||||
extensions/auto-move-windows/prefs.js | 2 +-
|
||||
extensions/classification-banner/prefs.js | 2 +-
|
||||
extensions/heads-up-display/prefs.js | 2 +-
|
||||
extensions/window-list/prefs.js | 2 +-
|
||||
extensions/workspace-indicator/prefs.js | 2 +-
|
||||
5 files changed, 5 insertions(+), 5 deletions(-)
|
||||
|
||||
diff --git a/extensions/auto-move-windows/prefs.js b/extensions/auto-move-windows/prefs.js
|
||||
index 2c529067..db09c28b 100644
|
||||
--- a/extensions/auto-move-windows/prefs.js
|
||||
+++ b/extensions/auto-move-windows/prefs.js
|
||||
@@ -48,7 +48,7 @@ class AutoMoveSettingsWidget extends Gtk.ScrolledWindow {
|
||||
const context = this._list.get_style_context();
|
||||
const cssProvider = new Gtk.CssProvider();
|
||||
cssProvider.load_from_data(
|
||||
- 'list { min-width: 30em; }');
|
||||
+ 'list { min-width: 30em; }', -1);
|
||||
|
||||
context.add_provider(cssProvider,
|
||||
Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
|
||||
diff --git a/extensions/classification-banner/prefs.js b/extensions/classification-banner/prefs.js
|
||||
index a5dd8af1..0a91a5da 100644
|
||||
--- a/extensions/classification-banner/prefs.js
|
||||
+++ b/extensions/classification-banner/prefs.js
|
||||
@@ -137,7 +137,7 @@ class AppearancePrefs extends Adw.PreferencesGroup {
|
||||
padding: 6px;
|
||||
color: ${item.color};
|
||||
background-color: ${item.background_color};
|
||||
- }`);
|
||||
+ }`, -1);
|
||||
child.get_style_context().add_provider(provider,
|
||||
Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
|
||||
child.label = item.message;
|
||||
diff --git a/extensions/heads-up-display/prefs.js b/extensions/heads-up-display/prefs.js
|
||||
index a7106e07..9262c11a 100644
|
||||
--- a/extensions/heads-up-display/prefs.js
|
||||
+++ b/extensions/heads-up-display/prefs.js
|
||||
@@ -55,7 +55,7 @@ var settings;
|
||||
function init() {
|
||||
settings = ExtensionUtils.getSettings("org.gnome.shell.extensions.heads-up-display");
|
||||
const cssProvider = new Gtk.CssProvider();
|
||||
- cssProvider.load_from_data(cssData);
|
||||
+ cssProvider.load_from_data(cssData, -1);
|
||||
|
||||
const display = Gdk.Display.get_default();
|
||||
Gtk.StyleContext.add_provider_for_display(display, cssProvider, Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
|
||||
diff --git a/extensions/window-list/prefs.js b/extensions/window-list/prefs.js
|
||||
index aec8cc9d..e35990ff 100644
|
||||
--- a/extensions/window-list/prefs.js
|
||||
+++ b/extensions/window-list/prefs.js
|
||||
@@ -43,7 +43,7 @@ class WindowListPrefsWidget extends Gtk.Box {
|
||||
const context = box.get_style_context();
|
||||
const cssProvider = new Gtk.CssProvider();
|
||||
cssProvider.load_from_data(
|
||||
- 'box { padding: 12px; }');
|
||||
+ 'box { padding: 12px; }', -1);
|
||||
|
||||
context.add_provider(cssProvider,
|
||||
Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
|
||||
diff --git a/extensions/workspace-indicator/prefs.js b/extensions/workspace-indicator/prefs.js
|
||||
index 567f3e99..d307dcac 100644
|
||||
--- a/extensions/workspace-indicator/prefs.js
|
||||
+++ b/extensions/workspace-indicator/prefs.js
|
||||
@@ -48,7 +48,7 @@ class WorkspaceSettingsWidget extends Gtk.ScrolledWindow {
|
||||
const context = this._list.get_style_context();
|
||||
const cssProvider = new Gtk.CssProvider();
|
||||
cssProvider.load_from_data(
|
||||
- 'list { min-width: 25em; }');
|
||||
+ 'list { min-width: 25em; }', -1);
|
||||
|
||||
context.add_provider(cssProvider,
|
||||
Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);
|
||||
--
|
||||
2.44.0
|
||||
|
||||
|
||||
From a51c420cf3cea60511405d4e6070721eca53216d Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 23 Mar 2022 19:59:14 +0100
|
||||
Subject: [PATCH 01/28] build: Remove unused stylesheets
|
||||
Subject: [PATCH 02/29] build: Remove unused stylesheets
|
||||
|
||||
The only reason for installing empty stylesheets is minimizing
|
||||
build system differences between extensions. That's not a very
|
||||
@ -157,10 +242,10 @@ index 71efa039..19858a39 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From b5ec53b2fcc134a667e92bccb93672e0f286e9f2 Mon Sep 17 00:00:00 2001
|
||||
From 4684f3fb41f2c7c960c839d30b22e388ad037f9b Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 12:38:33 +0100
|
||||
Subject: [PATCH 02/28] workspace-indicator: Move indicator code into separate
|
||||
Subject: [PATCH 03/29] workspace-indicator: Move indicator code into separate
|
||||
file
|
||||
|
||||
Shortly after the window-list extension was added, it gained a
|
||||
@ -1123,10 +1208,10 @@ index 10b1d517..bd39ab61 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 8c5020870abefdd1e14584bca80a96e3f50862ff Mon Sep 17 00:00:00 2001
|
||||
From cfed1102f4c435a14d724b96dc393cf58537e73d Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 19:09:38 +0100
|
||||
Subject: [PATCH 03/28] workspace-indicator: Use descendant style selectors
|
||||
Subject: [PATCH 04/29] workspace-indicator: Use descendant style selectors
|
||||
|
||||
Add a style class to the indicator itself, and only select
|
||||
descendant elements. This allows using the briefer class names
|
||||
@ -1200,10 +1285,10 @@ index b98de047..101c89c6 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 55614bb3ccaea057ca450e53d8d3a5b91ff1ffa0 Mon Sep 17 00:00:00 2001
|
||||
From 6d781d9bc99f207d500aa00fecf8afc5a1565d2e Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 12:48:43 +0100
|
||||
Subject: [PATCH 04/28] window-list: Use consistent style class prefix
|
||||
Subject: [PATCH 05/29] window-list: Use consistent style class prefix
|
||||
|
||||
This will eventually allow us to re-use the workspace-indicator
|
||||
extension without changing anything but the used prefix.
|
||||
@ -1267,10 +1352,10 @@ index cdfe5b61..c24f159f 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From df0a023f8c0721b5e2bd7613d32a71e3591381cd Mon Sep 17 00:00:00 2001
|
||||
From da81833162f3e4c59e5f6d66b42883792994f4bf Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 23 Feb 2024 01:59:15 +0100
|
||||
Subject: [PATCH 05/28] workspace-indicator: Allow overriding base style class
|
||||
Subject: [PATCH 06/29] workspace-indicator: Allow overriding base style class
|
||||
|
||||
This will allow reusing the code from the window-list extension
|
||||
without limiting the ability to specify styling that only applies
|
||||
@ -1320,10 +1405,10 @@ index 101c89c6..ba1e05d7 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 7a5a295b6ff1c82be9f159ac5ffcc95e79bd887a Mon Sep 17 00:00:00 2001
|
||||
From 7921f2587f7362f6ffe91de97b7fe4b82af0e215 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Fri, 23 Feb 2024 01:58:50 +0100
|
||||
Subject: [PATCH 06/28] window-list: Override base style class
|
||||
Subject: [PATCH 07/29] window-list: Override base style class
|
||||
|
||||
Apply the changes from the last commit to the workspace-indicator
|
||||
copy, and override the base style class from the extension.
|
||||
@ -1394,10 +1479,10 @@ index c24f159f..1a1d15cd 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 1d1f915a9cedf0717b2d5f04fd70feead4b109be Mon Sep 17 00:00:00 2001
|
||||
From a28cceb94a0afddbfcbefd5e7a240dab2461e440 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 12:48:43 +0100
|
||||
Subject: [PATCH 07/28] window-list: Externally adjust workspace menu
|
||||
Subject: [PATCH 08/29] window-list: Externally adjust workspace menu
|
||||
|
||||
In order to use a PanelMenu.Button in the bottom bar, we have
|
||||
to tweak its menu a bit.
|
||||
@ -1482,10 +1567,10 @@ index 1a1d15cd..4290d58a 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 70b2caf35fea16bbbb20333128a9800b29c92e6f Mon Sep 17 00:00:00 2001
|
||||
From cc0581a3e81699b53e2e0b41b09e9b19b00dfc75 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 21 Mar 2024 16:49:35 +0100
|
||||
Subject: [PATCH 08/28] window-list: Handle changes to workspace menu
|
||||
Subject: [PATCH 09/29] window-list: Handle changes to workspace menu
|
||||
|
||||
For now the menu is always set at construction time, however this
|
||||
will change in the future. Prepare for that by handling the
|
||||
@ -1525,10 +1610,10 @@ index c58df434..a011bc90 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 8915a813c5c5d4ca4eb71da56e4fa29def55abe9 Mon Sep 17 00:00:00 2001
|
||||
From b96a349004b3050f1686567bdd60a38e305044d0 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 15:58:39 +0100
|
||||
Subject: [PATCH 09/28] workspace-indicator: Don't use SCHEMA/KEY constants
|
||||
Subject: [PATCH 10/29] workspace-indicator: Don't use SCHEMA/KEY constants
|
||||
|
||||
Each constant is only used once, so all they do is disconnect
|
||||
the actual value from the code that uses it.
|
||||
@ -1569,10 +1654,10 @@ index ba1e05d7..60e084e2 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 50b5b6eba5cad5a3c47043834cdb87aaf7d33b75 Mon Sep 17 00:00:00 2001
|
||||
From 3b1d5852665b5959cdf82d62a68956bef28cb1fa Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 18:59:23 +0100
|
||||
Subject: [PATCH 10/28] workspace-indicator: Use existing property
|
||||
Subject: [PATCH 11/29] workspace-indicator: Use existing property
|
||||
|
||||
We already track the current workspace index, use that
|
||||
instead of getting it from the workspace manager again.
|
||||
@ -1597,10 +1682,10 @@ index 60e084e2..4f2188be 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From b2848cccdc75a8b354fe4e5693e0cf0e63fdeedf Mon Sep 17 00:00:00 2001
|
||||
From 0b77dc01322b565331df1d1a657a980f7433948b Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 16:14:24 +0100
|
||||
Subject: [PATCH 11/28] workspace-indicator: Don't use menu section
|
||||
Subject: [PATCH 12/29] workspace-indicator: Don't use menu section
|
||||
|
||||
We never added anything else to the menu, so we can just operate
|
||||
on the entire menu instead of an intermediate section.
|
||||
@ -1666,10 +1751,10 @@ index 4f2188be..66b71cd6 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 21cea529850b861bb813666efa25da70a4e52ac5 Mon Sep 17 00:00:00 2001
|
||||
From a348e4612ab94e2e3ee0c121d064164a7c28dfed Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 13:05:15 +0100
|
||||
Subject: [PATCH 12/28] workspace-indicator: Support showing tooltips above
|
||||
Subject: [PATCH 13/29] workspace-indicator: Support showing tooltips above
|
||||
|
||||
The indicator is located in the top bar, so tooltips are always
|
||||
shown below the previews. However supporting showing tooltips
|
||||
@ -1709,10 +1794,10 @@ index 66b71cd6..bc9e222b 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 658df8f7dd63d23f000738fb63fd145a744c0ccd Mon Sep 17 00:00:00 2001
|
||||
From be0cb3e873d225e172714f11fec0fbb319ea96db Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 17:37:16 +0100
|
||||
Subject: [PATCH 13/28] workspace-indicator: Only change top bar redirect when
|
||||
Subject: [PATCH 14/29] workspace-indicator: Only change top bar redirect when
|
||||
in top bar
|
||||
|
||||
While this is always the case for the workspace indicator, adding
|
||||
@ -1775,10 +1860,10 @@ index bc9e222b..ac270d64 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 2ed34034a2ee8ec8b2dc7a789ceac5753e76f61e Mon Sep 17 00:00:00 2001
|
||||
From a56bc8bacc0d1a04ca2c342cd2dc85e80b9a0db4 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 16:13:00 +0100
|
||||
Subject: [PATCH 14/28] workspace-indicator: Small cleanup
|
||||
Subject: [PATCH 15/29] workspace-indicator: Small cleanup
|
||||
|
||||
The code to update the menu labels is a bit cleaner in the
|
||||
window-list extension, so use that.
|
||||
@ -1823,10 +1908,10 @@ index ac270d64..9b22102a 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From b367e8a92de8fa8535ff27fcbc9a78c1476c9d19 Mon Sep 17 00:00:00 2001
|
||||
From 88c24e691c2ff96c92e4653ec8b8a4c31193dd43 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 16:13:00 +0100
|
||||
Subject: [PATCH 15/28] workspace-indicator: Simplify getting status text
|
||||
Subject: [PATCH 16/29] workspace-indicator: Simplify getting status text
|
||||
|
||||
Currently the same method is used to get the label text for the
|
||||
indicator itself and for the menu items.
|
||||
@ -1909,10 +1994,10 @@ index 9b22102a..d8b29f58 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 4918d40d0161a670baee9153599384d38a5166f2 Mon Sep 17 00:00:00 2001
|
||||
From b6652b18eac9afe866d4659c2b7ce49321898fee Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 16:35:09 +0100
|
||||
Subject: [PATCH 16/28] workspace-indicator: Include n-workspaces in status
|
||||
Subject: [PATCH 17/29] workspace-indicator: Include n-workspaces in status
|
||||
label
|
||||
|
||||
The two extensions currently use a slightly different label
|
||||
@ -1945,10 +2030,10 @@ index d8b29f58..756758b3 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 8a99594c3a33d1623fcdf4d87f4a1ace8e1952f1 Mon Sep 17 00:00:00 2001
|
||||
From 839db724bee85f65406af273878fe82073dce7da Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 22 Feb 2024 04:45:23 +0100
|
||||
Subject: [PATCH 17/28] workspace-indicator: Tweak preview style
|
||||
Subject: [PATCH 18/29] workspace-indicator: Tweak preview style
|
||||
|
||||
Sync sizes and padding with the window-list previews.
|
||||
|
||||
@ -1956,11 +2041,11 @@ Tone down the colors a bit, but less then the current window-list
|
||||
style where workspaces blend too much into the background and
|
||||
the selection is unclear.
|
||||
---
|
||||
extensions/workspace-indicator/stylesheet.css | 13 +++++++------
|
||||
1 file changed, 7 insertions(+), 6 deletions(-)
|
||||
extensions/workspace-indicator/stylesheet.css | 15 ++++++++-------
|
||||
1 file changed, 8 insertions(+), 7 deletions(-)
|
||||
|
||||
diff --git a/extensions/workspace-indicator/stylesheet.css b/extensions/workspace-indicator/stylesheet.css
|
||||
index 4e12cce4..68fd534c 100644
|
||||
index 4e12cce4..f74f7e88 100644
|
||||
--- a/extensions/workspace-indicator/stylesheet.css
|
||||
+++ b/extensions/workspace-indicator/stylesheet.css
|
||||
@@ -3,24 +3,25 @@
|
||||
@ -1975,10 +2060,11 @@ index 4e12cce4..68fd534c 100644
|
||||
|
||||
.workspace-indicator .workspace {
|
||||
- width: 40px;
|
||||
+ width: 52px;
|
||||
border: 2px solid #000;
|
||||
- border: 2px solid #000;
|
||||
- border-radius: 2px;
|
||||
- background-color: #595959;
|
||||
+ width: 52px;
|
||||
+ border: 2px solid transparent;
|
||||
+ border-radius: 4px;
|
||||
+ background-color: #3f3f3f;
|
||||
}
|
||||
@ -1999,10 +2085,10 @@ index 4e12cce4..68fd534c 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 786e03c6da64c9195223ad7648975e9007f7b2ac Mon Sep 17 00:00:00 2001
|
||||
From fd9c52d342a1abb70c6346c8ab481ba659437803 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 23:22:58 +0100
|
||||
Subject: [PATCH 18/28] workspace-indicator: Support light style
|
||||
Subject: [PATCH 19/29] workspace-indicator: Support light style
|
||||
|
||||
The window-list extension already includes light styling for
|
||||
its copy of the workspace indicator. Just copy that over to
|
||||
@ -2010,9 +2096,9 @@ support the light variant here as well.
|
||||
---
|
||||
extensions/workspace-indicator/meson.build | 6 +++-
|
||||
.../workspace-indicator/stylesheet-dark.css | 29 ++++++++++++++++++
|
||||
.../workspace-indicator/stylesheet-light.css | 26 ++++++++++++++++
|
||||
.../workspace-indicator/stylesheet-light.css | 25 ++++++++++++++++
|
||||
extensions/workspace-indicator/stylesheet.css | 30 +------------------
|
||||
4 files changed, 61 insertions(+), 30 deletions(-)
|
||||
4 files changed, 60 insertions(+), 30 deletions(-)
|
||||
create mode 100644 extensions/workspace-indicator/stylesheet-dark.css
|
||||
create mode 100644 extensions/workspace-indicator/stylesheet-light.css
|
||||
|
||||
@ -2034,7 +2120,7 @@ index eb25b9cc..0bf9f023 100644
|
||||
extension_sources += files('prefs.js', 'workspaceIndicator.js')
|
||||
diff --git a/extensions/workspace-indicator/stylesheet-dark.css b/extensions/workspace-indicator/stylesheet-dark.css
|
||||
new file mode 100644
|
||||
index 00000000..68fd534c
|
||||
index 00000000..f74f7e88
|
||||
--- /dev/null
|
||||
+++ b/extensions/workspace-indicator/stylesheet-dark.css
|
||||
@@ -0,0 +1,29 @@
|
||||
@ -2049,7 +2135,7 @@ index 00000000..68fd534c
|
||||
+
|
||||
+.workspace-indicator .workspace {
|
||||
+ width: 52px;
|
||||
+ border: 2px solid #000;
|
||||
+ border: 2px solid transparent;
|
||||
+ border-radius: 4px;
|
||||
+ background-color: #3f3f3f;
|
||||
+}
|
||||
@ -2069,10 +2155,10 @@ index 00000000..68fd534c
|
||||
+}
|
||||
diff --git a/extensions/workspace-indicator/stylesheet-light.css b/extensions/workspace-indicator/stylesheet-light.css
|
||||
new file mode 100644
|
||||
index 00000000..da77d90e
|
||||
index 00000000..049b6a38
|
||||
--- /dev/null
|
||||
+++ b/extensions/workspace-indicator/stylesheet-light.css
|
||||
@@ -0,0 +1,26 @@
|
||||
@@ -0,0 +1,25 @@
|
||||
+/*
|
||||
+ * SPDX-FileCopyrightText: 2013 Florian Müllner <fmuellner@gnome.org>
|
||||
+ * SPDX-FileCopyrightText: 2015 Jakub Steiner <jimmac@gmail.com>
|
||||
@ -2083,7 +2169,6 @@ index 00000000..da77d90e
|
||||
+@import url("stylesheet-dark.css");
|
||||
+
|
||||
+.workspace-indicator .workspace {
|
||||
+ border: 2px solid #f6f5f4;
|
||||
+ background-color: #ccc;
|
||||
+}
|
||||
+
|
||||
@ -2100,7 +2185,7 @@ index 00000000..da77d90e
|
||||
+ background-color: #f6f5f4;
|
||||
+}
|
||||
diff --git a/extensions/workspace-indicator/stylesheet.css b/extensions/workspace-indicator/stylesheet.css
|
||||
index 68fd534c..b0f7d171 100644
|
||||
index f74f7e88..b0f7d171 100644
|
||||
--- a/extensions/workspace-indicator/stylesheet.css
|
||||
+++ b/extensions/workspace-indicator/stylesheet.css
|
||||
@@ -1,29 +1 @@
|
||||
@ -2115,7 +2200,7 @@ index 68fd534c..b0f7d171 100644
|
||||
-
|
||||
-.workspace-indicator .workspace {
|
||||
- width: 52px;
|
||||
- border: 2px solid #000;
|
||||
- border: 2px solid transparent;
|
||||
- border-radius: 4px;
|
||||
- background-color: #3f3f3f;
|
||||
-}
|
||||
@ -2138,10 +2223,10 @@ index 68fd534c..b0f7d171 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 5e9b22449ec55f7f051b32d7d0b6fa9173a929e5 Mon Sep 17 00:00:00 2001
|
||||
From dd39bf22e11f40825113f11b102c6d7dbdce84eb Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Wed, 21 Feb 2024 13:08:52 +0100
|
||||
Subject: [PATCH 19/28] window-list: Use actual copy of workspace-indicator
|
||||
Subject: [PATCH 20/29] window-list: Use actual copy of workspace-indicator
|
||||
|
||||
We are now at a point where the code from the workspace-indicator
|
||||
extension is usable from the window-list.
|
||||
@ -2699,10 +2784,10 @@ index 4290d58a..00000000
|
||||
2.44.0
|
||||
|
||||
|
||||
From 61f68777292726c337cf4894be675bbd924376ea Mon Sep 17 00:00:00 2001
|
||||
From 69d9b0ccdf1422bd620b175366dff6c8b0b32c0b Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Tue, 20 Feb 2024 17:39:49 +0100
|
||||
Subject: [PATCH 20/28] workspace-indicator: Simplify scroll handling
|
||||
Subject: [PATCH 21/29] workspace-indicator: Simplify scroll handling
|
||||
|
||||
gnome-shell already includes a method for switching workspaces
|
||||
via scroll events. Use that instead of implementing our own.
|
||||
@ -2751,10 +2836,10 @@ index 756758b3..8e3fec56 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 4a3e86c8d54c256318620f2f8e2eea5ea0be181b Mon Sep 17 00:00:00 2001
|
||||
From 98cf358a56cb7fea6c8b55f6dc34216a14389408 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Tue, 27 Feb 2024 21:20:45 +0100
|
||||
Subject: [PATCH 21/28] workspace-indicator: Handle active indication in
|
||||
Subject: [PATCH 22/29] workspace-indicator: Handle active indication in
|
||||
thumbnail
|
||||
|
||||
Meta.Workspace has had an `active` property for a while now, so
|
||||
@ -2852,10 +2937,10 @@ index 8e3fec56..01b831f7 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 4ffe354adabcb830014196a89e898dc8c2ca6bda Mon Sep 17 00:00:00 2001
|
||||
From da227af7b7867c0e62ca7ab691e776848c400bf3 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Tue, 20 Feb 2024 17:27:57 +0100
|
||||
Subject: [PATCH 22/28] workspace-indicator: Split out WorkspacePreviews
|
||||
Subject: [PATCH 23/29] workspace-indicator: Split out WorkspacePreviews
|
||||
|
||||
The previews will become a bit more complex soon, so spit them out
|
||||
into a dedicated class.
|
||||
@ -3003,10 +3088,10 @@ index 01b831f7..a559b8e2 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 1e0f95c9f2f562348086dcd27a8f45430d399902 Mon Sep 17 00:00:00 2001
|
||||
From 07daa48f1f39b7fea86913f6bfc9e8f594ef0477 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Mon, 19 Feb 2024 14:42:04 +0100
|
||||
Subject: [PATCH 23/28] workspace-indicator: Handle preview overflow
|
||||
Subject: [PATCH 24/29] workspace-indicator: Handle preview overflow
|
||||
|
||||
We currently avoid previews from overflowing in most setups by
|
||||
artificially limiting them to a maximum of six workspaces.
|
||||
@ -3017,39 +3102,39 @@ limited, and to allow removing the restriction in the future.
|
||||
For that, wrap the previews in an auto-scrolling scroll view
|
||||
and add overflow indicators on each side.
|
||||
---
|
||||
.../workspace-indicator/stylesheet-dark.css | 8 +++
|
||||
.../workspace-indicator/workspaceIndicator.js | 59 ++++++++++++++++++-
|
||||
2 files changed, 66 insertions(+), 1 deletion(-)
|
||||
.../workspace-indicator/stylesheet-dark.css | 4 ++
|
||||
.../workspace-indicator/workspaceIndicator.js | 66 ++++++++++++++++++-
|
||||
2 files changed, 69 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/extensions/workspace-indicator/stylesheet-dark.css b/extensions/workspace-indicator/stylesheet-dark.css
|
||||
index 68fd534c..55f8ca5f 100644
|
||||
index f74f7e88..61d1e982 100644
|
||||
--- a/extensions/workspace-indicator/stylesheet-dark.css
|
||||
+++ b/extensions/workspace-indicator/stylesheet-dark.css
|
||||
@@ -2,11 +2,19 @@
|
||||
@@ -2,6 +2,10 @@
|
||||
padding: 0 8px;
|
||||
}
|
||||
|
||||
+.workspace-indicator .workspaces-view {
|
||||
+ /*max-width: 280px;*/
|
||||
+.workspace-indicator .workspaces-view.hfade {
|
||||
+ -st-hfade-offset: 20px;
|
||||
+}
|
||||
+
|
||||
.workspace-indicator .workspaces-box {
|
||||
padding: 5px;
|
||||
spacing: 3px;
|
||||
}
|
||||
|
||||
+.workspace-indicator .preview-arrow {
|
||||
+ icon-size: 1.08em;
|
||||
+}
|
||||
+
|
||||
.workspace-indicator .workspace {
|
||||
width: 52px;
|
||||
border: 2px solid #000;
|
||||
diff --git a/extensions/workspace-indicator/workspaceIndicator.js b/extensions/workspace-indicator/workspaceIndicator.js
|
||||
index a559b8e2..4cebeb20 100644
|
||||
index a559b8e2..17cf7c89 100644
|
||||
--- a/extensions/workspace-indicator/workspaceIndicator.js
|
||||
+++ b/extensions/workspace-indicator/workspaceIndicator.js
|
||||
@@ -299,12 +299,48 @@ class WorkspacePreviews extends Clutter.Actor {
|
||||
@@ -20,6 +20,8 @@ const PopupMenu = imports.ui.popupMenu;
|
||||
const TOOLTIP_OFFSET = 6;
|
||||
const TOOLTIP_ANIMATION_TIME = 150;
|
||||
|
||||
+const SCROLL_TIME = 100;
|
||||
+
|
||||
const MAX_THUMBNAILS = 6;
|
||||
|
||||
let baseStyleClassName = '';
|
||||
@@ -299,12 +301,30 @@ class WorkspacePreviews extends Clutter.Actor {
|
||||
this._nWorkspacesChanged =
|
||||
workspaceManager.connect_after('notify::n-workspaces',
|
||||
() => this._updateThumbnails());
|
||||
@ -3068,38 +3153,20 @@ index a559b8e2..4cebeb20 100644
|
||||
});
|
||||
- this.add_child(this._thumbnailsBox);
|
||||
+
|
||||
+ const view = new St.ScrollView({
|
||||
+ this._scrollView = new St.ScrollView({
|
||||
+ style_class: 'workspaces-view hfade',
|
||||
+ enable_mouse_scrolling: false,
|
||||
+ hscrollbar_policy: St.PolicyType.EXTERNAL,
|
||||
+ vscrollbar_policy: St.PolicyType.NEVER,
|
||||
+ y_expand: true,
|
||||
+ });
|
||||
+ this._scrollAdjustment = view.hscroll.adjustment;
|
||||
+ this._scrollView.add_actor(this._thumbnailsBox);
|
||||
+
|
||||
+ view.add_actor(this._thumbnailsBox);
|
||||
+
|
||||
+ this.add_child(view);
|
||||
+
|
||||
+ this._arrowStart = new St.Icon({
|
||||
+ icon_name: 'pan-start-symbolic',
|
||||
+ style_class: 'preview-arrow',
|
||||
+ x_align: Clutter.ActorAlign.START,
|
||||
+ x_expand: true,
|
||||
+ });
|
||||
+ this.add_child(this._arrowStart);
|
||||
+
|
||||
+ this._arrowEnd = new St.Icon({
|
||||
+ icon_name: 'pan-end-symbolic',
|
||||
+ style_class: 'preview-arrow',
|
||||
+ x_align: Clutter.ActorAlign.END,
|
||||
+ x_expand: true,
|
||||
+ });
|
||||
+ this.add_child(this._arrowEnd);
|
||||
+ this.add_child(this._scrollView);
|
||||
|
||||
this._updateThumbnails();
|
||||
}
|
||||
@@ -318,6 +354,27 @@ class WorkspacePreviews extends Clutter.Actor {
|
||||
@@ -318,6 +338,50 @@ class WorkspacePreviews extends Clutter.Actor {
|
||||
const thumb = new WorkspaceThumbnail(i);
|
||||
this._thumbnailsBox.add_child(thumb);
|
||||
}
|
||||
@ -3109,21 +3176,44 @@ index a559b8e2..4cebeb20 100644
|
||||
+ }
|
||||
+
|
||||
+ _updateScrollPosition() {
|
||||
+ const activeWorkspace = global.workspaceManager.get_active_workspace_index();
|
||||
+ const {nWorkspaces} = global.workspace_manager;
|
||||
+ const {pageSize} = this._scrollAdjustment;
|
||||
+ const [fullSize] = this._thumbnailsBox.get_preferred_width(-1);
|
||||
+ const wsSize = Math.floor(fullSize / nWorkspaces);
|
||||
+ const value = (activeWorkspace + 0.5) * wsSize - pageSize / 2;
|
||||
+ this._scrollAdjustment.set({value});
|
||||
+ this._updateArrowVisibility();
|
||||
+ }
|
||||
+ const adjustment = this._scrollView.hscroll.adjustment;
|
||||
+ const {upper, pageSize} = adjustment;
|
||||
+ let {value} = adjustment;
|
||||
+
|
||||
+ _updateArrowVisibility() {
|
||||
+ const {value, upper, pageSize} = this._scrollAdjustment;
|
||||
+ const activeWorkspace =
|
||||
+ [...this._thumbnailsBox].find(a => a.active);
|
||||
+
|
||||
+ this._arrowStart.opacity = value > 0 ? 255 : 0;
|
||||
+ this._arrowEnd.opacity = value < upper - pageSize ? 255 : 0;
|
||||
+ if (!activeWorkspace)
|
||||
+ return;
|
||||
+
|
||||
+ let offset = 0;
|
||||
+ const hfade = this._scrollView.get_effect('fade');
|
||||
+ if (hfade)
|
||||
+ offset = hfade.fade_margins.left;
|
||||
+
|
||||
+ let {x1, x2} = activeWorkspace.get_allocation_box();
|
||||
+ let parent = activeWorkspace.get_parent();
|
||||
+ while (parent !== this._scrollView) {
|
||||
+ if (!parent)
|
||||
+ throw new Error('actor not in scroll view');
|
||||
+
|
||||
+ const box = parent.get_allocation_box();
|
||||
+ x1 += box.x1;
|
||||
+ x2 += box.x1;
|
||||
+ parent = parent.get_parent();
|
||||
+ }
|
||||
+
|
||||
+ if (x1 < value + offset)
|
||||
+ value = Math.max(0, x1 - offset);
|
||||
+ else if (x2 > value + pageSize - offset)
|
||||
+ value = Math.min(upper, x2 + offset - pageSize);
|
||||
+ else
|
||||
+ return;
|
||||
+
|
||||
+ adjustment.ease(value, {
|
||||
+ mode: Clutter.AnimationMode.EASE_OUT_QUAD,
|
||||
+ duration: SCROLL_TIME,
|
||||
+ });
|
||||
}
|
||||
|
||||
_onDestroy() {
|
||||
@ -3131,10 +3221,10 @@ index a559b8e2..4cebeb20 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 3c41c8497080d6a3183916594f51fd623e12c1cf Mon Sep 17 00:00:00 2001
|
||||
From 7b619f11009468ed1d697ac9c7b7ba98a7755c67 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Sun, 3 Mar 2024 15:05:23 +0100
|
||||
Subject: [PATCH 24/28] workspace-indicator: Support labels in previews
|
||||
Subject: [PATCH 25/29] workspace-indicator: Support labels in previews
|
||||
|
||||
The space in the top bar is too limited to include the workspace
|
||||
names. However we'll soon replace the textual menu with a preview
|
||||
@ -3145,10 +3235,10 @@ names to not lose functionality with regards to the current menu.
|
||||
1 file changed, 55 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/extensions/workspace-indicator/workspaceIndicator.js b/extensions/workspace-indicator/workspaceIndicator.js
|
||||
index 4cebeb20..5ef5674d 100644
|
||||
index 17cf7c89..5e6d6300 100644
|
||||
--- a/extensions/workspace-indicator/workspaceIndicator.js
|
||||
+++ b/extensions/workspace-indicator/workspaceIndicator.js
|
||||
@@ -122,10 +122,23 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
@@ -124,10 +124,23 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
'active', '', '',
|
||||
GObject.ParamFlags.READWRITE,
|
||||
false),
|
||||
@ -3173,7 +3263,7 @@ index 4cebeb20..5ef5674d 100644
|
||||
style_class: 'workspace',
|
||||
child: new Clutter.Actor({
|
||||
layout_manager: new WorkspaceLayout(),
|
||||
@@ -133,7 +146,15 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
@@ -135,7 +148,15 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
x_expand: true,
|
||||
y_expand: true,
|
||||
}),
|
||||
@ -3189,7 +3279,7 @@ index 4cebeb20..5ef5674d 100644
|
||||
|
||||
this._tooltip = new St.Label({
|
||||
style_class: 'dash-label',
|
||||
@@ -141,9 +162,20 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
@@ -143,9 +164,20 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
});
|
||||
Main.uiGroup.add_child(this._tooltip);
|
||||
|
||||
@ -3210,7 +3300,7 @@ index 4cebeb20..5ef5674d 100644
|
||||
this._index = index;
|
||||
this._delegate = this; // needed for DND
|
||||
|
||||
@@ -169,14 +201,14 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
@@ -171,14 +203,14 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
}
|
||||
|
||||
get active() {
|
||||
@ -3228,7 +3318,7 @@ index 4cebeb20..5ef5674d 100644
|
||||
this.notify('active');
|
||||
}
|
||||
|
||||
@@ -202,7 +234,7 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
@@ -204,7 +236,7 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
let preview = new WindowPreview(window);
|
||||
preview.connect('clicked', (a, btn) => this.emit('clicked', btn));
|
||||
this._windowPreviews.set(window, preview);
|
||||
@ -3237,7 +3327,7 @@ index 4cebeb20..5ef5674d 100644
|
||||
}
|
||||
|
||||
_removeWindow(window) {
|
||||
@@ -222,7 +254,7 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
@@ -224,7 +256,7 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
if (!preview)
|
||||
continue;
|
||||
|
||||
@ -3246,7 +3336,7 @@ index 4cebeb20..5ef5674d 100644
|
||||
lastPreview = preview;
|
||||
}
|
||||
}
|
||||
@@ -241,6 +273,9 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
@@ -243,6 +275,9 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
}
|
||||
|
||||
_syncTooltip() {
|
||||
@ -3256,7 +3346,7 @@ index 4cebeb20..5ef5674d 100644
|
||||
if (this.hover) {
|
||||
this._tooltip.set({
|
||||
text: Meta.prefs_get_workspace_name(this._index),
|
||||
@@ -277,11 +312,20 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
@@ -279,11 +314,20 @@ const WorkspaceThumbnail = GObject.registerClass({
|
||||
this._workspace.disconnect(this._windowAddedId);
|
||||
this._workspace.disconnect(this._windowRemovedId);
|
||||
global.display.disconnect(this._restackedId);
|
||||
@ -3279,7 +3369,7 @@ index 4cebeb20..5ef5674d 100644
|
||||
_init(params) {
|
||||
super._init({
|
||||
...params,
|
||||
@@ -352,6 +396,9 @@ class WorkspacePreviews extends Clutter.Actor {
|
||||
@@ -336,6 +380,9 @@ class WorkspacePreviews extends Clutter.Actor {
|
||||
|
||||
for (let i = 0; i < nWorkspaces; i++) {
|
||||
const thumb = new WorkspaceThumbnail(i);
|
||||
@ -3293,10 +3383,10 @@ index 4cebeb20..5ef5674d 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 4c7c7df4965e1a06bf38e4404363b6c134ff56c7 Mon Sep 17 00:00:00 2001
|
||||
From 618b20c7c3237e16cf0c4e822ee570b337c6ea88 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Tue, 20 Feb 2024 21:43:55 +0100
|
||||
Subject: [PATCH 25/28] workspace-indicator: Stop handling vertical layouts
|
||||
Subject: [PATCH 26/29] workspace-indicator: Stop handling vertical layouts
|
||||
|
||||
Both the regular session and GNOME classic use a horizontal layout
|
||||
nowadays, so it doesn't seem worth to specifically handle vertical
|
||||
@ -3310,10 +3400,10 @@ previews and the actual layout.
|
||||
1 file changed, 1 insertion(+), 5 deletions(-)
|
||||
|
||||
diff --git a/extensions/workspace-indicator/workspaceIndicator.js b/extensions/workspace-indicator/workspaceIndicator.js
|
||||
index 5ef5674d..1171fbd1 100644
|
||||
index 5e6d6300..aad2716a 100644
|
||||
--- a/extensions/workspace-indicator/workspaceIndicator.js
|
||||
+++ b/extensions/workspace-indicator/workspaceIndicator.js
|
||||
@@ -468,8 +468,6 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
@@ -475,8 +475,6 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
this._nWorkspacesChanged.bind(this)),
|
||||
workspaceManager.connect_after('workspace-switched',
|
||||
this._onWorkspaceSwitched.bind(this)),
|
||||
@ -3322,7 +3412,7 @@ index 5ef5674d..1171fbd1 100644
|
||||
];
|
||||
|
||||
this.connect('scroll-event',
|
||||
@@ -511,9 +509,7 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
@@ -518,9 +516,7 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
|
||||
_updateThumbnailVisibility() {
|
||||
const {workspaceManager} = global;
|
||||
@ -3337,10 +3427,10 @@ index 5ef5674d..1171fbd1 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 02bc0cd65e082a390a22e2b2a25bad64aedc2299 Mon Sep 17 00:00:00 2001
|
||||
From a4dcb3bc3449eeeca78e2844e5bd5dbb83f66663 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Sun, 3 Mar 2024 15:05:23 +0100
|
||||
Subject: [PATCH 26/28] workspace-indicator: Also show previews in menu
|
||||
Subject: [PATCH 27/29] workspace-indicator: Also show previews in menu
|
||||
|
||||
Since the regular session also switched to horizontal workspaces,
|
||||
using a vertical menu has been a bit awkward.
|
||||
@ -3348,16 +3438,16 @@ using a vertical menu has been a bit awkward.
|
||||
Now that our previews have become more flexible, we can use them
|
||||
in the collapsed state as well as when embedded into the top bar.
|
||||
---
|
||||
.../workspace-indicator/stylesheet-dark.css | 26 +++++-
|
||||
.../workspace-indicator/stylesheet-dark.css | 25 +++++-
|
||||
.../workspace-indicator/workspaceIndicator.js | 79 +++----------------
|
||||
2 files changed, 37 insertions(+), 68 deletions(-)
|
||||
2 files changed, 36 insertions(+), 68 deletions(-)
|
||||
|
||||
diff --git a/extensions/workspace-indicator/stylesheet-dark.css b/extensions/workspace-indicator/stylesheet-dark.css
|
||||
index 55f8ca5f..77d187de 100644
|
||||
index 61d1e982..fb0e8b1a 100644
|
||||
--- a/extensions/workspace-indicator/stylesheet-dark.css
|
||||
+++ b/extensions/workspace-indicator/stylesheet-dark.css
|
||||
@@ -6,22 +6,46 @@
|
||||
/*max-width: 280px;*/
|
||||
@@ -6,18 +6,41 @@
|
||||
-st-hfade-offset: 20px;
|
||||
}
|
||||
|
||||
+.workspace-indicator-menu .workspaces-view {
|
||||
@ -3374,11 +3464,6 @@ index 55f8ca5f..77d187de 100644
|
||||
+ spacing: 6px;
|
||||
+}
|
||||
+
|
||||
+.workspace-indicator-menu .preview-arrow,
|
||||
.workspace-indicator .preview-arrow {
|
||||
icon-size: 1.08em;
|
||||
}
|
||||
|
||||
+.workspace-indicator-menu .workspace-box {
|
||||
+ spacing: 6px;
|
||||
+}
|
||||
@ -3386,7 +3471,7 @@ index 55f8ca5f..77d187de 100644
|
||||
+.workspace-indicator-menu .workspace,
|
||||
.workspace-indicator .workspace {
|
||||
- width: 52px;
|
||||
border: 2px solid #000;
|
||||
border: 2px solid transparent;
|
||||
border-radius: 4px;
|
||||
background-color: #3f3f3f;
|
||||
}
|
||||
@ -3405,10 +3490,10 @@ index 55f8ca5f..77d187de 100644
|
||||
border-color: #9f9f9f;
|
||||
}
|
||||
diff --git a/extensions/workspace-indicator/workspaceIndicator.js b/extensions/workspace-indicator/workspaceIndicator.js
|
||||
index 1171fbd1..368d785a 100644
|
||||
index aad2716a..7b3c6fbe 100644
|
||||
--- a/extensions/workspace-indicator/workspaceIndicator.js
|
||||
+++ b/extensions/workspace-indicator/workspaceIndicator.js
|
||||
@@ -432,7 +432,7 @@ const WorkspacePreviews = GObject.registerClass({
|
||||
@@ -439,7 +439,7 @@ const WorkspacePreviews = GObject.registerClass({
|
||||
var WorkspaceIndicator = GObject.registerClass(
|
||||
class WorkspaceIndicator extends PanelMenu.Button {
|
||||
_init(params = {}) {
|
||||
@ -3417,7 +3502,7 @@ index 1171fbd1..368d785a 100644
|
||||
|
||||
const {
|
||||
baseStyleClass = 'workspace-indicator',
|
||||
@@ -465,7 +465,7 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
@@ -472,7 +472,7 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
|
||||
this._workspaceManagerSignals = [
|
||||
workspaceManager.connect_after('notify::n-workspaces',
|
||||
@ -3426,7 +3511,7 @@ index 1171fbd1..368d785a 100644
|
||||
workspaceManager.connect_after('workspace-switched',
|
||||
this._onWorkspaceSwitched.bind(this)),
|
||||
];
|
||||
@@ -482,24 +482,13 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
@@ -489,24 +489,13 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
this._updateTopBarRedirect();
|
||||
});
|
||||
|
||||
@ -3451,7 +3536,7 @@ index 1171fbd1..368d785a 100644
|
||||
if (this._inTopBar)
|
||||
Main.panel.set_offscreen_redirect(Clutter.OffscreenRedirect.ALWAYS);
|
||||
this._inTopBar = false;
|
||||
@@ -515,6 +504,10 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
@@ -522,6 +511,10 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
this._statusLabel.visible = useMenu;
|
||||
this._thumbnails.visible = !useMenu;
|
||||
|
||||
@ -3462,7 +3547,7 @@ index 1171fbd1..368d785a 100644
|
||||
this._updateTopBarRedirect();
|
||||
}
|
||||
|
||||
@@ -531,69 +524,21 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
@@ -538,69 +531,21 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
|
||||
_onWorkspaceSwitched() {
|
||||
this._currentWorkspace = global.workspace_manager.get_active_workspace_index();
|
||||
@ -3542,10 +3627,10 @@ index 1171fbd1..368d785a 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From 94b21919c3d86901c24356739fb4baf7b747e990 Mon Sep 17 00:00:00 2001
|
||||
From 7ef858f1679823b2e86b392890513ce5138cd9ab Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Tue, 20 Feb 2024 22:00:57 +0100
|
||||
Subject: [PATCH 27/28] workspace-indicator: Make previews configurable
|
||||
Subject: [PATCH 28/29] workspace-indicator: Make previews configurable
|
||||
|
||||
Now that previews scroll when there are too many workspaces,
|
||||
there is no longer a reason for the 6-workspace limit.
|
||||
@ -3620,7 +3705,7 @@ index 0bf9f023..a88db78a 100644
|
||||
|
||||
extension_sources += files('prefs.js', 'workspaceIndicator.js')
|
||||
diff --git a/extensions/workspace-indicator/prefs.js b/extensions/workspace-indicator/prefs.js
|
||||
index 567f3e99..d93aa383 100644
|
||||
index d307dcac..9809b46a 100644
|
||||
--- a/extensions/workspace-indicator/prefs.js
|
||||
+++ b/extensions/workspace-indicator/prefs.js
|
||||
@@ -13,6 +13,34 @@ const N_ = e => e;
|
||||
@ -3689,19 +3774,19 @@ index 00000000..c7c634ca
|
||||
+ </schema>
|
||||
+</schemalist>
|
||||
diff --git a/extensions/workspace-indicator/workspaceIndicator.js b/extensions/workspace-indicator/workspaceIndicator.js
|
||||
index 368d785a..8c7b2258 100644
|
||||
index 7b3c6fbe..9d566f41 100644
|
||||
--- a/extensions/workspace-indicator/workspaceIndicator.js
|
||||
+++ b/extensions/workspace-indicator/workspaceIndicator.js
|
||||
@@ -20,8 +20,6 @@ const PopupMenu = imports.ui.popupMenu;
|
||||
const TOOLTIP_OFFSET = 6;
|
||||
const TOOLTIP_ANIMATION_TIME = 150;
|
||||
@@ -22,8 +22,6 @@ const TOOLTIP_ANIMATION_TIME = 150;
|
||||
|
||||
const SCROLL_TIME = 100;
|
||||
|
||||
-const MAX_THUMBNAILS = 6;
|
||||
-
|
||||
let baseStyleClassName = '';
|
||||
|
||||
const WindowPreview = GObject.registerClass(
|
||||
@@ -432,12 +430,15 @@ const WorkspacePreviews = GObject.registerClass({
|
||||
@@ -439,12 +437,15 @@ const WorkspacePreviews = GObject.registerClass({
|
||||
var WorkspaceIndicator = GObject.registerClass(
|
||||
class WorkspaceIndicator extends PanelMenu.Button {
|
||||
_init(params = {}) {
|
||||
@ -3718,7 +3803,7 @@ index 368d785a..8c7b2258 100644
|
||||
baseStyleClassName = baseStyleClass;
|
||||
this.add_style_class_name(baseStyleClassName);
|
||||
|
||||
@@ -464,8 +465,6 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
@@ -471,8 +472,6 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
this._workspacesItems = [];
|
||||
|
||||
this._workspaceManagerSignals = [
|
||||
@ -3727,7 +3812,7 @@ index 368d785a..8c7b2258 100644
|
||||
workspaceManager.connect_after('workspace-switched',
|
||||
this._onWorkspaceSwitched.bind(this)),
|
||||
];
|
||||
@@ -482,6 +481,8 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
@@ -489,6 +488,8 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
this._updateTopBarRedirect();
|
||||
});
|
||||
|
||||
@ -3736,7 +3821,7 @@ index 368d785a..8c7b2258 100644
|
||||
this._updateThumbnailVisibility();
|
||||
}
|
||||
|
||||
@@ -497,8 +498,7 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
@@ -504,8 +505,7 @@ class WorkspaceIndicator extends PanelMenu.Button {
|
||||
}
|
||||
|
||||
_updateThumbnailVisibility() {
|
||||
@ -3760,10 +3845,10 @@ index bd39ab61..4d551780 100644
|
||||
2.44.0
|
||||
|
||||
|
||||
From f8497b510f2778a1ec985b546128096b461aa11e Mon Sep 17 00:00:00 2001
|
||||
From 3304c81ae897ea84f666b8c6818fa52f2bbef57d Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
||||
Date: Thu, 21 Mar 2024 17:27:09 +0100
|
||||
Subject: [PATCH 28/28] window-list: Expose workspace preview option
|
||||
Subject: [PATCH 29/29] window-list: Expose workspace preview option
|
||||
|
||||
Now that we have the option, the window-list should expose it
|
||||
in its preference window like the workspace-indicator.
|
||||
@ -3772,7 +3857,7 @@ in its preference window like the workspace-indicator.
|
||||
1 file changed, 6 insertions(+)
|
||||
|
||||
diff --git a/extensions/window-list/prefs.js b/extensions/window-list/prefs.js
|
||||
index aec8cc9d..e870c087 100644
|
||||
index e35990ff..79cd1355 100644
|
||||
--- a/extensions/window-list/prefs.js
|
||||
+++ b/extensions/window-list/prefs.js
|
||||
@@ -102,6 +102,12 @@ class WindowListPrefsWidget extends Gtk.Box {
|
||||
|
Loading…
Reference in New Issue
Block a user