diff options
author | boliu <boliu@chromium.org> | 2015-10-28 14:38:34 -0700 |
---|---|---|
committer | Commit bot <commit-bot@chromium.org> | 2015-10-28 21:39:22 +0000 |
commit | 6d9425ec7badda912555d46ea7abcfab81fdd9b9 (patch) | |
tree | 0a6b83484eb8ebfad12622eec703c10d9678a498 /android_webview/native | |
parent | 083ca00e0870a86c974066236f53a09475fee4dc (diff) | |
download | chromium_src-6d9425ec7badda912555d46ea7abcfab81fdd9b9.zip chromium_src-6d9425ec7badda912555d46ea7abcfab81fdd9b9.tar.gz chromium_src-6d9425ec7badda912555d46ea7abcfab81fdd9b9.tar.bz2 |
sync compositor: pass simple gfx types by const ref
See bug for reasoning
BUG=159273
Review URL: https://codereview.chromium.org/1417893006
Cr-Commit-Position: refs/heads/master@{#356653}
Diffstat (limited to 'android_webview/native')
-rw-r--r-- | android_webview/native/aw_contents.cc | 10 | ||||
-rw-r--r-- | android_webview/native/aw_contents.h | 10 |
2 files changed, 10 insertions, 10 deletions
diff --git a/android_webview/native/aw_contents.cc b/android_webview/native/aw_contents.cc index 6a46d1d..e10eab6 100644 --- a/android_webview/native/aw_contents.cc +++ b/android_webview/native/aw_contents.cc @@ -1004,7 +1004,7 @@ gfx::Point AwContents::GetLocationOnScreen() { return gfx::Point(location[0], location[1]); } -void AwContents::ScrollContainerViewTo(gfx::Vector2d new_value) { +void AwContents::ScrollContainerViewTo(const gfx::Vector2d& new_value) { DCHECK_CURRENTLY_ON(BrowserThread::UI); JNIEnv* env = AttachCurrentThread(); ScopedJavaLocalRef<jobject> obj = java_ref_.get(env); @@ -1014,8 +1014,8 @@ void AwContents::ScrollContainerViewTo(gfx::Vector2d new_value) { env, obj.obj(), new_value.x(), new_value.y()); } -void AwContents::UpdateScrollState(gfx::Vector2d max_scroll_offset, - gfx::SizeF contents_size_dip, +void AwContents::UpdateScrollState(const gfx::Vector2d& max_scroll_offset, + const gfx::SizeF& contents_size_dip, float page_scale_factor, float min_page_scale_factor, float max_page_scale_factor) { @@ -1035,8 +1035,8 @@ void AwContents::UpdateScrollState(gfx::Vector2d max_scroll_offset, max_page_scale_factor); } -void AwContents::DidOverscroll(gfx::Vector2d overscroll_delta, - gfx::Vector2dF overscroll_velocity) { +void AwContents::DidOverscroll(const gfx::Vector2d& overscroll_delta, + const gfx::Vector2dF& overscroll_velocity) { DCHECK_CURRENTLY_ON(BrowserThread::UI); JNIEnv* env = AttachCurrentThread(); ScopedJavaLocalRef<jobject> obj = java_ref_.get(env); diff --git a/android_webview/native/aw_contents.h b/android_webview/native/aw_contents.h index 56b4d16..8edd1c0 100644 --- a/android_webview/native/aw_contents.h +++ b/android_webview/native/aw_contents.h @@ -206,14 +206,14 @@ class AwContents : public FindHelper::Listener, void DetachFunctorFromView() override; void OnNewPicture() override; gfx::Point GetLocationOnScreen() override; - void ScrollContainerViewTo(gfx::Vector2d new_value) override; - void UpdateScrollState(gfx::Vector2d max_scroll_offset, - gfx::SizeF contents_size_dip, + void ScrollContainerViewTo(const gfx::Vector2d& new_value) override; + void UpdateScrollState(const gfx::Vector2d& max_scroll_offset, + const gfx::SizeF& contents_size_dip, float page_scale_factor, float min_page_scale_factor, float max_page_scale_factor) override; - void DidOverscroll(gfx::Vector2d overscroll_delta, - gfx::Vector2dF overscroll_velocity) override; + void DidOverscroll(const gfx::Vector2d& overscroll_delta, + const gfx::Vector2dF& overscroll_velocity) override; void ParentDrawConstraintsUpdated( const ParentCompositorDrawConstraints& draw_constraints) override {} |