summaryrefslogtreecommitdiffstats
path: root/content/renderer/render_widget.h
diff options
context:
space:
mode:
authorapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-06-27 19:21:55 +0000
committerapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2011-06-27 19:21:55 +0000
commit2d7c85529b0210e148d70eb3d0edf485d6521708 (patch)
tree59152cec5d13a4f91b88ffa8610ca9a82f4fdcce /content/renderer/render_widget.h
parentbe16cf2bcf61a6ac255c347a6ba8c65d213a5a11 (diff)
downloadchromium_src-2d7c85529b0210e148d70eb3d0edf485d6521708.zip
chromium_src-2d7c85529b0210e148d70eb3d0edf485d6521708.tar.gz
chromium_src-2d7c85529b0210e148d70eb3d0edf485d6521708.tar.bz2
GPU compositing surface handle is no longer sent to renderer process.
Instead it is stored in a map in RenderWidgetHelper indexed by RenderWidgetHost route ID. This allows the UI thread to maintain the mapping as windows are created and destroyed and the IO thread to lookup the mapping in order to create GL contexts that render to the windows. This avoids a race where JavaScript would open a popup window and immediately try to use an accelerated canvas to render to it (2D canvas or WebGL canvas). <-- This is no longer true of this patch. There was a potential deadlock. WebGL canvas used to work in this case only because it would fall back to using ReadPixels. This goes some way to fixing the bug referenced below but does not fix it completely.BUG=80703 Review URL: http://codereview.chromium.org/7136001 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@90617 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'content/renderer/render_widget.h')
-rw-r--r--content/renderer/render_widget.h14
1 files changed, 2 insertions, 12 deletions
diff --git a/content/renderer/render_widget.h b/content/renderer/render_widget.h
index fde8220..e6c896f8 100644
--- a/content/renderer/render_widget.h
+++ b/content/renderer/render_widget.h
@@ -77,10 +77,6 @@ class RenderWidget : public IPC::Channel::Listener,
// The compositing surface assigned by the RenderWidgetHost
// (or RenderViewHost). Will be gfx::kNullPluginWindow if not assigned yet,
// in which case we should not create any GPU command buffers with it.
- gfx::PluginWindowHandle compositing_surface() const {
- return compositing_surface_;
- }
-
// The routing ID assigned by the RenderProcess. Will be MSG_ROUTING_NONE if
// not yet assigned a view ID, in which case, the process MUST NOT send
// messages with this ID to the parent.
@@ -153,8 +149,7 @@ class RenderWidget : public IPC::Channel::Listener,
IPC::SyncMessage* create_widget_message);
// Finishes creation of a pending view started with Init.
- void CompleteInit(gfx::NativeViewId parent,
- gfx::PluginWindowHandle compositing_surface);
+ void CompleteInit(gfx::NativeViewId parent);
// Sets whether this RenderWidget has been swapped out to be displayed by
// a RenderWidget in a different process. If so, no new IPC messages will be
@@ -187,8 +182,7 @@ class RenderWidget : public IPC::Channel::Listener,
// RenderWidget IPC message handlers
void OnClose();
- void OnCreatingNewAck(gfx::NativeViewId parent,
- gfx::PluginWindowHandle compositing_surface);
+ void OnCreatingNewAck(gfx::NativeViewId parent);
virtual void OnResize(const gfx::Size& new_size,
const gfx::Rect& resizer_rect);
virtual void OnWasHidden();
@@ -433,10 +427,6 @@ class RenderWidget : public IPC::Channel::Listener,
// compositor.
bool is_accelerated_compositing_active_;
- // Handle to a surface that is drawn to when accelerated compositing is
- // active.
- gfx::PluginWindowHandle compositing_surface_;
-
base::Time animation_floor_time_;
bool animation_update_pending_;
bool animation_task_posted_;