From 0139ed13fed3ace0fec79c8ffe634dff1d97338d Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Mon, 8 Feb 2021 15:11:35 +0530 Subject: [PATCH] E-book viewer: Hide the controls when clicking the back or forward buttons --- src/pyj/read_book/iframe.pyj | 1 - src/pyj/read_book/overlay.pyj | 2 ++ 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pyj/read_book/iframe.pyj b/src/pyj/read_book/iframe.pyj index 14715fd0a8..f7fef6334d 100644 --- a/src/pyj/read_book/iframe.pyj +++ b/src/pyj/read_book/iframe.pyj @@ -653,7 +653,6 @@ class IframeBoss: def send_message(self, action, **data): self.comm.send_message(action, data) - def connect_links(self): for a in document.body.querySelectorAll(f'a[{self.link_attr}]'): a.addEventListener('click', self.link_activated) diff --git a/src/pyj/read_book/overlay.pyj b/src/pyj/read_book/overlay.pyj index 2e87c0373f..a80bfec82c 100644 --- a/src/pyj/read_book/overlay.pyj +++ b/src/pyj/read_book/overlay.pyj @@ -428,9 +428,11 @@ class MainOverlay: # {{{ def back(self): window.history.back() + self.overlay.hide() def forward(self): window.history.forward() + self.overlay.hide() # }}}