Cros-ARC: Android on Chromebook UI getting cut off since dm.heightPixels wrongly includes the maximize/minimize bar only present on Chromebooks
Reported by
a...@infinut.com,
Sep 9 2016
|
|||||
Issue descriptionChrome OS Version: 53.0.27.85.100 beta Chrome OS Platform: 8530.80.0 Firmware Google_Cyan.7287.57.82 Chromebook: ACER R11 Please specify Cr-* of the system to which this bug/feature applies (add the label below). label:Cros-ARC Steps To Reproduce: (1) Run the attached android project on a Chromebook over ADB. The log on Chromebook Acer R11 shows, 09-08 16:58:44.960 1176-6209/com.infinut.anar.demos I/Screen: WidthPixels:960 09-08 16:58:44.960 1176-6209/com.infinut.anar.demos I/Screen: HeightPixels:600 09-08 16:58:44.959 1176-1176/com.infinut.anar.demos I/Surface: WidthPixels:960 09-08 16:58:44.959 1176-1176/com.infinut.anar.demos I/Surface: HeightPixels:568 Note that the log shows that the displayMetrics.heightPixels (Screen) are different from the surfaceHolder.OnSurfaceChanged (Surface) pixels even though the view is defined to be fullscreen and the theme is fullscreen - @android:style/Theme.Black.NoTitleBar.Fullscreen (2) Run the same application on an Android device. Note that the displayMetrics.heightPixels (Screen) from display metrics and surfaceHolder.onSurfaceChanged (Surface) are the same. On Nexus 7 Android tablet, 09-08 17:05:48.066 3503-3821/com.infinut.anar.demos I/Screen: WidthPixels:1920 09-08 17:05:48.066 3503-3821/com.infinut.anar.demos I/Screen: HeightPixels:1104 09-08 17:05:48.064 3503-3503/com.infinut.anar.demos I/Surface: WidthPixels:1920 09-08 17:05:48.065 3503-3503/com.infinut.anar.demos I/Surface: HeightPixels:1104 Expected Result: The dm.heightPixels should not include the maximize/minimize bar since it is a fixed bar that cannot be removed (similar to the back/home/apps bar at the bottom of android devices). Actual Result: The maximize/minimize bar is included in the dm.heightPixels, but not in surfaceHolder.surfaceChanged height. The surface one is correct. How frequently does this problem reproduce? (Always, sometimes, hard to reproduce?) Is a problem for all our apps, since we use the dm.widthPixels and dm.heightPixels extensively to determine sizing and positioning of UI elements What is the impact to the user, and is there a workaround? If so, what is it? The android app does not 'just work' on Chromebooks, and will require significant rework to not have the UI cut off at the bottom few pixels. See attached image. Please provide any additional information below. Attach a screen shot or log if possible.
,
Sep 9 2016
Re-attaching the code to reproduce the problem. Did not attach the first time.
,
Sep 12 2016
,
Sep 27 2016
David, could you also look into this issue, where the UI is getting cut off?
,
Sep 28 2016
skuhne@, can you take a look at this and assign back to me if it's a SF/HWC issue?
,
Sep 29 2016
The SurfaceView is not covering the entire window/display. It will be limited to the window without the caption. If that surface would cover everything, either the caption would be drawn over your content, hence blocking your content - OR - your content would cover the caption, hence making it impossible for the user to control the window - OR - part of the content would get cut off. The source of this is N's decision to put the caption into the app's window in free form mode. Going forward we will move the caption out of the window again, but for the initial version of ARC++, we are "N freeform compatible". So this is not a bug, it's intended. Please re-open if you feel that the surfaceView should have the size of the window, but note that without the ability to hide the caption and / or as long as the caption is part of the window nothing can be done here. |
|||||
►
Sign in to add a comment |
|||||
Comment 1 by dubois...@gmail.com
, Sep 9 2016