Commit 88bfc849 authored by Matt Reynolds's avatar Matt Reynolds Committed by Commit Bot

Convert base::Bind in VideoFrameCompositor timer callbacks

media::VideoFrameCompositor uses two base::RetainingOneShotTimers to
handle Start/StopForceBeginFrames and background rendering.
base::RepeatingCallback is correct because the timer is meant to retain
and reuse the callback after a reset.

BUG=1102651

Change-Id: I7c028cc08ba0d07c1f7e85518f9346a279313469
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2284148
Auto-Submit: Matt Reynolds <mattreynolds@chromium.org>
Reviewed-by: default avatarChrome Cunningham <chcunningham@chromium.org>
Commit-Queue: Chrome Cunningham <chcunningham@chromium.org>
Cr-Commit-Position: refs/heads/master@{#789566}
parent bc5c2c8b
......@@ -33,13 +33,13 @@ VideoFrameCompositor::VideoFrameCompositor(
background_rendering_timer_(
FROM_HERE,
base::TimeDelta::FromMilliseconds(kBackgroundRenderingTimeoutMs),
base::Bind(&VideoFrameCompositor::BackgroundRender,
base::Unretained(this))),
base::BindRepeating(&VideoFrameCompositor::BackgroundRender,
base::Unretained(this))),
force_begin_frames_timer_(
FROM_HERE,
base::TimeDelta::FromMilliseconds(kForceBeginFramesTimeoutMs),
base::Bind(&VideoFrameCompositor::StopForceBeginFrames,
base::Unretained(this))),
base::BindRepeating(&VideoFrameCompositor::StopForceBeginFrames,
base::Unretained(this))),
submitter_(std::move(submitter)) {
if (submitter_) {
task_runner_->PostTask(
......
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