Question

Converted an application using Android WebView as a wrapper for a Mobi site, this weird issue has occurred:

Bug Issue

Google Apps Mobile

Google Mobile

The app can scroll, only after rotating the view does it correct and still then it is only some of the time, additionally the issue can be presented when rotation is done if there was no issue before.

Tested Operating System: Simulator BB10.2.0X.1803 -> BB10.2.1.1925 (Occurs in all builds between)

BlackBerry Devices:

Z10 and Z30 running 1925.

I can provide more images if required.

Thank you in advance.

Was it helpful?

Solution

After awaiting a response from BlackBerry I have heard nothing so it is not confirmed that this will fix every issue with BlackBerry 10.2 devices and WebViews however it sure has resolved my issue.

The WebView appears to render incorrectly due to hardware acceleration being enabled on Android to BlackBerry applications, the solution to this problem is to disable hardware acceleration in one of two places.

if (Build.BRAND.equals(BLACK_BERRY)) 
{
webView.setLayerType(View.LAYER_TYPE_NONE, null);
}

Assuming that you have a WebView that is defined as webView, else deactivating the setting in the Android manifest for the entire application is also a feasible solution.

    <application 
       android:hardwareAccelerated="false"

This either one of these should solve the issue with the WebView.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top