| Index: chrome/browser/ui/cocoa/browser_window_controller_browsertest.mm
|
| diff --git a/chrome/browser/ui/cocoa/browser_window_controller_browsertest.mm b/chrome/browser/ui/cocoa/browser_window_controller_browsertest.mm
|
| index ce50f3e7cdd6dbd70d985fc477c35032300fdc47..a4a084ddcfcc7fd8540ede0aac8f64ef4b865cf0 100644
|
| --- a/chrome/browser/ui/cocoa/browser_window_controller_browsertest.mm
|
| +++ b/chrome/browser/ui/cocoa/browser_window_controller_browsertest.mm
|
| @@ -21,7 +21,7 @@
|
| #import "chrome/browser/ui/cocoa/fast_resize_view.h"
|
| #import "chrome/browser/ui/cocoa/infobars/infobar_container_controller.h"
|
| #import "chrome/browser/ui/cocoa/nsview_additions.h"
|
| -#import "chrome/browser/ui/cocoa/tab_contents/previewable_contents_controller.h"
|
| +#import "chrome/browser/ui/cocoa/tab_contents/overlayable_contents_controller.h"
|
| #include "chrome/browser/ui/search/search.h"
|
| #include "chrome/browser/ui/search/search_model.h"
|
| #include "chrome/browser/ui/tabs/tab_strip_model.h"
|
| @@ -254,7 +254,7 @@ IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest,
|
| EXPECT_LT(NSMaxX(fullscreen_frame), NSMinX(avatar_frame));
|
| }
|
|
|
| -// Verify that in non-instant normal mode that the find bar and download shelf
|
| +// Verify that in non-Instant normal mode that the find bar and download shelf
|
| // are above the content area. Everything else should be below it.
|
| IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest, ZOrderNormal) {
|
| browser()->GetFindBarController(); // add find bar
|
| @@ -269,7 +269,7 @@ IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest, ZOrderNormal) {
|
| VerifyZOrder(view_list);
|
| }
|
|
|
| -// Verify that in non-instant presentation mode that the info bar is below the
|
| +// Verify that in non-Instant presentation mode that the info bar is below the
|
| // content are and everything else is above it.
|
| // DISABLED due to flaky failures on trybots. http://crbug.com/178778
|
| IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest,
|
| @@ -288,7 +288,7 @@ IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest,
|
| VerifyZOrder(view_list);
|
| }
|
|
|
| -// Normal mode with instant results showing. Should be same z-order as normal
|
| +// Normal mode with Instant results showing. Should be same z-order as normal
|
| // mode except find bar is below content area.
|
| IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest, ZOrderNormalInstant) {
|
| ShowInstantResults();
|
| @@ -304,8 +304,8 @@ IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest, ZOrderNormalInstant) {
|
| VerifyZOrder(view_list);
|
| }
|
|
|
| -// Presentation mode with instant results showing. Should be exact same as
|
| -// non-instant presentation mode.
|
| +// Presentation mode with Instant results showing. Should be exact same as
|
| +// non-Instant presentation mode.
|
| IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest,
|
| ZOrderInstantPresentationMode) {
|
| chrome::ToggleFullscreenMode(browser());
|
| @@ -347,106 +347,106 @@ IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest,
|
| VerifyZOrder(view_list);
|
| }
|
|
|
| -// Verify that in non-instant presentation mode the content area is beneath
|
| +// Verify that in non-Instant presentation mode the content area is beneath
|
| // the bookmark bar and info bar.
|
| IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest, ContentOffset) {
|
| - PreviewableContentsController* preview =
|
| - [controller() previewableContentsController];
|
| + OverlayableContentsController* overlay =
|
| + [controller() overlayableContentsController];
|
|
|
| // Just toolbar.
|
| - EXPECT_EQ(0, [preview activeContainerOffset]);
|
| + EXPECT_EQ(0, [overlay activeContainerOffset]);
|
|
|
| // Plus bookmark bar.
|
| browser()->window()->ToggleBookmarkBar();
|
| EXPECT_EQ(GetViewHeight(VIEW_ID_BOOKMARK_BAR),
|
| - [preview activeContainerOffset]);
|
| + [overlay activeContainerOffset]);
|
|
|
| // Plus info bar.
|
| ShowInfoBar();
|
| EXPECT_EQ(GetViewHeight(VIEW_ID_BOOKMARK_BAR) +
|
| GetViewHeight(VIEW_ID_INFO_BAR),
|
| - [preview activeContainerOffset]);
|
| + [overlay activeContainerOffset]);
|
|
|
| // Minus bookmark bar.
|
| browser()->window()->ToggleBookmarkBar();
|
| - EXPECT_EQ(GetViewHeight(VIEW_ID_INFO_BAR), [preview activeContainerOffset]);
|
| + EXPECT_EQ(GetViewHeight(VIEW_ID_INFO_BAR), [overlay activeContainerOffset]);
|
| }
|
|
|
| -// Verify that in non-instant presentation mode the content area is beneath
|
| +// Verify that in non-Instant presentation mode the content area is beneath
|
| // the info bar.
|
| IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest,
|
| ContentOffsetPresentationMode) {
|
| chrome::ToggleFullscreenMode(browser());
|
| - PreviewableContentsController* preview =
|
| - [controller() previewableContentsController];
|
| + OverlayableContentsController* overlay =
|
| + [controller() overlayableContentsController];
|
|
|
| // Just toolbar.
|
| - EXPECT_EQ(0, [preview activeContainerOffset]);
|
| + EXPECT_EQ(0, [overlay activeContainerOffset]);
|
|
|
| // Plus bookmark bar.
|
| browser()->window()->ToggleBookmarkBar();
|
| - EXPECT_EQ(0, [preview activeContainerOffset]);
|
| + EXPECT_EQ(0, [overlay activeContainerOffset]);
|
|
|
| // Plus info bar.
|
| ShowInfoBar();
|
| - EXPECT_EQ(0, [preview activeContainerOffset]);
|
| + EXPECT_EQ(0, [overlay activeContainerOffset]);
|
|
|
| // Minus bookmark bar.
|
| browser()->window()->ToggleBookmarkBar();
|
| - EXPECT_EQ(0, [preview activeContainerOffset]);
|
| + EXPECT_EQ(0, [overlay activeContainerOffset]);
|
| }
|
|
|
| -// Verify that when showing instant results the content area overlaps the
|
| +// Verify that when showing Instant results the content area overlaps the
|
| // bookmark bar and info bar.
|
| IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest, ContentOffsetInstant) {
|
| ShowInstantResults();
|
| - PreviewableContentsController* preview =
|
| - [controller() previewableContentsController];
|
| + OverlayableContentsController* overlay =
|
| + [controller() overlayableContentsController];
|
|
|
| // Just toolbar.
|
| - EXPECT_EQ(0, [preview activeContainerOffset]);
|
| + EXPECT_EQ(0, [overlay activeContainerOffset]);
|
|
|
| // Plus bookmark bar.
|
| browser()->window()->ToggleBookmarkBar();
|
| - EXPECT_EQ(0, [preview activeContainerOffset]);
|
| + EXPECT_EQ(0, [overlay activeContainerOffset]);
|
|
|
| // Plus info bar.
|
| ShowInfoBar();
|
| - EXPECT_EQ(0, [preview activeContainerOffset]);
|
| + EXPECT_EQ(0, [overlay activeContainerOffset]);
|
|
|
| // Minus bookmark bar.
|
| browser()->window()->ToggleBookmarkBar();
|
| - EXPECT_EQ(0, [preview activeContainerOffset]);
|
| + EXPECT_EQ(0, [overlay activeContainerOffset]);
|
| }
|
|
|
| -// The instant NTP case is same as normal case except that the preview is
|
| +// The Instant NTP case is same as normal case except that the overlay is
|
| // also shifted down.
|
| IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest, ContentOffsetInstantNPT) {
|
| ShowInstantNTP();
|
| - PreviewableContentsController* preview =
|
| - [controller() previewableContentsController];
|
| + OverlayableContentsController* overlay =
|
| + [controller() overlayableContentsController];
|
|
|
| // Just toolbar.
|
| - EXPECT_EQ(0, [preview activeContainerOffset]);
|
| + EXPECT_EQ(0, [overlay activeContainerOffset]);
|
|
|
| // Plus bookmark bar.
|
| browser()->window()->ToggleBookmarkBar();
|
| EXPECT_EQ(GetViewHeight(VIEW_ID_BOOKMARK_BAR),
|
| - [preview activeContainerOffset]);
|
| + [overlay activeContainerOffset]);
|
|
|
| // Plus info bar.
|
| ShowInfoBar();
|
| EXPECT_EQ(GetViewHeight(VIEW_ID_BOOKMARK_BAR) +
|
| GetViewHeight(VIEW_ID_INFO_BAR),
|
| - [preview activeContainerOffset]);
|
| + [overlay activeContainerOffset]);
|
|
|
| // Minus bookmark bar.
|
| browser()->window()->ToggleBookmarkBar();
|
| - EXPECT_EQ(GetViewHeight(VIEW_ID_INFO_BAR), [preview activeContainerOffset]);
|
| + EXPECT_EQ(GetViewHeight(VIEW_ID_INFO_BAR), [overlay activeContainerOffset]);
|
| }
|
|
|
| -// Verify that if bookmark bar is underneath instant search results then
|
| -// clicking on instant search results still works.
|
| +// Verify that if bookmark bar is underneath Instant search results then
|
| +// clicking on Instant search results still works.
|
| IN_PROC_BROWSER_TEST_F(BrowserWindowControllerTest,
|
| InstantSearchResultsHitTest) {
|
| browser()->window()->ToggleBookmarkBar();
|
|
|