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

Unified Diff: content/browser/browser_plugin/browser_plugin_embedder.h

Issue 10965009: BrowserPluginGuest/Embedder: Remove friend helper classes, made necessary calls public (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/browser_plugin/browser_plugin_embedder.h
diff --git a/content/browser/browser_plugin/browser_plugin_embedder.h b/content/browser/browser_plugin/browser_plugin_embedder.h
index 2a92f946c8b885ff3102bc8c9c97f422f31d5976..db1f737e4bb6c5b1bb332d8f100536c0348e66b3 100644
--- a/content/browser/browser_plugin/browser_plugin_embedder.h
+++ b/content/browser/browser_plugin/browser_plugin_embedder.h
@@ -77,29 +77,6 @@ class CONTENT_EXPORT BrowserPluginEmbedder : public WebContentsObserver,
const NotificationSource& source,
const NotificationDetails& details) OVERRIDE;
- // Overrides factory for testing. Default (NULL) value indicates regular
- // (non-test) environment.
- static void set_factory_for_testing(BrowserPluginHostFactory* factory) {
- factory_ = factory;
- }
-
- private:
- friend class BrowserPluginEmbedderHelper;
- friend class TestBrowserPluginEmbedder;
-
- BrowserPluginEmbedder(WebContentsImpl* web_contents,
- RenderViewHost* render_view_host);
-
- // Returns a guest browser plugin delegate by its container ID specified
- // in BrowserPlugin.
- BrowserPluginGuest* GetGuestByInstanceID(int instance_id) const;
- // Adds a new guest web_contents to the embedder (overridable in test).
- virtual void AddGuest(int instance_id,
- WebContents* guest_web_contents,
- int64 frame_id);
- void DestroyGuestByInstanceID(int instance_id);
- void DestroyGuests();
-
// Message handlers (direct/indirect via BrowserPluginEmbedderHelper).
// Routes update rect ack message to the appropriate guest.
void UpdateRectACK(int instance_id, int message_id, const gfx::Size& size);
@@ -122,6 +99,28 @@ class CONTENT_EXPORT BrowserPluginEmbedder : public WebContentsObserver,
IPC::Message* reply_message);
void PluginDestroyed(int instance_id);
+ // Overrides factory for testing. Default (NULL) value indicates regular
+ // (non-test) environment.
+ static void set_factory_for_testing(BrowserPluginHostFactory* factory) {
+ factory_ = factory;
+ }
+
+ private:
+ friend class TestBrowserPluginEmbedder;
+
+ BrowserPluginEmbedder(WebContentsImpl* web_contents,
+ RenderViewHost* render_view_host);
+
+ // Returns a guest browser plugin delegate by its container ID specified
+ // in BrowserPlugin.
+ BrowserPluginGuest* GetGuestByInstanceID(int instance_id) const;
+ // Adds a new guest web_contents to the embedder (overridable in test).
+ virtual void AddGuest(int instance_id,
+ WebContents* guest_web_contents,
+ int64 frame_id);
+ void DestroyGuestByInstanceID(int instance_id);
+ void DestroyGuests();
+
// Called when visiblity of web_contents changes, so the embedder will
// show/hide its guest.
void WebContentsVisibilityChanged(bool visible);

Powered by Google App Engine
This is Rietveld 408576698