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

Unified Diff: cc/trees/thread_proxy.cc

Issue 609663003: cc: Remove use of PassAs() and constructor-casting with scoped_ptr. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: cc-passas: PassAs-presubmit-warning Created 6 years, 3 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/single_thread_proxy.cc ('k') | cc/trees/tree_synchronizer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/thread_proxy.cc
diff --git a/cc/trees/thread_proxy.cc b/cc/trees/thread_proxy.cc
index dddf112194a9960339bed5fe32f59b0eab9553e8..151cb3c5fe4ec2f49aff3a16c7c5c27ab9b079f5 100644
--- a/cc/trees/thread_proxy.cc
+++ b/cc/trees/thread_proxy.cc
@@ -49,9 +49,8 @@ scoped_ptr<Proxy> ThreadProxy::Create(
LayerTreeHost* layer_tree_host,
scoped_refptr<base::SingleThreadTaskRunner> main_task_runner,
scoped_refptr<base::SingleThreadTaskRunner> impl_task_runner) {
- return make_scoped_ptr(new ThreadProxy(layer_tree_host,
- main_task_runner,
- impl_task_runner)).PassAs<Proxy>();
+ return make_scoped_ptr(
+ new ThreadProxy(layer_tree_host, main_task_runner, impl_task_runner));
}
ThreadProxy::ThreadProxy(
@@ -963,7 +962,7 @@ void ThreadProxy::ScheduledActionCommit() {
// Complete all remaining texture updates.
impl().current_resource_update_controller->Finalize();
- impl().current_resource_update_controller.reset();
+ impl().current_resource_update_controller = nullptr;
if (impl().animations_frozen_until_next_draw) {
impl().animation_time = std::max(
@@ -1249,10 +1248,10 @@ void ThreadProxy::LayerTreeHostClosedOnImplThread(CompletionEvent* completion) {
DCHECK(IsMainThreadBlocked());
layer_tree_host()->DeleteContentsTexturesOnImplThread(
impl().layer_tree_host_impl->resource_provider());
- impl().current_resource_update_controller.reset();
+ impl().current_resource_update_controller = nullptr;
impl().layer_tree_host_impl->SetNeedsBeginFrame(false);
- impl().scheduler.reset();
- impl().layer_tree_host_impl.reset();
+ impl().scheduler = nullptr;
+ impl().layer_tree_host_impl = nullptr;
impl().weak_factory.InvalidateWeakPtrs();
// We need to explicitly cancel the notifier, since it isn't using weak ptrs.
// TODO(vmpstr): We should see if we can make it use weak ptrs and still keep
« no previous file with comments | « cc/trees/single_thread_proxy.cc ('k') | cc/trees/tree_synchronizer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698