aboutsummaryrefslogtreecommitdiffstats
path: root/main/src/cgeo/geocaching/ui/AbstractCachingPageViewCreator.java
diff options
context:
space:
mode:
Diffstat (limited to 'main/src/cgeo/geocaching/ui/AbstractCachingPageViewCreator.java')
-rw-r--r--main/src/cgeo/geocaching/ui/AbstractCachingPageViewCreator.java26
1 files changed, 26 insertions, 0 deletions
diff --git a/main/src/cgeo/geocaching/ui/AbstractCachingPageViewCreator.java b/main/src/cgeo/geocaching/ui/AbstractCachingPageViewCreator.java
index 333ef11..ed5d182 100644
--- a/main/src/cgeo/geocaching/ui/AbstractCachingPageViewCreator.java
+++ b/main/src/cgeo/geocaching/ui/AbstractCachingPageViewCreator.java
@@ -2,6 +2,12 @@ package cgeo.geocaching.ui;
import cgeo.geocaching.activity.AbstractViewPagerActivity.PageViewCreator;
+import edu.umd.cs.findbugs.annotations.SuppressFBWarnings;
+
+import org.eclipse.jdt.annotation.NonNull;
+import org.eclipse.jdt.annotation.Nullable;
+
+import android.os.Bundle;
import android.view.View;
/**
@@ -28,5 +34,25 @@ public abstract class AbstractCachingPageViewCreator<ViewClass extends View> imp
}
@Override
+ @SuppressFBWarnings("USM_USELESS_ABSTRACT_METHOD")
public abstract ViewClass getDispatchedView();
+
+ /**
+ * Gets the state of the view but returns an empty state if not overridden
+ *
+ * @return empty bundle
+ */
+ @Override
+ public @Nullable
+ Bundle getViewState() {
+ return new Bundle();
+ }
+
+ /**
+ * Restores the state of the view but just returns if not overridden.
+ */
+ @Override
+ public void setViewState(@NonNull Bundle state) {
+ return;
+ }
}