diff --git a/src/pyj/book_list/main.pyj b/src/pyj/book_list/main.pyj index b52de2eb9a..23a6d01152 100644 --- a/src/pyj/book_list/main.pyj +++ b/src/pyj/book_list/main.pyj @@ -67,7 +67,9 @@ def init_ui(): install(translations) remove_initial_progress_bar() document.head.appendChild(E.style(get_widget_css())) - set_css(document.body, background_color=get_color('window-background'), color=get_color('window-foreground')) + # See https://github.com/kovidgoyal/calibre/pull/1101 + # for why we need touch-action: none + set_css(document.body, background_color=get_color('window-background'), color=get_color('window-foreground'), touch_action='none') document.body.appendChild(E.div()) document.body.lastChild.appendChild(E.div(id=book_list_container_id, style='display: none')) document.body.lastChild.appendChild(E.div(id=read_book_container_id, style='display: none')) diff --git a/src/pyj/viewer-main.pyj b/src/pyj/viewer-main.pyj index 0899da7a53..8da2bedf32 100644 --- a/src/pyj/viewer-main.pyj +++ b/src/pyj/viewer-main.pyj @@ -408,7 +408,9 @@ if window is window.top: window.onerror = onerror create_modal_container() document.head.appendChild(E.style(get_widget_css())) - set_css(document.body, background_color=get_color('window-background'), color=get_color('window-foreground')) + # See https://github.com/kovidgoyal/calibre/pull/1101 + # for why we need touch-action: none + set_css(document.body, background_color=get_color('window-background'), color=get_color('window-foreground'), touch_action='none') setTimeout(def(): window.onpopstate = on_pop_state , 0) # We do this after event loop ticks over to avoid catching popstate events that some browsers send on page load