Re: Proposal for change notifications
- From: Iago Toral <itoral igalia com>
- To: <grilo-list gnome org>
- Subject: Re: Proposal for change notifications
- Date: Thu, 20 Jan 2011 07:13:09 +0000
On Wed, 19 Jan 2011 17:06:37 +0100, "Juan A." Suárez Romero
<jasuarez igalia com> wrote:
On Wed, 2011-01-19 at 15:49 +0000, Lionel Landwerlin wrote:
Why not just emit GSignals ?
Even if we still use such callback mechanism within
Grilo/Grilo-plugins.
Yep, I completely forgot about it. We do not use gsignals because not
all plugins can send the signal. gupnp works in a similar way.
Told this, I thought about using also the gsignal way, so Grilo would
offer both ways. Of course, this would be done without adding an
extra
effort to plugins. So in case of doing it, I would do later.
Basically, connecting to signals is the very same thing, in the end you
use a function (g_signal_connect) to register a callback. However, you
get the extra benefit of having the whole GSignal API at your disposal,
and this is a good pro. The only benefit I see in having our own
subscription mechanism is that we can check if the plugin actually
supports the operation at the moment it attempts to register a callback,
but that sounds too weak to discard gsignal.
Also, I think we should go with the callbacks or gsignal, but not both
as you suggested we may have in the future. Having two ways of doing the
same thing is just a waste of time and an unnecessary complication.
Iago
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]