Wait for callback to complete with dialog
<p>I am very new to Android development, so please bare with me.
I have a GPS class which returns the current GPS coordinates to the calling activity via a callback.</p>

<p>The user either takes a picture or chooses one from the library and then returns to the main activity. After he returns to the main activity, I poll the gps class for the location data.
Once the callback return, it updates two class properties, one for Lat and one for Lon.</p>

<p>Sometimes it takes several second for the callback to be called and I want the activity to wait for the callback and display some kind of dialog to the user.</p>

<p>Currently I am just useing a while loop to wait for the properties to update, but I'm sure there is a more graceful solution to this.</p>

<p>Thanks!</p>
