gtk.TreeView
drag
and drop operation
|
gtk.TreeView
drag
and drop operationclass gtk.TreeDragDest(gobject.GInterface): |
The gtk.TreeDragDest
is an interface for checking and receiving the data for the destination of a
gtk.TreeView
drag and drop operation.
def drag_data_received(dest
, selection_data
)
| the row to drop the data in front of |
| the data to drop |
Returns : | True if a new row was
created before position dest |
The drag_data_received
() method asks
the gtk.TreeDragDest
to insert a row before the path dest
, deriving the
contents of the row from selection_data
. If
dest
is outside the tree so that inserting before it
is impossible, False
will be returned. Also,
False
may be returned if the new row is not created for
some model-specific reason.
def row_drop_possible(dest_path
, selection_data
)
| a destination row |
| the data being dragged |
Returns : | True if a drop is possible before
dest_path |
The row_drop_possible
() method
determines if a drop is possible before the tree path specified by
dest_path
and at the same depth as
dest_path
. That is, can we drop the data specified by
selection_data
at that location.
dest_path
does not have to exist but the return value
will almost certainly be False
if the parent of
dest_path
doesn't exist, though.
© manpagez.com 2000-2024 Individual documents may contain additional copyright information.