mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-06-23 15:30:45 -04:00
Also add touch-action: none to the main document
This commit is contained in:
parent
ea7ad6fc0a
commit
1c9db87492
@ -67,7 +67,9 @@ def init_ui():
|
|||||||
install(translations)
|
install(translations)
|
||||||
remove_initial_progress_bar()
|
remove_initial_progress_bar()
|
||||||
document.head.appendChild(E.style(get_widget_css()))
|
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.appendChild(E.div())
|
||||||
document.body.lastChild.appendChild(E.div(id=book_list_container_id, style='display: none'))
|
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'))
|
document.body.lastChild.appendChild(E.div(id=read_book_container_id, style='display: none'))
|
||||||
|
@ -408,7 +408,9 @@ if window is window.top:
|
|||||||
window.onerror = onerror
|
window.onerror = onerror
|
||||||
create_modal_container()
|
create_modal_container()
|
||||||
document.head.appendChild(E.style(get_widget_css()))
|
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():
|
setTimeout(def():
|
||||||
window.onpopstate = on_pop_state
|
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
|
, 0) # We do this after event loop ticks over to avoid catching popstate events that some browsers send on page load
|
||||||
|
Loading…
x
Reference in New Issue
Block a user