diff options
author | jianli@chromium.org <jianli@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-05-11 20:09:28 +0000 |
---|---|---|
committer | jianli@chromium.org <jianli@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-05-11 20:09:28 +0000 |
commit | 8d621b39610e1f15f3c41a14254fa6ce4e67f60b (patch) | |
tree | 8db2d8b60fb9a38ead75350aeb5cd838ea49c4b0 /chrome/browser/ui/panels/display_settings_provider.cc | |
parent | 04be1128ebd1075a622fad990dfff2d8b811c912 (diff) | |
download | chromium_src-8d621b39610e1f15f3c41a14254fa6ce4e67f60b.zip chromium_src-8d621b39610e1f15f3c41a14254fa6ce4e67f60b.tar.gz chromium_src-8d621b39610e1f15f3c41a14254fa6ce4e67f60b.tar.bz2 |
Make sure that the panel cannot be dragged or resized under any top-aligned menu or taskbar.
This is platform-independent work that adds constraint logic to drag and resize controller. For Windows, we do not have problem for panel resizing since we rely on system resizing that does the correct thing. Also the MacOS specific fix for dragging issue is not longer needed.
In addition, I addressed some more feedbacks from http://codereview.chromium.org/10356007/.
BUG=122669
TEST=new tests
Review URL: https://chromiumcodereview.appspot.com/10389048
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@136645 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/ui/panels/display_settings_provider.cc')
-rw-r--r-- | chrome/browser/ui/panels/display_settings_provider.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/chrome/browser/ui/panels/display_settings_provider.cc b/chrome/browser/ui/panels/display_settings_provider.cc index f6b538a..08d5f1b 100644 --- a/chrome/browser/ui/panels/display_settings_provider.cc +++ b/chrome/browser/ui/panels/display_settings_provider.cc @@ -68,6 +68,10 @@ gfx::Rect DisplaySettingsProvider::GetDisplayArea() { return adjusted_work_area_; } +gfx::Rect DisplaySettingsProvider::GetPrimaryScreenArea() const { + return gfx::Screen::GetPrimaryMonitor().bounds(); +} + gfx::Rect DisplaySettingsProvider::GetWorkArea() const { #if defined(OS_MACOSX) // On OSX, panels should be dropped all the way to the bottom edge of the |