WebView rendering error - android

I'm developing a very simple Android application.
The application is just a webview linked to this OpenLayers3 docs.
There is really nothing special in the application. It is just a WebView,
but I get this rendering error when I open a popup:
This happen on a Honor7.
I noticed that if I disable the hardware acceleration the problem does not persist but in this way the performances are very poor.
Thanks a lot

This is probably due to the latest update to Android System Web View, that comes automatically from Google Play. If you uninstall the update, it helps. It is of course not a really good solution((((

Related

Cordova: restart app and clear browser history

We are adding a feature to our Cordova app to catch unhandled exceptions and restart the app. We would like the browser history to be cleared in this case so the user can't hit back on an Android device to go back to the screen that crashed.
It isn't possible to clear the browser history programmatically, but I expected there to be a Cordova plugin that reinstantiates the whole app (i.e. deletes the current webview and creates a new one). I wasn't able to find anything like this though.
Is there a good way to do this that will work on both iOS and Android?
In Android for every WebView instance you can do:
webView.clearCache(true);
webView.clearHistory();
webView.clearFormData();
For IOS please read here: Clearing UIWebview cache
I'd rather suggest cordova-plugin-cache-clear, in order to handle more than just Chrome on Android. but having an Activity restart itself cannot be accomplished by some Cordova plugin (and in case of an Exception, not even by Activity.recreate()), but it would require a helper Service, which gets notified (of course these have to be handled exceptions, un-handled exceptions would nevertheless just crash) and then handles the situation accordingly. It might make more sense, to iron out possible reasons for crashes - instead of wasting time to creating questionable workarounds for code which was not properly forged, in the first place. besides, if this is JavaScript which bugs out, there might be no way to work around these issues at all, but to fix them.

Android WebView accessibility in Lollipop

I'm having some trouble getting TalkBack to work with a web view (testing with a Nexus 9 on Android 5.1). I read that TalkBack support was added to web views around the release of Android JellyBean by checking a preference titled "Enhance Web Accessibility." I can't for the life of me find this preference in the system settings.
Focusing on the web view in our application simply reads "WebView" and provides no other options.
Was TalkBack support for web views removed in KitKat? If not, what am I missing here?
Am using Mobile accessibility Plugin to read my customized talkback
My app work fine with Android 4.4.4 . Am using aria-hidden=true to stop default talkback of Mobile accessibility. But with that attribute lollipop doesn't focus to the event and not all reading
Your question is a little unclear. But I can guarantee one thing, this has nothing to do with the "Enhanced Web Accessibility" option. This was an experimental accessibility setting in Android 4.1 - 4.2 and has since been deprecated. This is why you cannot find this setting. What "Enhanced Web Accessibility" did was add some visual elements to help users spot things like Links and such with nice outlines. It has nothing to do with basic TalkBack support for WebViews, which has been supported since TalkBack was released, though it has certainly improved since then, and is still improving.
Now, this doesn't really answer your question. Only removes one of the solutions you seem to have been concerned about investigating. As per your actual solution, your question is a little unclear what your actual problem is. It seems to me you have some sort of event firing in a custom WebView you have created, and this should cause TalkBack to read something out. I await further details to continue this answer, though I suspect that you have not set the WebView's accessibility delegate.
mWebView.setAccessibilityDelegate(new View.AccessibilityDelegate());
It must be set to setJavaScriptEnabled (false);
web components analysis appears to be view.view.

Android Application Lock

how to make application lock for android mobile.how to lock the application. I have done locking the home screen i.e the entire mobile, but im not sure how to lock particular application.
For this situation you need to catch the listener event to lock the installed apps..
I have to say that I don't quite get what you're trying to di.
If you're trying to prevent people from using an app after it's downloaded the only way I can think of is having an HTTP(S) request done to a server with an identifier that is set the first time the app is run and check a DB to see if it can run (set a boolean flag shouldRun or something like it).
If you wat to prevent it from being copied from one phone to another, you can use the Google Play built in option to prevent it.
if this is what you're trying to achieve, you should probably obfuscate your code as well
obfuscating code on android
There is currently no support in the Android SDK to reliably do this. The application locking apps that are currently on the market aren't reliable in that they exploit a security loophole and put themselves in the foreground when you try to run a given application. This can be bypassed without much difficulty if you know how, and the security flaws they exploit will hopefully be closed. Sorry.

Track clicks in webview Android

I have been facing with a serious issue since weeks! I want to track all the clicks done in a Android webview. I know, the solution is implementing WebViewClient, but that doesn't track the clicks done in frames!
Example -
When you open a website within google translate, webviewclient doesn't track clicks made in the translated page!
Secondly, even when using Android 3.0, when i open google.com, it shows Google instant i think, and i am unable to track that url!
I'll be very very thankful if you can help me with this.
Thanks
Nithin
If it is your own Web content, you should track this in JavaScript.
If it is not your own Web content, it's conceivable you could cook up some general-purpose JavaScript for this and apply it via loadUrl("javascript:...") and addJavascriptInterface(), but I wouldn't know the details, as I'm not a low-level JS+DOM expert.
WebViewClient itself does not handle all scenarios, as you note, and it is the only pure Java solution I know of.

Android: How to use a Android Pad as a customer information Terminal

I want to us an Android-powered Pad as an information terminal for my customers.
The only thing it has to to is to show a HTML5 Webpage.
Therefore,
1. it should not be posiible to show another website (only the local one), should be no problem
it should be only possible to leave the app with a password (how?)
and all buttons should be disabled (that´s hard).
I found out how to set the target for the home button, but maybe there is an existing solution.
Thanks
Christian
I assume you understand the easiest way to do this is to develop an Android native application to show your webpage. This is done by using a WebView, but the support of HTML5 depends on the platform, so if you use any video or audio, you may need some hooks.
Trhough a WebView, you can filter which urls can be opened or not.
And well, I don't think there are many problems on exiting only when a password is entered.
Regarding to number 2, AFAIK, you can let your Activity ("window" of the application) to handle most of keys, but obviously you can't map the power key.
But I have to confess, when you develop an application, you always find some issues... so probably is not that easy as I wrote in these lines... Good luck!

Categories

Resources