Commit 05e26554d02fe20b76540c9cdac2b4d65d236d83
1 parent
26341737
1 修改基类执行顺序
Showing
1 changed file
with
11 additions
and
11 deletions
core/base/src/main/java/com/cnlive/core/libs/base/frame/activity/BaseActivity.java
| ... | ... | @@ -148,14 +148,6 @@ public abstract class BaseActivity<V extends BaseView, P extends BasePresenter<V |
| 148 | 148 | observableList = new ArrayList<>(); |
| 149 | 149 | } |
| 150 | 150 | |
| 151 | - if (!isShowTitle) { | |
| 152 | - requestWindowFeature(Window.FEATURE_NO_TITLE); | |
| 153 | - } | |
| 154 | - | |
| 155 | - if (!isShowStatusBar) { | |
| 156 | - getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN | |
| 157 | - , WindowManager.LayoutParams.FLAG_FULLSCREEN); | |
| 158 | - } | |
| 159 | 151 | //设置binding数据 |
| 160 | 152 | if (null != baseBinding) { |
| 161 | 153 | initBindingLayoutData(baseBinding); |
| ... | ... | @@ -165,6 +157,14 @@ public abstract class BaseActivity<V extends BaseView, P extends BasePresenter<V |
| 165 | 157 | } |
| 166 | 158 | //初始化控件 |
| 167 | 159 | initView(); |
| 160 | + if (!isShowTitle) { | |
| 161 | + requestWindowFeature(Window.FEATURE_NO_TITLE); | |
| 162 | + } | |
| 163 | + | |
| 164 | + if (!isShowStatusBar) { | |
| 165 | + getWindow().setFlags(WindowManager.LayoutParams.FLAG_FULLSCREEN | |
| 166 | + , WindowManager.LayoutParams.FLAG_FULLSCREEN); | |
| 167 | + } | |
| 168 | 168 | //设置数据 |
| 169 | 169 | initData(); |
| 170 | 170 | //是否开启滑动返回 |
| ... | ... | @@ -234,9 +234,9 @@ public abstract class BaseActivity<V extends BaseView, P extends BasePresenter<V |
| 234 | 234 | /** |
| 235 | 235 | * 沉浸式状态栏 |
| 236 | 236 | */ |
| 237 | - public void showImmersiveStatusBar(){ | |
| 238 | - StatusBarUtil.setTransparentForWindow(this); | |
| 239 | - StatusBarUtil.addTranslucentView(this,0); | |
| 237 | + public void showImmersiveStatusBar() { | |
| 238 | + StatusBarUtil.setTransparentForWindow(this); | |
| 239 | + StatusBarUtil.addTranslucentView(this, 0); | |
| 240 | 240 | } |
| 241 | 241 | |
| 242 | 242 | /** | ... | ... |