| Index: ui/wm/core/default_screen_position_client.cc
|
| diff --git a/ui/wm/core/default_screen_position_client.cc b/ui/wm/core/default_screen_position_client.cc
|
| index 4d7a45359d4f805a6d1172b08380e1a0757dff77..d4e5191468d7b0de0eff0f77ceda13c8ece20375 100644
|
| --- a/ui/wm/core/default_screen_position_client.cc
|
| +++ b/ui/wm/core/default_screen_position_client.cc
|
| @@ -29,8 +29,16 @@ gfx::Point DefaultScreenPositionClient::GetOriginInScreen(
|
| void DefaultScreenPositionClient::ConvertPointToScreen(
|
| const aura::Window* window,
|
| gfx::Point* point) {
|
| + gfx::PointF point_f(*point);
|
| + ConvertPointToScreenF(window, &point_f);
|
| + *point = gfx::ToFlooredPoint(point_f);
|
| +}
|
| +
|
| +void DefaultScreenPositionClient::ConvertPointToScreenF(
|
| + const aura::Window* window,
|
| + gfx::PointF* point) {
|
| const aura::Window* root_window = window->GetRootWindow();
|
| - aura::Window::ConvertPointToTarget(window, root_window, point);
|
| + aura::Window::ConvertPointToTargetF(window, root_window, point);
|
| gfx::Point origin = GetOriginInScreen(root_window);
|
| point->Offset(origin.x(), origin.y());
|
| }
|
| @@ -38,10 +46,18 @@ void DefaultScreenPositionClient::ConvertPointToScreen(
|
| void DefaultScreenPositionClient::ConvertPointFromScreen(
|
| const aura::Window* window,
|
| gfx::Point* point) {
|
| + gfx::PointF point_f(*point);
|
| + ConvertPointFromScreenF(window, &point_f);
|
| + *point = gfx::ToFlooredPoint(point_f);
|
| +}
|
| +
|
| +void DefaultScreenPositionClient::ConvertPointFromScreenF(
|
| + const aura::Window* window,
|
| + gfx::PointF* point) {
|
| const aura::Window* root_window = window->GetRootWindow();
|
| gfx::Point origin = GetOriginInScreen(root_window);
|
| point->Offset(-origin.x(), -origin.y());
|
| - aura::Window::ConvertPointToTarget(root_window, window, point);
|
| + aura::Window::ConvertPointToTargetF(root_window, window, point);
|
| }
|
|
|
| void DefaultScreenPositionClient::ConvertHostPointToScreen(aura::Window* window,
|
|
|