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

Unified Diff: content/browser/renderer_host/render_widget_host_view_aura_unittest.cc

Issue 686513004: Creating default implementation for aura::client::ScreenPositionClient (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 1 -> 1.0f Created 6 years, 1 month 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 | « athena/screen/screen_manager_impl.cc ('k') | ui/views/corewm/tooltip_controller_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/render_widget_host_view_aura_unittest.cc
diff --git a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc
index 7508caa273796135f3e13636d0eaf30dafca56e0..302fed3a03af20a7be4cadb10384574a83fb6c56 100644
--- a/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc
+++ b/content/browser/renderer_host/render_widget_host_view_aura_unittest.cc
@@ -56,6 +56,7 @@
#include "ui/events/gesture_detection/gesture_configuration.h"
#include "ui/events/test/event_generator.h"
#include "ui/wm/core/default_activation_client.h"
+#include "ui/wm/core/default_screen_position_client.h"
#include "ui/wm/core/window_util.h"
using testing::_;
@@ -70,34 +71,6 @@ using blink::WebTouchPoint;
namespace content {
namespace {
-// Simple screen position client to test coordinate system conversion.
-class TestScreenPositionClient
- : public aura::client::ScreenPositionClient {
- public:
- TestScreenPositionClient() {}
- ~TestScreenPositionClient() override {}
-
- // aura::client::ScreenPositionClient overrides:
- void ConvertPointToScreen(const aura::Window* window,
- gfx::Point* point) override {
- point->Offset(-1, -1);
- }
-
- void ConvertPointFromScreen(const aura::Window* window,
- gfx::Point* point) override {
- point->Offset(1, 1);
- }
-
- void ConvertHostPointToScreen(aura::Window* window,
- gfx::Point* point) override {
- ConvertPointToScreen(window, point);
- }
-
- void SetBounds(aura::Window* window,
- const gfx::Rect& bounds,
- const gfx::Display& display) override {}
-};
-
class TestOverscrollDelegate : public OverscrollControllerDelegate {
public:
explicit TestOverscrollDelegate(RenderWidgetHostView* view)
@@ -706,7 +679,7 @@ TEST_F(RenderWidgetHostViewAuraTest, FocusFullscreen) {
// Checks that a popup is positioned correctly relative to its parent using
// screen coordinates.
TEST_F(RenderWidgetHostViewAuraTest, PositionChildPopup) {
- TestScreenPositionClient screen_position_client;
+ wm::DefaultScreenPositionClient screen_position_client;
aura::Window* window = parent_view_->GetNativeView();
aura::Window* root = window->GetRootWindow();
« no previous file with comments | « athena/screen/screen_manager_impl.cc ('k') | ui/views/corewm/tooltip_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698