diff --git a/js/ui/workspace.js b/js/ui/workspace.js index 3e76d717b..0fa38d13b 100644 --- a/js/ui/workspace.js +++ b/js/ui/workspace.js @@ -1051,9 +1051,6 @@ Workspace.prototype = { cloneWidth = this.scale * clone.actor.scale_x * cloneWidth; cloneHeight = this.scale * clone.actor.scale_y * cloneHeight; - if (!this._windowOverlaysGroup.visible) - this._windowOverlaysGroup.show(); - if (overlay) { overlay.updatePositions(cloneX, cloneY, cloneWidth, cloneHeight); if (fade) @@ -1074,13 +1071,6 @@ Workspace.prototype = { } }, - _hideAllOverlays: function() { - for (let i = 0; i < this._windows.length; i++) { - let overlay = this._windowOverlays[i]; - overlay.hide(); - } - }, - _delayedWindowRepositioning: function() { if (this._windowIsZooming) return true; @@ -1105,6 +1095,9 @@ Workspace.prototype = { }, showWindowsOverlays: function() { + if (this.leavingOverview) + return; + this._windowOverlaysGroup.show(); this._showAllOverlays(); }, @@ -1231,7 +1224,7 @@ Workspace.prototype = { this.leavingOverview = true; - this._hideAllOverlays(); + this.hideWindowsOverlays(); if (this._repositionWindowsId > 0) { Mainloop.source_remove(this._repositionWindowsId); diff --git a/js/ui/workspacesView.js b/js/ui/workspacesView.js index b2cd17888..32f5e2c71 100644 --- a/js/ui/workspacesView.js +++ b/js/ui/workspacesView.js @@ -634,7 +634,7 @@ WorkspacesView.prototype = { let dy = newY - currentY; for (let i = 0; i < this._workspaces.length; i++) { - this._workspaces[i]._hideAllOverlays(); + this._workspaces[i].hideWindowsOverlays(); this._workspaces[i].actor.visible = Math.abs(i - adj.value) <= 1; this._workspaces[i].actor.y += dy; }