From c7cb37347d7efa319244406fca52a20e15f1095c Mon Sep 17 00:00:00 2001 From: dtvv Date: Mon, 3 Sep 2018 15:59:32 -0600 Subject: [PATCH] Remove testing cases --- .../agorise/crystalwallet/activities/BoardActivity.java | 4 ++-- .../crystalwallet/activities/SendTransactionActivity.java | 8 +++++--- .../crystalwallet/fragments/SendTransactionFragment.java | 6 +++--- .../validationFields/BitsharesAccountNameValidation.kt | 2 +- 4 files changed, 11 insertions(+), 9 deletions(-) diff --git a/app/src/main/java/cy/agorise/crystalwallet/activities/BoardActivity.java b/app/src/main/java/cy/agorise/crystalwallet/activities/BoardActivity.java index e2833aa..3d37978 100644 --- a/app/src/main/java/cy/agorise/crystalwallet/activities/BoardActivity.java +++ b/app/src/main/java/cy/agorise/crystalwallet/activities/BoardActivity.java @@ -118,7 +118,7 @@ public class BoardActivity extends CustomActivity { /* * Listener tabLayout to resalt text when clicked * */ - /*final TabLayout tabLayoutFinal = tabLayout; + final TabLayout tabLayoutFinal = tabLayout; tabLayout.addOnTabSelectedListener(new TabLayout.OnTabSelectedListener() { @Override public void onTabSelected(final TabLayout.Tab tab) { @@ -162,7 +162,7 @@ public class BoardActivity extends CustomActivity { } - });*/ + }); // Appbar animation mSurfaceView.getHolder().addCallback(new SurfaceHolder.Callback() { diff --git a/app/src/main/java/cy/agorise/crystalwallet/activities/SendTransactionActivity.java b/app/src/main/java/cy/agorise/crystalwallet/activities/SendTransactionActivity.java index f1783e3..f34db62 100644 --- a/app/src/main/java/cy/agorise/crystalwallet/activities/SendTransactionActivity.java +++ b/app/src/main/java/cy/agorise/crystalwallet/activities/SendTransactionActivity.java @@ -11,6 +11,8 @@ import android.widget.EditText; import android.widget.Spinner; import android.widget.TextView; +import com.jaredrummler.materialspinner.MaterialSpinner; + import java.util.ArrayList; import java.util.List; @@ -35,8 +37,8 @@ public class SendTransactionActivity extends AppCompatActivity implements UIVali SendTransactionValidator sendTransactionValidator; - /*@BindView(R.id.etFrom) - EditText etFrom;*/ + @BindView(R.id.spFrom) + MaterialSpinner spFrom; @BindView(R.id.tvFromError) TextView tvFromError; @BindView(R.id.etTo) @@ -102,7 +104,7 @@ public class SendTransactionActivity extends AppCompatActivity implements UIVali } }); - //sendTransactionValidator = new SendTransactionValidator(this.getApplicationContext(), this.cryptoNetAccount, etFrom, etTo, spAsset, etAmount, etMemo); + sendTransactionValidator = new SendTransactionValidator(this.getApplicationContext(), this.cryptoNetAccount, spFrom, etTo, spAsset, etAmount, etMemo); sendTransactionValidator.setListener(this); } else { this.finish(); diff --git a/app/src/main/java/cy/agorise/crystalwallet/fragments/SendTransactionFragment.java b/app/src/main/java/cy/agorise/crystalwallet/fragments/SendTransactionFragment.java index 5a89378..05bfcfe 100644 --- a/app/src/main/java/cy/agorise/crystalwallet/fragments/SendTransactionFragment.java +++ b/app/src/main/java/cy/agorise/crystalwallet/fragments/SendTransactionFragment.java @@ -153,8 +153,8 @@ public class SendTransactionFragment extends DialogFragment implements UIValidat * this is only for graphene accounts. * **/ - this.grapheneAccount = new GrapheneAccount(this.cryptoNetAccount); - this.grapheneAccount.loadInfo(db.grapheneAccountInfoDao().getByAccountId(this.cryptoNetAccountId)); + //this.grapheneAccount = new GrapheneAccount(this.cryptoNetAccount); + //this.grapheneAccount.loadInfo(db.grapheneAccountInfoDao().getByAccountId(this.cryptoNetAccountId)); final LiveData> balancesList = db.cryptoCoinBalanceDao().getBalancesFromAccount(cryptoNetAccountId); balancesList.observe(this, new Observer>() { @@ -185,7 +185,7 @@ public class SendTransactionFragment extends DialogFragment implements UIValidat * Custom material spinner implementation * */ spFrom.setItems(cryptoNetAccounts); - spFrom.setSelectedIndex(0); + //spFrom.setSelectedIndex(0); spFrom.setOnItemSelectedListener(new MaterialSpinner.OnItemSelectedListener() { @Override public void onItemSelected(MaterialSpinner view, int position, long id, CryptoNetAccount item) { diff --git a/app/src/main/java/cy/agorise/crystalwallet/viewmodels/validators/customImpl/validationFields/BitsharesAccountNameValidation.kt b/app/src/main/java/cy/agorise/crystalwallet/viewmodels/validators/customImpl/validationFields/BitsharesAccountNameValidation.kt index 677e99f..9c56bfe 100644 --- a/app/src/main/java/cy/agorise/crystalwallet/viewmodels/validators/customImpl/validationFields/BitsharesAccountNameValidation.kt +++ b/app/src/main/java/cy/agorise/crystalwallet/viewmodels/validators/customImpl/validationFields/BitsharesAccountNameValidation.kt @@ -177,7 +177,7 @@ class BitsharesAccountNameValidation : CustomValidationField, UIValidator { * */ creatingAccountMaterialDialog.dismiss() - if (!request.accountExists) { + if (request.accountExists) { /* * The account exists and is not valid