Greatly enhanced thumbnail scrolling logic/simplified it

This commit is contained in:
2023-04-24 00:12:56 -05:00
parent 049bf2e408
commit f54acba4cb
3 changed files with 46 additions and 43 deletions

View File

@@ -23,8 +23,9 @@ class Image(Gtk.EventBox):
self._thumbnail_with = settings.get_thumbnail_with()
self._thumbnail_height = settings.get_thumbnail_height()
self.image = None
self.path = path
self.is_loaded = False
self.image = None
self.path = path
self._setup_styling()
self._setup_signals()
@@ -56,6 +57,7 @@ class Image(Gtk.EventBox):
self.set_from_pixbuf( self.get_pixbuf_data(self.path, \
self._thumbnail_with, \
self._thumbnail_height) )
self.is_loaded = True
def get_pixbuf_data(self, path, w = 126, h = 126):
path = self.path if not path else path