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

Unified Diff: content/shell/renderer/layout_test/blink_test_runner.cc

Issue 1842353002: Revert of Moving pixel-capturing code from web_test_proxy_base.* into pixel_dump.* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@replicating-accept-languages
Patch Set: Created 4 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 | « content/shell/renderer/layout_test/blink_test_runner.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/shell/renderer/layout_test/blink_test_runner.cc
diff --git a/content/shell/renderer/layout_test/blink_test_runner.cc b/content/shell/renderer/layout_test/blink_test_runner.cc
index 8e7610005fe87b6238660d4c473510a7f9a2849e..67cb1028323b679493d08287bd6b4c67bbbaf925 100644
--- a/content/shell/renderer/layout_test/blink_test_runner.cc
+++ b/content/shell/renderer/layout_test/blink_test_runner.cc
@@ -30,7 +30,6 @@
#include "build/build_config.h"
#include "components/plugins/renderer/plugin_placeholder.h"
#include "components/test_runner/gamepad_controller.h"
-#include "components/test_runner/pixel_dump.h"
#include "components/test_runner/web_test_interfaces.h"
#include "components/test_runner/web_test_proxy.h"
#include "components/test_runner/web_test_runner.h"
@@ -730,8 +729,11 @@
return placeholder->plugin();
}
-float BlinkTestRunner::GetDeviceScaleFactorForTest() const {
- return render_view()->GetDeviceScaleFactorForTest();
+blink::WebPoint BlinkTestRunner::ConvertDIPToNative(
+ const blink::WebPoint& point_in_dip) const {
+ float scale = render_view()->GetDeviceScaleFactorForTest();
+ return blink::WebPoint(point_in_dip.x * scale,
+ point_in_dip.y * scale);
}
bool BlinkTestRunner::AddMediaStreamVideoSourceAndTrack(
@@ -894,10 +896,8 @@
interfaces->TestRunner()->ShouldGeneratePixelResults() &&
!interfaces->TestRunner()->ShouldDumpAsAudio()) {
CHECK(render_view()->GetWebView()->isAcceleratedCompositingActive());
- interfaces->TestRunner()->DumpPixelsAsync(
- render_view()->GetWebView(),
- base::Bind(&BlinkTestRunner::OnPixelsDumpCompleted,
- base::Unretained(this)));
+ proxy()->CapturePixelsAsync(base::Bind(
+ &BlinkTestRunner::OnPixelsDumpCompleted, base::Unretained(this)));
return;
}
« no previous file with comments | « content/shell/renderer/layout_test/blink_test_runner.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698