]> git.ktnx.net Git - mobile-ledger.git/commitdiff
NT activity: drop method resetForm()
authorDamyan Ivanov <dam+mobileledger@ktnx.net>
Sun, 17 Nov 2019 17:23:49 +0000 (19:23 +0200)
committerDamyan Ivanov <dam+mobileledger@ktnx.net>
Sun, 17 Nov 2019 17:23:49 +0000 (19:23 +0200)
hollow wrapper around listAdapter.reset();

app/src/main/java/net/ktnx/mobileledger/ui/activity/NewTransactionActivity.java

index 6a6fb4194c5139e0e0187abee725e8fc3d09469d..a9d74727bd2d51f0a1056195490cb9a7059b84f4 100644 (file)
@@ -239,14 +239,15 @@ public class NewTransactionActivity extends ProfileThemedActivity implements Tas
                 getResources().getDisplayMetrics()));
     }
     public void resetTransactionFromMenu(MenuItem item) {
-        resetForm();
+        listAdapter.reset();
     }
     @Override
     public void done(String error) {
         progress.setVisibility(View.INVISIBLE);
         debug("visuals", "hiding progress");
 
-        if (error == null) resetForm();
+        if (error == null)
+            listAdapter.reset();
         else Snackbar.make(list, error, BaseTransientBottomBar.LENGTH_LONG)
                      .show();
 
@@ -254,9 +255,6 @@ public class NewTransactionActivity extends ProfileThemedActivity implements Tas
         viewModel.checkTransactionSubmittable(listAdapter);
     }
 
-    private void resetForm() {
-        listAdapter.reset();
-    }
     private class AsyncCrasher extends AsyncTask<Void, Void, Void> {
         @Override
         protected Void doInBackground(Void... voids) {