| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "blimp/client/android/blimp_view.h" | 5 #include "blimp/client/android/blimp_view.h" |
| 6 | 6 |
| 7 #include <android/native_window_jni.h> | 7 #include <android/native_window_jni.h> |
| 8 | 8 |
| 9 #include "blimp/client/compositor/blimp_compositor_android.h" | 9 #include "blimp/client/compositor/blimp_compositor_android.h" |
| 10 #include "blimp/client/session/blimp_client_session_android.h" | 10 #include "blimp/client/session/blimp_client_session_android.h" |
| 11 #include "jni/BlimpView_jni.h" | 11 #include "jni/BlimpView_jni.h" |
| 12 #include "ui/events/android/motion_event_android.h" | 12 #include "ui/events/android/motion_event_android.h" |
| 13 #include "ui/gfx/geometry/size.h" | 13 #include "ui/gfx/geometry/size.h" |
| 14 | 14 |
| 15 namespace blimp { | 15 namespace blimp { |
| 16 namespace client { |
| 16 | 17 |
| 17 static jlong Init(JNIEnv* env, | 18 static jlong Init(JNIEnv* env, |
| 18 const JavaParamRef<jobject>& jobj, | 19 const JavaParamRef<jobject>& jobj, |
| 19 const JavaParamRef<jobject>& blimp_client_session, | 20 const JavaParamRef<jobject>& blimp_client_session, |
| 20 jint real_width, | 21 jint real_width, |
| 21 jint real_height, | 22 jint real_height, |
| 22 jint width, | 23 jint width, |
| 23 jint height, | 24 jint height, |
| 24 jfloat dp_to_px) { | 25 jfloat dp_to_px) { |
| 25 BlimpClientSession* client_session = | 26 BlimpClientSession* client_session = |
| (...skipping 143 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 169 android_button_state, | 170 android_button_state, |
| 170 android_meta_state, | 171 android_meta_state, |
| 171 raw_pos_x - pos_x_0, | 172 raw_pos_x - pos_x_0, |
| 172 raw_pos_y - pos_y_0, | 173 raw_pos_y - pos_y_0, |
| 173 pointer0, | 174 pointer0, |
| 174 pointer1); | 175 pointer1); |
| 175 | 176 |
| 176 return compositor_->OnTouchEvent(event); | 177 return compositor_->OnTouchEvent(event); |
| 177 } | 178 } |
| 178 | 179 |
| 180 } // namespace client |
| 179 } // namespace blimp | 181 } // namespace blimp |
| OLD | NEW |