Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 28d01e67 authored by Justin Koh's avatar Justin Koh Committed by Android (Google) Code Review
Browse files

Merge "DO NOT MERGE Disable vibration from notificationmanagerservice when on...

Merge "DO NOT MERGE Disable vibration from notificationmanagerservice when on watch" into klp-modular-dev
parents 5913f406 26787462
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -43,6 +43,7 @@ import android.content.pm.PackageManager;
import android.content.pm.ResolveInfo;
import android.content.pm.ServiceInfo;
import android.content.pm.PackageManager.NameNotFoundException;
import android.content.res.Configuration;
import android.content.res.Resources;
import android.database.ContentObserver;
import android.graphics.Bitmap;
@@ -2013,7 +2014,10 @@ public class NotificationManagerService extends SystemService {

                        if ((useDefaultVibrate || convertSoundToVibration || hasCustomVibrate)
                                && !(mAudioManager.getRingerMode()
                                        == AudioManager.RINGER_MODE_SILENT)) {
                                        == AudioManager.RINGER_MODE_SILENT)
                                // HACK for klp-modular devices only: disable vibration on watches.
                                && ((getContext().getResources().getConfiguration().uiMode &
                                        Configuration.UI_MODE_TYPE_WATCH) == 0)) {
                            mVibrateNotification = r;

                            if (useDefaultVibrate || convertSoundToVibration) {