File tree Expand file tree Collapse file tree 2 files changed +6
-10
lines changed
library/src/main/java/com/hjq/window Expand file tree Collapse file tree 2 files changed +6
-10
lines changed Original file line number Diff line number Diff line change @@ -446,10 +446,9 @@ public EasyWindow(@NonNull Activity activity) {
446446 setSystemUiVisibility (params .systemUiVisibility );
447447 }
448448
449- // 相关问题地址:https://github.com/getActivity/EasyWindow/issues/85
450- //if (decorView.getSystemUiVisibility() != 0) {
451- // mWindowRootLayout.setSystemUiVisibility(decorView.getSystemUiVisibility());
452- //}
449+ if (decorView .getSystemUiVisibility () != 0 ) {
450+ mWindowRootLayout .setSystemUiVisibility (decorView .getSystemUiVisibility ());
451+ }
453452
454453 // 跟随 Activity 的生命周期
455454 mWindowLifecycleControl = new WindowLifecycleControl (this , activity );
Original file line number Diff line number Diff line change @@ -281,16 +281,13 @@ public void refreshWindowInfo() {
281281 return ;
282282 }
283283
284- View decorView = null ;
284+ // 相关问题地址:https://github.com/getActivity/EasyWindow/issues/85
285+ View decorView = getWindowRootLayout ();
285286
286- if (context instanceof Activity ) {
287+ if (decorView == null && context instanceof Activity ) {
287288 decorView = ((Activity ) context ).getWindow ().getDecorView ();
288289 }
289290
290- if (decorView == null ) {
291- decorView = getWindowRootLayout ();
292- }
293-
294291 if (decorView == null ) {
295292 return ;
296293 }
You can’t perform that action at this time.
0 commit comments