aboutsummaryrefslogtreecommitdiffstats
path: root/main/src
diff options
context:
space:
mode:
Diffstat (limited to 'main/src')
-rw-r--r--main/src/cgeo/geocaching/cgeocaches.java16
1 files changed, 8 insertions, 8 deletions
diff --git a/main/src/cgeo/geocaching/cgeocaches.java b/main/src/cgeo/geocaching/cgeocaches.java
index d29b924..df09936 100644
--- a/main/src/cgeo/geocaching/cgeocaches.java
+++ b/main/src/cgeo/geocaching/cgeocaches.java
@@ -439,23 +439,23 @@ public class cgeocaches extends AbstractListActivity implements FilteredActivity
}
}
+ setTitle(title);
+ setAdapter();
+
+ prepareFilterBar();
+
currentLoader = (AbstractSearchLoader) getSupportLoaderManager().initLoader(type.ordinal(), extras, this);
// init
if (CollectionUtils.isNotEmpty(cacheList)) {
- if (currentLoader.isStarted()) {
+ // currentLoader can be null if this activity is created from a map, as onCreateLoader() will return null.
+ if (currentLoader != null && currentLoader.isStarted()) {
showFooterLoadingCaches();
- }
- else {
+ } else {
showFooterMoreCaches();
}
}
- setTitle(title);
- setAdapter();
-
- prepareFilterBar();
-
if (isInvokedFromAttachment()) {
importGpxAttachement();
}