[gnome-shell/gbsneto/random-cleanups-pt1: 1/4] workspacesView: Override vfunc_hide
- From: Georges Basile Stavracas Neto <gbsneto src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell/gbsneto/random-cleanups-pt1: 1/4] workspacesView: Override vfunc_hide
- Date: Tue, 2 Jun 2020 17:53:55 +0000 (UTC)
commit 28e270c08a3c9903d6f012c4ad98e8532a74c4d4
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Tue Jun 2 14:15:45 2020 -0300
workspacesView: Override vfunc_hide
Override the hide vfunc instead of the plain hide() method.
https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1295
js/ui/viewSelector.js | 1 -
js/ui/workspacesView.js | 10 ++++++++--
2 files changed, 8 insertions(+), 3 deletions(-)
---
diff --git a/js/ui/viewSelector.js b/js/ui/viewSelector.js
index 930e5b1e6d..52fa664896 100644
--- a/js/ui/viewSelector.js
+++ b/js/ui/viewSelector.js
@@ -303,7 +303,6 @@ var ViewSelector = GObject.registerClass({
hide() {
this.reset();
- this._workspacesDisplay.hide();
}
_addPage(actor, name, a11yIcon, params) {
diff --git a/js/ui/workspacesView.js b/js/ui/workspacesView.js
index b196427cc9..2e34e4cc1c 100644
--- a/js/ui/workspacesView.js
+++ b/js/ui/workspacesView.js
@@ -393,7 +393,10 @@ class ExtraWorkspaceView extends WorkspacesViewBase {
var WorkspacesDisplay = GObject.registerClass(
class WorkspacesDisplay extends St.Widget {
_init(scrollAdjustment) {
- super._init({ clip_to_allocation: true });
+ super._init({
+ visible: true,
+ clip_to_allocation: true,
+ });
this.connect('notify::allocation', this._updateWorkspacesActualGeometry.bind(this));
let workspaceManager = global.workspace_manager;
@@ -609,6 +612,7 @@ class WorkspacesDisplay extends St.Widget {
}
animateToOverview(fadeOnPrimary) {
+ this.show();
this._updateWorkspacesViews();
for (let i = 0; i < this._workspacesViews.length; i++) {
let animationType;
@@ -640,7 +644,7 @@ class WorkspacesDisplay extends St.Widget {
}
}
- hide() {
+ vfunc_hide() {
if (this._restackedNotifyId > 0) {
Main.overview.disconnect(this._restackedNotifyId);
this._restackedNotifyId = 0;
@@ -656,6 +660,8 @@ class WorkspacesDisplay extends St.Widget {
for (let i = 0; i < this._workspacesViews.length; i++)
this._workspacesViews[i].destroy();
this._workspacesViews = [];
+
+ super.vfunc_hide();
}
_workspacesOnlyOnPrimaryChanged() {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]