diff options
Diffstat (limited to 'java/com/android/dialer/app')
-rw-r--r-- | java/com/android/dialer/app/calllog/VisualVoicemailCallLogFragment.java | 4 | ||||
-rw-r--r-- | java/com/android/dialer/app/voicemail/VoicemailPlaybackPresenter.java | 4 |
2 files changed, 6 insertions, 2 deletions
diff --git a/java/com/android/dialer/app/calllog/VisualVoicemailCallLogFragment.java b/java/com/android/dialer/app/calllog/VisualVoicemailCallLogFragment.java index e83fcd4c7..8b504737b 100644 --- a/java/com/android/dialer/app/calllog/VisualVoicemailCallLogFragment.java +++ b/java/com/android/dialer/app/calllog/VisualVoicemailCallLogFragment.java @@ -29,10 +29,10 @@ import android.view.LayoutInflater; import android.view.View; import android.view.ViewGroup; import com.android.dialer.app.R; -import com.android.dialer.app.list.ListsFragment; import com.android.dialer.app.voicemail.VoicemailAudioManager; import com.android.dialer.app.voicemail.VoicemailErrorManager; import com.android.dialer.app.voicemail.VoicemailPlaybackPresenter; +import com.android.dialer.common.FragmentUtils; import com.android.dialer.common.LogUtil; import com.android.dialer.common.concurrent.DialerExecutor; import com.android.dialer.common.concurrent.DialerExecutorComponent; @@ -151,7 +151,7 @@ public class VisualVoicemailCallLogFragment extends CallLogFragment { @Override public void fetchCalls() { super.fetchCalls(); - ((ListsFragment) getParentFragment()).updateTabUnreadCounts(); + FragmentUtils.getParentUnsafe(this, CallLogFragmentListener.class).updateTabUnreadCounts(); } @Override diff --git a/java/com/android/dialer/app/voicemail/VoicemailPlaybackPresenter.java b/java/com/android/dialer/app/voicemail/VoicemailPlaybackPresenter.java index e9b64dfe3..3a7733436 100644 --- a/java/com/android/dialer/app/voicemail/VoicemailPlaybackPresenter.java +++ b/java/com/android/dialer/app/voicemail/VoicemailPlaybackPresenter.java @@ -57,6 +57,7 @@ import com.android.dialer.constants.Constants; import com.android.dialer.logging.DialerImpression; import com.android.dialer.logging.Logger; import com.android.dialer.phonenumbercache.CallLogQuery; +import com.android.dialer.strictmode.StrictModeUtils; import com.android.dialer.telecom.TelecomUtil; import com.android.dialer.util.PermissionsUtil; import com.google.common.io.ByteStreams; @@ -518,7 +519,10 @@ public class VoicemailPlaybackPresenter handleError(new IllegalStateException("Cannot play voicemail when call is in progress")); return; } + StrictModeUtils.bypass(this::prepareMediaPlayer); + } + private void prepareMediaPlayer() { try { mediaPlayer = new MediaPlayer(); mediaPlayer.setOnPreparedListener(this); |