|
Methods defined here:
- __init__(self, types)
- Call this after initialising the widget.
Types is a list of MIME-types, or None to only accept files.
- xds_data_received(self, widget, context, x, y, selection, info, time)
- Called when we get some data. Internal.
- xds_drag_drop(self, widget, context, data, info, time)
- Called when something is dropped on us. Decide which of the
offered targets to request and ask for it. xds_data_received will
be called when it finally arrives.
- xds_load_from_file(self, path)
- Try to load this local file. Override this if you have a better way
to load files. The default method opens the file and calls xds_load_from_stream().
- xds_load_from_selection(self, selection, leafname=None)
- Try to load this selection (data from another application). The default
puts the data in a cStringIO and calls xds_load_from_stream().
- xds_load_from_stream(self, name, type, stream)
- Called when we get any data sent via drag-and-drop in any way (local
file or remote application transfer). You should override this and do
something with the data. 'name' may be None (if the data is unnamed),
a leafname, or a full path or URI. 'type' is the MIME type, or None if
unknown.
- xds_load_uris(self, uris)
- Try to load each URI in the list. Override this if you can handle URIs
directly. The default method passes each local path to xds_load_from_file()
and displays an error for anything else.
The uris are escaped, so a space will appear as '%20'
- xds_proxy_for(self, widget)
- Handle drops on this widget as if they were to 'self'.
|