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

Unified Diff: chrome/browser/chromeos/accessibility/accessibility_highlight_manager.cc

Issue 2432583002: Make cursor highlighting feature work across multiple displays (Closed)
Patch Set: Address feedback on test Created 4 years, 2 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: chrome/browser/chromeos/accessibility/accessibility_highlight_manager.cc
diff --git a/chrome/browser/chromeos/accessibility/accessibility_highlight_manager.cc b/chrome/browser/chromeos/accessibility/accessibility_highlight_manager.cc
index 9f7afdd1cac35c86890998561163f34fb2e1b2ec..69f935fe58a9ec3d22909b81cf3a9368c7e49161 100644
--- a/chrome/browser/chromeos/accessibility/accessibility_highlight_manager.cc
+++ b/chrome/browser/chromeos/accessibility/accessibility_highlight_manager.cc
@@ -9,6 +9,7 @@
#include "content/public/browser/notification_service.h"
#include "content/public/browser/notification_types.h"
#include "ui/aura/window_tree_host.h"
+#include "ui/wm/core/coordinate_conversion.h"
#include "ui/wm/core/cursor_manager.h"
namespace chromeos {
@@ -77,7 +78,11 @@ void AccessibilityHighlightManager::RegisterObservers() {
void AccessibilityHighlightManager::OnMouseEvent(ui::MouseEvent* event) {
if (event->type() == ui::ET_MOUSE_MOVED) {
- cursor_point_ = event->root_location();
+ cursor_point_ = event->location();
+ if (event->target()) {
+ ::wm::ConvertPointToScreen(static_cast<aura::Window*>(event->target()),
+ &cursor_point_);
+ }
UpdateCursorHighlight();
}
}

Powered by Google App Engine
This is Rietveld 408576698