Viewer: Stop autoscroll when changing page layout mode. Fixes #1861621 [Sudden position change when reading](https://bugs.launchpad.net/calibre/+bug/1861621)

This commit is contained in:
Kovid Goyal 2020-02-03 08:42:06 +05:30
parent 38950aa52c
commit 8c5810f8c3
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -198,6 +198,7 @@ class IframeBoss:
self.jump_to_cfi = scroll_to_cfi
self.anchor_funcs = flow_anchor_funcs
self.auto_scroll_action = flow_auto_scroll_action
paged_auto_scroll_action('stop')
else:
self.do_layout = paged_layout
self.handle_wheel = paged_onwheel
@ -207,6 +208,7 @@ class IframeBoss:
self._handle_gesture = paged_handle_gesture
self.anchor_funcs = paged_anchor_funcs
self.auto_scroll_action = paged_auto_scroll_action
flow_auto_scroll_action('stop')
update_settings(data.settings)
self.keyboard_shortcut_map = create_shortcut_map(data.settings.keyboard_shortcuts)
set_current_spine_item({