diff --git a/mastodon/src/main/AndroidManifest.xml b/mastodon/src/main/AndroidManifest.xml index 1b6cffb53..9968bae45 100644 --- a/mastodon/src/main/AndroidManifest.xml +++ b/mastodon/src/main/AndroidManifest.xml @@ -4,7 +4,8 @@ - + + diff --git a/mastodon/src/main/java/org/joinmastodon/android/fragments/ProfileFragment.java b/mastodon/src/main/java/org/joinmastodon/android/fragments/ProfileFragment.java index 39d665d0a..c58604a60 100644 --- a/mastodon/src/main/java/org/joinmastodon/android/fragments/ProfileFragment.java +++ b/mastodon/src/main/java/org/joinmastodon/android/fragments/ProfileFragment.java @@ -10,6 +10,7 @@ import android.app.Activity; import android.app.Fragment; import android.content.ClipData; import android.content.ClipboardManager; +import android.content.Context; import android.content.Intent; import android.content.res.Configuration; import android.graphics.Outline; @@ -18,6 +19,8 @@ import android.graphics.drawable.Drawable; import android.net.Uri; import android.os.Build; import android.os.Bundle; +import android.os.VibrationEffect; +import android.os.Vibrator; import android.text.SpannableStringBuilder; import android.text.TextUtils; import android.text.style.ImageSpan; @@ -292,6 +295,9 @@ public class ProfileFragment extends LoaderFragment implements OnBackPressedList if(Build.VERSION.SDK_INT= Build.VERSION_CODES.O) vibrator.vibrate(VibrationEffect.createOneShot(50, VibrationEffect.DEFAULT_AMPLITUDE)); + else vibrator.vibrate(50); return true; });