From 5470ca15234c95df5c8f1594f3bb82f42b9a367f Mon Sep 17 00:00:00 2001 From: Severiano Jaramillo Date: Wed, 9 Jan 2019 18:16:15 -0600 Subject: [PATCH] Chaged BrainKey modal in the Settings, it does not copu the BrainKey to the clipboard anymore, it just shows it so that the user writes it down. --- .../bitsybitshareswallet/fragments/SettingsFragment.kt | 10 +--------- app/src/main/res/values/strings.xml | 1 + 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/app/src/main/java/cy/agorise/bitsybitshareswallet/fragments/SettingsFragment.kt b/app/src/main/java/cy/agorise/bitsybitshareswallet/fragments/SettingsFragment.kt index 5cd77c5..083515c 100644 --- a/app/src/main/java/cy/agorise/bitsybitshareswallet/fragments/SettingsFragment.kt +++ b/app/src/main/java/cy/agorise/bitsybitshareswallet/fragments/SettingsFragment.kt @@ -1,7 +1,6 @@ package cy.agorise.bitsybitshareswallet.fragments import android.content.* -import android.content.Context.CLIPBOARD_SERVICE import android.os.Bundle import android.os.Handler import android.os.IBinder @@ -10,7 +9,6 @@ import android.util.Log import android.view.LayoutInflater import android.view.View import android.view.ViewGroup -import android.widget.Toast import androidx.fragment.app.Fragment import com.afollestad.materialdialogs.MaterialDialog import com.afollestad.materialdialogs.customview.customView @@ -228,13 +226,7 @@ class SettingsFragment : Fragment(), ServiceConnection { message(text = brainKey.brainKey) customView(R.layout.dialog_copy_brainkey) cancelable(false) - positiveButton(android.R.string.copy) { - Toast.makeText(it.context, "Copied to clipboard", Toast.LENGTH_SHORT).show() - val clipboard = it.context.getSystemService(CLIPBOARD_SERVICE) as ClipboardManager - val clip = ClipData.newPlainText("label", brainKey.brainKey) - clipboard.primaryClip = clip - it.dismiss() - } + positiveButton(R.string.button__copied) { it.dismiss() } } } diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml index 55833a4..d1f0b5c 100644 --- a/app/src/main/res/values/strings.xml +++ b/app/src/main/res/values/strings.xml @@ -108,6 +108,7 @@ Write this down! Be sure you have 2 copies of this BrainKey in 2 secure locations in case of fire or loss. Security First! Anyone with access to your BrainKey can access the funds in your account! + Copied Bugs or Ideas? Telegram chat: http://t.me/Agorise\nEmail: Agorise@protonmail.ch\nOpen Source: