--- a/src/com/beem/project/beem/BeemApplication.java Mon Mar 21 21:54:08 2011 +0100
+++ b/src/com/beem/project/beem/BeemApplication.java Mon Mar 21 21:55:23 2011 +0100
@@ -94,6 +94,7 @@
private boolean mIsConnected;
private boolean mIsAccountConfigured;
+ private boolean mPepEnabled;
private SharedPreferences mSettings;
private final PreferenceListener mPreferenceListener = new PreferenceListener();
@@ -117,7 +118,6 @@
public void onTerminate() {
super.onTerminate();
mSettings.unregisterOnSharedPreferenceChangeListener(mPreferenceListener);
-
}
/**
@@ -145,6 +145,24 @@
}
/**
+ * Enable Pep in the application context.
+ *
+ * @param enabled true to enable pep
+ */
+ public void setPepEnabled(boolean enabled) {
+ mPepEnabled = enabled;
+ }
+
+ /**
+ * Check if Pep is enabled.
+ *
+ * @return true if enabled
+ */
+ public boolean isPepEnabled() {
+ return mPepEnabled;
+ }
+
+ /**
* A listener for all the change in the preference file. It is used to maintain the global state of the application.
*/
private class PreferenceListener implements SharedPreferences.OnSharedPreferenceChangeListener {