Hide statustics logging option

Change-Id: I1ee258948a8335af7996f9e3afcc0508adbb1ac0
This commit is contained in:
Satoshi Kataoka 2012-11-14 14:01:52 +09:00
parent 372f9da4f9
commit 1ee6e14507

View file

@ -37,6 +37,8 @@ public final class DebugSettings extends PreferenceFragment
private static final String DEBUG_MODE_KEY = "debug_mode"; private static final String DEBUG_MODE_KEY = "debug_mode";
public static final String FORCE_NON_DISTINCT_MULTITOUCH_KEY = "force_non_distinct_multitouch"; public static final String FORCE_NON_DISTINCT_MULTITOUCH_KEY = "force_non_distinct_multitouch";
public static final String PREF_USABILITY_STUDY_MODE = "usability_study_mode"; public static final String PREF_USABILITY_STUDY_MODE = "usability_study_mode";
private static final String PREF_STATISTICS_LOGGING_KEY = "enable_logging";
private static final boolean SHOW_STATISTICS_LOGGING = false;
private boolean mServiceNeedsRestart = false; private boolean mServiceNeedsRestart = false;
private CheckBoxPreference mDebugMode; private CheckBoxPreference mDebugMode;
@ -55,6 +57,12 @@ public final class DebugSettings extends PreferenceFragment
ResearchLogger.DEFAULT_USABILITY_STUDY_MODE)); ResearchLogger.DEFAULT_USABILITY_STUDY_MODE));
checkbox.setSummary(R.string.settings_warning_researcher_mode); checkbox.setSummary(R.string.settings_warning_researcher_mode);
} }
final Preference statisticsLoggingPref = findPreference(PREF_STATISTICS_LOGGING_KEY);
if (statisticsLoggingPref instanceof CheckBoxPreference) {
if (!SHOW_STATISTICS_LOGGING) {
getPreferenceScreen().removePreference(statisticsLoggingPref);
}
}
mServiceNeedsRestart = false; mServiceNeedsRestart = false;
mDebugMode = (CheckBoxPreference) findPreference(DEBUG_MODE_KEY); mDebugMode = (CheckBoxPreference) findPreference(DEBUG_MODE_KEY);