[Sugar-devel] Performance of Android WebView

Manuel Quiñones manuq at laptop.org
Fri Aug 23 14:24:27 EDT 2013


I've been trying Gears activity in Android.  First, running it
"standalone", pointing Chrome for Android to
http://manuq.github.io/gears-activity/.  Then I bundled it as an APK,
and found that performance was bad in my device (tablet ASUS
transformer with Android 4.2).  After finding that, I tested the webpage in
the default browser that my device provides, called "Browser", and the
same performance issue appears.

So, the performance depends on the default webkit of the device, the
one installed system-wide.  And that will be the same as the default
browser uses.

There is discussion going on about this issue in a noisy chromium
ticket: https://code.google.com/p/chromium/issues/detail?id=113088

Andrew pointed me to this chromeview project, also mentioned in that
ticket: https://github.com/pwnall/chromeview

It attempts to solve the issue I see by replacing Android's WebView
with Chromium code.  But is too new and buggy.  A basic HTML + JS
example works fine, but when I tried to use it for Gears the app was
slow and unusable.

Also after adding chromeview, the APK weights 37 MB instead of the
previous 700 KB, but there are ways to separate that lib in its own
APK, so this shouldn't be a stopper.

Is still unclear to me what to do about this, but I wanted to
summarize what I have for now.

Here is the code:

Using default webview: https://github.com/manuq/gears-android
APK: https://github.com/manuq/gears-android/blob/master/bin/GearsActivity.apk

Using chromeview: https://github.com/manuq/gears-android/tree/chromeview
APK: https://github.com/manuq/gears-android/blob/chromeview/bin/GearsActivity.apk


-- 
.. manuq ..


More information about the Sugar-devel mailing list