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

Unified Diff: chrome/browser/renderer_host/render_widget_host_view_win.cc

Issue 5528007: If compositor window already exists, then simply return it rather than compla... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years 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
Index: chrome/browser/renderer_host/render_widget_host_view_win.cc
===================================================================
--- chrome/browser/renderer_host/render_widget_host_view_win.cc (revision 68022)
+++ chrome/browser/renderer_host/render_widget_host_view_win.cc (working copy)
@@ -1542,8 +1542,11 @@
// Creates a HWND within the RenderWidgetHostView that will serve as a host
// for a HWND that the GPU process will create. The host window is used
// to Z-position the GPU's window relative to other plugin windows.
-gfx::PluginWindowHandle RenderWidgetHostViewWin::CreateCompositorHostWindow() {
- DCHECK(!compositor_host_window_);
+gfx::PluginWindowHandle RenderWidgetHostViewWin::GetCompositorHostWindow() {
+ // If the window has been created, don't recreate it a second time
+ if (compositor_host_window_)
+ return compositor_host_window_;
+
static ATOM window_class = 0;
if (!window_class) {
WNDCLASSEX wcex;
« no previous file with comments | « chrome/browser/renderer_host/render_widget_host_view_win.h ('k') | chrome/browser/renderer_host/test/test_render_view_host.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698