[gnome-shell] workspace: Fix a signal leak in WorkspaceBackground
- From: Marge Bot <marge-bot src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] workspace: Fix a signal leak in WorkspaceBackground
- Date: Tue, 1 Feb 2022 12:17:41 +0000 (UTC)
commit ed7fe756ef41a4c6ba8515ad06d3cc166594898c
Author: Daniel van Vugt <daniel van vugt canonical com>
Date: Fri Jan 21 18:47:09 2022 +0800
workspace: Fix a signal leak in WorkspaceBackground
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2143>
js/ui/workspace.js | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
---
diff --git a/js/ui/workspace.js b/js/ui/workspace.js
index 6c32f01da9..1ad403f9f8 100644
--- a/js/ui/workspace.js
+++ b/js/ui/workspace.js
@@ -939,7 +939,7 @@ class WorkspaceBackground extends St.Widget {
this._workarea = Main.layoutManager.getWorkAreaForMonitor(monitorIndex);
this._stateAdjustment = stateAdjustment;
- stateAdjustment.connect('notify::value', () => {
+ this._adjustmentId = stateAdjustment.connect('notify::value', () => {
this._updateBorderRadius();
this.queue_relayout();
});
@@ -1054,6 +1054,11 @@ class WorkspaceBackground extends St.Widget {
global.display.disconnect(this._workareasChangedId);
delete this._workareasChangedId;
}
+
+ if (this._adjustmentId) {
+ this._stateAdjustment.disconnect(this._adjustmentId);
+ delete this._adjustmentId;
+ }
}
});
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]