mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Edit Book: Reports tool: Fix double clicking on an unused image causing an error
This commit is contained in:
parent
0e2de4306c
commit
e07fc77a52
@ -336,9 +336,10 @@ class Jump(object):
|
||||
self.pos_map.clear()
|
||||
|
||||
def __call__(self, key, locations):
|
||||
self.pos_map[key] = (self.pos_map[key] + 1) % len(locations)
|
||||
loc = locations[self.pos_map[key]]
|
||||
jump_to_location(loc)
|
||||
if len(locations):
|
||||
self.pos_map[key] = (self.pos_map[key] + 1) % len(locations)
|
||||
loc = locations[self.pos_map[key]]
|
||||
jump_to_location(loc)
|
||||
|
||||
jump = Jump() # }}}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user