overview: Skip SHOWN to SHOWN when changing from app grid to overview

Switching between the app grid and the window picker in the overview via
gestures results in _gestureEnd() getting called with endProgress !== 0
in both cases, which leads to it calling _showDone(). This then
unconditionally changes the state to SHOWN, which in this situation is
already the current state. Since the previous commit this results in a
warning, so check if we are already in the SHOWN state.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/2514>
This commit is contained in:
Sebastian Keller 2022-12-20 13:49:59 +01:00 committed by Marge Bot
parent a91b6439ba
commit f5d793647b

View File

@ -573,7 +573,9 @@ var Overview = class extends Signals.EventEmitter {
this._animationInProgress = false;
this._coverPane.hide();
this._changeShownState(OverviewShownState.SHOWN);
if (this._shownState !== OverviewShownState.SHOWN)
this._changeShownState(OverviewShownState.SHOWN);
// Handle any calls to hide* while we were showing
if (!this._shown)
this._animateNotVisible();