From 67df1fb341eb135204f6ae6e285dd0c86ded4dc7 Mon Sep 17 00:00:00 2001 From: Andy Scherzinger Date: Mon, 25 Oct 2021 22:01:05 +0200 Subject: [PATCH 1/2] cleanup code after custom vibrate code removal Signed-off-by: Andy Scherzinger --- .../talk/controllers/CallNotificationController.java | 6 ------ 1 file changed, 6 deletions(-) diff --git a/app/src/main/java/com/nextcloud/talk/controllers/CallNotificationController.java b/app/src/main/java/com/nextcloud/talk/controllers/CallNotificationController.java index dc8f1bfee..8d8d590c5 100644 --- a/app/src/main/java/com/nextcloud/talk/controllers/CallNotificationController.java +++ b/app/src/main/java/com/nextcloud/talk/controllers/CallNotificationController.java @@ -31,7 +31,6 @@ import android.media.MediaPlayer; import android.net.Uri; import android.os.Bundle; import android.os.Handler; -import android.os.Vibrator; import android.renderscript.RenderScript; import android.text.TextUtils; import android.util.Log; @@ -149,7 +148,6 @@ public class CallNotificationController extends BaseController { private MediaPlayer mediaPlayer; private boolean leavingScreen = false; private RenderScript renderScript; - private Vibrator vibrator; private Handler handler; public CallNotificationController(Bundle args) { @@ -452,10 +450,6 @@ public class CallNotificationController extends BaseController { mediaPlayer.release(); mediaPlayer = null; } - - if (vibrator != null) { - vibrator.cancel(); - } } @Override From e8930530de1b20f7bdc64768d3066ec0d3528537 Mon Sep 17 00:00:00 2001 From: Andy Scherzinger Date: Tue, 26 Oct 2021 12:15:13 +0200 Subject: [PATCH 2/2] rename method since vibrator implementation has been removed Signed-off-by: Andy Scherzinger --- .../talk/controllers/CallNotificationController.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/src/main/java/com/nextcloud/talk/controllers/CallNotificationController.java b/app/src/main/java/com/nextcloud/talk/controllers/CallNotificationController.java index 8d8d590c5..66e6dcdf7 100644 --- a/app/src/main/java/com/nextcloud/talk/controllers/CallNotificationController.java +++ b/app/src/main/java/com/nextcloud/talk/controllers/CallNotificationController.java @@ -441,7 +441,7 @@ public class CallNotificationController extends BaseController { } } - private void endMediaAndVibratorNotifications() { + private void endMediaNotifications() { if (mediaPlayer != null) { if (mediaPlayer.isPlaying()) { mediaPlayer.stop(); @@ -461,7 +461,7 @@ public class CallNotificationController extends BaseController { handler = null; } dispose(); - endMediaAndVibratorNotifications(); + endMediaNotifications(); super.onDestroy(); }