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

Side by Side Diff: ui/gfx/screen_aura.cc

Issue 8549008: Extract MonitorInfoProvider from WindowSizer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add docs Created 9 years 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ui/gfx/screen.h ('k') | ui/gfx/screen_gtk.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ui/gfx/screen.h" 5 #include "ui/gfx/screen.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "ui/gfx/native_widget_types.h" 8 #include "ui/gfx/native_widget_types.h"
9 9
10 namespace gfx { 10 namespace gfx {
(...skipping 30 matching lines...) Expand all
41 gfx::Rect Screen::GetMonitorWorkAreaNearestPoint(const gfx::Point& point) { 41 gfx::Rect Screen::GetMonitorWorkAreaNearestPoint(const gfx::Point& point) {
42 return instance_->GetMonitorWorkAreaNearestPointImpl(point); 42 return instance_->GetMonitorWorkAreaNearestPointImpl(point);
43 } 43 }
44 44
45 // static 45 // static
46 gfx::Rect Screen::GetMonitorAreaNearestPoint(const gfx::Point& point) { 46 gfx::Rect Screen::GetMonitorAreaNearestPoint(const gfx::Point& point) {
47 return instance_->GetMonitorAreaNearestPointImpl(point); 47 return instance_->GetMonitorAreaNearestPointImpl(point);
48 } 48 }
49 49
50 // static 50 // static
51 gfx::Rect Screen::GetPrimaryMonitorWorkArea() {
52 return instance_->GetMonitorWorkAreaNearestPoint(gfx::Point());
53 }
54
55 // static
56 gfx::Rect Screen::GetPrimaryMonitorBounds() {
57 return instance_->GetMonitorAreaNearestPoint(gfx::Point());
58 }
59
60 // static
61 gfx::Rect Screen::GetMonitorWorkAreaMatching(const gfx::Rect& match_rect) {
62 return instance_->GetMonitorWorkAreaNearestPoint(gfx::Point());
63 }
64
65 // static
51 gfx::NativeWindow Screen::GetWindowAtCursorScreenPoint() { 66 gfx::NativeWindow Screen::GetWindowAtCursorScreenPoint() {
52 return instance_->GetWindowAtCursorScreenPointImpl(); 67 return instance_->GetWindowAtCursorScreenPointImpl();
53 } 68 }
54 69
55 // static 70 // static
56 gfx::Size Screen::GetPrimaryMonitorSize() { 71 gfx::Size Screen::GetPrimaryMonitorSize() {
57 return instance_->GetPrimaryMonitorSizeImpl(); 72 return instance_->GetPrimaryMonitorSizeImpl();
58 } 73 }
59 74
60 // static 75 // static
61 int Screen::GetNumMonitors() { 76 int Screen::GetNumMonitors() {
62 return instance_->GetNumMonitorsImpl(); 77 return instance_->GetNumMonitorsImpl();
63 } 78 }
64 79
65 } // namespace gfx 80 } // namespace gfx
OLDNEW
« no previous file with comments | « ui/gfx/screen.h ('k') | ui/gfx/screen_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698