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

Side by Side Diff: ui/events/gestures/blink/web_gesture_curve_impl.cc

Issue 1557553002: Global conversion of Pass()→std::move() on OS=android (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 months 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/events/gestures/blink/web_gesture_curve_impl.h" 5 #include "ui/events/gestures/blink/web_gesture_curve_impl.h"
6 6
7 #include <limits.h> 7 #include <limits.h>
8 8
9 #include <utility> 9 #include <utility>
10 10
(...skipping 22 matching lines...) Expand all
33 auto scroller = make_scoped_ptr(new Scroller(Scroller::Config())); 33 auto scroller = make_scoped_ptr(new Scroller(Scroller::Config()));
34 scroller->Fling(0, 34 scroller->Fling(0,
35 0, 35 0,
36 initial_velocity.x(), 36 initial_velocity.x(),
37 initial_velocity.y(), 37 initial_velocity.y(),
38 INT_MIN, 38 INT_MIN,
39 INT_MAX, 39 INT_MAX,
40 INT_MIN, 40 INT_MIN,
41 INT_MAX, 41 INT_MAX,
42 base::TimeTicks()); 42 base::TimeTicks());
43 return scroller.Pass(); 43 return std::move(scroller);
44 #else 44 #else
45 return make_scoped_ptr( 45 return make_scoped_ptr(
46 new FlingCurve(initial_velocity, base::TimeTicks())); 46 new FlingCurve(initial_velocity, base::TimeTicks()));
47 #endif 47 #endif
48 } 48 }
49 49
50 } // namespace 50 } // namespace
51 51
52 // static 52 // static
53 scoped_ptr<WebGestureCurve> WebGestureCurveImpl::CreateFromDefaultPlatformCurve( 53 scoped_ptr<WebGestureCurve> WebGestureCurveImpl::CreateFromDefaultPlatformCurve(
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after
136 return still_active; 136 return still_active;
137 137
138 // scrollBy() could delete this curve if the animation is over, so don't touch 138 // scrollBy() could delete this curve if the animation is over, so don't touch
139 // any member variables after making that call. 139 // any member variables after making that call.
140 bool did_scroll = target->scrollBy(blink::WebFloatSize(delta), 140 bool did_scroll = target->scrollBy(blink::WebFloatSize(delta),
141 blink::WebFloatSize(velocity)); 141 blink::WebFloatSize(velocity));
142 return did_scroll && still_active; 142 return did_scroll && still_active;
143 } 143 }
144 144
145 } // namespace ui 145 } // namespace ui
OLDNEW
« no previous file with comments | « third_party/mojo/src/mojo/edk/embedder/simple_platform_shared_buffer_android.cc ('k') | ui/snapshot/snapshot_android.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698