Re: [Java-gnome-developer] Multithreaded apps (was: Re: broken link)
Brought to you by:
afcowie
From: Weiqi G. <wei...@gm...> - 2005-01-11 03:57:22
|
JavaLobby is running a great presentation on exactly this issue. http://javalobby.org/eps/galbraith-swing-2/ On Mon, 10 Jan 2005 23:20:40 -0300 (ART), Joao Victor <jvi...@ya...> wrote: > Err... sorry but i didn't understand the problem very well yet. BTW, ther= e's a doc about it here: >=20 > http://java.sun.com/docs/books/tutorial/uiswing/misc/threads.html >=20 > I've read parts of it, but still didn't understand (maybe i'm too sleepy.= ..). I think the reason > why i didn't understand is because i've used threads many times on Swing = apps, and i've never used > invokeLater. Let me picture a simple example so we can work on it: >=20 > Suppose you're making a chat client, where you have a List widget showing= the online users. > Suppose you have a thread which is listening for new packets. Everytime t= his thread receives a > "New user" msg packet, it adds a new user to the List widget, and calls r= epaint (i think it's not > necessary to call repaint on this situation, but whatever). >=20 > So in this example there's no use of invokeLater, even though the widget = is being updated by a > thread. Would this somehow "break" something? I mean... i think i've done= that sometimes, never > seen any problem :P >=20 > Cheers, > J.V. >=20 > _______________________________________________________ > Yahoo! Acesso Gr=C3=A1tis - Instale o discador do Yahoo! agora. http://br= .acesso.yahoo.com/ - Internet r=C3=A1pida e gr=C3=A1tis >=20 > ------------------------------------------------------- > The SF.Net email is sponsored by: Beat the post-holiday blues > Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. > It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt > _______________________________________________ > java-gnome-developer mailing list > jav...@li... > https://lists.sourceforge.net/lists/listinfo/java-gnome-developer >=20 --=20 Weiqi Gao (=E9=AB=98=E4=B8=BA=E5=A5=87) wei...@gm... http://www.weiqigao.com/blog/ |