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

Issue 1287573002: [Mac] Add gfx::ScreenPoint[To|From]NSPoint. (Closed)

Created:
5 years, 4 months ago by jackhou1
Modified:
5 years, 4 months ago
Reviewers:
tapted, msw
CC:
chromium-reviews, chrome-apps-syd-reviews_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@openurl
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

[Mac] Add gfx::ScreenPoint[To|From]NSPoint. Similarly to ScreenRect[To|From]NSRect, we want to avoid a proliferation of the following patterns for doing this conversion: gfx::Point point(ns_point.x, NSMaxY([[[NSScreen screens] objectAtIndex:0] frame]) - ns_point.y); Or alternatively, creating an NSRect, converting with gfx::ScreenRectFromNSRect(), and taking the origin. BUG=None Committed: https://crrev.com/148c98707491251276ec2380e269e1b7f0edc699 Cr-Commit-Position: refs/heads/master@{#342914}

Patch Set 1 #

Total comments: 16

Patch Set 2 : Address comments. #

Total comments: 6
Unified diffs Side-by-side diffs Delta from patch set Stats (+58 lines, -12 lines) Patch
M ui/gfx/mac/coordinate_conversion.h View 1 chunk +11 lines, -2 lines 0 comments Download
M ui/gfx/mac/coordinate_conversion.mm View 1 2 chunks +14 lines, -6 lines 3 comments Download
M ui/gfx/mac/coordinate_conversion_unittest.mm View 1 1 chunk +33 lines, -4 lines 3 comments Download

Depends on Patchset:

Dependent Patchsets:

Messages

Total messages: 15 (4 generated)
jackhou1
5 years, 4 months ago (2015-08-11 03:34:16 UTC) #2
tapted
https://codereview.chromium.org/1287573002/diff/1/ui/gfx/mac/coordinate_conversion.h File ui/gfx/mac/coordinate_conversion.h (right): https://codereview.chromium.org/1287573002/diff/1/ui/gfx/mac/coordinate_conversion.h#newcode1 ui/gfx/mac/coordinate_conversion.h:1: // Copyright 2014 The Chromium Authors. All rights reserved. ...
5 years, 4 months ago (2015-08-11 04:01:01 UTC) #3
tapted
oh and lgtm after all those nits
5 years, 4 months ago (2015-08-11 04:01:15 UTC) #4
jackhou1
https://codereview.chromium.org/1287573002/diff/1/ui/gfx/mac/coordinate_conversion.h File ui/gfx/mac/coordinate_conversion.h (right): https://codereview.chromium.org/1287573002/diff/1/ui/gfx/mac/coordinate_conversion.h#newcode1 ui/gfx/mac/coordinate_conversion.h:1: // Copyright 2014 The Chromium Authors. All rights reserved. ...
5 years, 4 months ago (2015-08-11 06:40:56 UTC) #5
jackhou1
msw, please review for OWNERS
5 years, 4 months ago (2015-08-11 06:41:47 UTC) #7
msw
lgtm with a nit and a q. https://codereview.chromium.org/1287573002/diff/20001/ui/gfx/mac/coordinate_conversion.mm File ui/gfx/mac/coordinate_conversion.mm (right): https://codereview.chromium.org/1287573002/diff/20001/ui/gfx/mac/coordinate_conversion.mm#newcode16 ui/gfx/mac/coordinate_conversion.mm:16: // The ...
5 years, 4 months ago (2015-08-11 17:41:48 UTC) #8
jackhou1
https://codereview.chromium.org/1287573002/diff/20001/ui/gfx/mac/coordinate_conversion.mm File ui/gfx/mac/coordinate_conversion.mm (right): https://codereview.chromium.org/1287573002/diff/20001/ui/gfx/mac/coordinate_conversion.mm#newcode16 ui/gfx/mac/coordinate_conversion.mm:16: // The height of the primary display, which OSX ...
5 years, 4 months ago (2015-08-11 22:01:12 UTC) #9
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1287573002/20001 View timeline at https://chromium-cq-status.appspot.com/patch-timeline/1287573002/20001
5 years, 4 months ago (2015-08-11 22:01:47 UTC) #12
msw
lgtm, thanks for the explanations. https://codereview.chromium.org/1287573002/diff/20001/ui/gfx/mac/coordinate_conversion.mm File ui/gfx/mac/coordinate_conversion.mm (right): https://codereview.chromium.org/1287573002/diff/20001/ui/gfx/mac/coordinate_conversion.mm#newcode16 ui/gfx/mac/coordinate_conversion.mm:16: // The height of ...
5 years, 4 months ago (2015-08-11 22:02:02 UTC) #13
commit-bot: I haz the power
Committed patchset #2 (id:20001)
5 years, 4 months ago (2015-08-11 22:06:45 UTC) #14
commit-bot: I haz the power
5 years, 4 months ago (2015-08-11 22:07:29 UTC) #15
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/148c98707491251276ec2380e269e1b7f0edc699
Cr-Commit-Position: refs/heads/master@{#342914}

Powered by Google App Engine
This is Rietveld 408576698