|
|
2008-03-17
, 17:47
|
|
Posts: 99 |
Thanked: 65 times |
Joined on Jan 2008
@ Finland
|
#2
|
static void
my_destroy_function(GtkObject *obj)
{
g_source_remove(foo);
}
static void
example_class_init(MyClass *class)
{
/* foo */
GTK_OBJECT_CLASS(class)->destroy = my_destroy_function;
/* bar */
}
|
|
2008-03-17
, 19:49
|
|
Posts: 35 |
Thanked: 5 times |
Joined on Sep 2007
|
#3
|
|
|
2008-03-17
, 20:20
|
|
Posts: 87 |
Thanked: 98 times |
Joined on Oct 2007
@ Austria
|
#4
|
How do the events work in hildon home plugin? Does it have similar destroy and delete events as normal gtk applications? I use the gobject timers and I think they keep on running after I have closed the plugin. So I guess they should be disabled somehow. Can anybody help with this? I'm developing with python btw.
...
self.timer = gobject.timeout_add(delay, self.update)
self.connect ("unrealize", self.unrealize)
...
def unrealize(self, widget):
if self.timer:
gobject.source_remove(self.timer)
|
|
2008-03-17
, 20:40
|
|
Posts: 35 |
Thanked: 5 times |
Joined on Sep 2007
|
#5
|
I'll test it tomorrow.
How do the events work in hildon home plugin? Does it have similar destroy and delete events as normal gtk applications? I use the gobject timers and I think they keep on running after I have closed the plugin. So I guess they should be disabled somehow. Can anybody help with this? I'm developing with python btw.