On Fri, Jun 02, 2006 at 03:06:30PM +0000, [EMAIL PROTECTED] wrote:
> Answering to my own question (again):
[...]
> So the answer seems to be "yes, but only if you do all by hand".

Not that bad after all. Just enable the icon view's model as source and
destination. Make sure "GTK_TREE_MODEL_ROW" is included in the
acceptable types -- when coming from the same widget, like so:

  | typedef enum {
  |   drop_internal,
  |   drop_image,
  |   drop_string
  | } drooptype;
  | 
  | static GtkTargetEntry droptypes[] = {
  |   {"GTK_TREE_MODEL_ROW", GTK_TARGET_SAME_WIDGET, drop_internal},
  |   {"image/png",  0, drop_image},
  |   {"STRING",     0, drop_string},
  |   {"text/plain", 0, drop_string}
  |   /* other types may go here */
  | };
  | 
Then
  | 
  |   gtk_icon_view_enable_model_drag_source(board,
  |                                          GDK_BUTTON1_MASK,
  |                                          droptypes,
  |                                          G_N_ELEMENTS(droptypes),
  |                                          GDK_ACTION_MOVE);
  | 
  |   gtk_icon_view_enable_model_drag_dest(board,
  |                                        droptypes,
  |                                        G_N_ELEMENTS (droptypes),
  |                                        GDK_ACTION_MOVE);

All is well now.

Regards
-- tomás
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list

Reply via email to