Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(307)

Unified Diff: cc/trees/latency_info_swap_promise_monitor.cc

Issue 1866203004: Convert //cc from scoped_ptr to std::unique_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: scopedptrcc: rebase Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « cc/trees/damage_tracker_unittest.cc ('k') | cc/trees/layer_tree_host.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/latency_info_swap_promise_monitor.cc
diff --git a/cc/trees/latency_info_swap_promise_monitor.cc b/cc/trees/latency_info_swap_promise_monitor.cc
index 23635cd856602edc16c79e355d03f350b9fd7136..96a6d7786e12ab86136221f1b0b19dabaed234e8 100644
--- a/cc/trees/latency_info_swap_promise_monitor.cc
+++ b/cc/trees/latency_info_swap_promise_monitor.cc
@@ -53,14 +53,16 @@ LatencyInfoSwapPromiseMonitor::~LatencyInfoSwapPromiseMonitor() {
void LatencyInfoSwapPromiseMonitor::OnSetNeedsCommitOnMain() {
if (AddRenderingScheduledComponent(latency_, true /* on_main */)) {
- scoped_ptr<SwapPromise> swap_promise(new LatencyInfoSwapPromise(*latency_));
+ std::unique_ptr<SwapPromise> swap_promise(
+ new LatencyInfoSwapPromise(*latency_));
layer_tree_host_->QueueSwapPromise(std::move(swap_promise));
}
}
void LatencyInfoSwapPromiseMonitor::OnSetNeedsRedrawOnImpl() {
if (AddRenderingScheduledComponent(latency_, false /* on_main */)) {
- scoped_ptr<SwapPromise> swap_promise(new LatencyInfoSwapPromise(*latency_));
+ std::unique_ptr<SwapPromise> swap_promise(
+ new LatencyInfoSwapPromise(*latency_));
// Queue a pinned swap promise on the active tree. This will allow
// measurement of the time to the next SwapBuffers(). The swap
// promise is pinned so that it is not interrupted by new incoming
@@ -95,7 +97,7 @@ void LatencyInfoSwapPromiseMonitor::OnForwardScrollUpdateToMainThreadOnImpl() {
new_latency.CopyLatencyFrom(
*latency_,
ui::INPUT_EVENT_LATENCY_FORWARD_SCROLL_UPDATE_TO_MAIN_COMPONENT);
- scoped_ptr<SwapPromise> swap_promise(
+ std::unique_ptr<SwapPromise> swap_promise(
new LatencyInfoSwapPromise(new_latency));
layer_tree_host_impl_->QueueSwapPromiseForMainThreadScrollUpdate(
std::move(swap_promise));
« no previous file with comments | « cc/trees/damage_tracker_unittest.cc ('k') | cc/trees/layer_tree_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698