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

Unified Diff: chrome/browser/cocoa/toolbar_controller_unittest.mm

Issue 495010: Mac: fix/implement app windows (not app mode), popups, drawing; refactor code. (Closed)
Patch Set: Updated per pink's review. Created 11 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/cocoa/toolbar_controller.mm ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/cocoa/toolbar_controller_unittest.mm
diff --git a/chrome/browser/cocoa/toolbar_controller_unittest.mm b/chrome/browser/cocoa/toolbar_controller_unittest.mm
index f7a2310ec34690dbcafce1f2c7e18607a04127eb..5ce499bfdef085e85a3112174d500de982f44922 100644
--- a/chrome/browser/cocoa/toolbar_controller_unittest.mm
+++ b/chrome/browser/cocoa/toolbar_controller_unittest.mm
@@ -95,11 +95,11 @@ TEST_F(ToolbarControllerTest, InitialState) {
CompareState(updater, [bar_ toolbarViews]);
}
-// Make sure a "titlebar only" toolbar works
+// Make sure a "titlebar only" toolbar with location bar works.
TEST_F(ToolbarControllerTest, TitlebarOnly) {
NSView* view = [bar_ view];
- [bar_ setHasToolbar:NO];
+ [bar_ setHasToolbar:NO hasLocationBar:YES];
EXPECT_NE(view, [bar_ view]);
// Simulate a popup going fullscreen and back.
@@ -110,13 +110,14 @@ TEST_F(ToolbarControllerTest, TitlebarOnly) {
[view removeFromSuperview];
[superview addSubview:view];
- [bar_ setHasToolbar:YES];
+ [bar_ setHasToolbar:YES hasLocationBar:YES];
EXPECT_EQ(view, [bar_ view]);
// Leave it off to make sure that's fine
- [bar_ setHasToolbar:NO];
+ [bar_ setHasToolbar:NO hasLocationBar:YES];
}
+// TODO(viettrungluu): make a version of above without location bar.
// Make some changes to the enabled state of a few of the buttons and ensure
// that we're still in sync.
@@ -208,7 +209,7 @@ TEST_F(ToolbarControllerTest, TogglePageWrench) {
// having the full toolbar. Also ensure that the location bar doesn't change
// size.
TEST_F(ToolbarControllerTest, DontToggleWhenNoToolbar) {
- [bar_ setHasToolbar:NO];
+ [bar_ setHasToolbar:NO hasLocationBar:YES];
NSView* homeButton = [[bar_ toolbarViews] objectAtIndex:kHomeIndex];
NSView* pageButton = [[bar_ toolbarViews] objectAtIndex:kPageIndex];
NSView* wrenchButton = [[bar_ toolbarViews] objectAtIndex:kWrenchIndex];
« no previous file with comments | « chrome/browser/cocoa/toolbar_controller.mm ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698