Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Developer
Posts: 205
Registered: ‎07-14-2008
My Device: 7230, 8700, 8820, 9000

Dialog and EventThread blocking

I am trying to write a simple class (PromptPopup) that is similar to Dialog where I can say:

 

String foo = PromptPopup.prompt(....); // PromptPopup extends PopupScreen

 

which displays a prompt similar to Dialog.ask(..) but returns a string containing within an EditField. 

 

I can get this example to work if called by a non-event thread; however, blocking in an event-thread causes the application to hang until the OS eventually kills it.

 

How is it that Dialog.ask(), which must be called from the event thread, can block execution except not actually block the underlying event thread from handling input events?

 

Earl 

 

Earl Oliver
Highlighted
Developer
Posts: 205
Registered: ‎07-14-2008
My Device: 7230, 8700, 8820, 9000

Re: Dialog and EventThread blocking

pushModalScreen(..)

 

never mind :-)

 

Earl 

Earl Oliver