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

Side by Side Diff: android_webview/browser/browser_view_renderer.cc

Issue 1946583002: Avoid recreating hardware_renderer_ if a draw occurs during cleanup. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: return uncomitted frame to BVR when RTM dies Created 4 years, 7 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 | android_webview/browser/render_thread_manager.cc » ('j') | 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 "android_webview/browser/browser_view_renderer.h" 5 #include "android_webview/browser/browser_view_renderer.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "android_webview/browser/browser_view_renderer_client.h" 9 #include "android_webview/browser/browser_view_renderer_client.h"
10 #include "android_webview/browser/child_frame.h" 10 #include "android_webview/browser/child_frame.h"
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 SetCompositorFrameConsumer(nullptr); 113 SetCompositorFrameConsumer(nullptr);
114 } 114 }
115 115
116 void BrowserViewRenderer::SetCompositorFrameConsumer( 116 void BrowserViewRenderer::SetCompositorFrameConsumer(
117 CompositorFrameConsumer* compositor_frame_consumer) { 117 CompositorFrameConsumer* compositor_frame_consumer) {
118 if (compositor_frame_consumer == compositor_frame_consumer_) { 118 if (compositor_frame_consumer == compositor_frame_consumer_) {
119 return; 119 return;
120 } 120 }
121 if (compositor_frame_consumer_) { 121 if (compositor_frame_consumer_) {
122 compositor_frame_consumer_->DeleteHardwareRendererOnUI(); 122 compositor_frame_consumer_->DeleteHardwareRendererOnUI();
123 ReturnUnusedResource(
124 compositor_frame_consumer_->PassUncommittedFrameOnUI());
123 ReturnResourceFromParent(compositor_frame_consumer_); 125 ReturnResourceFromParent(compositor_frame_consumer_);
124 compositor_frame_consumer_->SetCompositorFrameProducer(nullptr); 126 compositor_frame_consumer_->SetCompositorFrameProducer(nullptr);
125 } 127 }
126 compositor_frame_consumer_ = compositor_frame_consumer; 128 compositor_frame_consumer_ = compositor_frame_consumer;
127 if (compositor_frame_consumer_) { 129 if (compositor_frame_consumer_) {
128 compositor_frame_consumer_->SetCompositorFrameProducer(this); 130 compositor_frame_consumer_->SetCompositorFrameProducer(this);
129 } 131 }
130 } 132 }
131 133
132 void BrowserViewRenderer::RegisterWithWebContents( 134 void BrowserViewRenderer::RegisterWithWebContents(
(...skipping 585 matching lines...) Expand 10 before | Expand all | Expand 10 after
718 base::StringAppendF(&str, 720 base::StringAppendF(&str,
719 "overscroll_rounding_error_: %s ", 721 "overscroll_rounding_error_: %s ",
720 overscroll_rounding_error_.ToString().c_str()); 722 overscroll_rounding_error_.ToString().c_str());
721 base::StringAppendF( 723 base::StringAppendF(
722 &str, "on_new_picture_enable: %d ", on_new_picture_enable_); 724 &str, "on_new_picture_enable: %d ", on_new_picture_enable_);
723 base::StringAppendF(&str, "clear_view: %d ", clear_view_); 725 base::StringAppendF(&str, "clear_view: %d ", clear_view_);
724 return str; 726 return str;
725 } 727 }
726 728
727 } // namespace android_webview 729 } // namespace android_webview
OLDNEW
« no previous file with comments | « no previous file | android_webview/browser/render_thread_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698