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

Side by Side Diff: ui/views/controls/table/table_view.cc

Issue 1539583003: Convert Pass()→std::move() in ui/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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
« no previous file with comments | « ui/views/controls/styled_label.cc ('k') | ui/views/controls/textfield/textfield.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) 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 "ui/views/controls/table/table_view.h" 5 #include "ui/views/controls/table/table_view.h"
6 6
7 #include <map> 7 #include <map>
8 #include <utility>
8 9
9 #include "base/auto_reset.h" 10 #include "base/auto_reset.h"
10 #include "base/i18n/rtl.h" 11 #include "base/i18n/rtl.h"
11 #include "base/strings/string_util.h" 12 #include "base/strings/string_util.h"
12 #include "base/strings/utf_string_conversions.h" 13 #include "base/strings/utf_string_conversions.h"
13 #include "ui/accessibility/ax_view_state.h" 14 #include "ui/accessibility/ax_view_state.h"
14 #include "ui/events/event.h" 15 #include "ui/events/event.h"
15 #include "ui/gfx/canvas.h" 16 #include "ui/gfx/canvas.h"
16 #include "ui/gfx/geometry/rect_conversions.h" 17 #include "ui/gfx/geometry/rect_conversions.h"
17 #include "ui/gfx/image/image_skia.h" 18 #include "ui/gfx/image/image_skia.h"
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
169 ScrollView* scroll_view = ScrollView::CreateScrollViewWithBorder(); 170 ScrollView* scroll_view = ScrollView::CreateScrollViewWithBorder();
170 scroll_view->SetContents(this); 171 scroll_view->SetContents(this);
171 CreateHeaderIfNecessary(); 172 CreateHeaderIfNecessary();
172 if (header_) 173 if (header_)
173 scroll_view->SetHeader(header_); 174 scroll_view->SetHeader(header_);
174 return scroll_view; 175 return scroll_view;
175 } 176 }
176 177
177 void TableView::SetRowBackgroundPainter( 178 void TableView::SetRowBackgroundPainter(
178 scoped_ptr<TableViewRowBackgroundPainter> painter) { 179 scoped_ptr<TableViewRowBackgroundPainter> painter) {
179 row_background_painter_ = painter.Pass(); 180 row_background_painter_ = std::move(painter);
180 } 181 }
181 182
182 void TableView::SetGrouper(TableGrouper* grouper) { 183 void TableView::SetGrouper(TableGrouper* grouper) {
183 grouper_ = grouper; 184 grouper_ = grouper;
184 SortItemsAndUpdateMapping(); 185 SortItemsAndUpdateMapping();
185 } 186 }
186 187
187 int TableView::RowCount() const { 188 int TableView::RowCount() const {
188 return model_ ? model_->RowCount() : 0; 189 return model_ ? model_->RowCount() : 0;
189 } 190 }
(...skipping 755 matching lines...) Expand 10 before | Expand all | Expand 10 after
945 if (tooltip) 946 if (tooltip)
946 *tooltip = text; 947 *tooltip = text;
947 if (tooltip_origin) { 948 if (tooltip_origin) {
948 tooltip_origin->SetPoint(cell_bounds.x(), 949 tooltip_origin->SetPoint(cell_bounds.x(),
949 cell_bounds.y() + kTextVerticalPadding); 950 cell_bounds.y() + kTextVerticalPadding);
950 } 951 }
951 return true; 952 return true;
952 } 953 }
953 954
954 } // namespace views 955 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/controls/styled_label.cc ('k') | ui/views/controls/textfield/textfield.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698