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

Side by Side Diff: content/renderer/child_frame_compositing_helper.cc

Issue 857643002: Cleanup ChildFrameCompositingHelper on destruction. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 11 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/child_frame_compositing_helper.h" 5 #include "content/renderer/child_frame_compositing_helper.h"
6 6
7 #include "cc/blink/web_layer_impl.h" 7 #include "cc/blink/web_layer_impl.h"
8 #include "cc/layers/delegated_frame_provider.h" 8 #include "cc/layers/delegated_frame_provider.h"
9 #include "cc/layers/delegated_frame_resource_collection.h" 9 #include "cc/layers/delegated_frame_resource_collection.h"
10 #include "cc/layers/delegated_renderer_layer.h" 10 #include "cc/layers/delegated_renderer_layer.h"
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
54 : host_routing_id_(host_routing_id), 54 : host_routing_id_(host_routing_id),
55 last_route_id_(0), 55 last_route_id_(0),
56 last_output_surface_id_(0), 56 last_output_surface_id_(0),
57 last_host_id_(0), 57 last_host_id_(0),
58 ack_pending_(true), 58 ack_pending_(true),
59 opaque_(true), 59 opaque_(true),
60 browser_plugin_(browser_plugin), 60 browser_plugin_(browser_plugin),
61 render_frame_proxy_(render_frame_proxy), 61 render_frame_proxy_(render_frame_proxy),
62 frame_(frame) {} 62 frame_(frame) {}
63 63
64 ChildFrameCompositingHelper::~ChildFrameCompositingHelper() {} 64 ChildFrameCompositingHelper::~ChildFrameCompositingHelper() {
65 if (resource_collection_.get())
66 resource_collection_->SetClient(NULL);
danakj 2015/02/03 20:07:42 Destruction implies the child compositor is shutti
lfg 2015/02/03 20:26:22 The child compositor is shutting down. I'm not sur
danakj 2015/02/03 20:40:10 Right. But if you just drop the client, you'll lea
67 }
65 68
66 BrowserPluginManager* ChildFrameCompositingHelper::GetBrowserPluginManager() { 69 BrowserPluginManager* ChildFrameCompositingHelper::GetBrowserPluginManager() {
67 if (!browser_plugin_) 70 if (!browser_plugin_)
68 return NULL; 71 return NULL;
69 72
70 return BrowserPluginManager::Get(); 73 return BrowserPluginManager::Get();
71 } 74 }
72 75
73 blink::WebPluginContainer* ChildFrameCompositingHelper::GetContainer() { 76 blink::WebPluginContainer* ChildFrameCompositingHelper::GetContainer() {
74 if (!browser_plugin_) 77 if (!browser_plugin_)
(...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after
280 SendReclaimCompositorResourcesToBrowser(params); 283 SendReclaimCompositorResourcesToBrowser(params);
281 } 284 }
282 285
283 void ChildFrameCompositingHelper::SetContentsOpaque(bool opaque) { 286 void ChildFrameCompositingHelper::SetContentsOpaque(bool opaque) {
284 opaque_ = opaque; 287 opaque_ = opaque;
285 if (delegated_layer_.get()) 288 if (delegated_layer_.get())
286 delegated_layer_->SetContentsOpaque(opaque_); 289 delegated_layer_->SetContentsOpaque(opaque_);
287 } 290 }
288 291
289 } // namespace content 292 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698