mirror of
https://codeberg.org/Bazsalanszky/Infinity-For-Lemmy.git
synced 2024-12-27 03:18:24 +01:00
Disable Copied toast on android 13+ (#1139)
This commit is contained in:
parent
9b8cd3816f
commit
48dcf2293c
@ -148,7 +148,9 @@ public class GiveAwardActivity extends BaseActivity {
|
||||
if (clipboard != null) {
|
||||
ClipData clip = ClipData.newPlainText("simple text", text);
|
||||
clipboard.setPrimaryClip(clip);
|
||||
Toast.makeText(GiveAwardActivity.this, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
if (android.os.Build.VERSION.SDK_INT < 33) {
|
||||
Toast.makeText(GiveAwardActivity.this, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
} else {
|
||||
Toast.makeText(GiveAwardActivity.this, R.string.copy_failed, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
@ -157,7 +157,9 @@ public class WebViewActivity extends BaseActivity {
|
||||
if (clipboard != null) {
|
||||
ClipData clip = ClipData.newPlainText("simple text", url);
|
||||
clipboard.setPrimaryClip(clip);
|
||||
Toast.makeText(this, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
if (android.os.Build.VERSION.SDK_INT < 33) {
|
||||
Toast.makeText(this, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
} else {
|
||||
Toast.makeText(this, R.string.copy_link_failed, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
@ -294,7 +294,9 @@ public class PrivateMessagesDetailRecyclerViewAdapter extends RecyclerView.Adapt
|
||||
if (clipboard != null) {
|
||||
ClipData clip = ClipData.newPlainText("simple text", message.getBody());
|
||||
clipboard.setPrimaryClip(clip);
|
||||
Toast.makeText(mViewPrivateMessagesActivity, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
if (android.os.Build.VERSION.SDK_INT < 33) {
|
||||
Toast.makeText(mViewPrivateMessagesActivity, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
} else {
|
||||
Toast.makeText(mViewPrivateMessagesActivity, R.string.copy_failed, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
@ -134,7 +134,9 @@ public class CopyTextBottomSheetFragment extends LandscapeExpandedRoundedBottomS
|
||||
if (clipboard != null) {
|
||||
ClipData clip = ClipData.newPlainText("simple text", text);
|
||||
clipboard.setPrimaryClip(clip);
|
||||
Toast.makeText(activity, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
if (android.os.Build.VERSION.SDK_INT < 33) {
|
||||
Toast.makeText(activity, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
} else {
|
||||
Toast.makeText(activity, R.string.copy_link_failed, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
@ -140,7 +140,9 @@ public class ShareLinkBottomSheetFragment extends LandscapeExpandedRoundedBottom
|
||||
if (clipboard != null) {
|
||||
ClipData clip = ClipData.newPlainText("simple text", link);
|
||||
clipboard.setPrimaryClip(clip);
|
||||
Toast.makeText(activity, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
if (android.os.Build.VERSION.SDK_INT < 33) {
|
||||
Toast.makeText(activity, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
} else {
|
||||
Toast.makeText(activity, R.string.copy_link_failed, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
@ -80,7 +80,9 @@ public class UrlMenuBottomSheetFragment extends LandscapeExpandedRoundedBottomSh
|
||||
if (clipboard != null) {
|
||||
ClipData clip = ClipData.newPlainText("simple text", url);
|
||||
clipboard.setPrimaryClip(clip);
|
||||
Toast.makeText(activity, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
if (android.os.Build.VERSION.SDK_INT < 33) {
|
||||
Toast.makeText(activity, R.string.copy_success, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
} else {
|
||||
Toast.makeText(activity, R.string.copy_link_failed, Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user