Two questions about crosswalk for Android

Two questions about crosswalk for Android

I've read some of the docs about crosswalk like for instance https://software.intel.com/en-us/xdk/docs/why-use-crosswalk-for-android-... ´       I've got a app that's just a normal app framework app, not using WebGL and stuff like that. However i have a few css things that makes the app look and run bad on my Android running on version 4.1.2. I tried to build the app as crosswalk which fixed this issues and the app was now looking and running good on this device. I also have another Android device with version 4.4.2 which runs good using crosswalk, however this app also works fine using the normal cordova build which the other device didn't. This leaves me with two questions. 

1. If i only allow the app to run on Android 4.4+ devices and build using cordova without crosswalk, can i rely that it will work since it worked on my android 4.4 device? I'm wondering since in the link added earlier there's this sentence that says "We recommend that you test your app on distinct Android 4.0, 4.1, 4.2, 4.3 and 4.4 versions from a variety of manufacturers to make sure that your HTML5 app works consistently." if building for cordova without crosswalk i assume and allowing theese versions. Does this mean that above 4.4+ my application will work even if not using crosswalk since it works on my 4.4 device? 

2. This leads me to my second question, my app works fine using crosswalk on the 4.1 and 4.4 android devices tested. Can i now rely that my app will work on all 4+ or atleast 4.1+ devices if using crosswalk or do i still need to test as many devices and versions as possible like i would if i allowed theese versions building with just cordova and not crosswalk?

Any help or input is highly appreciated, Thanks alot!

 

 

Zone: 

5 posts / 0 new
Last post
For more complete information about compiler optimizations, see our Optimization Notice.

Mattias -- all excellent questions. In essence:

  • If you build with Crosswalk you'll get the same behavior on all devices (Android 4.0+), especially regarding layout and CSS behavior. Obviously, performance will vary as a function of the device processor and memory, etc.
  • Android 4.4 versions use Chromium in the webview (30 and 32, I believe) that generally works well for many apps. Earlier versions of Android (4.3 and lower) do not use Chromium, but an ancient Android webview, which does not work well.
  • Android 5.0 and later use a very new version of Chromium in the webview (it is updated via the store), so those webviews work very nicely.
  • If you restrict yourself to no Crosswalk on Android 4.4+ you should be okay. You'll want to do the majority of your testing on 4.4 devices (there are two versions of 4.4 devices you'll need to test: 4.4.0 and 4.4.2).
  • If you use Crosswalk and deploy to Android 4.0-4.3 (plus later), you'll want to confirm that the app runs properly on a few older devices (doesn't hang or crash, doesn't have performance problems), and otherwise only need to do light testing on the later devices. There are some 4.x devices that will crash, due to bugs in their GPUs, but if your layout is simple and does not rely on the GPU, you should be fine (e.g., no use of shading or gradients, etc.).

Thanks Paul for your answer, it's highly appreciated and helped me alot with my understanding!

I've been searching around on the Google Play Store and noticed that alot of apps either run on really low versions and others are restricted to 4+ devices while some are to 4.4+. At this moment i'm considering to just restrict the app  to 4.4+ and run without crosswalk this is simply because i dont have the possibility to test alot of devices and i've seen top apps only allowing this version so it cant be hurting that much i'd hope. However i'm not sure on how many potential users that wouldn't be able to use the application because of this, which ofcourse is hard/impossible to know and varies.I know this is a vague question but, do you have any advice in this for my scenario(not being able to test different devices) and what to choose? it just looks like 4.4+ is the safer bet here.

Also i'm just wondering if understood this comment correctly "there are two versions of 4.4 devices you'll need to test: 4.4.0 and 4.4.2" there seems to be versions 4.4.1 and 4.4.4 also, but they don't need to be tested, if it works on 4.4.0 and 4.4.2 it's fine?

Also "Android 5.0 and later use a very new version of Chromium..." does this mean they overall perform better without crosswalk?

Once again thanks alot for the support

Mattias -- if you are not able to test on a lot of devices I would recommend that you build with Crosswalk and not use the native webview. This way you'll have identical runtime behavior on all devices. It does result in a larger download, but it is the safer route. Even if you restrict yourself to Android 4.4+ devices. The problem with the Android 5.0+ devices is that the webview gets updated on a regular basis, so even though they are modern Chromium webviews, they can change without notice (usually about once a month) and can potentially break your app. So the most conservative approach is to build with embedded Crosswalk, because then your tested app does not change.

Regarding Android 4.4 and two different versions of Chromium, see this FAQ > https://developer.chrome.com/multidevice/webview/overview < there are two versions of Android 4.4 out there: one uses Chromium 30 and the other uses Chromium 33 (both have modified from standard Chromium, they are reduced functional versions of Chromium). Also, this slide set is interesting > http://blog.html5test.com/2014/07/the-android-browser/ < and here is a blog I wrote on the subject > http://blogs.intel.com/evangelists/2014/09/02/html5-web-app-webview-app/ <

This is about the best info available regarding how many devices are running in each version of Android > https://developer.android.com/about/dashboards/index.html < I read the other day that there are something like 1.7 billion Android devices on the planet. Between that chart and that estimated number of devices, you can estimate how many devices you are leaving out. Note that the Google statistics include very few, if any, of the Asian devices (especially China) because those devices do not have Google Play Services installed and, therefore, cannot ever visit the Google store. Notice that 4.1-4.3 devices are still a fairly large percentage of the measured population.

Thanks for the links and tips, i'm switching my focus to crosswalk and Android 4.1+ for now, only downside is the 60mb file instead of 10mb, not sure how much users care about this, but as you mention, it's the safer bet since there so many different Android devices and versions out there

Leave a Comment

Please sign in to add a comment. Not a member? Join today