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

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

Issue 1293963002: Fixing the Position of Context Menu for BrowserPlugin (<webview>) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed a Build Error in MAC Created 5 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_guest.h
diff --git a/content/browser/browser_plugin/browser_plugin_guest.h b/content/browser/browser_plugin/browser_plugin_guest.h
index 1d975f406a20fe3797bc3f7aa42e0e5cff1f2ffd..bb4879902a65715ad08f32e255f60c46791e5704 100644
--- a/content/browser/browser_plugin/browser_plugin_guest.h
+++ b/content/browser/browser_plugin/browser_plugin_guest.h
@@ -187,6 +187,17 @@ class CONTENT_EXPORT BrowserPluginGuest : public GuestHost,
gfx::Point GetScreenCoordinates(const gfx::Point& relative_position) const;
+ // This method is called by the RenderWidgetHostViewGuest to inform the
+ // BrowserPlugin of the potential location of the context menu event (to
+ // come). The need for this (hack) is that the input events when passed on to
+ // the BrowserPlugin are modified by any CSS transforms applied on the plugin.
+ // Therefore, the coordinates of the context menu event with respect to the
+ // container window are modifed with the guest renderer process beiung unaware
+ // of the change. Then eventually, when the context menu event arrives at the
+ // browser, it contains the wrong coordinates (BUG=470087).
+ // TODO(ekaramad): Find a more fundamental solution and remove this later.
+ void SetContextMenuPosition(const gfx::Point& position);
+
// Helper to send messages to embedder. If this guest is not yet attached,
// then IPCs will be queued until attachment.
void SendMessageToEmbedder(IPC::Message* msg);
« no previous file with comments | « components/guest_view/browser/guest_view_base.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