hey could anyone please tell me how to create a dialog from a background thread that is not a UI thread in Android??
something like this..

Thread t=new Thread(new Runnable() {
    @Override
    public void run() {
        Thread innerThread=new Thread(new Runnable() {
            @Override
            public void run() {
                /////***** i need to create a dialog here *****////
                /////***** but the dialog doesn't appear or it closes too soon
                /////      to be able to record a user input *****////
            }
        });
    }
});

the thing is I want the dialog box to block the thread which created/showed it until I get a response from the dialog box..could you please give me a few hints on how to do that??

i'm trying to make the game thread pause till the dialog box is dismissed after the input is received..