This repository was archived by the owner on Feb 25, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +6
-6
lines changed
shell/platform/android/io/flutter Expand file tree Collapse file tree 2 files changed +6
-6
lines changed Original file line number Diff line number Diff line change 14
14
import android .database .ContentObserver ;
15
15
import android .graphics .Insets ;
16
16
import android .graphics .Rect ;
17
+ import android .hardware .display .DisplayManager ;
17
18
import android .os .Build ;
18
19
import android .os .Handler ;
19
20
import android .os .Looper ;
31
32
import android .view .ViewGroup ;
32
33
import android .view .ViewStructure ;
33
34
import android .view .WindowInsets ;
34
- import android .view .WindowManager ;
35
35
import android .view .accessibility .AccessibilityManager ;
36
36
import android .view .accessibility .AccessibilityNodeProvider ;
37
37
import android .view .autofill .AutofillValue ;
@@ -612,8 +612,8 @@ private ZeroSides calculateShouldZeroSides() {
612
612
Context context = getContext ();
613
613
int orientation = context .getResources ().getConfiguration ().orientation ;
614
614
int rotation =
615
- ((WindowManager ) context .getSystemService (Context .WINDOW_SERVICE ))
616
- .getDefaultDisplay ( )
615
+ ((DisplayManager ) context .getSystemService (Context .DISPLAY_SERVICE ))
616
+ .getDisplay ( 0 )
617
617
.getRotation ();
618
618
619
619
if (orientation == Configuration .ORIENTATION_LANDSCAPE ) {
Original file line number Diff line number Diff line change 15
15
import android .graphics .Insets ;
16
16
import android .graphics .PixelFormat ;
17
17
import android .graphics .SurfaceTexture ;
18
- import android .hardware .display .DisplayManager ;
19
18
import android .os .Build ;
20
19
import android .os .Handler ;
21
20
import android .text .format .DateFormat ;
32
31
import android .view .ViewConfiguration ;
33
32
import android .view .ViewStructure ;
34
33
import android .view .WindowInsets ;
34
+ import android .view .WindowManager ;
35
35
import android .view .accessibility .AccessibilityManager ;
36
36
import android .view .accessibility .AccessibilityNodeProvider ;
37
37
import android .view .autofill .AutofillValue ;
@@ -537,8 +537,8 @@ private ZeroSides calculateShouldZeroSides() {
537
537
Context context = getContext ();
538
538
int orientation = context .getResources ().getConfiguration ().orientation ;
539
539
int rotation =
540
- ((DisplayManager ) context .getSystemService (Context .DISPLAY_SERVICE ))
541
- .getDisplay ( 0 )
540
+ ((WindowManager ) context .getSystemService (Context .WINDOW_SERVICE ))
541
+ .getDefaultDisplay ( )
542
542
.getRotation ();
543
543
544
544
if (orientation == Configuration .ORIENTATION_LANDSCAPE ) {
You can’t perform that action at this time.
0 commit comments