mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-11-05 13:26:48 +08:00
Merge pull request #2235 from NativeScript/travis
Trying to fix the Travis build.
This commit is contained in:
@@ -4,7 +4,7 @@ env:
|
||||
- PACKAGE_VERSION=$DATE-$TRAVIS_BUILD_NUMBER
|
||||
- PACKAGE_NAME=tns-core-modules
|
||||
- NODE_VERSION=5.10.1
|
||||
- EMULATOR_API_VER=22
|
||||
- EMULATOR_API_VER=21
|
||||
- RUNTIMEVERSION=next
|
||||
- AVD_NAME=Arm$EMULATOR_API_VER
|
||||
addons:
|
||||
@@ -33,10 +33,10 @@ before_script:
|
||||
- npm install -g grunt-cli
|
||||
- npm install
|
||||
- "(cd build/platform-declarations && npm install)"
|
||||
- echo no | android create avd --force -n $AVD_NAME -t android-$EMULATOR_API_VER -b
|
||||
armeabi-v7a -c 12M
|
||||
- emulator -avd $AVD_NAME -skin WXGA720 -no-audio -no-window -memory 2048 &
|
||||
- echo no | android create avd --force -n $AVD_NAME -t android-$EMULATOR_API_VER --abi default/armeabi-v7a -c 12M
|
||||
- emulator -avd $AVD_NAME -no-audio -no-window &
|
||||
- android-wait-for-emulator
|
||||
- adb shell input keyevent 82 &
|
||||
script:
|
||||
- jdk_switcher use oraclejdk8
|
||||
- grunt default &&
|
||||
|
||||
@@ -376,18 +376,20 @@ export class Animation extends common.Animation implements definition.Animation
|
||||
private _enableHardwareAcceleration() {
|
||||
for (let i = 0, length = this._propertyAnimations.length; i < length; i++) {
|
||||
let cache = <CacheLayerType>this._propertyAnimations[i].target._nativeView;
|
||||
let layerType = cache.getLayerType();
|
||||
if (layerType !== android.view.View.LAYER_TYPE_HARDWARE) {
|
||||
cache.layerType = layerType;
|
||||
cache.setLayerType(android.view.View.LAYER_TYPE_HARDWARE, null);
|
||||
}
|
||||
if (cache){
|
||||
let layerType = cache.getLayerType();
|
||||
if (layerType !== android.view.View.LAYER_TYPE_HARDWARE) {
|
||||
cache.layerType = layerType;
|
||||
cache.setLayerType(android.view.View.LAYER_TYPE_HARDWARE, null);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private _disableHardwareAcceleration() {
|
||||
for (let i = 0, length = this._propertyAnimations.length; i < length; i++) {
|
||||
let cache = <CacheLayerType>this._propertyAnimations[i].target._nativeView;
|
||||
if (cache.layerType !== undefined) {
|
||||
if (cache && cache.layerType !== undefined) {
|
||||
cache.setLayerType(cache.layerType, null);
|
||||
cache.layerType = undefined;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user