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

Side by Side Diff: ui/views/controls/textfield/textfield.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/table/table_view.cc ('k') | ui/views/controls/webview/webview.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/textfield/textfield.h" 5 #include "ui/views/controls/textfield/textfield.h"
6 6
7 #include <string> 7 #include <string>
8 #include <utility>
8 9
9 #include "base/trace_event/trace_event.h" 10 #include "base/trace_event/trace_event.h"
10 #include "ui/accessibility/ax_view_state.h" 11 #include "ui/accessibility/ax_view_state.h"
11 #include "ui/base/clipboard/scoped_clipboard_writer.h" 12 #include "ui/base/clipboard/scoped_clipboard_writer.h"
12 #include "ui/base/cursor/cursor.h" 13 #include "ui/base/cursor/cursor.h"
13 #include "ui/base/dragdrop/drag_drop_types.h" 14 #include "ui/base/dragdrop/drag_drop_types.h"
14 #include "ui/base/dragdrop/drag_utils.h" 15 #include "ui/base/dragdrop/drag_utils.h"
15 #include "ui/base/ime/input_method.h" 16 #include "ui/base/ime/input_method.h"
16 #include "ui/base/touch/selection_bound.h" 17 #include "ui/base/touch/selection_bound.h"
17 #include "ui/base/ui_base_switches_util.h" 18 #include "ui/base/ui_base_switches_util.h"
(...skipping 538 matching lines...) Expand 10 before | Expand all | Expand 10 after
556 557
557 void Textfield::SetAccessibleName(const base::string16& name) { 558 void Textfield::SetAccessibleName(const base::string16& name) {
558 accessible_name_ = name; 559 accessible_name_ = name;
559 } 560 }
560 561
561 void Textfield::ExecuteCommand(int command_id) { 562 void Textfield::ExecuteCommand(int command_id) {
562 ExecuteCommand(command_id, ui::EF_NONE); 563 ExecuteCommand(command_id, ui::EF_NONE);
563 } 564 }
564 565
565 void Textfield::SetFocusPainter(scoped_ptr<Painter> focus_painter) { 566 void Textfield::SetFocusPainter(scoped_ptr<Painter> focus_painter) {
566 focus_painter_ = focus_painter.Pass(); 567 focus_painter_ = std::move(focus_painter);
567 } 568 }
568 569
569 bool Textfield::HasTextBeingDragged() { 570 bool Textfield::HasTextBeingDragged() {
570 return initiating_drag_; 571 return initiating_drag_;
571 } 572 }
572 573
573 //////////////////////////////////////////////////////////////////////////////// 574 ////////////////////////////////////////////////////////////////////////////////
574 // Textfield, View overrides: 575 // Textfield, View overrides:
575 576
576 gfx::Insets Textfield::GetInsets() const { 577 gfx::Insets Textfield::GetInsets() const {
(...skipping 1314 matching lines...) Expand 10 before | Expand all | Expand 10 after
1891 RequestFocus(); 1892 RequestFocus();
1892 model_->MoveCursorTo(mouse); 1893 model_->MoveCursorTo(mouse);
1893 if (!selection_clipboard_text.empty()) { 1894 if (!selection_clipboard_text.empty()) {
1894 model_->InsertText(selection_clipboard_text); 1895 model_->InsertText(selection_clipboard_text);
1895 UpdateAfterChange(true, true); 1896 UpdateAfterChange(true, true);
1896 } 1897 }
1897 OnAfterUserAction(); 1898 OnAfterUserAction();
1898 } 1899 }
1899 1900
1900 } // namespace views 1901 } // namespace views
OLDNEW
« no previous file with comments | « ui/views/controls/table/table_view.cc ('k') | ui/views/controls/webview/webview.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698