[apps/stats] FIx navigation bug in boxes

This commit is contained in:
Léa Saviot
2018-05-25 16:37:48 +02:00
parent 0cb2c6215d
commit d5e75e2598

View File

@@ -40,7 +40,7 @@ bool MultipleDataViewController::handleEvent(Ion::Events::Event event) {
assert(m_selectedSeries >= 0);
if (event == Ion::Events::Down) {
int currentSelectedSubview = multipleDataView()->indexOfSubviewAtSeries(m_selectedSeries);
if (currentSelectedSubview < multipleDataView()->numberOfSubviews() - 2) {
if (currentSelectedSubview < m_store->numberOfNonEmptySeries() - 1) {
multipleDataView()->deselectDataView(m_selectedSeries);
m_selectedSeries = multipleDataView()->seriesOfSubviewAtIndex(currentSelectedSubview+1);
*m_selectedBarIndex = 0;