@@ -46,7 +46,10 @@ FocusScope {
4646 if (root.altTabPressed) {
4747 print("should tab next")
4848 appRepeater.highlightedIndex = (appRepeater.highlightedIndex + 1) % ApplicationManager.count;
49− spreadFlickable.snapTo(spreadFlickable.width / 5 * Math.max(0, Math.min(ApplicationManager.count - 5, appRepeater.highlightedIndex - 3)))
49+ var newContentX = spreadFlickable.width / 5 * Math.max(0, Math.min(ApplicationManager.count - 5, appRepeater.highlightedIndex - 3));
50+ if (spreadFlickable.contentX < newContentX) {
51+ spreadFlickable.snapTo(newContentX)
52+ }
5053 }
5154 }
5255
@@ -55,7 +58,10 @@ FocusScope {
5558 if (root.altTabPressed) {
5659 var newIndex = appRepeater.highlightedIndex - 1 >= 0 ? appRepeater.highlightedIndex - 1 : ApplicationManager.count - 1;
5760 appRepeater.highlightedIndex = newIndex;
58− spreadFlickable.snapTo(spreadFlickable.width / 5 * Math.max(0, Math.min(ApplicationManager.count - 5, appRepeater.highlightedIndex - 1)))
61+ var newContentX = spreadFlickable.width / 5 * Math.max(0, Math.min(ApplicationManager.count - 5, appRepeater.highlightedIndex - 1));
62+ if (spreadFlickable.contentX > newContentX) {
63+ spreadFlickable.snapTo(newContentX)
64+ }
5965 }
6066 }
6167