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

Side by Side Diff: content/browser/browser_plugin/browser_plugin_embedder.h

Issue 10917225: Browser Plugin: Reload and Stop operations (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Updated Created 8 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // A BrowserPluginEmbedder has a list of guest it manages. 5 // A BrowserPluginEmbedder has a list of guest it manages.
6 // In the beginning when a renderer sees one or more guests (BrowserPlugin 6 // In the beginning when a renderer sees one or more guests (BrowserPlugin
7 // instance(s)) and there is a request to navigate to them, the WebContents for 7 // instance(s)) and there is a request to navigate to them, the WebContents for
8 // that renderer creates a BrowserPluginEmbedder for itself. The 8 // that renderer creates a BrowserPluginEmbedder for itself. The
9 // BrowserPluginEmbedder, in turn, manages a set of BrowserPluginGuests -- one 9 // BrowserPluginEmbedder, in turn, manages a set of BrowserPluginGuests -- one
10 // BrowserPluginGuest for each guest in the embedding WebContents. 10 // BrowserPluginGuest for each guest in the embedding WebContents.
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 bool resize_pending, 128 bool resize_pending,
129 float scale_factor); 129 float scale_factor);
130 // Handles input events sent from the BrowserPlugin (embedder's renderer 130 // Handles input events sent from the BrowserPlugin (embedder's renderer
131 // process) by passing them to appropriate guest's input handler. 131 // process) by passing them to appropriate guest's input handler.
132 void HandleInputEvent(int instance_id, 132 void HandleInputEvent(int instance_id,
133 RenderViewHost* render_view_host, 133 RenderViewHost* render_view_host,
134 const gfx::Rect& guest_rect, 134 const gfx::Rect& guest_rect,
135 const WebKit::WebInputEvent& event, 135 const WebKit::WebInputEvent& event,
136 IPC::Message* reply_message); 136 IPC::Message* reply_message);
137 void PluginDestroyed(int instance_id); 137 void PluginDestroyed(int instance_id);
138 void Stop(int instance_id);
139 void Reload(int instance_id);
138 140
139 // Called when visiblity of web_contents changes, so the embedder will 141 // Called when visiblity of web_contents changes, so the embedder will
140 // show/hide its guest. 142 // show/hide its guest.
141 void WebContentsVisibilityChanged(bool visible); 143 void WebContentsVisibilityChanged(bool visible);
142 144
143 // Static factory instance (always NULL for non-test). 145 // Static factory instance (always NULL for non-test).
144 static BrowserPluginHostFactory* factory_; 146 static BrowserPluginHostFactory* factory_;
145 147
146 // A scoped container for notification registries. 148 // A scoped container for notification registries.
147 NotificationRegistrar registrar_; 149 NotificationRegistrar registrar_;
148 150
149 // Contains guests' WebContents, mapping to their frame ids. 151 // Contains guests' WebContents, mapping to their frame ids.
150 GuestWebContentsMap guest_web_contents_container_; 152 GuestWebContentsMap guest_web_contents_container_;
151 // Contains guests' WebContents, mapping from their instance ids. 153 // Contains guests' WebContents, mapping from their instance ids.
152 ContainerInstanceMap guest_web_contents_by_instance_id_; 154 ContainerInstanceMap guest_web_contents_by_instance_id_;
153 RenderViewHost* render_view_host_; 155 RenderViewHost* render_view_host_;
154 156
155 DISALLOW_COPY_AND_ASSIGN(BrowserPluginEmbedder); 157 DISALLOW_COPY_AND_ASSIGN(BrowserPluginEmbedder);
156 }; 158 };
157 159
158 } // namespace content 160 } // namespace content
159 161
160 #endif // CONTENT_BROWSER_BROWSER_PLUGIN_BROWSER_PLUGIN_EMBEDDER_H_ 162 #endif // CONTENT_BROWSER_BROWSER_PLUGIN_BROWSER_PLUGIN_EMBEDDER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698