The onProgressUpdate() is never called, can you tell me why?
private class LoginMe extends AsyncTask<Context, Void, Boolean> {
@Override
protected Boolean doInBackground(Context... arg0) {
doSomething();
return true;
}
@Override
protected void onProgressUpdate(Void... v) {
super.onProgressUpdate(v);
Log.d("Dev", "Im in onProgressUpdate()");
}
@Override
protected void onPostExecute(Boolean result) {
super.onPostExecute(result);
if (result) {
doOne();
} else {
doTwo();
}
}
}
You have to call
publishProgressfrom withindoInBackgroundmanually.http://developer.android.com/reference/android/os/AsyncTask.html