r1537: Bugfix: Default icon for iconified windows wasn't found (Jimmy Olgeni).
[rox-filer.git] / ROX-Filer / src / dnd.h
blob7fab50678ad1ad6c31b1776567af2366dc782b9e
1 /*
2 * $Id$
4 * ROX-Filer, filer for the ROX desktop project
5 * By Thomas Leonard, <tal197@users.sourceforge.net>.
6 */
8 #ifndef _DND_H
9 #define _DND_H
11 #include <gtk/gtk.h>
13 enum
15 TARGET_RAW,
16 TARGET_URI_LIST,
17 TARGET_XDS,
18 TARGET_STRING,
21 typedef enum {
22 MOTION_NONE, /* Ignoring motion events - click to start! */
23 MOTION_REPOSITION, /* Motion events move current_grab_icon */
24 MOTION_READY_FOR_DND, /* Moving much will start dnd */
25 MOTION_DISABLED, /* Release all buttons to go to MOTION_NONE */
26 } MotionType;
27 extern MotionType motion_state;
28 extern gint drag_start_x, drag_start_y;
29 extern gint motion_buttons_pressed;
31 extern gboolean o_no_hostnames;
32 extern Option o_dnd_spring_open;
33 extern char *drop_dest_prog;
34 extern char *drop_dest_dir;
35 extern GdkAtom XdndDirectSave0;
36 extern GdkAtom text_uri_list;
37 extern GdkAtom _rox_run_action;
38 extern GdkAtom application_octet_stream;
39 extern GdkAtom xa_string;
41 void drag_selection(GtkWidget *widget, GdkEventMotion *event, guchar *uri_list);
42 void drag_one_item(GtkWidget *widget,
43 GdkEventMotion *event,
44 const guchar *full_path,
45 DirItem *item,
46 MaskedPixmap *image);
47 void drag_data_get(GtkWidget *widget,
48 GdkDragContext *context,
49 GtkSelectionData *selection_data,
50 guint info,
51 guint32 time,
52 gpointer data);
53 void make_drop_target(GtkWidget *widget, GtkDestDefaults defaults);
54 void drag_set_dest(FilerWindow *filer_window);
55 void drag_set_pinboard_dest(GtkWidget *widget);
56 void dnd_init();
57 GtkWidget *create_dnd_options();
58 gboolean provides(GdkDragContext *context, GdkAtom target);
60 void dnd_spring_load(GdkDragContext *context, FilerWindow *src_win);
61 void dnd_spring_abort(void);
62 GList *uri_list_to_glist(const char *uri_list);
63 guchar *dnd_motion_item(GdkDragContext *context, DirItem **item_p);
65 gboolean dnd_motion_press(GtkWidget *widget, GdkEventButton *event);
66 void dnd_motion_start(MotionType motion);
67 gboolean dnd_motion_release(GdkEventButton *event);
68 void dnd_motion_disable(void);
69 void dnd_motion_ungrab(void);
70 gboolean dnd_motion_moved(GdkEventMotion *event);
71 void dnd_motion_grab_pointer(void);
73 #endif /* _DND_H */