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

Issue 8382019: Move DisplayUtils methods into gfx::Screen. (Closed)

Created:
9 years, 2 months ago by Daniel Erat
Modified:
9 years, 1 month ago
Reviewers:
James Cook, sky, dhollowa
CC:
chromium-reviews, Paweł Hajdan Jr.
Visibility:
Public.

Description

Move DisplayUtils methods into gfx::Screen. These methods are currently just used by metrics. I moved them from base into the browser a while back, but I think it makes the most sense for them to live in gfx::Screen. I'm also relocating the tests to ui_unittest and making them work on Aura. BUG=99711, 100341 TEST=ran ui_unittest Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=107027

Patch Set 1 #

Total comments: 3

Patch Set 2 : remove DCHECKS #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+158 lines, -198 lines) Patch
D chrome/browser/metrics/display_utils.h View 1 chunk +0 lines, -24 lines 0 comments Download
D chrome/browser/metrics/display_utils_aura.cc View 1 chunk +0 lines, -23 lines 0 comments Download
D chrome/browser/metrics/display_utils_gtk.cc View 1 chunk +0 lines, -28 lines 0 comments Download
D chrome/browser/metrics/display_utils_mac.cc View 1 chunk +0 lines, -51 lines 0 comments Download
D chrome/browser/metrics/display_utils_unittest.cc View 1 chunk +0 lines, -32 lines 0 comments Download
D chrome/browser/metrics/display_utils_win.cc View 1 chunk +0 lines, -21 lines 0 comments Download
M chrome/browser/metrics/metrics_log.cc View 3 chunks +5 lines, -7 lines 0 comments Download
M chrome/chrome_browser.gypi View 2 chunks +0 lines, -5 lines 0 comments Download
M chrome/chrome_tests.gypi View 1 chunk +0 lines, -1 line 0 comments Download
M ui/aura/screen_aura.h View 1 chunk +2 lines, -0 lines 0 comments Download
M ui/aura/screen_aura.cc View 1 chunk +8 lines, -0 lines 0 comments Download
M ui/gfx/screen.h View 4 chunks +12 lines, -0 lines 0 comments Download
M ui/gfx/screen_aura.cc View 1 1 chunk +10 lines, -6 lines 0 comments Download
M ui/gfx/screen_gtk.cc View 2 chunks +15 lines, -0 lines 0 comments Download
M ui/gfx/screen_mac.mm View 2 chunks +43 lines, -0 lines 0 comments Download
A ui/gfx/screen_unittest.cc View 1 chunk +45 lines, -0 lines 0 comments Download
M ui/gfx/screen_win.cc View 1 chunk +12 lines, -0 lines 0 comments Download
M ui/ui_unittests.gypi View 2 chunks +6 lines, -0 lines 1 comment Download

Messages

Total messages: 7 (0 generated)
Daniel Erat
9 years, 2 months ago (2011-10-24 22:54:06 UTC) #1
sky
LGTM Bonus points (in a separate cl) if you make WindowSizer::MonitorInfoProvider use this.
9 years, 2 months ago (2011-10-24 23:29:29 UTC) #2
James Cook
LGTM too. http://codereview.chromium.org/8382019/diff/1/ui/gfx/screen_aura.cc File ui/gfx/screen_aura.cc (right): http://codereview.chromium.org/8382019/diff/1/ui/gfx/screen_aura.cc#newcode63 ui/gfx/screen_aura.cc:63: DCHECK(instance_); nit: Do we really need all ...
9 years, 2 months ago (2011-10-24 23:40:54 UTC) #3
Daniel Erat
http://codereview.chromium.org/8382019/diff/1/ui/gfx/screen_aura.cc File ui/gfx/screen_aura.cc (right): http://codereview.chromium.org/8382019/diff/1/ui/gfx/screen_aura.cc#newcode63 ui/gfx/screen_aura.cc:63: DCHECK(instance_); On 2011/10/24 23:40:54, James Cook (Chromium) wrote: > ...
9 years, 2 months ago (2011-10-25 00:32:48 UTC) #4
dhollowa
http://codereview.chromium.org/8382019/diff/5001/ui/ui_unittests.gypi File ui/ui_unittests.gypi (right): http://codereview.chromium.org/8382019/diff/5001/ui/ui_unittests.gypi#newcode180 ui/ui_unittests.gypi:180: ['use_aura==1', { This dependency causes a circularity between aura.gyp ...
9 years, 1 month ago (2011-10-27 02:09:10 UTC) #5
sky
Sadrul is fixing this at http://codereview.chromium.org/8391006/ . But it seems to have stalled. Sadrul, how ...
9 years, 1 month ago (2011-10-27 03:17:14 UTC) #6
sadrul
9 years, 1 month ago (2011-10-27 14:23:44 UTC) #7
On 2011/10/27 03:17:14, sky wrote:
> Sadrul is fixing this at http://codereview.chromium.org/8391006/ . But
> it seems to have stalled. Sadrul, how about making it work for
> non-aura platforms so we don't have the circularity.

Done! :)

[sorry about the delay, I was OOO yesterday]

> 
>   -Scott
> 
> On Wed, Oct 26, 2011 at 7:09 PM,  <mailto:dhollowa@chromium.org> wrote:
> >
> > http://codereview.chromium.org/8382019/diff/5001/ui/ui_unittests.gypi
> > File ui/ui_unittests.gypi (right):
> >
> >
>
http://codereview.chromium.org/8382019/diff/5001/ui/ui_unittests.gypi#newcode180
> > ui/ui_unittests.gypi:180: ['use_aura==1', {
> > This dependency causes a circularity between aura.gyp and ui.gyp. &nbsp;This
> > currently only breaks Mac builds with use_aura=1. &nbsp;But we're trying to
> > eliminate circularities where possible.
> >
> > To be clear, the circularity is not between targets themselves, only
> > .gyp files.
> >
> > Is there a good way to break the cycle?
> >
> > Here's the breakage I see on Mac:
> >
> > Updating projects from gyp files...
> > Using overrides found in /Users/dhollowa/.gyp/include.gypi
> > Traceback (most recent call last):
> > &nbsp;File "src/build/gyp_chromium", line 171, in <module>
> > &nbsp; &nbsp;sys.exit(gyp.main(args))
> > &nbsp;File
> > "/Volumes/Code/code107/chromium.git/src/tools/gyp/pylib/gyp/__init__.py",
> > line 465, in main
> > &nbsp; &nbsp;options.circular_check)
> > &nbsp;File
> > "/Volumes/Code/code107/chromium.git/src/tools/gyp/pylib/gyp/__init__.py",
> > line 101, in Load
> > &nbsp; &nbsp;depth, generator_input_info, check, circular_check)
> > &nbsp;File
> > "/Volumes/Code/code107/chromium.git/src/tools/gyp/pylib/gyp/input.py",
> > line 2296, in Load
> > &nbsp; &nbsp;VerifyNoGYPFileCircularDependencies(targets)
> > &nbsp;File
> > "/Volumes/Code/code107/chromium.git/src/tools/gyp/pylib/gyp/input.py",
> > line 1474, in VerifyNoGYPFileCircularDependencies
> > &nbsp; &nbsp;' '.join(bad_files)
> > gyp.input.CircularException: Some files not reachable, cycle in .gyp
> > file dependency graph detected involving some or all of:
> > src/webkit/support/webkit_support.gyp src/ui/gfx/surface/surface.gyp
> > src/gpu/gles2_conform_support/gles2_conform_support.gyp
> > src/ui/gfx/gl/gl.gyp src/printing/printing.gyp src/ui/ui.gyp
> > src/third_party/WebKit/Source/WebCore/WebCore.gyp/WebCore.gyp
> > src/webkit/webkit.gyp src/gpu/demos/demos.gyp
> > src/chrome/default_plugin/default_plugin.gyp src/views/views.gyp
> > src/third_party/WebKit/Source/WebKit/chromium/WebKit.gyp
> > src/tools/imagediff/image_diff.gyp src/ui/aura_shell/aura_shell.gyp
> > src/remoting/remoting.gyp src/build/all.gyp
> > src/ui/gfx/compositor/compositor.gyp src/gpu/gpu.gyp
> > src/third_party/gles2_book/gles2_book.gyp src/chrome/chrome.gyp
> > src/content/content.gyp src/chrome/browser/sync/tools/sync_tools.gyp
> > src/media/media.gyp src/ui/aura/aura.gyp src/ppapi/ppapi_internal.gyp
> > Error: Command /usr/bin/python src/build/gyp_chromium returned non-zero
> > exit status 1 in /Volumes/Code/code107/chromium.git
> >
> > http://codereview.chromium.org/8382019/
> >

Powered by Google App Engine
This is Rietveld 408576698