summaryrefslogtreecommitdiff
path: root/gi/overrides
diff options
context:
space:
mode:
authorArjan Molenaar <gaphor@gmail.com>2021-05-19 15:36:42 +0200
committerChristoph Reiter <reiter.christoph@gmail.com>2022-03-27 15:35:23 +0200
commit8ea38cd186f5e33d8e328a8b66180f7ca83abedc (patch)
treec2c963cda8edc5670947ee9c869e2f793dee5dd4 /gi/overrides
parent22c7b28d4395dbf7da9b9ff9a1ef6725c4d52399 (diff)
downloadpygobject-8ea38cd186f5e33d8e328a8b66180f7ca83abedc.tar.gz
Do not override Treeview.enable_model_drag_xx for GTK4
Those methods require a Gdk.ContentFormats object.
Diffstat (limited to 'gi/overrides')
-rw-r--r--gi/overrides/Gtk.py22
1 files changed, 12 insertions, 10 deletions
diff --git a/gi/overrides/Gtk.py b/gi/overrides/Gtk.py
index f53ec6bd..d9ec6fbe 100644
--- a/gi/overrides/Gtk.py
+++ b/gi/overrides/Gtk.py
@@ -1359,16 +1359,18 @@ class TreeView(Gtk.TreeView, Container):
get_visible_range = strip_boolean_result(Gtk.TreeView.get_visible_range)
get_dest_row_at_pos = strip_boolean_result(Gtk.TreeView.get_dest_row_at_pos)
- def enable_model_drag_source(self, start_button_mask, targets, actions):
- target_entries = _construct_target_list(targets)
- super(TreeView, self).enable_model_drag_source(start_button_mask,
- target_entries,
- actions)
-
- def enable_model_drag_dest(self, targets, actions):
- target_entries = _construct_target_list(targets)
- super(TreeView, self).enable_model_drag_dest(target_entries,
- actions)
+ if GTK2 or GTK3:
+ def enable_model_drag_source(self, start_button_mask, targets, actions):
+ target_entries = _construct_target_list(targets)
+ super(TreeView, self).enable_model_drag_source(start_button_mask,
+ target_entries,
+ actions)
+
+ if GTK2 or GTK3:
+ def enable_model_drag_dest(self, targets, actions):
+ target_entries = _construct_target_list(targets)
+ super(TreeView, self).enable_model_drag_dest(target_entries,
+ actions)
def scroll_to_cell(self, path, column=None, use_align=False, row_align=0.0, col_align=0.0):
if not isinstance(path, Gtk.TreePath):