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

Side by Side Diff: services/native_viewport/platform_viewport_android.h

Issue 1029753002: Plumbs through android supplying multipe touch points (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: cleanup Created 5 years, 9 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #ifndef SERVICES_NATIVE_VIEWPORT_PLATFORM_VIEWPORT_ANDROID_H_ 5 #ifndef SERVICES_NATIVE_VIEWPORT_PLATFORM_VIEWPORT_ANDROID_H_
6 #define SERVICES_NATIVE_VIEWPORT_PLATFORM_VIEWPORT_ANDROID_H_ 6 #define SERVICES_NATIVE_VIEWPORT_PLATFORM_VIEWPORT_ANDROID_H_
7 7
8 #include "base/android/jni_weak_ref.h" 8 #include "base/android/jni_weak_ref.h"
9 #include "base/android/scoped_java_ref.h" 9 #include "base/android/scoped_java_ref.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 20 matching lines...) Expand all
31 virtual ~PlatformViewportAndroid(); 31 virtual ~PlatformViewportAndroid();
32 32
33 void Destroy(JNIEnv* env, jobject obj); 33 void Destroy(JNIEnv* env, jobject obj);
34 void SurfaceCreated(JNIEnv* env, jobject obj, jobject jsurface); 34 void SurfaceCreated(JNIEnv* env, jobject obj, jobject jsurface);
35 void SurfaceDestroyed(JNIEnv* env, jobject obj); 35 void SurfaceDestroyed(JNIEnv* env, jobject obj);
36 void SurfaceSetSize(JNIEnv* env, 36 void SurfaceSetSize(JNIEnv* env,
37 jobject obj, 37 jobject obj,
38 jint width, 38 jint width,
39 jint height, 39 jint height,
40 jfloat density); 40 jfloat density);
41 bool TouchEvent(JNIEnv* env, jobject obj, jint pointer_id, jint action, 41 bool TouchEvent(JNIEnv* env,
42 jfloat x, jfloat y, jlong time_ms); 42 jobject obj,
43 jobject motion_event,
44 jlong time_ms,
45 jint masked_action,
46 jint pointer_id,
47 jfloat x,
48 jfloat y,
49 jfloat pressure,
50 jfloat touch_major,
51 jfloat touch_minor,
52 jfloat orientation,
53 jfloat h_wheel,
54 jfloat v_wheel);
43 bool KeyEvent(JNIEnv* env, 55 bool KeyEvent(JNIEnv* env,
44 jobject obj, 56 jobject obj,
45 bool pressed, 57 bool pressed,
46 jint key_code, 58 jint key_code,
47 jint unicode_character); 59 jint unicode_character);
48 60
49 private: 61 private:
50 // Overridden from PlatformViewport: 62 // Overridden from PlatformViewport:
51 virtual void Init(const gfx::Rect& bounds) override; 63 virtual void Init(const gfx::Rect& bounds) override;
52 virtual void Show() override; 64 virtual void Show() override;
(...skipping 10 matching lines...) Expand all
63 ui::SequentialIDGenerator id_generator_; 75 ui::SequentialIDGenerator id_generator_;
64 76
65 base::WeakPtrFactory<PlatformViewportAndroid> weak_factory_; 77 base::WeakPtrFactory<PlatformViewportAndroid> weak_factory_;
66 78
67 DISALLOW_COPY_AND_ASSIGN(PlatformViewportAndroid); 79 DISALLOW_COPY_AND_ASSIGN(PlatformViewportAndroid);
68 }; 80 };
69 81
70 } // namespace native_viewport 82 } // namespace native_viewport
71 83
72 #endif // SERVICES_NATIVE_VIEWPORT_PLATFORM_VIEWPORT_ANDROID_H_ 84 #endif // SERVICES_NATIVE_VIEWPORT_PLATFORM_VIEWPORT_ANDROID_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698