diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-02-05 07:44:04 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2023-02-05 08:57:36 +0000 |
commit | 4a62513b17d915afcae80b1adfb1b0cdcf86f748 (patch) | |
tree | a21f339a82d742682a1dfbf63d7fe9c43d58a3a2 /extensions/vertical-workspaces/overview.js | |
parent | Adding upstream version 20230204. (diff) | |
download | gnome-shell-extensions-extra-4a62513b17d915afcae80b1adfb1b0cdcf86f748.tar.xz gnome-shell-extensions-extra-4a62513b17d915afcae80b1adfb1b0cdcf86f748.zip |
Adding upstream version 20230205.upstream/20230205
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to '')
-rw-r--r-- | extensions/vertical-workspaces/overview.js | 68 |
1 files changed, 68 insertions, 0 deletions
diff --git a/extensions/vertical-workspaces/overview.js b/extensions/vertical-workspaces/overview.js new file mode 100644 index 0000000..db267b6 --- /dev/null +++ b/extensions/vertical-workspaces/overview.js @@ -0,0 +1,68 @@ +/** + * Vertical Workspaces + * overview.js + * + * panel barrier should follow panel position + * or disable it to not collide with Custom Hot Corners barriers + * + * @author GdH <G-dH@github.com> + * @copyright 2022 - 2023 + * @license GPL-3.0 + * + */ + +'use strict'; + +const { Meta, Clutter } = imports.gi; + +const Main = imports.ui.main; +const Overview = imports.ui.overview; + +const Me = imports.misc.extensionUtils.getCurrentExtension(); +const _Util = Me.imports.util; + +let _overrides; +let opt; + +function update(reset = false) { + if (_overrides) { + _overrides.removeAll(); + } + + if (reset) { + _overrides = null; + opt = null; + return; + } + + opt = Me.imports.settings.opt; + + _overrides = new _Util.Overrides(); + + _overrides.addOverride('Overview', Overview.Overview.prototype, OverviewCommon); +} + + +const OverviewCommon = { + _showDone: function() { + this._animationInProgress = false; + this._coverPane.hide(); + + this.emit('shown'); + // Handle any calls to hide* while we were showing + if (!this._shown) + this._animateNotVisible(); + + this._syncGrab(); + + // if user activates overview during startup animation, transition needs to be shifted to the state 2 here + const controls = this._overview._controls; + if (controls._searchController._searchActive && controls._stateAdjustment.value === 1) { + if (opt.SEARCH_VIEW_ANIMATION) { + controls._onSearchChanged(); + } else { + controls._stateAdjustment.value = 2; + } + } + } +} |