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

Unified Diff: Source/web/WebPagePopupImpl.cpp

Issue 530653002: Use page popup pixel readback for calendar-picker-appearance.html (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 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: Source/web/WebPagePopupImpl.cpp
diff --git a/Source/web/WebPagePopupImpl.cpp b/Source/web/WebPagePopupImpl.cpp
index bf001cf9b4cb0cb2ae4dfe88493d227d9ddef551..6905076cb476439fec70e086dc33cccbc9969cae 100644
--- a/Source/web/WebPagePopupImpl.cpp
+++ b/Source/web/WebPagePopupImpl.cpp
@@ -43,6 +43,7 @@
#include "core/page/FocusController.h"
#include "core/page/Page.h"
#include "core/page/PagePopupClient.h"
+#include "platform/LayoutTestSupport.h"
#include "platform/TraceEvent.h"
#include "platform/heap/Handle.h"
#include "public/platform/WebCompositeAndReadbackAsyncCallback.h"
@@ -114,12 +115,16 @@ private:
virtual void scheduleAnimation() OVERRIDE
{
+ // Calling scheduleAnimation on m_webView so WebTestProxy will call beginFrame.
+ if (LayoutTestSupport::isRunningLayoutTest())
+ m_popup->m_webView->scheduleAnimation();
+
if (m_popup->isAcceleratedCompositingActive()) {
ASSERT(m_popup->m_layerTreeView);
m_popup->m_layerTreeView->setNeedsAnimate();
return;
}
- m_popup->widgetClient()->scheduleAnimation();
+ m_popup->m_widgetClient->scheduleAnimation();
}
virtual WebScreenInfo screenInfo() const OVERRIDE
@@ -426,6 +431,11 @@ void WebPagePopupImpl::closePopup()
m_popupClient->didClosePopup();
}
+LocalDOMWindow* WebPagePopupImpl::window()
+{
+ return m_page->mainFrame()->domWindow();
+}
+
void WebPagePopupImpl::compositeAndReadbackAsync(WebCompositeAndReadbackAsyncCallback* callback)
{
ASSERT(isAcceleratedCompositingActive());

Powered by Google App Engine
This is Rietveld 408576698