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

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

Issue 14348011: Add a unit test for BrowserViewLayout (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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 | « no previous file | chrome/browser/ui/views/frame/browser_view.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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_
6 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_ 6 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 public views::WidgetObserver, 96 public views::WidgetObserver,
97 public views::ClientView, 97 public views::ClientView,
98 public InfoBarContainer::Delegate, 98 public InfoBarContainer::Delegate,
99 public views::SingleSplitViewListener, 99 public views::SingleSplitViewListener,
100 public gfx::SysColorChangeListener, 100 public gfx::SysColorChangeListener,
101 public LoadCompleteListener::Delegate { 101 public LoadCompleteListener::Delegate {
102 public: 102 public:
103 // The browser view's class name. 103 // The browser view's class name.
104 static const char kViewClassName[]; 104 static const char kViewClassName[];
105 105
106 explicit BrowserView(Browser* browser); 106 BrowserView();
107 virtual ~BrowserView(); 107 virtual ~BrowserView();
108 108
109 // Takes ownership of |browser|.
110 void Init(Browser* browser);
111
109 void set_frame(BrowserFrame* frame) { frame_ = frame; } 112 void set_frame(BrowserFrame* frame) { frame_ = frame; }
110 BrowserFrame* frame() const { return frame_; } 113 BrowserFrame* frame() const { return frame_; }
111 114
112 // Returns a pointer to the BrowserView* interface implementation (an 115 // Returns a pointer to the BrowserView* interface implementation (an
113 // instance of this object, typically) for a given native window, or NULL if 116 // instance of this object, typically) for a given native window, or NULL if
114 // there is no such association. 117 // there is no such association.
115 // 118 //
116 // Don't use this unless you only have a NativeWindow. In nearly all 119 // Don't use this unless you only have a NativeWindow. In nearly all
117 // situations plumb through browser and use it. 120 // situations plumb through browser and use it.
118 static BrowserView* GetBrowserViewForNativeWindow(gfx::NativeWindow window); 121 static BrowserView* GetBrowserViewForNativeWindow(gfx::NativeWindow window);
(...skipping 346 matching lines...) Expand 10 before | Expand all | Expand 10 after
465 468
466 bool pending; 469 bool pending;
467 GURL url; 470 GURL url;
468 FullscreenExitBubbleType bubble_type; 471 FullscreenExitBubbleType bubble_type;
469 }; 472 };
470 473
471 // Appends to |toolbars| a pointer to each AccessiblePaneView that 474 // Appends to |toolbars| a pointer to each AccessiblePaneView that
472 // can be traversed using F6, in the order they should be traversed. 475 // can be traversed using F6, in the order they should be traversed.
473 void GetAccessiblePanes(std::vector<views::AccessiblePaneView*>* panes); 476 void GetAccessiblePanes(std::vector<views::AccessiblePaneView*>* panes);
474 477
475 // Browser window related initializations. 478 // Constructs and initializes the child views.
476 void Init(); 479 void InitViews();
477 480
478 // Callback for the loading animation(s) associated with this view. 481 // Callback for the loading animation(s) associated with this view.
479 void LoadingAnimationCallback(); 482 void LoadingAnimationCallback();
480 483
481 // LoadCompleteListener::Delegate implementation. Creates and initializes the 484 // LoadCompleteListener::Delegate implementation. Creates and initializes the
482 // |jumplist_| after the first page load. 485 // |jumplist_| after the first page load.
483 virtual void OnLoadCompleted() OVERRIDE; 486 virtual void OnLoadCompleted() OVERRIDE;
484 487
485 // Returns the BrowserViewLayout. 488 // Returns the BrowserViewLayout.
486 BrowserViewLayout* GetBrowserViewLayout() const; 489 BrowserViewLayout* GetBrowserViewLayout() const;
(...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after
743 gfx::ScopedSysColorChangeListener color_change_listener_; 746 gfx::ScopedSysColorChangeListener color_change_listener_;
744 747
745 scoped_ptr<InstantOverlayControllerViews> overlay_controller_; 748 scoped_ptr<InstantOverlayControllerViews> overlay_controller_;
746 749
747 mutable base::WeakPtrFactory<BrowserView> activate_modal_dialog_factory_; 750 mutable base::WeakPtrFactory<BrowserView> activate_modal_dialog_factory_;
748 751
749 DISALLOW_COPY_AND_ASSIGN(BrowserView); 752 DISALLOW_COPY_AND_ASSIGN(BrowserView);
750 }; 753 };
751 754
752 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_ 755 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/views/frame/browser_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698