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

Side by Side Diff: chrome/browser/ui/views/frame/browser_view.cc

Issue 8351007: views: Factor out SingleSplitView Observer into SingleSplitViewListener. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 2 months 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 | « chrome/browser/ui/views/frame/browser_view.h ('k') | views/controls/single_split_view.h » ('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 "chrome/browser/ui/views/frame/browser_view.h" 5 #include "chrome/browser/ui/views/frame/browser_view.h"
6 6
7 #if defined(TOOLKIT_USES_GTK) 7 #if defined(TOOLKIT_USES_GTK)
8 #include <gtk/gtk.h> 8 #include <gtk/gtk.h>
9 #endif 9 #endif
10 10
(...skipping 1812 matching lines...) Expand 10 before | Expand all | Expand 10 after
1823 if (x) { 1823 if (x) {
1824 const LocationIconView* location_icon_view = 1824 const LocationIconView* location_icon_view =
1825 toolbar_->location_bar()->location_icon_view(); 1825 toolbar_->location_bar()->location_icon_view();
1826 gfx::Point icon_center(location_icon_view->GetImageBounds().CenterPoint()); 1826 gfx::Point icon_center(location_icon_view->GetImageBounds().CenterPoint());
1827 ConvertPointToView(location_icon_view, this, &icon_center); 1827 ConvertPointToView(location_icon_view, this, &icon_center);
1828 *x = icon_center.x(); 1828 *x = icon_center.x();
1829 } 1829 }
1830 return true; 1830 return true;
1831 } 1831 }
1832 1832
1833 bool BrowserView::SplitHandleMoved(views::SingleSplitView* view) { 1833 bool BrowserView::SplitHandleMoved(views::SingleSplitView* sender) {
1834 for (int i = 0; i < view->child_count(); ++i) 1834 for (int i = 0; i < sender->child_count(); ++i)
1835 view->child_at(i)->InvalidateLayout(); 1835 sender->child_at(i)->InvalidateLayout();
1836 SchedulePaint(); 1836 SchedulePaint();
1837 Layout(); 1837 Layout();
1838 return false; 1838 return false;
1839 } 1839 }
1840 1840
1841 views::LayoutManager* BrowserView::CreateLayoutManager() const { 1841 views::LayoutManager* BrowserView::CreateLayoutManager() const {
1842 return new BrowserViewLayout; 1842 return new BrowserViewLayout;
1843 } 1843 }
1844 1844
1845 void BrowserView::InitTabStrip(TabStripModel* model) { 1845 void BrowserView::InitTabStrip(TabStripModel* model) {
(...skipping 771 matching lines...) Expand 10 before | Expand all | Expand 10 after
2617 views::View::ConvertPointToScreen(GetTabContentsContainerView(), &origin); 2617 views::View::ConvertPointToScreen(GetTabContentsContainerView(), &origin);
2618 gfx::Rect bounds; 2618 gfx::Rect bounds;
2619 bounds.set_origin(origin); 2619 bounds.set_origin(origin);
2620 2620
2621 AvatarMenuBubbleView* bubble_view = new AvatarMenuBubbleView(browser_.get()); 2621 AvatarMenuBubbleView* bubble_view = new AvatarMenuBubbleView(browser_.get());
2622 // Bubble::Show() takes ownership of the view. 2622 // Bubble::Show() takes ownership of the view.
2623 Bubble::Show(this->GetWidget(), bounds, 2623 Bubble::Show(this->GetWidget(), bounds,
2624 views::BubbleBorder::TOP_RIGHT, 2624 views::BubbleBorder::TOP_RIGHT,
2625 bubble_view, bubble_view); 2625 bubble_view, bubble_view);
2626 } 2626 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/frame/browser_view.h ('k') | views/controls/single_split_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698