-Toast after copy to clipboard in backupseed window

-Integrate https://github.com/afollestad/material-dialogs in androide app by gradle
-Change the loading dialog in the registration window for the new one material
-In the registration window in the PIN sections, i fixed the max length validation to 32 in both Fields
This commit is contained in:
dtvv 2018-07-31 14:13:19 -05:00
parent 1cd36489eb
commit 7a9c4c0012
5 changed files with 17 additions and 6 deletions

View file

@ -44,6 +44,7 @@ dependencies {
exclude group: 'com.android.support', module: 'support-annotations'
})
//testCompile 'com.android.support.test:runner:1.0.1'
implementation 'com.afollestad.material-dialogs:core:0.9.6.0' //DTVV Thrusday 31 July 2018
implementation 'com.android.support:appcompat-v7:27.1.1'
implementation 'com.android.support:support-v4:27.1.1'
implementation 'com.android.support:design:27.1.1'

View file

@ -15,6 +15,7 @@ import android.view.Display;
import android.widget.Button;
import android.widget.EditText;
import android.widget.TextView;
import android.widget.Toast;
import butterknife.BindView;
import butterknife.ButterKnife;
@ -39,8 +40,8 @@ public class BackupSeedActivity extends AppCompatActivity {
super.onCreate(savedInstanceState);
setContentView(R.layout.backup_seed);
/* Note: Test porpouses
final TextView textView = findViewById(R.id.backup_seed_view_textview_brainkey);
//Note: Test porpouses
/*final TextView textView = findViewById(R.id.backup_seed_view_textview_brainkey);
textView.setText("sakk902909321o p3k21kldsa0'dsa90'e930eidakdñsakdñlsakdi90i03 2i90idopsasakk902909321op3k21 kldsa0'dsa90'e930eid akdñsakdñlsakdi90i032i90idopsa");
*/
@ -87,5 +88,6 @@ public class BackupSeedActivity extends AppCompatActivity {
/*
* Success message
* */
Toast.makeText(this.getBaseContext(),getResources().getString(R.string.window_seed_toast_clipboard), Toast.LENGTH_SHORT).show();
}
}

View file

@ -11,12 +11,15 @@ import android.text.Editable;
import android.view.ViewGroup;
import android.widget.Button;
import com.afollestad.materialdialogs.MaterialDialog;
import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.OnClick;
import butterknife.OnTextChanged;
import cy.agorise.crystalwallet.R;
import cy.agorise.crystalwallet.dialogs.ProgressCreatingAccountDialog;
import cy.agorise.crystalwallet.dialogs.material.CreatingAccountMaterialDialog;
import cy.agorise.crystalwallet.requestmanagers.CryptoNetInfoRequestListener;
import cy.agorise.crystalwallet.requestmanagers.CryptoNetInfoRequests;
import cy.agorise.crystalwallet.requestmanagers.ValidateCreateBitsharesAccountRequest;
@ -143,18 +146,17 @@ public class CreateSeedActivity extends AppCompatActivity implements UIValidator
//DTVV: Friday 27 July 2018
//Makes dialog to tell the user that the account is been created
final ProgressCreatingAccountDialog progressCreatingAccountDialog = new ProgressCreatingAccountDialog(CreateSeedActivity.this);
progressCreatingAccountDialog.show();
final CreatingAccountMaterialDialog creatingAccountMaterialDialog = new CreatingAccountMaterialDialog(this);
CreateSeedActivity.this.runOnUiThread(new Runnable() {
@Override
public void run() {
progressCreatingAccountDialog.show();
creatingAccountMaterialDialog.show();
}
});
request.setListener(new CryptoNetInfoRequestListener() {
@Override
public void onCarryOut() {
progressCreatingAccountDialog.dismiss();
creatingAccountMaterialDialog.dismiss();
if (request.getStatus().equals(ValidateCreateBitsharesAccountRequest.StatusCode.SUCCEEDED)) {
GrapheneAccount accountSeed = request.getAccount();
Intent intent = new Intent(getApplicationContext(), BackupSeedActivity.class);

View file

@ -23,6 +23,7 @@
<android.support.design.widget.TextInputEditText
android:id="@+id/tietPin"
android:maxLength="32"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/txt_6_digits_pin"
@ -45,6 +46,7 @@
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:hint="@string/txt_6_digits_pin_confirm"
android:maxLength="32"
android:inputType="number"
android:singleLine="true" />
</android.support.design.widget.TextInputLayout>

View file

@ -33,7 +33,11 @@
<string name="account_label">Choose File</string>
<string name="loading_msg">Please wait until Balances are loading</string>
<string name="window_create_seed_DialogTittle"></string>
<string name="window_create_seed_DialogMessage">Creating New Account ...</string>
<string name="window_seed_backup">Backup brainkey</string>
<string name="window_seed_toast_clipboard">Brainkey copied to clipboard!</string>
<string name="window_seed_copy">Copy</string>
<string name="window_seed_leyend_backup">IMPORTANT: Print this out, or write it down. Anyone with access to your recovery key will have access to funds within this wallet</string>