- How do I play audio with different playback rates?
- Why are Intel XDK Android Crosswalk build files so large?
- Why is the size of my installed app much larger than the apk for a Crosswalk application?
- Why does my Android Crosswalk build fail with the com.google.playservices plugin?
- Why does my app fail to run on some devices?
- How do I stop "pull to refresh" from resetting and restarting my Crosswalk app?
- Which versions of Crosswalk are supported and why do you not support version X, Y or Z?
- How do I prevent my Crosswalk app from auto-completing passwords?
- How can I improve the performance of my Crosswalk app so it is as fast as Crosswalk 7 was?
How do I play audio with different playback rates?
Here is a code snippet that allows you to specify playback rate:
var myAudio = new Audio('/path/to/audio.mp3'); myAudio.play(); myAudio.playbackRate = 1.5;
Why are Intel XDK Android Crosswalk build files so large?
When your app is built with Crosswalk it will be a minimum of 15-18MB in size because it includes a complete web browser (the Crosswalk runtime or webview) for rendering your app instead of the built-in webview on the device. Despite the additional size, this is the preferred solution for Android, because the built-in webviews on the majority of Android devices are inconsistent and poorly performing.
See these articles for more information:
Why is the size of my installed app much larger than the apk for a Crosswalk application?
This is because the apk is a compressed image, so when installed it occupies more space due to being decompressed. Also, when your Crosswalk app starts running on your device it will create some data files for caching purposes which will increase the installed size of the application.
Why does my Android Crosswalk build fail with the com.google.playservices plugin?
The Intel XDK Crosswalk build system used with CLI 4.1.2 Crosswalk builds does not support the library project format that was introduced in the "com.google.playservices@21.0.0" plugin. Use "com.google.playservices@19.0.0" instead.
Why does my app fail to run on some devices?
There are some Android devices in which the GPU hardware/software subsystem does not work properly. This is typically due to poor design or improper validation by the manufacturer of that Android device. Your problem Android device probably falls under this category.
How do I stop "pull to refresh" from resetting and restarting my Crosswalk app?
See the code posted in this forum thread for a solution: /en-us/forums/topic/557191#comment-1827376.
An alternate solution is to add the following lines to your intelxdk.config.additions.xml
file:
<!-- disable reset on vertical swipe down --><intelxdk:crosswalk xwalk-command-line="--disable-pull-to-refresh-effect" />
Which versions of Crosswalk are supported and why do you not support version X, Y or Z?
The specific versions of Crosswalk that are offered via the Intel XDK are based on what the Crosswalk project releases and the timing of those releases relative to Intel XDK build system updates. This is one of the reasons you do not see every version of Crosswalk supported by our Android-Crosswalk build system.
With the September, 2015 release of the Intel XDK, the method used to build embedded Android-Crosswalk versions changed to the "pluggable" webview Cordova build system. This new build system was implemented with the help of the Cordova project and became available with their release of the Android Cordova 4.0 framework (coincident with their Cordova CLI 5 release). With this change to the Android Cordova framework and the Cordova CLI build system, we can now more quickly adapt to new version releases of the Crosswalk project. Support for previous Crosswalk releases required updating a special build system that was forked from the Cordova Android project. This new "pluggable" webview build system means that the build system can now use the standard Cordova build system, because it now includes the Crosswalk library as a "pluggable" component.
The "old" method of building Android-Crosswalk APKs relied on a "forked" version of the Cordova Android framework, and is based on the Cordova Android 3.6.3 framework and is used when you select CLI 4.1.2 in the Project tab's build settings page. Only Crosswalk versions 7, 10, 11, 12 and 14 are supported by the Intel XDK when using this build setting.
Selecting CLI 5.1.1 in the build settings will generate a "pluggable" webview built app. A "pluggable" webview app (built with CLI 5.1.1) results in an app built with the Cordova Android 4.1.0 framework. As of the latest update to this FAQ, the CLI 5.1.1 build system supported Crosswalk 15. Future releases of the Intel XDK and the build system will support higher versions of Crosswalk and the Cordova Android framework.
In both cases, above, the net result (when performing an "embedded" build) will be two processor architecture-specific APKs: one for use on an x86 device and one for use on an ARM device. The version codes of those APKs are modified to insure that both can be uploaded to the Android store under the same app name, insuring that the appropriate APK is automatically delivered to the matching device (i.e., the x86 APK is delivered to Intel-based Android devices and the ARM APK is delivered to ARM-based Android devices).
For more information regarding Crosswalk and the Intel XDK, please review these documents:
- Intel XDK Crosswalk Chapter
- Using the Crosswalk for Android Build Option
- Choosing Crosswalk* Build Options: Shared or Embedded
How do I prevent my Crosswalk app from auto-completing passwords?
Use the Ionic Keyboard plugin and set the spellcheck attribute to false.
How can I improve the performance of my Crosswalk app so it is as fast as Crosswalk 7 was?
Try adding the CrosswalkAnimatable option to your intelxdk.config.additions.xml
file (details regarding the CrosswalkAnimatable option are available in this Crosswalk Project wiki post: Android SurfaceView vs TextureView):
<!-- Controls configuration of Crosswalk-Android "SurfaceView" or "TextureView" --><!-- Default is SurfaceView if >= CW15 and TextureView if <= CW14 --><!-- Option can only be used with Intel XDK CLI5+ build systems --><!-- SurfaceView is preferred, TextureView should only be used in special cases --><!-- Enable Crosswalk-Android TextureView by setting this option to true --><preference name="CrosswalkAnimatable" value="true" />
Also, see Chromium Command-Line Options for Crosswalk Builds with the Intel XDK for some additional tools that can be used to modify the Crosswalk's webview runtime parameters.