This question already has answers here:
Android SystemUI glitches in Lollipop
(6 answers)
Closed 7 years ago.
I have a full screen video using Exoplayer in a FullScreenActivity where status bar and navigation bar are hidden (from android >= 4.4).
When the activity is finished, I go back to last activity which is NOT a fullscreen (system ui is displayed) and 70% of the time I'm having a really strange issue on the system UI as follow :
Note that the image is the original one, so the white space on the right of the navigation bar is displayed on the phone.
This artefact disappear when another video play of when resuming the app. The top artifact correspond to the Toolbar + status bar. The artifact appear when fullscreen activity is fully fade out and finished.
Any sugestion or code request is welcome.
There is a known bug in WebView (at least since KitKat) that sometimes causes these artifacts. It was filed in the Android bug tracker as this issue. Although they claim it's fixed in Android 5.0, that is not the case, though (at least from my experience) it's not quite as easy to reproduce as before.
In any case, the workaround is to use software rendering for the WebView, via setLayerType():
webView.setLayerType(View.LAYER_TYPE_SOFTWARE, null);
Some related questions:
Android SystemUI glitches in Lollipop
FlipAnimation causing issue in 4.4.3
If you have a self-contained example that reproduces the bug, I would be very grateful if you could provide it to the guys at the AOSP Issue Tracker, in the link above.
This might be rendering problem and has been reported here
Setting your WebView like so:
yourWebView.setLayerType(View.LAYER_TYPE_SOFTWARE, null);
can solve your problem.
Related
On devices with Android >= 4.4.2 I've faced a strange behavior of popupWindows.
If more than 1 window is opened, and you switch to another application, then after you resume first application, all popupWindows will be shown in the reversed order (I mean if you had window1, window2 on top of window1, and window3 on top of previous two, then after app is resumed, you will have window3, window2, window1).
Earlier versions (< 4.4.2) doesn't have this bug (or maybe it is not a bug, and this is supposed to be correct behavior?). And to my shame, I have no idea how to fix this in my app. I appreciate if any can help.
This is my first question on this forum.
I have a weird problem on Android platform. Currently our app is in closed beta and I have received few error reports of disappearing texts.
In practice, all the texts disappear in my app. In every Fragment, in every Activity. Also from Action Bar. Based on the reports, it seems that this occurs after using WebView, but I can not be sure if usage of the WebView has something to do with this issue.
I'm targeting the app >= 4.2 Android and received error reports from 4.2 to 4.4. Unfortunately I haven't been able to reproduce the problem.
This image shows you the problem. In the image should have texts in Action Bar (App name, Tab texts and also lot of texts in the view:Screenshot of the problem
Have you ever encountered this kind of problem and do you have any idea what might be the problem.
Thanks, Veikko
I try to run an embedded web in Android, but it crashes when using Android 4.3 (Nexus 4). I run the app and the first webview appears correctly, but when I touch the textbox and the keyboard appears, the view gets frozen just on the top part of the keyboard (where the text predictor is located in case it's active).
This problem only appeared when using 4.3, not with the previous versions.
I've been trying to fix the bug as it says in this issue, but the solutions they give don't resolve my case: https://code.google.com/p/android/issues/detail?id=42518&q=webview&colspec=ID%20Type%20Status%20Owner%20Summary%20Stars
I would love if somebody have been through this problem, because we don't know what to do to fix it...
After more than one year without trying the app, it is working now. The device now is running Android Lollipop, so I guess that probably the WebView has some improvement that avoids the bug.
I'm experiencing strange, perhaps version-specific behavior with my DialogFragment subclass when testing the following steps:
(1) Open the dialog
(2) Leave the app with either the Home key or the Recent Apps key
(3) Return to the app, and the dialog is no longer visible. It seems to be briefly, translucently visible behind the main activity.
(4) Rotate the device, and the dialog re-appears.
This bug occurs on my Asus TF700T pad running Android 4.2.1, and it does not occur on my Motorola Razr phone running Android 4.1.2 (which has a menu key rather than an overflow button). Moreover, it only occurs if the dialog is opened via the overflow menu - dialogs opened via ActionBar items do not exhibit this issue! And finally, the issue does not occur if you do an orientation change before pausing the activity.
I have found a very similar issue which includes depressing comments like "This is clearly an Android bug." There are associated bug reports. Please, say it ain't so...
My workaround for this issue is in onResume(): I check the FragmentManager for existing dialogs with findFragmentByTag; if any are not null I dismiss and re-show them. But I'd like to understand what's really going on here.
I guess the answer to this question is the Google bug report linked above. I changed my design to avoid the problem, so I have not tried the workaround someone there has posted.
I'm building an html5 wrapped iOS / Android app with Trigger.io.
I have a problem on Android with a grey background appearing on the screen in some occasions after the virtual keyboard has closed, or after the phone has changed orientation.
Example screenshots are shown below.
The grey background is after the end of my app's page. Sometimes it is visible for a split second, other times it stays visible until you make an action such as scroll the page, bring the keyboard back, change orientation.
It's pretty jarring to look at.
I'd ideally like to stop the issue occurring, but as a temporary fix I'd be happy with being able to set the grey to my own background colour to make it less noticeable.
This looks like the HTML's not being re-drawn when the keyboard disappears... does it clear up if you do something to trigger a render?
Are you using a framework to handle the UI here? Something that might be trying to do something clever based on the visible viewport?
From what I can tell, the root of the issue is in the webview not re-drawing correctly, or something in your JavaScript failing to respond to the viewport changing size.
You could try running the app on the "web" target (instead of Android) then opening it in your phone's browser: if you can get far enough into the app to create the same effect it would help isolate the problem to the webview rendering or your JS.
I had a very similar issue in my project, in my case on Android 2.3.5 but not on Android 4.*. The cause in my case was not setting a window soft input mode for the associated activity in the manifest:
android:windowSoftInputMode="adjustPan"
Instead, the window was resizing when the keyboard appeared but apparently not resizing once more when the keyboard disappeared.
More details can be found here.
I almost went crazy with the same issue. I finally found out that this largely depends on the device you are using. I had a similar problem : Fixed elements (HTML) break after android keyboard dissapears?
And I am also using trigger.io. This doesn't happen with some devices. Could be the particular OS in android or could just be the way the specific device handles the memory latency.
I have looked for this but I go with #jamesbrady in that the HTML doesn't redraw. The problem in trigger is that you cannot edit the
android:windowSoftInputMode="adjustPan"
because the activity tag in the AndroidManifest.xml updates on each run. You would need to build a private module for that.