mirror of
https://github.com/edu4rdshl/gnome-shell.git
synced 2026-07-17 23:24:51 +00:00
iconGrid: Disconnect signals on destroy
Otherwise the handler will trip over unset properties on an object
that is being disposed. Avoid the resulting log spam by disconnecting
the handler in question.
Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1909>
(cherry picked from commit 30e49cc3ca)
This commit is contained in:
parent
ef3ac72b68
commit
fc0a87e8a5
1 changed files with 3 additions and 1 deletions
|
|
@ -1311,7 +1311,8 @@ var IconGrid = GObject.registerClass({
|
|||
row_spacing: 0,
|
||||
});
|
||||
const layoutManager = new IconGridLayout(layoutParams);
|
||||
layoutManager.connect('pages-changed', () => this.emit('pages-changed'));
|
||||
const pagesChangedId = layoutManager.connect('pages-changed',
|
||||
() => this.emit('pages-changed'));
|
||||
|
||||
super._init({
|
||||
style_class: 'icon-grid',
|
||||
|
|
@ -1327,6 +1328,7 @@ var IconGrid = GObject.registerClass({
|
|||
|
||||
this.connect('actor-added', this._childAdded.bind(this));
|
||||
this.connect('actor-removed', this._childRemoved.bind(this));
|
||||
this.connect('destroy', () => layoutManager.disconnect(pagesChangedId));
|
||||
}
|
||||
|
||||
_getChildrenToAnimate() {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue