浏览代码

temp comment explaining this mess

Daniel Zlotin 8 年前
父节点
当前提交
1514743224
共有 1 个文件被更改,包括 1 次插入2 次删除
  1. 1
    2
      android/app/src/main/java/com/reactnativenavigation/NavigationApplication.java

+ 1
- 2
android/app/src/main/java/com/reactnativenavigation/NavigationApplication.java 查看文件

81
                             UiThread.postDelayed(new Runnable() {
81
                             UiThread.postDelayed(new Runnable() {
82
                                 @Override
82
                                 @Override
83
                                 public void run() {
83
                                 public void run() {
84
-                                    android.util.Log.d("DebuggingIsHell", "NavigationApplication:run() " + 1);
85
                                     new NavigationEventEmitter(context).emitAppLaunched();
84
                                     new NavigationEventEmitter(context).emitAppLaunched();
86
                                 }
85
                                 }
87
                             }, diff);
86
                             }, diff);
95
                 host.getReactInstanceManager().onHostResume(activity, (DefaultHardwareBackBtnHandler) activity);
94
                 host.getReactInstanceManager().onHostResume(activity, (DefaultHardwareBackBtnHandler) activity);
96
 
95
 
97
                 if (creating.compareAndSet(true, false)) {
96
                 if (creating.compareAndSet(true, false)) {
97
+                    // this should run only after activity closed and started again, but we already HAVE context
98
                     UiThread.postDelayed(new Runnable() {
98
                     UiThread.postDelayed(new Runnable() {
99
                         @Override
99
                         @Override
100
                         public void run() {
100
                         public void run() {
101
-                            android.util.Log.d("DebuggingIsHell", "NavigationApplication:run() " + 2);
102
                             new NavigationEventEmitter(host.getReactInstanceManager().getCurrentReactContext()).emitAppLaunched();
101
                             new NavigationEventEmitter(host.getReactInstanceManager().getCurrentReactContext()).emitAppLaunched();
103
                         }
102
                         }
104
                     }, 1000);
103
                     }, 1000);