Commit b3b711c9 authored by huayinz's avatar huayinz Committed by Commit bot

Remove unused histograms

Removed Omnibox.ProgressBarUpdateCount and
Omnibox.ProgressBarBreakPointUpdateCount
since collected data is not used anymore

BUG=719801
R=mdjones@chromium.org

Review-Url: https://codereview.chromium.org/2885013004
Cr-Commit-Position: refs/heads/master@{#473413}
parent 0e3e423a
...@@ -39,7 +39,6 @@ public class ClipDrawableProgressBar extends ImageView { ...@@ -39,7 +39,6 @@ public class ClipDrawableProgressBar extends ImageView {
private final ColorDrawable mForegroundDrawable; private final ColorDrawable mForegroundDrawable;
private int mBackgroundColor = Color.TRANSPARENT; private int mBackgroundColor = Color.TRANSPARENT;
private float mProgress; private float mProgress;
private int mProgressUpdateCount;
private int mDesiredVisibility; private int mDesiredVisibility;
/** /**
...@@ -84,7 +83,6 @@ public class ClipDrawableProgressBar extends ImageView { ...@@ -84,7 +83,6 @@ public class ClipDrawableProgressBar extends ImageView {
if (mProgress == progress) return; if (mProgress == progress) return;
mProgress = progress; mProgress = progress;
mProgressUpdateCount += 1;
getDrawable().setLevel(Math.round(progress * CLIP_DRAWABLE_MAX)); getDrawable().setLevel(Math.round(progress * CLIP_DRAWABLE_MAX));
} }
...@@ -130,20 +128,6 @@ public class ClipDrawableProgressBar extends ImageView { ...@@ -130,20 +128,6 @@ public class ClipDrawableProgressBar extends ImageView {
} }
} }
/**
* Resets progress update count to 0.
*/
public void resetProgressUpdateCount() {
mProgressUpdateCount = 0;
}
/**
* @return Progress update count since reset.
*/
public int getProgressUpdateCount() {
return mProgressUpdateCount;
}
private void updateInternalVisibility() { private void updateInternalVisibility() {
int oldVisibility = getVisibility(); int oldVisibility = getVisibility();
int newVisibility = mDesiredVisibility; int newVisibility = mDesiredVisibility;
......
...@@ -19,7 +19,6 @@ import android.widget.ProgressBar; ...@@ -19,7 +19,6 @@ import android.widget.ProgressBar;
import org.chromium.base.ApiCompatibilityUtils; import org.chromium.base.ApiCompatibilityUtils;
import org.chromium.base.CommandLine; import org.chromium.base.CommandLine;
import org.chromium.base.VisibleForTesting; import org.chromium.base.VisibleForTesting;
import org.chromium.base.metrics.RecordHistogram;
import org.chromium.chrome.R; import org.chromium.chrome.R;
import org.chromium.chrome.browser.ChromeSwitches; import org.chromium.chrome.browser.ChromeSwitches;
import org.chromium.chrome.browser.util.ColorUtils; import org.chromium.chrome.browser.util.ColorUtils;
...@@ -33,10 +32,6 @@ import org.chromium.ui.interpolators.BakedBezierInterpolator; ...@@ -33,10 +32,6 @@ import org.chromium.ui.interpolators.BakedBezierInterpolator;
public class ToolbarProgressBar extends ClipDrawableProgressBar { public class ToolbarProgressBar extends ClipDrawableProgressBar {
private static final String ANIMATION_FIELD_TRIAL_NAME = "ProgressBarAnimationAndroid"; private static final String ANIMATION_FIELD_TRIAL_NAME = "ProgressBarAnimationAndroid";
private static final String PROGRESS_BAR_UPDATE_COUNT_HISTOGRAM =
"Omnibox.ProgressBarUpdateCount";
private static final String PROGRESS_BAR_BREAK_POINT_UPDATE_COUNT_HISTOGRAM =
"Omnibox.ProgressBarBreakPointUpdateCount";
/** /**
* Interface for progress bar animation interpolation logics. * Interface for progress bar animation interpolation logics.
...@@ -72,7 +67,6 @@ public class ToolbarProgressBar extends ClipDrawableProgressBar { ...@@ -72,7 +67,6 @@ public class ToolbarProgressBar extends ClipDrawableProgressBar {
private boolean mIsStarted; private boolean mIsStarted;
private float mTargetProgress; private float mTargetProgress;
private int mTargetProgressUpdateCount;
private AnimationLogic mAnimationLogic; private AnimationLogic mAnimationLogic;
private boolean mAnimationInitialized; private boolean mAnimationInitialized;
private int mMarginTop; private int mMarginTop;
...@@ -262,8 +256,6 @@ public class ToolbarProgressBar extends ClipDrawableProgressBar { ...@@ -262,8 +256,6 @@ public class ToolbarProgressBar extends ClipDrawableProgressBar {
} }
mIsRunningSmoothIndeterminate = false; mIsRunningSmoothIndeterminate = false;
mTargetProgressUpdateCount = 0;
resetProgressUpdateCount();
super.setProgress(0.0f); super.setProgress(0.0f);
if (mAnimationLogic != null) mAnimationLogic.reset(0.0f); if (mAnimationLogic != null) mAnimationLogic.reset(0.0f);
removeCallbacks(mHideRunnable); removeCallbacks(mHideRunnable);
...@@ -286,11 +278,6 @@ public class ToolbarProgressBar extends ClipDrawableProgressBar { ...@@ -286,11 +278,6 @@ public class ToolbarProgressBar extends ClipDrawableProgressBar {
if (delayed) { if (delayed) {
updateVisibleProgress(); updateVisibleProgress();
RecordHistogram.recordCount1000Histogram(PROGRESS_BAR_UPDATE_COUNT_HISTOGRAM,
getProgressUpdateCount());
RecordHistogram.recordCount100Histogram(
PROGRESS_BAR_BREAK_POINT_UPDATE_COUNT_HISTOGRAM,
mTargetProgressUpdateCount);
} else { } else {
removeCallbacks(mHideRunnable); removeCallbacks(mHideRunnable);
animate().cancel(); animate().cancel();
...@@ -386,7 +373,6 @@ public class ToolbarProgressBar extends ClipDrawableProgressBar { ...@@ -386,7 +373,6 @@ public class ToolbarProgressBar extends ClipDrawableProgressBar {
} }
} }
mTargetProgressUpdateCount += 1;
mTargetProgress = progress; mTargetProgress = progress;
updateVisibleProgress(); updateVisibleProgress();
} }
......
...@@ -46385,6 +46385,9 @@ http://cs/file:chrome/histograms.xml - but prefer this file for new entries. ...@@ -46385,6 +46385,9 @@ http://cs/file:chrome/histograms.xml - but prefer this file for new entries.
<histogram name="Omnibox.ProgressBarBreakPointUpdateCount" <histogram name="Omnibox.ProgressBarBreakPointUpdateCount"
units="break point updates"> units="break point updates">
<obselete>
Obselete 05/16/2017. Data is unused (crbug.com/719801).
</obselete>
<owner>kkimlabs@chromium.org</owner> <owner>kkimlabs@chromium.org</owner>
<summary> <summary>
The number of progress bar break point updates from page load started to The number of progress bar break point updates from page load started to
...@@ -46393,6 +46396,9 @@ http://cs/file:chrome/histograms.xml - but prefer this file for new entries. ...@@ -46393,6 +46396,9 @@ http://cs/file:chrome/histograms.xml - but prefer this file for new entries.
</histogram> </histogram>
<histogram name="Omnibox.ProgressBarUpdateCount" units="frame updates"> <histogram name="Omnibox.ProgressBarUpdateCount" units="frame updates">
<obselete>
Obselete 05/16/2017. Data is unused (crbug.com/719801).
</obselete>
<owner>kkimlabs@chromium.org</owner> <owner>kkimlabs@chromium.org</owner>
<summary> <summary>
The number of progress bar frame updates from page load started to page load The number of progress bar frame updates from page load started to page load
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment