summaryrefslogtreecommitdiffstats
path: root/chrome/views/chrome_menu.cc
diff options
context:
space:
mode:
authorben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-10-16 18:17:47 +0000
committerben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2008-10-16 18:17:47 +0000
commit80f8b9f5cf620c37e9d1408a114dc90699584d89 (patch)
tree9e2f5fcacbb18cd86690bc47e0d22ea8f10ac317 /chrome/views/chrome_menu.cc
parentf377cebc8bb25bb9f6708adbfda567a95c296642 (diff)
downloadchromium_src-80f8b9f5cf620c37e9d1408a114dc90699584d89.zip
chromium_src-80f8b9f5cf620c37e9d1408a114dc90699584d89.tar.gz
chromium_src-80f8b9f5cf620c37e9d1408a114dc90699584d89.tar.bz2
Make View::SetBounds take a const gfx::Rect& instead of a const CRect&
Make View::DidChangeBounds call Layout by default, eliminating this function from most places. http://crbug.com/2186 Review URL: http://codereview.chromium.org/7429 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@3471 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/views/chrome_menu.cc')
-rw-r--r--chrome/views/chrome_menu.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/chrome/views/chrome_menu.cc b/chrome/views/chrome_menu.cc
index 72519d5..1b8cb4d 100644
--- a/chrome/views/chrome_menu.cc
+++ b/chrome/views/chrome_menu.cc
@@ -442,7 +442,8 @@ class MenuScrollViewContainer : public View {
scroll_view_->Layout();
}
- virtual void DidChangeBounds(const CRect& previous, const CRect& current) {
+ virtual void DidChangeBounds(const gfx::Rect& previous,
+ const gfx::Rect& current) {
gfx::Size content_pref = scroll_view_->GetContents()->GetPreferredSize();
scroll_up_button_->SetVisible(content_pref.height() > height());
scroll_down_button_->SetVisible(content_pref.height() > height());
@@ -829,7 +830,8 @@ gfx::Size SubmenuView::GetPreferredSize() {
return gfx::Size(max_width + insets.width(), height + insets.height());
}
-void SubmenuView::DidChangeBounds(const CRect& previous, const CRect& current) {
+void SubmenuView::DidChangeBounds(const gfx::Rect& previous,
+ const gfx::Rect& current) {
SchedulePaint();
}