Index: chrome/browser/gtk/tabs/tab_strip_gtk.cc |
=================================================================== |
--- chrome/browser/gtk/tabs/tab_strip_gtk.cc (revision 25676) |
+++ chrome/browser/gtk/tabs/tab_strip_gtk.cc (working copy) |
@@ -1015,7 +1015,7 @@ |
bool loading_only) { |
// Index is in terms of the model. Need to make sure we adjust that index in |
// case we have an animation going. |
- TabGtk* tab = GetTabAt(index); |
+ TabGtk* tab = GetTabAtAdjustForAnimation(index); |
tab->UpdateData(contents, loading_only); |
tab->UpdateFromModel(); |
} |
@@ -1213,6 +1213,16 @@ |
return tab_data_.at(index).tab; |
} |
+TabGtk* TabStripGtk::GetTabAtAdjustForAnimation(int index) const { |
+ if (active_animation_.get() && |
+ active_animation_->type() == TabAnimation::REMOVE && |
+ index >= |
+ static_cast<RemoveTabAnimation*>(active_animation_.get())->index()) { |
+ index++; |
+ } |
+ return GetTabAt(index); |
+} |
+ |
void TabStripGtk::RemoveTabAt(int index) { |
TabGtk* removed = tab_data_.at(index).tab; |