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

Unified Diff: third_party/WebKit/Source/web/ChromeClientImpl.cpp

Issue 1456753002: Compute the popup location/size correctly when use-zoom-for-dsf is enabled. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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: third_party/WebKit/Source/web/ChromeClientImpl.cpp
diff --git a/third_party/WebKit/Source/web/ChromeClientImpl.cpp b/third_party/WebKit/Source/web/ChromeClientImpl.cpp
index 5488a951af657152cd3f6241aaf0d61bd38b3f31..c0198e443398bfaeb4aef155df05565eca427916 100644
--- a/third_party/WebKit/Source/web/ChromeClientImpl.cpp
+++ b/third_party/WebKit/Source/web/ChromeClientImpl.cpp
@@ -512,13 +512,14 @@ void ChromeClientImpl::scheduleAnimationForFrame(LocalFrame* localRoot)
IntRect ChromeClientImpl::viewportToScreen(const IntRect& rectInViewport) const
{
- IntRect screenRect(rectInViewport);
+ WebRect screenRect(rectInViewport);
if (m_webView->client()) {
+ m_webView->client()->convertViewportToWindow(&screenRect);
WebRect windowRect = m_webView->client()->windowRect();
- screenRect.move(windowRect.x, windowRect.y);
+ screenRect.x += windowRect.x;
+ screenRect.y += windowRect.y;
}
-
return screenRect;
}

Powered by Google App Engine
This is Rietveld 408576698