Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(521)

Side by Side Diff: chrome/browser/tabs/tab_strip_model_order_controller.cc

Issue 5582002: Move:... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 10 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/tabs/tab_strip_model.cc ('k') | chrome/browser/tabs/tab_strip_model_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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 #include "chrome/browser/tabs/tab_strip_model_order_controller.h" 5 #include "chrome/browser/tabs/tab_strip_model_order_controller.h"
6 6
7 #include "chrome/browser/tab_contents_wrapper.h" 7 #include "chrome/browser/ui/tab_contents/tab_contents_wrapper.h"
8 8
9 /////////////////////////////////////////////////////////////////////////////// 9 ///////////////////////////////////////////////////////////////////////////////
10 // TabStripModelOrderController, public: 10 // TabStripModelOrderController, public:
11 11
12 TabStripModelOrderController::TabStripModelOrderController( 12 TabStripModelOrderController::TabStripModelOrderController(
13 TabStripModel* tabstrip) 13 TabStripModel* tabstrip)
14 : tabstrip_(tabstrip), 14 : tabstrip_(tabstrip),
15 insertion_policy_(TabStripModel::INSERT_AFTER) { 15 insertion_policy_(TabStripModel::INSERT_AFTER) {
16 tabstrip_->AddObserver(this); 16 tabstrip_->AddObserver(this);
17 } 17 }
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 132
133 /////////////////////////////////////////////////////////////////////////////// 133 ///////////////////////////////////////////////////////////////////////////////
134 // TabStripModelOrderController, private: 134 // TabStripModelOrderController, private:
135 135
136 int TabStripModelOrderController::GetValidIndex( 136 int TabStripModelOrderController::GetValidIndex(
137 int index, int removing_index) const { 137 int index, int removing_index) const {
138 if (removing_index < index) 138 if (removing_index < index)
139 index = std::max(0, index - 1); 139 index = std::max(0, index - 1);
140 return index; 140 return index;
141 } 141 }
OLDNEW
« no previous file with comments | « chrome/browser/tabs/tab_strip_model.cc ('k') | chrome/browser/tabs/tab_strip_model_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698