Before you dismiss this question as a duplicate, just know that I saw these:
AlertDialog setmessage not working inside Asynctask
ProgressDialog does not want to update the message
Android: Progress Dialog change ProgressDialog.setMessage() while loading
Changing Progress Dialog Message While Running
But no luck.
I'm trying to update the message inside a ProgressDialog while it is showing. Yep. As simple as that.
Right now my code looks like this:
private BroadcastReceiver createMapReceiver(MapEntry entry) {
return new BroadcastReceiver() {
@Override
public void onReceive(Context context, Intent intent) {
...
dialogMessage = getString(R.string.maps_download_extracting)
.concat("\n\n")
.concat(getString(R.string.maps_download_suffix));
Runnable changeMessage = () -> {
downloadingDialog.setMessage(dialogMessage);
downloadingDialog.show();
};
runOnUiThread(changeMessage);
...
}
};
}
But the message does not update. Everything else works as expected. What am I missing?