Skype Plugin

Evan Schoenberg evan.s at
Thu Sep 27 06:10:09 EDT 2007

On Sep 26, 2007, at 10:28 PM, Ka-Hing Cheung wrote:

> On Wed, 2007-09-26 at 22:02 -0400, Evan Schoenberg wrote:
>> On Sep 26, 2007, at 9:27 PM, Eion Robb wrote:
>>> FWIW, g_idle_add() will make a function call on the main thread.
>> We should probably have an entry in eventloop.c such that this is
>> instead purple_idle_add(), unless I misunderstand the purpose.
>> g_idle_add() assumes that the UI is using the glib event loop, which
>> is definitely not an assumption libpurple should ever make.
> g_idle_add is the same as g_timeout_add with timeout of 0. Is this not
> the same in libpurple's OS X eventloop?

g_timeout_add() should not be called either; the call is  
purple_timeout_out(), which in Pidgin calls through to  
g_timeout_add().  Using a Cocoa event loop or another non-glib run  
loop, a call to g_timeout_add() would result in the callback never  
being called, because the glib run loop is not being executed.

The use of the eventloop.c functions exclusively should be made clear  
for plugin authors somehow... is there a central document for them?

Eion, you should use purple_timeout_add() with a timeout of 0, not  
g_idle_add(), in your plugin.


More information about the Devel mailing list