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

Side by Side Diff: chrome/browser/ui/views/toolbar/toolbar_button_test.cc

Issue 273223002: views: Make view::Views::GetPreferredSize() const. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: More compile fix for ToT Created 6 years, 7 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "base/message_loop/message_loop.h" 5 #include "base/message_loop/message_loop.h"
6 #include "base/strings/utf_string_conversions.h" 6 #include "base/strings/utf_string_conversions.h"
7 #include "chrome/browser/ui/views/toolbar/toolbar_button.h" 7 #include "chrome/browser/ui/views/toolbar/toolbar_button.h"
8 #include "chrome/test/base/interactive_test_utils.h" 8 #include "chrome/test/base/interactive_test_utils.h"
9 #include "chrome/test/base/ui_test_utils.h" 9 #include "chrome/test/base/ui_test_utils.h"
10 #include "chrome/test/base/view_event_test_base.h" 10 #include "chrome/test/base/view_event_test_base.h"
(...skipping 20 matching lines...) Expand all
31 } 31 }
32 32
33 virtual void TearDown() OVERRIDE { 33 virtual void TearDown() OVERRIDE {
34 ViewEventTestBase::TearDown(); 34 ViewEventTestBase::TearDown();
35 } 35 }
36 36
37 virtual views::View* CreateContentsView() OVERRIDE { 37 virtual views::View* CreateContentsView() OVERRIDE {
38 return button_; 38 return button_;
39 } 39 }
40 40
41 virtual gfx::Size GetPreferredSize() OVERRIDE { 41 virtual gfx::Size GetPreferredSize() const OVERRIDE {
42 return button_->GetPreferredSize(); 42 return button_->GetPreferredSize();
43 } 43 }
44 44
45 // ui::SimpleMenuModel::Delegate implementation. 45 // ui::SimpleMenuModel::Delegate implementation.
46 virtual bool IsCommandIdChecked(int id) const OVERRIDE { 46 virtual bool IsCommandIdChecked(int id) const OVERRIDE {
47 return false; 47 return false;
48 } 48 }
49 49
50 virtual bool IsCommandIdEnabled(int id) const OVERRIDE { 50 virtual bool IsCommandIdEnabled(int id) const OVERRIDE {
51 return true; 51 return true;
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 } 123 }
124 124
125 private: 125 private:
126 ToolbarButton* button_; 126 ToolbarButton* button_;
127 bool menu_shown_; 127 bool menu_shown_;
128 bool menu_closed_; 128 bool menu_closed_;
129 }; 129 };
130 130
131 // Broken since landed. crbug.com/325055 131 // Broken since landed. crbug.com/325055
132 VIEW_TEST(ToolbarButtonDragTest, DISABLED_DragActivation) 132 VIEW_TEST(ToolbarButtonDragTest, DISABLED_DragActivation)
OLDNEW
« no previous file with comments | « chrome/browser/ui/views/toolbar/toolbar_button.cc ('k') | chrome/browser/ui/views/toolbar/toolbar_origin_chip_view.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698