From 667576e0567eb64f1470a83686b96b9ba578d367 Mon Sep 17 00:00:00 2001 From: MrTimscampi Date: Sun, 16 Aug 2020 16:12:33 +0200 Subject: [PATCH] Fix suggestions --- src/components/scrollManager.js | 4 +--- src/plugins/chromecastPlayer/chromecastHelper.js | 2 +- src/scripts/site.js | 2 -- 3 files changed, 2 insertions(+), 6 deletions(-) diff --git a/src/components/scrollManager.js b/src/components/scrollManager.js index 4ee31a6275..c2cbfb7587 100644 --- a/src/components/scrollManager.js +++ b/src/components/scrollManager.js @@ -532,9 +532,7 @@ import layoutManager from 'layoutManager'; if (isEnabled()) { dom.addEventListener(window, 'focusin', function(e) { - setTimeout(function() { - scrollToElement(e.target, useSmoothScroll()); - }, 0); + scrollToElement(e.target, useSmoothScroll()); }, {capture: true}); } diff --git a/src/plugins/chromecastPlayer/chromecastHelper.js b/src/plugins/chromecastPlayer/chromecastHelper.js index 5893a5fe20..7aac76c544 100644 --- a/src/plugins/chromecastPlayer/chromecastHelper.js +++ b/src/plugins/chromecastPlayer/chromecastHelper.js @@ -170,7 +170,7 @@ function isLocalIpAddress(address) { return false; } -function getServerAddress(apiClient) { +export function getServerAddress(apiClient) { const serverAddress = apiClient.serverAddress(); if (isValidIpAddress(serverAddress) && !isLocalIpAddress(serverAddress)) { diff --git a/src/scripts/site.js b/src/scripts/site.js index bf0fa75efa..08e75cfd1a 100644 --- a/src/scripts/site.js +++ b/src/scripts/site.js @@ -425,7 +425,6 @@ function initClient() { keyboardnavigation.enable(); }); require(['mouseManager']); - require(['focusPreventScroll']); require(['autoFocuser'], function(autoFocuser) { autoFocuser.enable(); }); @@ -819,7 +818,6 @@ function initClient() { return viewManager; }); define('slideshow', [componentsPath + '/slideshow/slideshow'], returnFirstDependency); - define('focusPreventScroll', ['legacy/focusPreventScroll'], returnFirstDependency); define('userdataButtons', [componentsPath + '/userdatabuttons/userdatabuttons'], returnFirstDependency); define('listView', [componentsPath + '/listview/listview'], returnFirstDependency); define('indicators', [componentsPath + '/indicators/indicators'], returnFirstDependency);