I have solved this problem by a synch point between two thread i.e. using CountDownLatch
On Mon, Jan 18, 2010 at 6:32 PM, skink <psk...@gmail.com> wrote: > > > On Jan 18, 1:52 pm, ls02 <agal...@audible.com> wrote: > > Yes, I read Android docs about dialogs. However, this still does not > > answer my trivial questions. I also do not want to block UI thread. > > Blocking UI thread means you block message pump and UI becomes > > unresponsive. What I want is to call the function from UI thread that > > would popup the dialog and this function will not return until the > > dialog is closed. It is obvious that this modal dialog internally must > > implement message pump and break this message loop when user closes > > the dialog. Something similar to DialogBox or MessageBox Windows APIs. > > I understand that I can implement OnClickListener, but this will > > effectively call another function in the activity class that pops up > > this dialog. I cannot this way to return to the same execution point > > in the function that popped up the dialog. > > > > If Android does not have truly modal dialog I wonder what the > > suggested approach to the following standard situation. Say you have > > function that at certain point needs to prompt user for some input via > > a modal dialog and then must use the input from the dialog to continue > > its execution. > > > > see: > > http://groups.google.com/group/android-developers/browse_thread/thread/f8f1ac25831adcf5/c651bb429b694bba?lnk=gst&q=modal+dialog#c651bb429b694bba > > pskink > > -- > You received this message because you are subscribed to the Google > Groups "Android Developers" group. > To post to this group, send email to android-developers@googlegroups.com > To unsubscribe from this group, send email to > android-developers+unsubscr...@googlegroups.com<android-developers%2bunsubscr...@googlegroups.com> > For more options, visit this group at > http://groups.google.com/group/android-developers?hl=en > -- ...Swapnil || Hare Krishna Hare Krishna Krishna Krishna Hare Hare || || Hare Rama Hare Rama Rama Rama Hare Hare ||
-- You received this message because you are subscribed to the Google Groups "Android Developers" group. To post to this group, send email to android-developers@googlegroups.com To unsubscribe from this group, send email to android-developers+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/android-developers?hl=en