Migrate to SettingsStatsLog from StatsLog
As part of statsd becoming a Mainline module in R, autogenerated StatsLog.write() calls are going away and replaced by *StatsLog.java that is autogenerated for each module. This CL adds autogenerated SettingsStatsLog and replaces usages of StatsLog with SettingsStatsLog. Bug: 145952197 Test: m Change-Id: I3ffdb51394017e3e48b65734d67595abd69dd70d
This commit is contained in:
@@ -19,7 +19,6 @@ package com.android.settings.core.instrumentation;
|
||||
import android.app.settings.SettingsEnums;
|
||||
import android.content.Context;
|
||||
import android.util.Pair;
|
||||
import android.util.StatsLog;
|
||||
|
||||
import com.android.settingslib.core.instrumentation.LogWriter;
|
||||
|
||||
@@ -27,7 +26,7 @@ public class StatsLogWriter implements LogWriter {
|
||||
|
||||
@Override
|
||||
public void visible(Context context, int attribution, int pageId, int latency) {
|
||||
StatsLog.write(StatsLog.SETTINGS_UI_CHANGED /* Atom name */,
|
||||
SettingsStatsLog.write(SettingsStatsLog.SETTINGS_UI_CHANGED /* Atom name */,
|
||||
attribution, /* from pageId */
|
||||
SettingsEnums.PAGE_VISIBLE /* action */,
|
||||
pageId, /* target pageId */
|
||||
@@ -37,7 +36,7 @@ public class StatsLogWriter implements LogWriter {
|
||||
|
||||
@Override
|
||||
public void hidden(Context context, int pageId, int visibleTime) {
|
||||
StatsLog.write(StatsLog.SETTINGS_UI_CHANGED /* Atom name */,
|
||||
SettingsStatsLog.write(SettingsStatsLog.SETTINGS_UI_CHANGED /* Atom name */,
|
||||
SettingsEnums.PAGE_UNKNOWN /* attribution */,
|
||||
SettingsEnums.PAGE_HIDE /* action */,
|
||||
pageId,
|
||||
@@ -83,7 +82,7 @@ public class StatsLogWriter implements LogWriter {
|
||||
|
||||
@Override
|
||||
public void action(int attribution, int action, int pageId, String key, int value) {
|
||||
StatsLog.write(StatsLog.SETTINGS_UI_CHANGED /* atomName */,
|
||||
SettingsStatsLog.write(SettingsStatsLog.SETTINGS_UI_CHANGED /* atomName */,
|
||||
attribution,
|
||||
action,
|
||||
pageId,
|
||||
|
Reference in New Issue
Block a user