mirror of
https://github.com/aclist/dztui.git
synced 2026-11-06 10:00:54 +01:00
fix: pass correct number of records
This commit is contained in:
1 parent
1b1cb33a6e
commit
672c8f9e9e
4 files changed
+22
-13
No files matched your search
@@ -50,15 +50,22 @@ class LogTreeView(ContextMixin, TreeView):
|
||||
|
||||
def _on_log_buttonpress(self, widget: Gtk.Widget, event: Gdk.EventButton) -> None:
|
||||
if event.button == Gdk.BUTTON_SECONDARY:
|
||||
path, col, x, y = self.get_path_at_pos(int(event.x), int(event.y))
|
||||
if path:
|
||||
selection = self.get_selection()
|
||||
model, selected_paths = selection.get_selected_rows()
|
||||
if path not in selected_paths:
|
||||
selection.select_path(path)
|
||||
self.present_menu(widget, event)
|
||||
return True
|
||||
return False
|
||||
#selection = self.get_selection()
|
||||
#model, selected_paths = selection.get_selected_rows()
|
||||
#if len(selected_paths) > 1:
|
||||
# for path in selected_paths:
|
||||
# selection.select_path(path)
|
||||
# path, col, x, y = self.get_path_at_pos(int(event.x), int(event.y))
|
||||
# if path:
|
||||
# selection = self.get_selection()
|
||||
# model, selected_paths = selection.get_selected_rows()
|
||||
# if path not in selected_paths:
|
||||
# selection.select_path(path)
|
||||
# self.present_menu(widget, event)
|
||||
# return True
|
||||
#return False
|
||||
|
||||
def _on_log_keypress(self, widget: Gtk.Widget, event: Gdk.EventKey) -> None:
|
||||
self.present_menu(widget, event)
|
||||
Reference in new issue
Block a user