| OLD | NEW | 
|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 #include "chrome/browser/ui/gtk/tabs/tab_strip_gtk.h" | 5 #include "chrome/browser/ui/gtk/tabs/tab_strip_gtk.h" | 
| 6 | 6 | 
| 7 #include <gtk/gtk.h> | 7 #include <gtk/gtk.h> | 
| 8 | 8 | 
| 9 #include <algorithm> | 9 #include <algorithm> | 
| 10 #include <string> | 10 #include <string> | 
| (...skipping 1074 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 1085       model_->selection_model().selected_indices().end(), | 1085       model_->selection_model().selected_indices().end(), | 
| 1086       it1); | 1086       it1); | 
| 1087   for (std::vector<int>::iterator it = indices_affected.begin(); | 1087   for (std::vector<int>::iterator it = indices_affected.begin(); | 
| 1088        it != indices_affected.end(); ++it) { | 1088        it != indices_affected.end(); ++it) { | 
| 1089     // SchedulePaint() has already been called for the active tab and | 1089     // SchedulePaint() has already been called for the active tab and | 
| 1090     // the previously active tab (if it still exists). | 1090     // the previously active tab (if it still exists). | 
| 1091     if (*it != model_->active_index() && *it != old_model.active()) | 1091     if (*it != model_->active_index() && *it != old_model.active()) | 
| 1092       GetTabAtAdjustForAnimation(*it)->SchedulePaint(); | 1092       GetTabAtAdjustForAnimation(*it)->SchedulePaint(); | 
| 1093   } | 1093   } | 
| 1094 | 1094 | 
| 1095   ui::ListSelectionModel::SelectedIndices no_longer_selected; | 1095   ui::ListSelectionModel::SelectedIndices no_longer_selected = | 
| 1096   std::insert_iterator<std::vector<int> > it2(no_longer_selected, | 1096       base::STLSetDifference<ui::ListSelectionModel::SelectedIndices>( | 
| 1097                                               no_longer_selected.begin()); | 1097           old_model.selected_indices(), | 
| 1098   std::set_difference(old_model.selected_indices().begin(), | 1098           model_->selection_model().selected_indices()); | 
| 1099                       old_model.selected_indices().end(), |  | 
| 1100                       model_->selection_model().selected_indices().begin(), |  | 
| 1101                       model_->selection_model().selected_indices().end(), |  | 
| 1102                       it2); |  | 
| 1103   for (std::vector<int>::iterator it = no_longer_selected.begin(); | 1099   for (std::vector<int>::iterator it = no_longer_selected.begin(); | 
| 1104        it != no_longer_selected.end(); ++it) { | 1100        it != no_longer_selected.end(); ++it) { | 
| 1105     GetTabAtAdjustForAnimation(*it)->StopMiniTabTitleAnimation(); | 1101     GetTabAtAdjustForAnimation(*it)->StopMiniTabTitleAnimation(); | 
| 1106   } | 1102   } | 
| 1107 } | 1103 } | 
| 1108 | 1104 | 
| 1109 void TabStripGtk::TabMoved(WebContents* contents, | 1105 void TabStripGtk::TabMoved(WebContents* contents, | 
| 1110                            int from_index, | 1106                            int from_index, | 
| 1111                            int to_index) { | 1107                            int to_index) { | 
| 1112   gfx::Rect start_bounds = GetIdealBounds(from_index); | 1108   gfx::Rect start_bounds = GetIdealBounds(from_index); | 
| (...skipping 1159 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 2272 | 2268 | 
| 2273 void TabStripGtk::SetNewTabButtonBackground() { | 2269 void TabStripGtk::SetNewTabButtonBackground() { | 
| 2274   SkColor color = theme_service_->GetColor( | 2270   SkColor color = theme_service_->GetColor( | 
| 2275       ThemeProperties::COLOR_BUTTON_BACKGROUND); | 2271       ThemeProperties::COLOR_BUTTON_BACKGROUND); | 
| 2276   SkBitmap background = theme_service_->GetImageNamed( | 2272   SkBitmap background = theme_service_->GetImageNamed( | 
| 2277       IDR_THEME_WINDOW_CONTROL_BACKGROUND).AsBitmap(); | 2273       IDR_THEME_WINDOW_CONTROL_BACKGROUND).AsBitmap(); | 
| 2278   SkBitmap mask = theme_service_->GetImageNamed( | 2274   SkBitmap mask = theme_service_->GetImageNamed( | 
| 2279       IDR_NEWTAB_BUTTON_MASK).AsBitmap(); | 2275       IDR_NEWTAB_BUTTON_MASK).AsBitmap(); | 
| 2280   newtab_button_->SetBackground(color, background, mask); | 2276   newtab_button_->SetBackground(color, background, mask); | 
| 2281 } | 2277 } | 
| OLD | NEW | 
|---|