Fix expanding

This commit is contained in:
Victor Shcherb 2015-03-18 00:38:45 +01:00
parent f733ad4f8a
commit e12a5ced22

View file

@ -648,7 +648,8 @@ public class AvailableGPXFragment extends OsmandExpandableListFragment {
if (getActivity() != null) { if (getActivity() != null) {
((ActionBarActivity) getActivity()).setSupportProgressBarIndeterminateVisibility(false); ((ActionBarActivity) getActivity()).setSupportProgressBarIndeterminateVisibility(false);
} }
if (allGpxAdapter.getGroupCount() > 0) { if (allGpxAdapter.getGroupCount() > 0 &&
allGpxAdapter.isShowingSelection()) {
getExpandableListView().expandGroup(0); getExpandableListView().expandGroup(0);
} }
} }
@ -919,7 +920,7 @@ public class AvailableGPXFragment extends OsmandExpandableListFragment {
return isShowingSelection() && groupPosition == 0; return isShowingSelection() && groupPosition == 0;
} }
private boolean isShowingSelection() { public boolean isShowingSelection() {
return selected.size() > 0 && !selectionMode; return selected.size() > 0 && !selectionMode;
} }