Closed GoogleCodeExporter closed 9 years ago
Original comment by nekoh...@gmail.com
on 15 Nov 2006 at 12:08
Ok. Here's one option:
Watches don't need to do any UI. At all. So why don't we just spool off one
thread
per watch (using one of those nifty "threaded" decorators), since it doesn't
matter
that gtk+ isn't threadsafe. If the watch has something to say (there's an
error, the
watch has been updated, etc), it should signal the core, and the core can do
whatever
updating it wants/needs to do in its very own cosy little GTK+ thread.
Code, as I see it, would look something like:
#Oops, Signal error
self.specto.raise_error(self, 'Bad username/password')
#We're updated. Notify core
self.specto.add_update(self, "Your email account, <b>%s</b>, has <b>%d</b> new
mail."
% (self.name, self.newMsg-self.oldMsg))
These would add data to some sort of (probably mutex'd) list, then send a
signal to
the main thread. It's then the main thread's responsibility to do whatever
displaing
needs to be done.
Original comment by chalsero...@gmail.com
on 23 Nov 2006 at 4:25
Fixed in revision 34!!!
Original comment by woutclym...@gmail.com
on 15 Dec 2006 at 4:59
Original comment by nekoh...@gmail.com
on 1 Jul 2007 at 2:25
Original comment by nekoh...@gmail.com
on 18 Mar 2008 at 1:50
Original issue reported on code.google.com by
nekoh...@gmail.com
on 12 Nov 2006 at 9:58