Merge "Add fallback for TEXTURE_TICK" into qt-dev
This commit is contained in:
committed by
Android (Google) Code Review
commit
c87a593dee
@@ -2010,6 +2010,7 @@ package android.os {
|
|||||||
field public static final int EFFECT_STRENGTH_LIGHT = 0; // 0x0
|
field public static final int EFFECT_STRENGTH_LIGHT = 0; // 0x0
|
||||||
field public static final int EFFECT_STRENGTH_MEDIUM = 1; // 0x1
|
field public static final int EFFECT_STRENGTH_MEDIUM = 1; // 0x1
|
||||||
field public static final int EFFECT_STRENGTH_STRONG = 2; // 0x2
|
field public static final int EFFECT_STRENGTH_STRONG = 2; // 0x2
|
||||||
|
field public static final int EFFECT_TEXTURE_TICK = 21; // 0x15
|
||||||
field public static final int EFFECT_THUD = 3; // 0x3
|
field public static final int EFFECT_THUD = 3; // 0x3
|
||||||
field public static final int[] RINGTONES;
|
field public static final int[] RINGTONES;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -104,6 +104,7 @@ public abstract class VibrationEffect implements Parcelable {
|
|||||||
* @see #get(int)
|
* @see #get(int)
|
||||||
* @hide
|
* @hide
|
||||||
*/
|
*/
|
||||||
|
@TestApi
|
||||||
public static final int EFFECT_TEXTURE_TICK = Effect.TEXTURE_TICK;
|
public static final int EFFECT_TEXTURE_TICK = Effect.TEXTURE_TICK;
|
||||||
|
|
||||||
/** {@hide} */
|
/** {@hide} */
|
||||||
|
|||||||
@@ -236,6 +236,7 @@ public class VibratorService extends IVibratorService.Stub
|
|||||||
case VibrationEffect.EFFECT_CLICK:
|
case VibrationEffect.EFFECT_CLICK:
|
||||||
case VibrationEffect.EFFECT_DOUBLE_CLICK:
|
case VibrationEffect.EFFECT_DOUBLE_CLICK:
|
||||||
case VibrationEffect.EFFECT_HEAVY_CLICK:
|
case VibrationEffect.EFFECT_HEAVY_CLICK:
|
||||||
|
case VibrationEffect.EFFECT_TEXTURE_TICK:
|
||||||
case VibrationEffect.EFFECT_TICK:
|
case VibrationEffect.EFFECT_TICK:
|
||||||
case VibrationEffect.EFFECT_POP:
|
case VibrationEffect.EFFECT_POP:
|
||||||
case VibrationEffect.EFFECT_THUD:
|
case VibrationEffect.EFFECT_THUD:
|
||||||
@@ -379,6 +380,9 @@ public class VibratorService extends IVibratorService.Stub
|
|||||||
mFallbackEffects.put(VibrationEffect.EFFECT_TICK, tickEffect);
|
mFallbackEffects.put(VibrationEffect.EFFECT_TICK, tickEffect);
|
||||||
mFallbackEffects.put(VibrationEffect.EFFECT_HEAVY_CLICK, heavyClickEffect);
|
mFallbackEffects.put(VibrationEffect.EFFECT_HEAVY_CLICK, heavyClickEffect);
|
||||||
|
|
||||||
|
mFallbackEffects.put(VibrationEffect.EFFECT_TEXTURE_TICK,
|
||||||
|
VibrationEffect.get(VibrationEffect.EFFECT_TICK, false));
|
||||||
|
|
||||||
mScaleLevels = new SparseArray<>();
|
mScaleLevels = new SparseArray<>();
|
||||||
mScaleLevels.put(SCALE_VERY_LOW,
|
mScaleLevels.put(SCALE_VERY_LOW,
|
||||||
new ScaleLevel(SCALE_VERY_LOW_GAMMA, SCALE_VERY_LOW_MAX_AMPLITUDE));
|
new ScaleLevel(SCALE_VERY_LOW_GAMMA, SCALE_VERY_LOW_MAX_AMPLITUDE));
|
||||||
|
|||||||
Reference in New Issue
Block a user