From 3ac08a8c0df1f4a70d6b3ca600a9a88fe06ae092 Mon Sep 17 00:00:00 2001 From: GarcaMan Date: Thu, 2 Dec 2021 18:20:14 +0000 Subject: [PATCH] After toggling fullscreen, focus on main container --- cps/static/js/kthoom.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cps/static/js/kthoom.js b/cps/static/js/kthoom.js index cfc9cf2d..b637fc93 100644 --- a/cps/static/js/kthoom.js +++ b/cps/static/js/kthoom.js @@ -666,7 +666,6 @@ function init(filename) { //reloadImages is a slow process when multiple images are involved. Only used when rotating/mirroring reloadImages(); } else if(this.name === "direction") { - // Skips updatePage and updateScale so that the current image doesn't scroll up return updateProgress(); } @@ -689,6 +688,8 @@ function init(filename) { if (typeof screenfull !== "undefined") { $("#fullscreen").click(function() { screenfull.toggle($("#container")[0]); + // Focus so you can use up/down keys immediately after fullscreen + $("#mainContent").focus(); }); if (screenfull.raw) {