Merge pull request #18 from misaochan/usage

Removed usage reports option and code behind it
This commit is contained in:
Nicolas Raoul 2015-10-05 12:45:11 +09:00
commit fd3595e336
3 changed files with 2 additions and 14 deletions

View file

@ -1,12 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<PreferenceScreen xmlns:android="http://schemas.android.com/apk/res/android">
<CheckBoxPreference
android:key="eventLogging"
android:title="@string/preference_tracking"
android:summary="@string/preference_tracking_summary"
android:defaultValue="false"
/>
<ListPreference
android:key="defaultLicense"
android:title="@string/preference_license"

View file

@ -65,7 +65,7 @@ public class CommonsApplication extends Application {
public static final Object[] EVENT_LOGIN_ATTEMPT = {"MobileAppLoginAttempts", 5257721L};
public static final Object[] EVENT_SHARE_ATTEMPT = {"MobileAppShareAttempts", 5346170L};
public static final Object[] EVENT_CATEGORIZATION_ATTEMPT = {"MobileAppCategorizationAttempts", 5359208L};
public static final Object[] EVENT_EVENTLOGGING_CHANGE = {"MobileAppTrackingChange", 5369400L};
public static final String DEFAULT_EDIT_SUMMARY = "Uploaded using Android Commons app";

View file

@ -54,13 +54,6 @@ public class SettingsActivity extends SherlockPreferenceActivity implements Shar
}
public void onSharedPreferenceChanged(SharedPreferences sharedPreferences, String key) {
if(key.equals(Prefs.TRACKING_ENABLED)) {
// We force log this, so it is logged even if EL is turned off
EventLog.schema(CommonsApplication.EVENT_EVENTLOGGING_CHANGE)
.param("username", app.getCurrentAccount().name)
.param("state", sharedPreferences.getBoolean(key, true))
.log(true);
}
}
}