From e35bcd60663b3f3146e1a65116a125e52fc2a8aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tor=20Hedin=20Br=C3=B8nner?= Date: Tue, 17 Apr 2018 18:16:20 +0200 Subject: [PATCH] Always animate worspace change properly --- navigator.js | 11 ----------- tiling.js | 8 ++++---- 2 files changed, 4 insertions(+), 15 deletions(-) diff --git a/navigator.js b/navigator.js index 432c37c..c190d30 100644 --- a/navigator.js +++ b/navigator.js @@ -267,17 +267,6 @@ WindowManager.WindowManager.prototype._previewWorkspace = function(from, to, cal y: yDest, time: 0.25, transition: 'easeInOutQuad', - onComplete: () => { - Main.uiGroup.set_child_above_sibling( - toSpace.cloneContainer, - fromSpace.cloneContainer); - }, - onOverwrite: () => { - Main.uiGroup.set_child_above_sibling( - toSpace.cloneContainer, - fromSpace.cloneContainer); - } - }); Tweener.addTween(toSpace.cloneContainer, { x: 0, diff --git a/tiling.js b/tiling.js index 8d603f0..d4262f8 100644 --- a/tiling.js +++ b/tiling.js @@ -70,10 +70,10 @@ function enable() { global.screen.connect( 'workspace-switched', (screen, from, to) => { - let f = spaces.get(global.screen.get_workspace_by_index(from)); - let t = spaces.get(global.screen.get_workspace_by_index(to)); - Main.uiGroup.set_child_above_sibling(t.cloneContainer, - f.cloneContainer); + Main.wm._previewWorkspace( + global.screen.get_workspace_by_index(from), + global.screen.get_workspace_by_index(to) + ); }), // Reset primary when monitors change