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

Unified Diff: ash/drag_drop/drag_drop_tracker.cc

Issue 425363002: Moving coordinate conversion methods from ash/wm to ui/wm. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: More fixes Created 6 years, 4 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 | « ash/drag_drop/drag_drop_controller.cc ('k') | ash/shelf/shelf_bezel_event_filter.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/drag_drop/drag_drop_tracker.cc
diff --git a/ash/drag_drop/drag_drop_tracker.cc b/ash/drag_drop/drag_drop_tracker.cc
index 193dc62054a930c675fb2a90c199f19ac460e70f..c1ec24441a29db955f0b3dd731c93cd26cf4df59 100644
--- a/ash/drag_drop/drag_drop_tracker.cc
+++ b/ash/drag_drop/drag_drop_tracker.cc
@@ -12,6 +12,7 @@
#include "ui/aura/window_event_dispatcher.h"
#include "ui/events/event.h"
#include "ui/gfx/screen.h"
+#include "ui/wm/core/coordinate_conversion.h"
#include "ui/wm/public/activation_delegate.h"
namespace ash {
@@ -68,12 +69,11 @@ void DragDropTracker::TakeCapture() {
aura::Window* DragDropTracker::GetTarget(const ui::LocatedEvent& event) {
DCHECK(capture_window_.get());
gfx::Point location_in_screen = event.location();
- wm::ConvertPointToScreen(capture_window_.get(),
- &location_in_screen);
+ ::wm::ConvertPointToScreen(capture_window_.get(), &location_in_screen);
aura::Window* root_window_at_point =
wm::GetRootWindowAt(location_in_screen);
gfx::Point location_in_root = location_in_screen;
- wm::ConvertPointFromScreen(root_window_at_point, &location_in_root);
+ ::wm::ConvertPointFromScreen(root_window_at_point, &location_in_root);
return root_window_at_point->GetEventHandlerForPoint(location_in_root);
}
@@ -85,7 +85,7 @@ ui::LocatedEvent* DragDropTracker::ConvertEvent(
aura::Window::ConvertPointToTarget(capture_window_.get(), target,
&target_location);
gfx::Point location_in_screen = event.location();
- ash::wm::ConvertPointToScreen(capture_window_.get(), &location_in_screen);
+ ::wm::ConvertPointToScreen(capture_window_.get(), &location_in_screen);
gfx::Point target_root_location = event.root_location();
aura::Window::ConvertPointToTarget(
capture_window_->GetRootWindow(),
« no previous file with comments | « ash/drag_drop/drag_drop_controller.cc ('k') | ash/shelf/shelf_bezel_event_filter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698