Improve cold start by postponing voice note service creation.

This commit is contained in:
Clark
2023-02-23 08:38:11 -05:00
committed by Nicholas Tinsley
parent 0a971569d9
commit 4f31dc36ba
2 changed files with 2 additions and 2 deletions

View File

@@ -54,7 +54,7 @@ public class MainActivity extends PassphraseRequiredActivity implements VoiceNot
setContentView(R.layout.main_activity);
mediaController = new VoiceNoteMediaController(this);
mediaController = new VoiceNoteMediaController(this, true);
ConversationListTabRepository repository = new ConversationListTabRepository();
ConversationListTabsViewModel.Factory factory = new ConversationListTabsViewModel.Factory(repository);

View File

@@ -881,7 +881,7 @@ public class ConversationListFragment extends MainFragment implements ActionMode
AppStartup.getInstance().onCriticalRenderEventEnd();
startupStopwatch.split("first-render");
startupStopwatch.stop(TAG);
mediaControllerOwner.getVoiceNoteMediaController().finishPostpone();
if (getContext() != null) {
ConversationFragment.prepare(getContext());
}