[pygobject] Override get_path_at_pos and get_dest_row_at_pos of Gtk.TreeView to not return success value
- From: Sebastian Polsterl <sebp src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pygobject] Override get_path_at_pos and get_dest_row_at_pos of Gtk.TreeView to not return success value
- Date: Tue, 26 Oct 2010 13:50:15 +0000 (UTC)
commit 6679d39ace06294e98f9d6fc911ed6fb27656010
Author: Sebastian Pölsterl <sebp k-d-w org>
Date: Sat Oct 23 14:21:36 2010 +0200
Override get_path_at_pos and get_dest_row_at_pos of Gtk.TreeView to not return success value
gi/overrides/Gtk.py | 15 +++++++++++++++
1 files changed, 15 insertions(+), 0 deletions(-)
---
diff --git a/gi/overrides/Gtk.py b/gi/overrides/Gtk.py
index 1d3be32..047d3e7 100644
--- a/gi/overrides/Gtk.py
+++ b/gi/overrides/Gtk.py
@@ -781,6 +781,21 @@ class TreeSortable(Gtk.TreeSortable):
TreeSortable = override(TreeSortable)
__all__.append('TreeSortable')
+class TreeView(Gtk.TreeView):
+
+ def get_path_at_pos(self, x, y):
+ success, path, column, cell_x, cell_y = super(TreeView, self).get_path_at_pos(x, y)
+ if success:
+ return (path, column, cell_x, cell_y,)
+
+ def get_dest_row_at_pos(self, drag_x, drag_y):
+ success, path, pos = super(TreeView, self).get_dest_row_at_pos(drag_x, drag_y)
+ if success:
+ return (path, pos,)
+
+TreeView = override(TreeView)
+__all__.append('TreeView')
+
class TreeViewColumn(Gtk.TreeViewColumn):
def __init__(self, title='',
cell_renderer=None,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]