I need to create a modal dialog in Android. By modal, I mean the code should stop executing and wait for the dialog to close. When I tried AlertDialog or PopupWindow, the code always continues without waiting.
Asked
Active
Viewed 1,792 times
-1
-
what code always continues? Did you start something in a background thread? When you pop the dialog, stop that work. – ataulm Dec 29 '16 at 15:06
1 Answers
0
I believe you will find your answer here
Dialogs / AlertDialogs: How to "block execution" while dialog is up (.NET-style)
In general you should not be blocking the code while a dialog is visible, your logic should be different and fit android way of doing things.