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

Unified Diff: ui/gfx/screen_win.cc

Issue 341763002: Ensure that mouse events on Windows reposted by the menu_controller are converted to pixel. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Convert screen_loc to pixels in menu_controller.cc Created 6 years, 6 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 | « no previous file | ui/views/controls/menu/menu_controller.cc » ('j') | ui/views/controls/menu/menu_controller.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/screen_win.cc
diff --git a/ui/gfx/screen_win.cc b/ui/gfx/screen_win.cc
index 0da5833a0c9c143b688619204d47079dfa6ceef1..4530642e24bcd7450f0eae014091b9c4b772d192 100644
--- a/ui/gfx/screen_win.cc
+++ b/ui/gfx/screen_win.cc
@@ -76,7 +76,8 @@ gfx::NativeWindow ScreenWin::GetWindowUnderCursor() {
}
gfx::NativeWindow ScreenWin::GetWindowAtScreenPoint(const gfx::Point& point) {
- return GetNativeWindowFromHWND(WindowFromPoint(point.ToPOINT()));
+ gfx::Point point_in_pixels = gfx::win::DIPToScreenPoint(point);
+ return GetNativeWindowFromHWND(WindowFromPoint(point_in_pixels.ToPOINT()));
}
int ScreenWin::GetNumDisplays() const {
« no previous file with comments | « no previous file | ui/views/controls/menu/menu_controller.cc » ('j') | ui/views/controls/menu/menu_controller.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698