Android 手机震动
2018-04-04 本文已影响7人
ChenME
- 权限
<uses-permission android:name="android.permission.VIBRATE"/>
- 使用
Vibrator vibrator = (Vibrator)_activity.getSystemService(VIBRATOR_SERVICE);
vibrator.vibrate(100);
<uses-permission android:name="android.permission.VIBRATE"/>
Vibrator vibrator = (Vibrator)_activity.getSystemService(VIBRATOR_SERVICE);
vibrator.vibrate(100);