| Index: ui/events/cocoa/events_mac.mm
|
| diff --git a/ui/events/cocoa/events_mac.mm b/ui/events/cocoa/events_mac.mm
|
| index 09398f922e1bcae9f64c19eb87744bc24a1a1e21..29b7fc9601d5275b81fffed7312710c1eba98f16 100644
|
| --- a/ui/events/cocoa/events_mac.mm
|
| +++ b/ui/events/cocoa/events_mac.mm
|
| @@ -90,14 +90,18 @@ base::TimeTicks EventTimeFromNative(const base::NativeEvent& native_event) {
|
| }
|
|
|
| gfx::Point EventLocationFromNative(const base::NativeEvent& native_event) {
|
| + return gfx::ToFlooredPoint(EventLocationFromNativeF(native_event));
|
| +}
|
| +
|
| +gfx::PointF EventLocationFromNativeF(const base::NativeEvent& native_event) {
|
| NSWindow* window = [native_event window];
|
| if (!window) {
|
| NOTIMPLEMENTED(); // Point will be in screen coordinates.
|
| - return gfx::Point();
|
| + return gfx::PointF();
|
| }
|
| NSPoint location = [native_event locationInWindow];
|
| NSRect content_rect = [window contentRectForFrameRect:[window frame]];
|
| - return gfx::Point(location.x, NSHeight(content_rect) - location.y);
|
| + return gfx::PointF(location.x, NSHeight(content_rect) - location.y);
|
| }
|
|
|
| gfx::Point EventSystemLocationFromNative(
|
|
|