Index: chrome/browser/tabs/tab_strip_model_observer.cc |
diff --git a/chrome/browser/tabs/tab_strip_model_observer.cc b/chrome/browser/tabs/tab_strip_model_observer.cc |
index f20746abeeafac2624dbc4268f691f173f05d54e..b6d0fef6399d5fef4340ba4d56b6660847db0ccc 100644 |
--- a/chrome/browser/tabs/tab_strip_model_observer.cc |
+++ b/chrome/browser/tabs/tab_strip_model_observer.cc |
@@ -4,6 +4,8 @@ |
#include "chrome/browser/tabs/tab_strip_model_observer.h" |
+#include "chrome/browser/tabs/tab_strip_model.h" |
+ |
void TabStripModelObserver::TabInsertedAt(TabContentsWrapper* contents, |
int index, |
bool foreground) { |
@@ -21,6 +23,17 @@ void TabStripModelObserver::TabDetachedAt(TabContentsWrapper* contents, |
void TabStripModelObserver::TabDeselected(TabContentsWrapper* contents) { |
} |
+void TabStripModelObserver::TabSelectionChanged( |
+ TabStripModel* model, |
+ TabContentsWrapper* old_contents, |
+ bool user_gesture) { |
+ TabContentsWrapper* new_contents = model->GetSelectedTabContents(); |
+ if (new_contents != old_contents) { |
+ TabSelectedAt(old_contents, new_contents, model->selected_index(), |
+ user_gesture); |
+ } |
+} |
+ |
void TabStripModelObserver::TabSelectedAt(TabContentsWrapper* old_contents, |
TabContentsWrapper* new_contents, |
int index, |