Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef UI_ANDROID_VIEW_CLIENT_H_ | |
| 6 #define UI_ANDROID_VIEW_CLIENT_H_ | |
| 7 | |
| 8 #include <jni.h> | |
| 9 | |
| 10 #include "ui/android/ui_android_export.h" | |
| 11 #include "ui/events/android/motion_event_android.h" | |
|
boliu
2017/02/27 19:21:57
forward declare is enough
Jinsuk Kim
2017/02/28 06:56:04
Done.
| |
| 12 | |
| 13 namespace ui { | |
| 14 | |
| 15 // Client interface used to forward events from Java to native views. | |
| 16 // Calls are dispatched to its children along the hierarchy of ViewAndroid. | |
| 17 // Use bool return type to stop propagating the call i.e. overriden method | |
| 18 // should return true to indicate that the event was handled and stop | |
| 19 // the processing. | |
| 20 class UI_ANDROID_EXPORT ViewClient { | |
| 21 public: | |
| 22 virtual bool OnTouchEvent(const MotionEventAndroid& event, | |
| 23 bool is_touch_handle_event); | |
| 24 virtual bool OnMouseEvent(const MotionEventAndroid& event, int action_button); | |
| 25 }; | |
| 26 | |
| 27 } // namespace ui | |
| 28 | |
| 29 #endif // UI_ANDROID_VIEW_CLIENT_H_ | |
| OLD | NEW |