Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

alternative for web worker in android-phonegap?

can any one suggest me an alternative for phone gap web workers because i want my application to run successfully from android 2.2 to 4.2. As i know web workers support for 4.0 and above.

I tried Android Google cloud messaging and that is working perfectly fine. but i am looking for phone gap options not native android options.

like image 562
mahesh Avatar asked Feb 22 '13 08:02

mahesh


1 Answers

You could try https://crosswalk-project.org, which enables you to use an modern version of a Chromium-based Webview and get rid of the system webview. It's an Intel project, the documentation is complete and concise, and it includes many examples of how to use it along Apache Cordova.

Note Web Workers API is listed as supported: https://crosswalk-project.org (as well as WebRTC, WebGL, or other less unheard-of niceties like Web Notification API, which would free you of using a Cordova plugin for launching system native notifications).

The Chrome team also made a tool for packaging Chrome Apps with Cordova via the Crosswalk Webview: https://github.com/MobileChromeApps/mobile-chrome-apps

Using Crosswalk has some caveats, though. See https://github.com/MobileChromeApps/mobile-chrome-apps/blob/master/docs/Crosswalk.md For me, the more important one is: "An increase of about 17MB in the size of the .apk file". Depending on the app type (mainly if it's not a game), I, as an Android user, won't install such big app.

like image 118
jrub Avatar answered Oct 20 '22 00:10

jrub