am 6529f2c9
: Add some null-checks
* commit '6529f2c99d24f0dd801ed142ce946b46c92d5e9f': Add some null-checks
This commit is contained in:
commit
0e26184ac7
@ -25,6 +25,7 @@ import android.content.DialogInterface;
|
||||
import android.os.Bundle;
|
||||
|
||||
import com.android.email.R;
|
||||
import com.android.mail.utils.LogUtils;
|
||||
|
||||
/**
|
||||
* Simple dialog that shows progress as we work through the settings checks.
|
||||
@ -110,7 +111,11 @@ public class CheckSettingsProgressDialogFragment extends DialogFragment {
|
||||
public void onCancel(DialogInterface dialog) {
|
||||
super.onCancel(dialog);
|
||||
final Callback callback = (Callback) getActivity();
|
||||
callback.onCheckSettingsProgressDialogCancel();
|
||||
if (callback != null) {
|
||||
callback.onCheckSettingsProgressDialogCancel();
|
||||
} else {
|
||||
LogUtils.d(LogUtils.TAG, "Null callback in CheckSettings dialog onCancel");
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -17,6 +17,7 @@
|
||||
package com.android.email.activity.setup;
|
||||
|
||||
import com.android.email.R;
|
||||
import com.android.mail.utils.LogUtils;
|
||||
|
||||
import android.app.AlertDialog;
|
||||
import android.app.Dialog;
|
||||
@ -72,6 +73,10 @@ public class DuplicateAccountDialogFragment extends DialogFragment {
|
||||
public void onDismiss(DialogInterface dialog) {
|
||||
super.onDismiss(dialog);
|
||||
final Callback callback = (Callback) getActivity();
|
||||
callback.onDuplicateAccountDialogDismiss();
|
||||
if (callback != null) {
|
||||
callback.onDuplicateAccountDialogDismiss();
|
||||
} else {
|
||||
LogUtils.d(LogUtils.TAG, "Null callback in DuplicateAccount dialog onDismiss");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user