@Override protected void onStop() { try { mEventManager.fire(new OnStopEvent()); } finally { super.onStop(); } }
@Override protected void onCreate(Bundle savedInstanceState) { TriainaInjector injector = TriainaInjectorFactory.getInjector(this); mEventManager = injector.getInstance(EventManager.class); injector.injectMembersWithoutViews(this); super.onCreate(savedInstanceState); mEventManager.fire(new OnCreateEvent(savedInstanceState)); }
@Override protected void onDestroy() { try { mEventManager.fire(new OnDestroyEvent()); } finally { try { TriainaInjectorFactory.destroyInjector(this); } finally { super.onDestroy(); } } }
@Override protected void onNewIntent(Intent intent) { super.onNewIntent(intent); mEventManager.fire(new OnNewIntentEvent()); }
@Override protected void onPause() { super.onPause(); mEventManager.fire(new OnPauseEvent()); }
@Override protected void onResume() { super.onResume(); mEventManager.fire(new OnResumeEvent()); }
@Override protected void onStart() { super.onStart(); mEventManager.fire(new OnStartEvent()); }
@Override protected void onPostCreate(Bundle savedInstanceState) { super.onPostCreate(savedInstanceState); mEventManager.fire(new OnPostCreateEvent(savedInstanceState)); }
@Override protected void onActivityResult(int requestCode, int resultCode, Intent data) { super.onActivityResult(requestCode, resultCode, data); mEventManager.fire(new OnActivityResultEvent(requestCode, resultCode, data)); }
@Override public void onContentChanged() { super.onContentChanged(); TriainaInjectorFactory.getInjector(this).injectMembers(this); mEventManager.fire(new OnContentChangedEvent()); }
@Override public void onConfigurationChanged(Configuration newConfig) { final Configuration currentConfig = getResources().getConfiguration(); super.onConfigurationChanged(newConfig); mEventManager.fire(new OnConfigurationChangedEvent(currentConfig, newConfig)); }
@Override protected void onRestoreInstanceState(final Bundle savedInstanceState) { super.onRestoreInstanceState(savedInstanceState); mEventManager.fire(new OnRestoreInstanceStateEvent(savedInstanceState)); }
@Override protected void onSaveInstanceState(final Bundle outState) { super.onSaveInstanceState(outState); mEventManager.fire(new OnSaveInstanceStateEvent(outState)); }