mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Merge pull request #96 from cbhaley/master
Fix not actually setting the compression level
This commit is contained in:
commit
0ba14158c2
@ -1381,6 +1381,8 @@ class SMART_DEVICE_APP(DeviceConfig, DevicePlugin):
|
|||||||
cq = int(self.settings().extra_customization[self.OPT_COMPRESSION_QUALITY])
|
cq = int(self.settings().extra_customization[self.OPT_COMPRESSION_QUALITY])
|
||||||
if cq < 50 or cq > 99:
|
if cq < 50 or cq > 99:
|
||||||
compression_quality_ok = False
|
compression_quality_ok = False
|
||||||
|
else:
|
||||||
|
self.THUMBNAIL_COMPRESSION_QUALITY = cq
|
||||||
except:
|
except:
|
||||||
compression_quality_ok = False
|
compression_quality_ok = False
|
||||||
if not compression_quality_ok:
|
if not compression_quality_ok:
|
||||||
|
@ -111,6 +111,8 @@ class ColumnIcon(object): # {{{
|
|||||||
d = os.path.join(config_dir, 'cc_icons', icon)
|
d = os.path.join(config_dir, 'cc_icons', icon)
|
||||||
if (os.path.exists(d)):
|
if (os.path.exists(d)):
|
||||||
bm = QPixmap(d)
|
bm = QPixmap(d)
|
||||||
|
bm = bm.scaled(128, 128, aspectRatioMode= Qt.KeepAspectRatio,
|
||||||
|
transformMode=Qt.SmoothTransformation)
|
||||||
icon_bitmaps.append(bm)
|
icon_bitmaps.append(bm)
|
||||||
total_width += bm.width()
|
total_width += bm.width()
|
||||||
if len(icon_bitmaps) > 1:
|
if len(icon_bitmaps) > 1:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user