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
3 // found in the LICENSE file.
5 #include "chrome/browser/ui/tabs/test_tab_strip_model_delegate.h"
7 #include "chrome/browser/extensions/tab_helper.h"
8 #include "chrome/browser/ui/tab_contents/core_tab_helper.h"
10 TestTabStripModelDelegate::TestTabStripModelDelegate() {
13 TestTabStripModelDelegate::~TestTabStripModelDelegate() {
16 void TestTabStripModelDelegate::AddTabAt(const GURL
& url
,
21 Browser
* TestTabStripModelDelegate::CreateNewStripWithContents(
22 const std::vector
<NewStripContents
>& contentses
,
23 const gfx::Rect
& window_bounds
,
28 void TestTabStripModelDelegate::WillAddWebContents(
29 content::WebContents
* contents
) {
30 // Required to determine reloadability of tabs.
31 CoreTabHelper::CreateForWebContents(contents
);
32 // Required to determine if tabs are app tabs.
33 extensions::TabHelper::CreateForWebContents(contents
);
36 int TestTabStripModelDelegate::GetDragActions() const {
40 bool TestTabStripModelDelegate::CanDuplicateContentsAt(int index
) {
44 void TestTabStripModelDelegate::DuplicateContentsAt(int index
) {
47 void TestTabStripModelDelegate::CreateHistoricalTab(
48 content::WebContents
* contents
) {
51 bool TestTabStripModelDelegate::ShouldRunUnloadListenerBeforeClosing(
52 content::WebContents
* contents
) {
56 bool TestTabStripModelDelegate::RunUnloadListenerBeforeClosing(
57 content::WebContents
* contents
) {
61 TabStripModelDelegate::RestoreTabType
62 TestTabStripModelDelegate::GetRestoreTabType() {
63 return TabStripModelDelegate::RESTORE_NONE
;
66 void TestTabStripModelDelegate::RestoreTab() {
69 bool TestTabStripModelDelegate::CanBookmarkAllTabs() const {
73 void TestTabStripModelDelegate::BookmarkAllTabs() {