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

Unified Diff: Source/web/ContextMenuClientImpl.cpp

Issue 967213004: Removed FrameView's windowToContents and contentsToWindow methods. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 5 years, 9 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
« no previous file with comments | « Source/web/ChromeClientImpl.cpp ('k') | Source/web/ExternalPopupMenu.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/web/ContextMenuClientImpl.cpp
diff --git a/Source/web/ContextMenuClientImpl.cpp b/Source/web/ContextMenuClientImpl.cpp
index 73bd4e0a89a358846b3be112573a3a2286abbaee..f0425637956b0f959e71fd524f33abe1e41764cb 100644
--- a/Source/web/ContextMenuClientImpl.cpp
+++ b/Source/web/ContextMenuClientImpl.cpp
@@ -195,14 +195,7 @@ void ContextMenuClientImpl::showContextMenu(const ContextMenu* defaultMenu)
LocalFrame* selectedFrame = r.innerNodeFrame();
WebContextMenuData data;
- IntPoint mousePoint = selectedFrame->view()->contentsToWindow(r.roundedPointInInnerNodeFrame());
-
- // FIXME(bokan): crbug.com/371902 - We shouldn't be making these scale
- // related coordinate transformatios in an ad hoc way.
- PinchViewport& pinchViewport = selectedFrame->host()->pinchViewport();
- mousePoint -= flooredIntSize(pinchViewport.visibleRect().location());
- mousePoint.scale(m_webView->pageScaleFactor(), m_webView->pageScaleFactor());
- data.mousePosition = mousePoint;
+ data.mousePosition = selectedFrame->view()->contentsToViewport(r.roundedPointInInnerNodeFrame());
// Compute edit flags.
data.editFlags = WebContextMenuData::CanDoNone;
« no previous file with comments | « Source/web/ChromeClientImpl.cpp ('k') | Source/web/ExternalPopupMenu.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698