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

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

Issue 258373002: Towards moving guest management to chrome: Introduce GuestViewManager (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix Android build Created 6 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/browser_plugin/browser_plugin_guest.h
diff --git a/content/browser/browser_plugin/browser_plugin_guest.h b/content/browser/browser_plugin/browser_plugin_guest.h
index 61d2d8edc8ce19d9d1d0b5054d8234780fdeb17c..835acb01dfb4fe6f69e0fed62e845a71042feac1 100644
--- a/content/browser/browser_plugin/browser_plugin_guest.h
+++ b/content/browser/browser_plugin/browser_plugin_guest.h
@@ -59,6 +59,7 @@ class Range;
namespace content {
+class BrowserPluginGuestManager;
class BrowserPluginHostFactory;
class RenderWidgetHostView;
class SiteInstance;
@@ -136,7 +137,8 @@ class CONTENT_EXPORT BrowserPluginGuest
bool visible() const { return guest_visible_; }
bool is_in_destruction() { return is_in_destruction_; }
- BrowserPluginGuest* opener() const { return opener_.get(); }
+ // Returns the BrowserPluginGuest that created this guest, if any.
+ BrowserPluginGuest* GetOpener() const;
// Returns whether the mouse pointer was unlocked.
bool UnlockMouseIfNecessary(const NativeWebKeyboardEvent& event);
@@ -148,6 +150,8 @@ class CONTENT_EXPORT BrowserPluginGuest
gfx::Size dst_size,
const base::Callback<void(bool, const SkBitmap&)>& callback);
+ BrowserPluginGuestManager* GetBrowserPluginGuestManager() const;
+
// WebContentsObserver implementation.
virtual void DidCommitProvisionalLoadForFrame(
int64 frame_id,
@@ -220,7 +224,7 @@ class CONTENT_EXPORT BrowserPluginGuest
const blink::WebGestureEvent& event) OVERRIDE;
// Exposes the protected web_contents() from WebContentsObserver.
- WebContentsImpl* GetWebContents();
+ WebContentsImpl* GetWebContents() const;
gfx::Point GetScreenCoordinates(const gfx::Point& relative_position) const;
@@ -297,8 +301,7 @@ class CONTENT_EXPORT BrowserPluginGuest
// |web_contents| has to stay valid for the lifetime of BrowserPluginGuest.
BrowserPluginGuest(int instance_id,
bool has_render_view,
- WebContentsImpl* web_contents,
- BrowserPluginGuest* opener);
+ WebContentsImpl* web_contents);
// Destroy unattached new windows that have been opened by this
// BrowserPluginGuest.
@@ -488,7 +491,6 @@ class CONTENT_EXPORT BrowserPluginGuest
typedef std::map<BrowserPluginGuest*, NewWindowInfo> PendingWindowMap;
PendingWindowMap pending_new_windows_;
- base::WeakPtr<BrowserPluginGuest> opener_;
// A counter to generate a unique request id for a permission request.
// We only need the ids to be unique for a given BrowserPluginGuest.
int next_permission_request_id_;
« no previous file with comments | « content/browser/browser_plugin/browser_plugin_embedder.cc ('k') | content/browser/browser_plugin/browser_plugin_guest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698