Fix multiple summary generation

This commit is contained in:
Tanguy Herbron 2018-04-16 02:42:47 +02:00
parent aa99543f48
commit 4001e8d094
3 changed files with 5 additions and 3 deletions

View File

@ -135,7 +135,7 @@ public class Summary extends Fragment {
} }
}); });
updateTitle(); //updateTitle();
updateAll(true); updateAll(true);
@ -495,7 +495,8 @@ public class Summary extends Fragment {
protected void onPostExecute(Void result) protected void onPostExecute(Void result)
{ {
refreshLayout.setRefreshing(false); refreshLayout.setRefreshing(false);
refreshCurrencyList(); //refreshCurrencyList();
adaptView();
handler.removeCallbacks(updateRunnable); handler.removeCallbacks(updateRunnable);
} }
} }
@ -632,6 +633,7 @@ public class Summary extends Fragment {
@Override @Override
public void onSuccess(Currency currency) { public void onSuccess(Currency currency) {
countCoins(true, false); countCoins(true, false);
Log.d("coinfolio", "History " + currency.getSymbol());
} }
}); });
} }

View File

@ -111,6 +111,7 @@ public class Currency implements Parcelable {
} }
else else
{ {
Log.d("coinfolio", "Error for : " + symbol);
value = NULL; value = NULL;
} }

View File

@ -253,7 +253,6 @@ public class HomeLayoutGenerator {
List<CurrencyDataChart> dataChartList = currency.getHistoryMinutes(); List<CurrencyDataChart> dataChartList = currency.getHistoryMinutes();
ArrayList<Entry> values = new ArrayList<>(); ArrayList<Entry> values = new ArrayList<>();
Log.d("coinfolio", "Generating data for " + currency.getSymbol());
for(int i = 0; i < dataChartList.size(); i+=10) for(int i = 0; i < dataChartList.size(); i+=10)
{ {
values.add(new Entry(i, (float) dataChartList.get(i).getOpen())); values.add(new Entry(i, (float) dataChartList.get(i).getOpen()));