Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
cbf5c839cd
1 changed files with 2 additions and 1 deletions
|
@ -482,7 +482,8 @@ public class LocalIndexesFragment extends OsmandExpandableListFragment {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
//fixes issue when local files not shown after switching tabs
|
//fixes issue when local files not shown after switching tabs
|
||||||
if (listAdapter.getGroupCount() == 0 && getDownloadActivity().getLocalIndexInfos().size() > 0) {
|
//Next line throws NPE in some circumstances when called from dashboard and listAdpater=null is not checked for. (Checking !this.isAdded above is not sufficient!)
|
||||||
|
if (listAdapter != null && listAdapter.getGroupCount() == 0 && getDownloadActivity().getLocalIndexInfos().size() > 0) {
|
||||||
for(LocalIndexInfo info : getDownloadActivity().getLocalIndexInfos()) {
|
for(LocalIndexInfo info : getDownloadActivity().getLocalIndexInfos()) {
|
||||||
listAdapter.addLocalIndexInfo(info);
|
listAdapter.addLocalIndexInfo(info);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue