mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
a72084d92c
commit
2cdb738d90
@ -224,7 +224,9 @@ class ImageView(QDialog):
|
|||||||
def factor_from_fit(self):
|
def factor_from_fit(self):
|
||||||
scaled_height = self.label.size().height()
|
scaled_height = self.label.size().height()
|
||||||
actual_height = self.current_img.size().height()
|
actual_height = self.current_img.size().height()
|
||||||
return scaled_height / actual_height
|
if actual_height:
|
||||||
|
return scaled_height / actual_height
|
||||||
|
return 1
|
||||||
|
|
||||||
def zoom_requested(self, zoom_out):
|
def zoom_requested(self, zoom_out):
|
||||||
if (zoom_out and self.zo_button.isEnabled()) or (not zoom_out and self.zi_button.isEnabled()):
|
if (zoom_out and self.zo_button.isEnabled()) or (not zoom_out and self.zi_button.isEnabled()):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user