From f840387d70226cc2f09abb08e5d50ec24bf23a1e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tor=20Hedin=20Br=C3=B8nner?= Date: Thu, 19 Apr 2018 06:12:18 +0200 Subject: [PATCH] liveAltTab: Block un/minimize animations When alt-tabbing to a scratch window we do an instant preview. Focusing the window would then trigger an un-minimize animation which would look weird. --- liveAltTab.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/liveAltTab.js b/liveAltTab.js index e254f2f..dc02d71 100644 --- a/liveAltTab.js +++ b/liveAltTab.js @@ -17,6 +17,10 @@ var LiveAltTab = Lang.Class({ _getWindowList: function () { let tabList = global.display.get_tab_list(Meta.TabList.NORMAL_ALL, global.screen.get_active_workspace()); + + this._block = Main.wm._blockAnimations; + Main.wm._blockAnimations = true; + if (Scratch.isScratchActive()) { return Scratch.getScratchWindows(); } else { @@ -86,6 +90,7 @@ var LiveAltTab = Lang.Class({ _onDestroy: function() { debug('#preview', 'onDestroy', this.was_accepted); + Main.wm._blockAnimations = this._block; if(!this.was_accepted) { // Select the starting window this._select(0);