| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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/views/tabs/tab_overview_controller.h" | 5 #include "chrome/browser/views/tabs/tab_overview_controller.h" |
| 6 | 6 |
| 7 #include "chrome/browser/browser.h" | 7 #include "chrome/browser/browser.h" |
| 8 #include "chrome/browser/browser_process.h" | 8 #include "chrome/browser/browser_process.h" |
| 9 #include "chrome/browser/gtk/browser_window_gtk.h" | 9 #include "chrome/browser/gtk/browser_window_gtk.h" |
| 10 #include "chrome/browser/tab_contents/tab_contents.h" | 10 #include "chrome/browser/tab_contents/tab_contents.h" |
| (...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 244 scoped_ptr<TabOverviewCell> child(grid_->GetTabOverviewCellAt(index)); | 244 scoped_ptr<TabOverviewCell> child(grid_->GetTabOverviewCellAt(index)); |
| 245 mutating_grid_ = true; | 245 mutating_grid_ = true; |
| 246 grid_->RemoveCell(index); | 246 grid_->RemoveCell(index); |
| 247 mutating_grid_ = false; | 247 mutating_grid_ = false; |
| 248 | 248 |
| 249 UpdateStartAndTargetBounds(); | 249 UpdateStartAndTargetBounds(); |
| 250 } | 250 } |
| 251 | 251 |
| 252 void TabOverviewController::TabMoved(TabContents* contents, | 252 void TabOverviewController::TabMoved(TabContents* contents, |
| 253 int from_index, | 253 int from_index, |
| 254 int to_index) { | 254 int to_index, |
| 255 bool pinned_state_changed) { |
| 255 if (!grid_->modifying_model()) | 256 if (!grid_->modifying_model()) |
| 256 grid_->CancelDrag(); | 257 grid_->CancelDrag(); |
| 257 | 258 |
| 258 mutating_grid_ = true; | 259 mutating_grid_ = true; |
| 259 grid_->MoveCell(from_index, to_index); | 260 grid_->MoveCell(from_index, to_index); |
| 260 mutating_grid_ = false; | 261 mutating_grid_ = false; |
| 261 | 262 |
| 262 UpdateStartAndTargetBounds(); | 263 UpdateStartAndTargetBounds(); |
| 263 } | 264 } |
| 264 | 265 |
| (...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 356 configure_timer_.Stop(); | 357 configure_timer_.Stop(); |
| 357 } | 358 } |
| 358 | 359 |
| 359 void TabOverviewController::StartDelayTimer() { | 360 void TabOverviewController::StartDelayTimer() { |
| 360 configure_timer_.Stop(); | 361 configure_timer_.Stop(); |
| 361 delay_timer_.Stop(); | 362 delay_timer_.Stop(); |
| 362 delay_timer_.Start( | 363 delay_timer_.Start( |
| 363 base::TimeDelta::FromMilliseconds(350), this, | 364 base::TimeDelta::FromMilliseconds(350), this, |
| 364 &TabOverviewController::StartConfiguring); | 365 &TabOverviewController::StartConfiguring); |
| 365 } | 366 } |
| OLD | NEW |