fix: update crumbs when paginating

This commit is contained in:
aclist committed 2025-12-22 17:03:44 +09:00
1 parent 37dab3e83b
commit 248978f993
9 files changed
+54 -122

No files matched your search

+20 -6
View File
@@ -5,11 +5,25 @@ import gi
gi.require_version("Gtk", "3.0")
from gi.repository import Gtk # noqa E402
# TODO: abstract to support other icons
class WebButton(Gtk.Button):
def __init__(self, label: str):
super().__init__(label=label)
icon = Icon(WEB_BROWSER, l_margin=5)
self.set_image(icon)
class IconButton(Gtk.Button):
def __init__(self, icon: str, margin: int = 0):
super().__init__()
i = Icon(icon, l_margin=margin)
self.set_image(i)
self.set_image_position(Gtk.PositionType.RIGHT)
class IconTextButton(IconButton):
def __init__(self, icon: str, label: str):
super().__init__(icon, margin=5)
self.set_label(label)
class WebButton(IconTextButton):
def __init__(self, label: str):
super().__init__(icon=WEB_BROWSER, label=label)
pass