mirror of
https://github.com/bitwarden/mobile
synced 2025-12-12 14:23:26 +00:00
custom toast implementations
This commit is contained in:
@@ -45,6 +45,12 @@ namespace Bit.Android.Services
|
||||
|
||||
private Context CurrentContext => CrossCurrentActivity.Current.Activity;
|
||||
|
||||
public void Toast(string text, bool longDuration = false)
|
||||
{
|
||||
global::Android.Widget.Toast.MakeText(CurrentContext, text,
|
||||
longDuration ? global::Android.Widget.ToastLength.Long : global::Android.Widget.ToastLength.Short).Show();
|
||||
}
|
||||
|
||||
public void CopyToClipboard(string text)
|
||||
{
|
||||
var clipboardManager = (ClipboardManager)CurrentContext.GetSystemService(Context.ClipboardService);
|
||||
|
||||
Reference in New Issue
Block a user