refactor (almost) entire gui to split into multiple files

This commit is contained in:
2026-03-13 18:57:25 +01:00
parent 7de83ae6d0
commit 7cc36fb3ed
15 changed files with 747 additions and 665 deletions
@@ -0,0 +1,19 @@
from core.interface.dialogs.theme import _theme_colors
from PySide6.QtWidgets import QStyledItemDelegate
from PySide6 import QtWidgets
class HoverRowDelegate(QStyledItemDelegate):
def paint(self, painter, option, index):
from core.interface.gui import MainWindow
opt = QtWidgets.QStyleOptionViewItem(option)
option.state &= ~QtWidgets.QStyle.StateFlag.State_HasFocus
option.state &= ~QtWidgets.QStyle.StateFlag.State_Selected
hovered_row = MainWindow._instance._hovered_row if MainWindow._instance else -1
if index.row() == hovered_row:
painter.save()
painter.fillRect(option.rect, _theme_colors()["hover"])
painter.restore()
super().paint(painter, opt, index)