OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 #ifndef CHROME_BROWSER_TABS_TAB_STRIP_MODEL_OBSERVER_H_ | 5 #ifndef CHROME_BROWSER_TABS_TAB_STRIP_MODEL_OBSERVER_H_ |
6 #define CHROME_BROWSER_TABS_TAB_STRIP_MODEL_OBSERVER_H_ | 6 #define CHROME_BROWSER_TABS_TAB_STRIP_MODEL_OBSERVER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 class TabContentsWrapper; | 9 class TabContentsWrapper; |
10 class TabStripModel; | 10 class TabStripModel; |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
78 // The specified TabContents at |index| changed in some way. |contents| may | 78 // The specified TabContents at |index| changed in some way. |contents| may |
79 // be an entirely different object and the old value is no longer available | 79 // be an entirely different object and the old value is no longer available |
80 // by the time this message is delivered. | 80 // by the time this message is delivered. |
81 // | 81 // |
82 // See TabChangeType for a description of |change_type|. | 82 // See TabChangeType for a description of |change_type|. |
83 virtual void TabChangedAt(TabContentsWrapper* contents, | 83 virtual void TabChangedAt(TabContentsWrapper* contents, |
84 int index, | 84 int index, |
85 TabChangeType change_type); | 85 TabChangeType change_type); |
86 | 86 |
87 // The tab contents was replaced at the specified index. This is invoked when | 87 // The tab contents was replaced at the specified index. This is invoked when |
88 // a tab becomes phantom. See description of phantom tabs in class description | 88 // instant is enabled and the user navigates by way of instant. |
89 // of TabStripModel for details. | 89 virtual void TabReplacedAt(TabStripModel* tab_strip_model, |
90 virtual void TabReplacedAt(TabContentsWrapper* old_contents, | 90 TabContentsWrapper* old_contents, |
91 TabContentsWrapper* new_contents, | 91 TabContentsWrapper* new_contents, |
92 int index); | 92 int index); |
93 | 93 |
94 // Invoked when the pinned state of a tab changes. See note in | 94 // Invoked when the pinned state of a tab changes. See note in |
95 // TabMiniStateChanged as to how this relates to TabMiniStateChanged. | 95 // TabMiniStateChanged as to how this relates to TabMiniStateChanged. |
96 virtual void TabPinnedStateChanged(TabContentsWrapper* contents, int index); | 96 virtual void TabPinnedStateChanged(TabContentsWrapper* contents, int index); |
97 | 97 |
98 // Invoked if the mini state of a tab changes. | 98 // Invoked if the mini state of a tab changes. |
99 // NOTE: this is sent when the pinned state of a non-app tab changes and is | 99 // NOTE: this is sent when the pinned state of a non-app tab changes and is |
100 // sent in addition to TabPinnedStateChanged. UI code typically need not care | 100 // sent in addition to TabPinnedStateChanged. UI code typically need not care |
(...skipping 12 matching lines...) Expand all Loading... |
113 | 113 |
114 // Sent when the tabstrip model is about to be deleted and any reference held | 114 // Sent when the tabstrip model is about to be deleted and any reference held |
115 // must be dropped. | 115 // must be dropped. |
116 virtual void TabStripModelDeleted(); | 116 virtual void TabStripModelDeleted(); |
117 | 117 |
118 protected: | 118 protected: |
119 virtual ~TabStripModelObserver() {} | 119 virtual ~TabStripModelObserver() {} |
120 }; | 120 }; |
121 | 121 |
122 #endif // CHROME_BROWSER_TABS_TAB_STRIP_MODEL_OBSERVER_H_ | 122 #endif // CHROME_BROWSER_TABS_TAB_STRIP_MODEL_OBSERVER_H_ |
OLD | NEW |