You've already forked android_translation_layer
mirror of
https://gitlab.com/android_translation_layer/android_translation_layer.git
synced 2025-10-27 11:48:10 -07:00
View: basic implementation for performHapticFeedback
we currently ignore the feedbackConstant and simply vibrate for 10ms
This commit is contained in:
@@ -65,6 +65,8 @@ public class Context extends Object {
|
||||
public static final String WINDOW_SERVICE = "window";
|
||||
public static AndroidManifestBlock manifest = null;
|
||||
|
||||
public static Vibrator vibrator;
|
||||
|
||||
static AssetManager assets;
|
||||
static DisplayMetrics dm;
|
||||
static Resources r;
|
||||
@@ -172,7 +174,7 @@ public class Context extends Object {
|
||||
case "usb":
|
||||
return new UsbManager();
|
||||
case "vibrator":
|
||||
return new Vibrator();
|
||||
return (vibrator != null) ? vibrator : (vibrator = new Vibrator());
|
||||
case "power":
|
||||
return new PowerManager();
|
||||
case "display":
|
||||
|
||||
Reference in New Issue
Block a user