am c759ed68: fw/policy/base:Phonewindowmanager: Make vkey button haptics part of global haptic setting
Merge commit 'c759ed684857a085e5cf74f5a62bc98e78abd660' * commit 'c759ed684857a085e5cf74f5a62bc98e78abd660': fw/policy/base:Phonewindowmanager: Make vkey button haptics part of global haptic setting
This commit is contained in:
5
policy/com/android/internal/policy/impl/PhoneWindowManager.java
Normal file → Executable file
5
policy/com/android/internal/policy/impl/PhoneWindowManager.java
Normal file → Executable file
@@ -2184,7 +2184,10 @@ public class PhoneWindowManager implements WindowManagerPolicy {
|
||||
public void keyFeedbackFromInput(KeyEvent event) {
|
||||
if (event.getAction() == KeyEvent.ACTION_DOWN
|
||||
&& (event.getFlags()&KeyEvent.FLAG_VIRTUAL_HARD_KEY) != 0) {
|
||||
mVibrator.vibrate(mVirtualKeyVibePattern, -1);
|
||||
if (Settings.System.getInt(mContext.getContentResolver(),
|
||||
Settings.System.HAPTIC_FEEDBACK_ENABLED, 0) != 0) {
|
||||
mVibrator.vibrate(mVirtualKeyVibePattern, -1);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user