diff --git a/.idea/caches/build_file_checksums.ser b/.idea/caches/build_file_checksums.ser index 663bf4b1b..3a0f7ce4b 100644 Binary files a/.idea/caches/build_file_checksums.ser and b/.idea/caches/build_file_checksums.ser differ diff --git a/.idea/caches/gradle_models.ser b/.idea/caches/gradle_models.ser index e298ddf6c..8d3e51aef 100644 Binary files a/.idea/caches/gradle_models.ser and b/.idea/caches/gradle_models.ser differ diff --git a/app/build.gradle b/app/build.gradle index ef1b30997..4cc4592ec 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -7,8 +7,8 @@ android { applicationId = 'com.wagerrwallet' minSdkVersion 23 targetSdkVersion 28 - versionCode 240 - versionName "240" + versionCode 241 + versionName "241" multiDexEnabled true // Similar to other properties in the defaultConfig block, diff --git a/app/src/main/java/com/wagerrwallet/presenter/activities/EventsActivity.java b/app/src/main/java/com/wagerrwallet/presenter/activities/EventsActivity.java index 7b5b6f9d7..d333623c6 100644 --- a/app/src/main/java/com/wagerrwallet/presenter/activities/EventsActivity.java +++ b/app/src/main/java/com/wagerrwallet/presenter/activities/EventsActivity.java @@ -295,6 +295,10 @@ public void onClick(View v) { } + public boolean isSearchActive() { + return searchBar.isShown(); + } + @Override protected void onDestroy() { super.onDestroy(); diff --git a/app/src/main/java/com/wagerrwallet/presenter/activities/WalletActivity.java b/app/src/main/java/com/wagerrwallet/presenter/activities/WalletActivity.java index e717f8130..7ae5c7a28 100644 --- a/app/src/main/java/com/wagerrwallet/presenter/activities/WalletActivity.java +++ b/app/src/main/java/com/wagerrwallet/presenter/activities/WalletActivity.java @@ -228,6 +228,10 @@ public void onClick(View v) { } + public boolean isSearchActive() { + return searchBar.isShown(); + } + @Override protected void onDestroy() { super.onDestroy(); diff --git a/app/src/main/java/com/wagerrwallet/presenter/customviews/BRSearchBar.java b/app/src/main/java/com/wagerrwallet/presenter/customviews/BRSearchBar.java index a1aa25986..6bf591ef7 100644 --- a/app/src/main/java/com/wagerrwallet/presenter/customviews/BRSearchBar.java +++ b/app/src/main/java/com/wagerrwallet/presenter/customviews/BRSearchBar.java @@ -148,12 +148,12 @@ private void setListeners() { searchEdit.setOnFocusChangeListener(new View.OnFocusChangeListener() { @Override public void onFocusChange(View v, boolean hasFocus) { - if (!hasFocus) { + /*if (!hasFocus) { if (breadActivity.barFlipper != null) { breadActivity.barFlipper.setDisplayedChild(0); clearSwitches(); } - } + }*/ } }); diff --git a/app/src/main/java/com/wagerrwallet/tools/adapter/EventListAdapter.java b/app/src/main/java/com/wagerrwallet/tools/adapter/EventListAdapter.java index e38090a53..dd3b0c369 100644 --- a/app/src/main/java/com/wagerrwallet/tools/adapter/EventListAdapter.java +++ b/app/src/main/java/com/wagerrwallet/tools/adapter/EventListAdapter.java @@ -240,7 +240,7 @@ public void resetFilter() { public void filter(final long[] switches, boolean bNotify, String query) { long start = System.currentTimeMillis(); int switchesON = 0; - for (long i : switches) if (i>0) switchesON++; + for (long i : switches) if (i>=0) switchesON++; final List filteredList = new ArrayList<>(); String lowerQuery = query.toLowerCase().trim(); diff --git a/app/src/main/java/com/wagerrwallet/tools/manager/EventTxManager.java b/app/src/main/java/com/wagerrwallet/tools/manager/EventTxManager.java index 69060521d..8c87211bf 100644 --- a/app/src/main/java/com/wagerrwallet/tools/manager/EventTxManager.java +++ b/app/src/main/java/com/wagerrwallet/tools/manager/EventTxManager.java @@ -114,7 +114,7 @@ public synchronized void updateTxList(final Context app) { long took = (System.currentTimeMillis() - start); if (took > 500) Log.e(TAG, "updateEventList: took: " + took); - if (adapter != null) { + if (adapter != null && !((EventsActivity)app).isSearchActive()) { ((Activity) app).runOnUiThread(new Runnable() { @Override public void run() { diff --git a/app/src/main/java/com/wagerrwallet/tools/manager/TxManager.java b/app/src/main/java/com/wagerrwallet/tools/manager/TxManager.java index c0769cd01..6be90a39a 100644 --- a/app/src/main/java/com/wagerrwallet/tools/manager/TxManager.java +++ b/app/src/main/java/com/wagerrwallet/tools/manager/TxManager.java @@ -67,9 +67,13 @@ public void init(final WalletActivity app) { txList, new RecyclerItemClickListener.OnItemClickListener() { @Override public void onItemClick(View view, int position, float x, float y) { + try { + TxUiHolder item = adapter.getItems().get(position); + BRAnimator.showTransactionDetails(app, item, position); + } + catch (ArrayIndexOutOfBoundsException e) { - TxUiHolder item = adapter.getItems().get(position); - BRAnimator.showTransactionDetails(app, item, position); + } } @Override @@ -104,7 +108,7 @@ public synchronized void updateTxList(final Context app) { long took = (System.currentTimeMillis() - start); if (took > 500) Log.e(TAG, "updateTxList: took: " + took); - if (adapter != null) { + if (adapter != null && !((WalletActivity)app).isSearchActive() ) { ((WalletActivity) app).runOnUiThread(new Runnable() { @Override public void run() { diff --git a/app/src/main/java/com/wagerrwallet/tools/sqlite/BetEventTxDataStore.java b/app/src/main/java/com/wagerrwallet/tools/sqlite/BetEventTxDataStore.java index 86463e196..e12864620 100644 --- a/app/src/main/java/com/wagerrwallet/tools/sqlite/BetEventTxDataStore.java +++ b/app/src/main/java/com/wagerrwallet/tools/sqlite/BetEventTxDataStore.java @@ -315,7 +315,9 @@ public List getAllTransactions(Context app, String iso, long ev cursor.moveToFirst(); while (!cursor.isAfterLast()) { EventTxUiHolder transactionEntity = cursorToUIEvent(app, iso.toUpperCase(), cursor); - transactions.add(transactionEntity); + if (transactionEntity.getHomeOdds()>0 || transactionEntity.getDrawOdds()>0 || transactionEntity.getAwayOdds()>0) { + transactions.add(transactionEntity); + } cursor.moveToNext(); } } finally {