Don't set album art from pixbuf if pixbuf is None
This commit is contained in:
parent
ca46e8db4c
commit
0c3acb92d2
|
@ -25,7 +25,8 @@ class Image(gtk.Image):
|
|||
new_w = (float(w) / float(h)) * new_h
|
||||
if new_w > 0 and new_h > 0:
|
||||
buf = buf.scale_simple(int(new_w), int(new_h), gtk.gdk.INTERP_HYPER)
|
||||
self.set_from_pixbuf(buf)
|
||||
if buf != None:
|
||||
self.set_from_pixbuf(buf)
|
||||
|
||||
|
||||
class AlbumArt(Image):
|
||||
|
|
Loading…
Reference in New Issue