From 68296bb2981aac2730c99c455b603c0c4b985577 Mon Sep 17 00:00:00 2001 From: rpm-build Date: Jan 15 2021 06:11:28 +0000 Subject: fix-some-js-warnings.patch patch_name: fix-some-js-warnings.patch present_in_specfile: true location_in_specfile: 39 --- diff --git a/js/gdm/realmd.js b/js/gdm/realmd.js index 50f3c58..04cd997 100644 --- a/js/gdm/realmd.js +++ b/js/gdm/realmd.js @@ -21,6 +21,7 @@ var Manager = class { '/org/freedesktop/realmd', this._reloadRealms.bind(this)) this._realms = {}; + this._loginFormat = null; this._signalId = this._aggregateProvider.connect('g-properties-changed', (proxy, properties) => { @@ -86,7 +87,7 @@ var Manager = class { } get loginFormat() { - if (this._loginFormat !== undefined) + if (this._loginFormat) return this._loginFormat; this._updateLoginFormat(); diff --git a/js/ui/popupMenu.js b/js/ui/popupMenu.js index badde35..d30c157 100644 --- a/js/ui/popupMenu.js +++ b/js/ui/popupMenu.js @@ -696,7 +696,8 @@ var PopupMenuBase = class { } _getMenuItems() { - return this.box.get_children().map(a => a._delegate).filter(item => { + const children = this.box.get_children().filter(a => a._delegate !== undefined); + return children.map(a => a._delegate).filter(item => { return item instanceof PopupBaseMenuItem || item instanceof PopupMenuSection; }); } diff --git a/js/ui/viewSelector.js b/js/ui/viewSelector.js index 7714655..6529ac9 100644 --- a/js/ui/viewSelector.js +++ b/js/ui/viewSelector.js @@ -301,11 +301,13 @@ var ViewSelector = class { _addPage(actor, name, a11yIcon, params) { params = Params.parse(params, { a11yFocus: null }); - let page = new St.Bin({ child: actor, - x_align: St.Align.START, - y_align: St.Align.START, - x_fill: true, - y_fill: true }); + let page = new St.Bin({ + x_align: St.Align.START, + y_align: St.Align.START, + x_fill: true, + y_fill: true, + }); + page.set_child(actor); if (params.a11yFocus) Main.ctrlAltTabManager.addGroup(params.a11yFocus, name, a11yIcon); else diff --git a/js/ui/workspacesView.js b/js/ui/workspacesView.js index 3e9d776..8ec610a 100644 --- a/js/ui/workspacesView.js +++ b/js/ui/workspacesView.js @@ -721,6 +721,9 @@ var WorkspacesDisplay = class { oldParent.disconnect(this._notifyOpacityId); this._notifyOpacityId = 0; + if (!this.actor.get_parent()) + return; + Meta.later_add(Meta.LaterType.BEFORE_REDRAW, () => { let newParent = this.actor.get_parent(); if (!newParent) diff --git a/src/st/st-shadow.c b/src/st/st-shadow.c index f3a22f0..7665de7 100644 --- a/src/st/st-shadow.c +++ b/src/st/st-shadow.c @@ -289,9 +289,10 @@ st_shadow_helper_paint (StShadowHelper *helper, ClutterActorBox *actor_box, guint8 paint_opacity) { - _st_paint_shadow_with_opacity (helper->shadow, - framebuffer, - helper->pipeline, - actor_box, - paint_opacity); + if (helper->pipeline != NULL) + _st_paint_shadow_with_opacity (helper->shadow, + framebuffer, + helper->pipeline, + actor_box, + paint_opacity); }