| Index: chrome/android/java/src/org/chromium/chrome/browser/tabmodel/TabModelDelegate.java
|
| diff --git a/chrome/android/java/src/org/chromium/chrome/browser/tabmodel/TabModelDelegate.java b/chrome/android/java/src/org/chromium/chrome/browser/tabmodel/TabModelDelegate.java
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..9b8c8a7ba779d250eb5c132bd876fff1307f0239
|
| --- /dev/null
|
| +++ b/chrome/android/java/src/org/chromium/chrome/browser/tabmodel/TabModelDelegate.java
|
| @@ -0,0 +1,39 @@
|
| +// Copyright 2014 The Chromium Authors. All rights reserved.
|
| +// Use of this source code is governed by a BSD-style license that can be
|
| +// found in the LICENSE file.
|
| +
|
| +package org.chromium.chrome.browser.tabmodel;
|
| +
|
| +import org.chromium.chrome.browser.Tab;
|
| +import org.chromium.chrome.browser.tabmodel.TabModel.TabSelectionType;
|
| +
|
| +/**
|
| + * This class serves as a callback from TabModel to TabModelSelector. The number of methods in this
|
| + * class should be reduced to a minimum. http://crbug.com/263579
|
| + */
|
| +public interface TabModelDelegate {
|
| +
|
| + /**
|
| + * Called when a new tab is created.
|
| + */
|
| + void didCreateNewTab(Tab tab);
|
| +
|
| + /**
|
| + * Called when the {@link TabModelSelector} or its {@link TabModel} has changed.
|
| + */
|
| + void didChange();
|
| +
|
| + /**
|
| + * Requests the specified to be shown.
|
| + * @param tab The tab that is requested to be shown.
|
| + * @param type The reason why this tab was requested to be shown.
|
| + */
|
| + void requestToShowTab(Tab tab, TabSelectionType type);
|
| +
|
| + // TODO(aurimas): clean these methods up.
|
| + TabModel getCurrentModel();
|
| + TabModel getModel(boolean incognito);
|
| + boolean isInOverviewMode();
|
| + boolean isSessionRestoreInProgress();
|
| + void selectModel(boolean incognito);
|
| +}
|
|
|