mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Viewer: Fix a regression that broke the New bookmark button
Fixes #1864143 [Cannot create bookmark](https://bugs.launchpad.net/calibre/+bug/1864143)
This commit is contained in:
parent
2d61ed50d9
commit
6e8a80341b
@ -34,7 +34,7 @@ from calibre.srv.code import get_translations_data
|
|||||||
from calibre.utils.config import JSONConfig
|
from calibre.utils.config import JSONConfig
|
||||||
from calibre.utils.serialize import json_loads
|
from calibre.utils.serialize import json_loads
|
||||||
from calibre.utils.shared_file import share_open
|
from calibre.utils.shared_file import share_open
|
||||||
from polyglot.builtins import as_bytes, iteritems
|
from polyglot.builtins import as_bytes, iteritems, unicode_type
|
||||||
|
|
||||||
try:
|
try:
|
||||||
from PyQt5 import sip
|
from PyQt5 import sip
|
||||||
@ -633,7 +633,7 @@ class WebView(RestartingWebEngineView):
|
|||||||
vprefs['local_storage'] = sd
|
vprefs['local_storage'] = sd
|
||||||
|
|
||||||
def do_callback(self, func_name, callback):
|
def do_callback(self, func_name, callback):
|
||||||
cid = next(self.callback_id_counter)
|
cid = unicode_type(next(self.callback_id_counter))
|
||||||
self.callback_map[cid] = callback
|
self.callback_map[cid] = callback
|
||||||
self.execute_when_ready('get_current_cfi', cid)
|
self.execute_when_ready('get_current_cfi', cid)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user