Re: [GnomeMeeting-devel-list] [RFC] New addressbook, evolution-data-server and internal contacts



Damien wrote, but the braindead webmail can't quote properly:
> >Hmmm... Can't the receiver just call
> >gtk_drag_get_source_widget () to find the source, and then get
> >the data from that?

> That will just give the same problem than what you are
discussing about.

No, that won't. The current code has to know that the source
is a gtk tree view, and has to know it. What I propose is
something like:
src_widget = gtk_drag_get_source_widget (...);
drag_url = g_object_get_data (src_widget, "vcard");
...

> The piece of code you are talking about just does a test to
determine
> the origin, now imagine you are using
gtk_drag_get_source_widget, where
> is the difference? You will still have to know the
format/composition of
> the source tree view widget to be able to get the URL from
that widget
> as the URL is placed at a different place in each tree view
(calls
> history, address book, ...).

No, see above.

> I think you have misunderstood some basic here :
> - the callback you are mentionning is triggered when there
is a drag and
> drop occuring from a tree view. In the sake of code reuse,
the same
> callback is reused for all tree views in gnomemeeting.

grep tells me that callback isn't reused: it is declared,
defined and used only in ldap_window.cpp. But it still needs
to know about the calls history!

> - when the drag is released, you copy the URL in the drag
data. There is
> a consistent format in the whole GnomeMeeting code for this.

No. The data is passed around as embedded in gtk tree views,
or a gstring, and once passed, made into the "consistent"
format. The piece of code I pointed to is an example of that.

What I want is to pass the common representation directly.

> - another callback is called on the widget where the drag is
released.
> That callback reads the data and calls the URL from the
uniform data.
>
> You suggest that the data format is not unique. That's not true.
> You suggest that the callback you have indicated requires to
know where
> the drag comes from. That's right, and that's nothing you
will be able
> to change, you always have to know the format of the source
widget to
> know where teh URL is placed in that widget.

I'm asking for directions on #gtk, because the scheme I
propose above allows to ignore the format of the source
widget, but still needs the source widget to do something
special when the drag begins, ie: it wouldn't work for
cross-apps drag'n drop.

> >When the user selects a contact in the list, isn't it possible
> >to generate the vcard, and put it as data to the widget that
> >is a drag source? The destination would then get the widget,
> >and read the vcard? (even that sounds way too complex ; how
> >would different apps be supposed to cooperate with such a
> >terrible dnd scheme!?)
>
> I find dnd in GTK hard to understand and to play with.

I must agree there: awful. Let's ask to Great Masters of GTK
for directions. ;-)

> Setting the VCard
> as data of the widget is not something to do, because I can
already
> imagine corruption. What if there are 2 callbacks for 2
drags happening
> at the same time?

Hmmmm... in the callback, you get the data from the source
widget of the drag it's concerned with... I don't see the
problem (yet).

> >> Yes, small remark here : it has to be optional, ie you
> >should be able to
> >> do with or without evolution-data-server.
> >
> >For drag'n drop between different gnome apps, what is
> >transmitted _must_ be compatible. So that will have to be
> >generated from gm's own code (notice: from a GPL app to a GPL
> >app, I guess we can copy-paste some code -- just making it
> >openly, talking to the original authors, and with proper
> >copyright assignments). Probably not a big deal, since most of
> >gm won't need a full-featured contact.
> >
>
> Of course, I agree with this.

My idea doesn't work for cross-apps :-(

There is something that escapes us there, I think.

> That's the real problem, but I don't know anything about
EDS, so I
> can't really discuss it. But I can't imagine forcing people
to open
> the Evolution Addressbook to be able to give GnomeMeeting calls.

Well, wait and see... We still have some cleaning to do, and
for that we need to understand gtk's drag'n drop.

Snark from a sucky webmail

Accédez au courrier électronique de La Poste : www.laposte.net ; 
3615 LAPOSTENET (0,34?/mn) ; tél : 08 92 68 13 50 (0,34?/mn)






[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]