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 6a6fb41..a9d7472 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) {