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

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

Issue 2568353003: Scale scrollbar width in popup properly (Closed)
Patch Set: rebase mac Created 4 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/WebPagePopupImpl.cpp
diff --git a/third_party/WebKit/Source/web/WebPagePopupImpl.cpp b/third_party/WebKit/Source/web/WebPagePopupImpl.cpp
index f75540807ab011d538b0ffb69988dac7f5bdf0c1..d4eacc7f32b983831c1c58e44fc32441ff6ca661 100644
--- a/third_party/WebKit/Source/web/WebPagePopupImpl.cpp
+++ b/third_party/WebKit/Source/web/WebPagePopupImpl.cpp
@@ -55,6 +55,7 @@
#include "platform/tracing/TraceEvent.h"
#include "public/platform/WebCompositeAndReadbackAsyncCallback.h"
#include "public/platform/WebCursorInfo.h"
+#include "public/platform/WebFloatRect.h"
#include "public/web/WebAXObject.h"
#include "public/web/WebFrameClient.h"
#include "public/web/WebViewClient.h"
@@ -96,6 +97,12 @@ class PagePopupChromeClient final : public EmptyChromeClient {
return rectInScreen;
}
+ float windowToViewportScalar(const float scalarValue) const override {
+ WebFloatRect viewportRect(0, 0, scalarValue, 0);
+ m_popup->widgetClient()->convertWindowToViewport(&viewportRect);
+ return viewportRect.width;
+ }
+
void addMessageToConsole(LocalFrame*,
MessageSource,
MessageLevel,

Powered by Google App Engine
This is Rietveld 408576698