chore: clear typehinting errors

This commit is contained in:
aclist committed 2026-05-05 23:37:31 +09:00
1 parent e64feac425
commit 25640751a5
23 files changed
+86 -105

No files matched your search

+3 -2
View File
@@ -134,7 +134,8 @@ class TreeView(CursorMixin, Gtk.TreeView): # type: ignore
self.get_selection().unselect_path(path)
def focus_first_row(self) -> None:
self.set_cursor(0)
path = Gtk.TreePath.new_from_indices([0])
self.set_cursor(path)
def get_value_at_index(self, index: int) -> str:
(model, pathlist) = self.get_model_and_pathlist()
@@ -143,7 +144,7 @@ class TreeView(CursorMixin, Gtk.TreeView): # type: ignore
path = pathlist[0]
tree_iter = model.get_iter(path)
value = model.get_value(tree_iter, index)
return value
return str(value)
def get_name(self) -> str:
name = self.get_value_at_index(0)