def get_thumbnail(self, width, height): if not (hasattr(self, "cover_data") or hasattr(self, "cover_file")): cover_file = self._get_thumb_local() if cover_file: self.cover_file = cover_file if _MUTAGEN and not hasattr(self, "cover_file"): cover_data = self._get_thumb_metadata() if cover_data: self.cover_data = cover_data try: if hasattr(self, "cover_file"): return icons.get_pixbuf_from_file(self.cover_file, width, height) elif hasattr(self, "cover_data"): return icons.get_pixbuf_from_data(self.cover_data, width, height) except(glib.GError): pass
def get_thumbnail(self, width, height): if not (hasattr(self, "cover_data") or hasattr(self, "cover_file")): cover_file = self._get_thumb_local() if cover_file: self.cover_file = cover_file if _MUTAGEN and not hasattr(self, "cover_file"): cover_data = self._get_thumb_metadata() if cover_data: self.cover_data = cover_data try: if hasattr(self, "cover_file"): return icons.get_pixbuf_from_file(self.cover_file, width, height) elif hasattr(self, "cover_data"): return icons.get_pixbuf_from_data(self.cover_data, width, height) except (glib.GError): pass
def get_thumbnail(self, width, height): if self.image: return icons.get_pixbuf_from_data(self.image, width, height) return GroupingLeaf.get_thumbnail(self, width, height)
def get_thumbnail(self, width, height): if self.image: return icons.get_pixbuf_from_data(self.image, width, height) return EmailContact.get_thumbnail(self, width, height)
def get_thumbnail(self, width, height): if self.thumb: return icons.get_pixbuf_from_data(self.thumb, width, height) return UrlLeaf.get_thumbnail(self, width, height)