]> git.ktnx.net Git - mobile-ledger.git/commitdiff
fix a bunch of spelling mistakes all around
authorDamyan Ivanov <dam+mobileledger@ktnx.net>
Sat, 15 Aug 2020 09:57:52 +0000 (09:57 +0000)
committerDamyan Ivanov <dam+mobileledger@ktnx.net>
Sat, 15 Aug 2020 12:48:13 +0000 (12:48 +0000)
14 files changed:
app/src/main/java/net/ktnx/mobileledger/async/DbOpRunner.java
app/src/main/java/net/ktnx/mobileledger/async/SendTransactionTask.java
app/src/main/java/net/ktnx/mobileledger/ui/CrashReportDialogFragment.java
app/src/main/java/net/ktnx/mobileledger/ui/MobileLedgerListFragment.java
app/src/main/java/net/ktnx/mobileledger/ui/account_summary/AccountSummaryFragment.java
app/src/main/java/net/ktnx/mobileledger/ui/activity/NewTransactionItemsAdapter.java
app/src/main/java/net/ktnx/mobileledger/ui/profiles/ProfileDetailFragment.java
app/src/main/java/net/ktnx/mobileledger/ui/transaction_list/TransactionListFragment.java
app/src/main/res/layout/account_summary_fragment.xml
app/src/main/res/values/strings.xml
metadata/en-US/changelogs/20.txt
metadata/en-US/changelogs/30.txt
metadata/en-US/changelogs/32.txt
metadata/en-US/changelogs/34.txt

index 67d8a0b1b868b6b7b8e6c4963c010c55ff834f8f..f8ea577554a1511c96691d614334d0e567a7097d 100644 (file)
@@ -36,7 +36,7 @@ class DbOpRunner extends Thread {
         while (!interrupted()) {
             try {
                 DbOpItem item = queue.take();
-                debug("opQrunner", "Got " + item.sql);
+                debug("opQRunner", "Got " + item.sql);
                 {
                     SQLiteDatabase db = App.getDatabase();
                     if (BuildConfig.DEBUG) {
@@ -54,7 +54,7 @@ class DbOpRunner extends Thread {
                             }
                             b.append("]");
                         }
-                        debug("opQrunner", b.toString());
+                        debug("opQRunner", b.toString());
                     }
                     db.execSQL(item.sql, item.params);
                 }
index 0fd4a1b50fc284660d7663197d737f72af330404..f67e1844f052157d47e92f9e695c181646c43f2e 100644 (file)
@@ -62,7 +62,7 @@ public class SendTransactionTask extends AsyncTask<LedgerTransaction, Void, Void
     protected String error;
     private String token;
     private String session;
-    private LedgerTransaction ltr;
+    private LedgerTransaction transaction;
     private MobileLedgerProfile mProfile;
     private boolean simulate = false;
 
@@ -84,7 +84,8 @@ public class SendTransactionTask extends AsyncTask<LedgerTransaction, Void, Void
         http.setRequestProperty("Accept", "*/*");
 
         net.ktnx.mobileledger.json.v1_15.ParsedLedgerTransaction jsonTransaction =
-                net.ktnx.mobileledger.json.v1_15.ParsedLedgerTransaction.fromLedgerTransaction(ltr);
+                net.ktnx.mobileledger.json.v1_15.ParsedLedgerTransaction.fromLedgerTransaction(
+                        transaction);
         ObjectMapper mapper = new ObjectMapper();
         ObjectWriter writer =
                 mapper.writerFor(net.ktnx.mobileledger.json.v1_15.ParsedLedgerTransaction.class);
@@ -99,7 +100,8 @@ public class SendTransactionTask extends AsyncTask<LedgerTransaction, Void, Void
         http.setRequestProperty("Accept", "*/*");
 
         net.ktnx.mobileledger.json.v1_14.ParsedLedgerTransaction jsonTransaction =
-                net.ktnx.mobileledger.json.v1_14.ParsedLedgerTransaction.fromLedgerTransaction(ltr);
+                net.ktnx.mobileledger.json.v1_14.ParsedLedgerTransaction.fromLedgerTransaction(
+                        transaction);
         ObjectMapper mapper = new ObjectMapper();
         ObjectWriter writer =
                 mapper.writerFor(net.ktnx.mobileledger.json.v1_14.ParsedLedgerTransaction.class);
@@ -175,14 +177,14 @@ public class SendTransactionTask extends AsyncTask<LedgerTransaction, Void, Void
         if (token != null)
             params.addPair("_token", token);
 
-        SimpleDate transactionDate = ltr.getDate();
+        SimpleDate transactionDate = transaction.getDate();
         if (transactionDate == null) {
             transactionDate = SimpleDate.today();
         }
 
         params.addPair("date", Globals.formatLedgerDate(transactionDate));
-        params.addPair("description", ltr.getDescription());
-        for (LedgerTransactionAccount acc : ltr.getAccounts()) {
+        params.addPair("description", transaction.getDescription());
+        for (LedgerTransactionAccount acc : transaction.getAccounts()) {
             params.addPair("account", acc.getAccountName());
             if (acc.isAmountSet())
                 params.addPair("amount", String.format(Locale.US, "%1.2f", acc.getAmount()));
@@ -258,7 +260,7 @@ public class SendTransactionTask extends AsyncTask<LedgerTransaction, Void, Void
     protected Void doInBackground(LedgerTransaction... ledgerTransactions) {
         error = null;
         try {
-            ltr = ledgerTransactions[0];
+            transaction = ledgerTransactions[0];
 
             switch (mProfile.getApiVersion()) {
                 case auto:
index b87268ee6836fd98998b0ca0be97426f20753ccb..617a006c9f65dfea051a1dca347020b0be86aa3b 100644 (file)
@@ -79,7 +79,7 @@ public class CrashReportDialogFragment extends DialogFragment {
         AlertDialog dialog = builder.create();
         dialog.setOnShowListener(new DialogInterface.OnShowListener() {
             @Override
-            public void onShow(DialogInterface dialogIinterface) {
+            public void onShow(DialogInterface dialogInterface) {
                 dialog.getButton(AlertDialog.BUTTON_NEUTRAL)
                         .setOnClickListener(new View.OnClickListener() {
                             @Override
index 94d54f16b41208063810ad5dbe3da8bc6c649b46..da1ea1e642bb54c7e2a59cf8f6da0d6937372dca 100644 (file)
@@ -30,7 +30,7 @@ import net.ktnx.mobileledger.utils.Colors;
 import net.ktnx.mobileledger.utils.DimensionUtils;
 
 public class MobileLedgerListFragment extends Fragment {
-    public SwipeRefreshLayout swiper;
+    public SwipeRefreshLayout refreshLayout;
     public TransactionListAdapter modelAdapter;
     protected RecyclerView root;
     @NonNull
@@ -38,14 +38,14 @@ public class MobileLedgerListFragment extends Fragment {
         return (MainActivity) requireActivity();
     }
     protected void themeChanged(Integer counter) {
-        swiper.setColorSchemeColors(Colors.getSwipeCircleColors());
+        refreshLayout.setColorSchemeColors(Colors.getSwipeCircleColors());
     }
     public void onBackgroundTaskRunningChanged(Boolean isRunning) {
         if (getActivity() == null)
             return;
-        if (swiper == null)
+        if (refreshLayout == null)
             return;
-        swiper.setRefreshing(isRunning);
+        refreshLayout.setRefreshing(isRunning);
     }
     protected void manageFabOnScroll() {
         final MainActivity mainActivity = getMainActivity();
index eb61dcc6b0bbee9f37a4ff0188687971afe5e113..fdeb54804e26471bbb2117c1736c29f7b7018fd7 100644 (file)
@@ -89,9 +89,9 @@ public class AccountSummaryFragment extends MobileLedgerListFragment {
 
         manageFabOnScroll();
 
-        swiper = mainActivity.findViewById(R.id.account_swiper);
+        refreshLayout = mainActivity.findViewById(R.id.account_swipe_refresh_layout);
         Colors.themeWatch.observe(getViewLifecycleOwner(), this::themeChanged);
-        swiper.setOnRefreshListener(() -> {
+        refreshLayout.setOnRefreshListener(() -> {
             debug("ui", "refreshing accounts via swipe");
             Data.scheduleTransactionListRetrieval(mainActivity);
         });
index 80deaf27281315af7974e05f2c7def6fd9bb1cae..d3e9d8f2a4f51549341c5c7df0e42cbd1315d0d0 100644 (file)
@@ -186,7 +186,7 @@ class NewTransactionItemsAdapter extends RecyclerView.Adapter<NewTransactionItem
         this.recyclerView = null;
     }
     public void descriptionSelected(String description) {
-        debug("descr selected", description);
+        debug("description selected", description);
         if (!accountListIsEmpty())
             return;
 
@@ -212,8 +212,8 @@ class NewTransactionItemsAdapter extends RecyclerView.Adapter<NewTransactionItem
         sb.append(" ORDER BY t.year desc, t.month desc, t.day desc LIMIT 1");
 
         final String sql = sb.toString();
-        debug("descr", sql);
-        debug("descr", params.toString());
+        debug("description", sql);
+        debug("description", params.toString());
 
         Activity activity = (Activity) recyclerView.getContext();
         // FIXME: handle exceptions?
@@ -238,14 +238,14 @@ class NewTransactionItemsAdapter extends RecyclerView.Adapter<NewTransactionItem
                 if (Misc.isEmptyOrNull(accFilter))
                     return;
 
-                debug("descr", "Trying transaction search without preferred account filter");
+                debug("description", "Trying transaction search without preferred account filter");
 
                 final String broaderSql =
                         "select t.profile, t.id from transactions t where t.description=?" +
                         " ORDER BY year desc, month desc, day desc LIMIT 1";
                 params.remove(1);
-                debug("descr", broaderSql);
-                debug("descr", description);
+                debug("description", broaderSql);
+                debug("description", description);
 
                 activity.runOnUiThread(() -> {
                     Snackbar.make(recyclerView, R.string.ignoring_preferred_account,
index 7a7afef6221f2ec7c25b133b49a2119b2b4d2676..95faf5d1ade773559bbf51de734ad50a9bcddebb 100644 (file)
@@ -172,7 +172,7 @@ public class ProfileDetailFragment extends Fragment {
         if (mProfile.equals(Data.getProfile()))
             Data.setCurrentProfile(newProfile);
     }
-    private void hookTextChangeSyncRoutine(TextView view, TextChangeSyncProc syncRoutine) {
+    private void hookTextChangeSyncRoutine(TextView view, TextChangeSyncRoutine syncRoutine) {
         view.addTextChangedListener(new TextWatcher() {
             @Override
             public void beforeTextChanged(CharSequence s, int start, int count, int after) {}
@@ -586,7 +586,7 @@ public class ProfileDetailFragment extends Fragment {
         defaultCommodity.setText(name);
         defaultCommodity.setTypeface(Typeface.DEFAULT);
     }
-    interface TextChangeSyncProc {
+    interface TextChangeSyncRoutine {
         void onTextChanged(String text);
     }
 }
index 19945505c86dbb524bb529f41f759071be840c5b..fd13bc60ee70a825227ec47495df64baf0f9b1fa 100644 (file)
@@ -98,8 +98,8 @@ public class TransactionListFragment extends MobileLedgerListFragment
 
         MainActivity mainActivity = getMainActivity();
 
-        swiper = mainActivity.findViewById(R.id.transaction_swipe);
-        if (swiper == null)
+        refreshLayout = mainActivity.findViewById(R.id.transaction_swipe);
+        if (refreshLayout == null)
             throw new RuntimeException("Can't get hold on the swipe layout");
         root = mainActivity.findViewById(R.id.transaction_root);
         if (root == null)
@@ -116,7 +116,7 @@ public class TransactionListFragment extends MobileLedgerListFragment
         llm.setOrientation(RecyclerView.VERTICAL);
         root.setLayoutManager(llm);
 
-        swiper.setOnRefreshListener(() -> {
+        refreshLayout.setOnRefreshListener(() -> {
             debug("ui", "refreshing transactions via swipe");
             Data.scheduleTransactionListRetrieval(mainActivity);
         });
@@ -137,7 +137,7 @@ public class TransactionListFragment extends MobileLedgerListFragment
         Data.accountFilter.observe(getViewLifecycleOwner(), this::onAccountNameFilterChanged);
 
         TransactionListViewModel.updating.addObserver(
-                (o, arg) -> swiper.setRefreshing(TransactionListViewModel.updating.get()));
+                (o, arg) -> refreshLayout.setRefreshing(TransactionListViewModel.updating.get()));
         TransactionListViewModel.updateError.addObserver((o, arg) -> {
             String err = TransactionListViewModel.updateError.get();
             if (err == null)
index 296b1c47e97e2d7184881e227acf0cfc807f1848..55f4af9f25322e50b1144b828d3ff0a2625669ba 100644 (file)
@@ -33,7 +33,7 @@
         >
 
         <androidx.swiperefreshlayout.widget.SwipeRefreshLayout
-            android:id="@+id/account_swiper"
+            android:id="@+id/account_swipe_refresh_layout"
             android:layout_width="match_parent"
             android:layout_height="match_parent"
             >
index 21742503c4b2f19d80b23c8f52de8754192746c7..00028d434bbc924a56f8a378f5c82a329f6982ce 100644 (file)
     <string name="zero_amount">0.00</string>
     <string name="new_transaction_saving">Saving…</string>
     <string name="simulate_save_label">Simulate save requests</string>
-    <string name="simulate_save_condensed_label">Simul. save</string>
+    <string name="simulate_save_condensed_label">Simulate saves</string>
     <string name="simulation_label">SIMULATION</string>
     <string name="profile_future_dates_label">Allow input of dates in the future</string>
     <string name="future_dates_none">No future dates are allowed</string>
index 56e7ec48ffe34de5dab8c9c41e0213a3b957e18f..829160c8d1b39dc6f40c28e2d76269db78dece66 100644 (file)
@@ -1,6 +1,6 @@
  * NEW:
   - App shortcuts for starting the new transaction activity on Android 7.1+
-  - Auto-filling of the accounts in the new transaction screen can be limitted to the transactions using accounts corresponding to a filter -- the filter is set in the profile details
+  - Auto-filling of the accounts in the new transaction screen can be limited to the transactions using accounts corresponding to a filter -- the filter is set in the profile details
  * IMPROVED:
   - Account list: Accounts with many commodities have their commodity list collapsed to avoid filling too much of the screen with one account
   - Account list: Viewing account's transactions migrated to a context menu
index a55f91cd7614ab1fb59b7725834f3ef48e693052..e064b67b160e2b3831bf7388930e3aedfa4fda0d 100644 (file)
@@ -3,7 +3,7 @@
 * SECURITY
     + avoid exposing basic HTTP authentication to wifi portals
     + profile editor: warn when using authentication with insecure HTTP scheme
-    + permit cleartext HTTP traffic on Android 8+ (still, please use HTTPS to keep yout data safe while in transit)
+    + permit cleartext HTTP traffic on Android 8+ (still, please use HTTPS to keep your data safe while in transit)
 * IMPROVEMENTS
     + clarify that crash reports are sent via email and user can review them before sending
     + allow toggling password visibility in profile details
index 0a9b8ef3b2ddc23c0158eff9f62ebbb1f50423ed..d37e9c60dc5a286ee3875e2c7a7cc7be49c6ee27 100644 (file)
@@ -4,4 +4,4 @@
 * FIXES:
     + fixed crash when parsing posting flags with hledger-web before 1.14
     + visual fixes
-    + fix numerical entry with some samsung keyboards
+    + fix numerical entry with some Samsung keyboards
index 06fce4fe30c4c4ab6ce56f831cc2f2467110209c..2072184b1157079f04ee4dc703fd568756a3aa42 100644 (file)
@@ -2,7 +2,7 @@
     + show transaction-level comment in transaction list
     + scroll to a specific date in the transaction list
 * IMPROVEMENTS
-    + better all-around theming; employ some material design recommendations
+    + better all-around theme integration; employ some material design recommendations
     + follow system-wide font size settings
 * FIXES
     + fix a crash in legacy parser with amounts like '$123.45'