| OLD | NEW |
| (Empty) |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 package org.chromium.chromoting; | |
| 6 | |
| 7 import org.chromium.chromoting.jni.Client; | |
| 8 | |
| 9 /** | |
| 10 * This interface allows multiple styles of touchscreen UI to be implemented and
dynamically | |
| 11 * switched. The DesktopView passes the low-level touchscreen events and other e
vents via this | |
| 12 * interface. The implementation recognizes and processes the touchscreen gestur
es, and then | |
| 13 * performs actions on the DesktopView (such as panning/zooming the display, inj
ecting input, or | |
| 14 * showing/hiding UI elements). All methods are called on the main UI thread. | |
| 15 */ | |
| 16 public interface TouchInputHandlerInterface { | |
| 17 // These constants must match those in the generated struct protocol::MouseE
vent_MouseButton. | |
| 18 int BUTTON_UNDEFINED = 0; | |
| 19 int BUTTON_LEFT = 1; | |
| 20 int BUTTON_MIDDLE = 2; | |
| 21 int BUTTON_RIGHT = 3; | |
| 22 | |
| 23 /** | |
| 24 * Initializes the instance. Implementations can assume this function will b
e called exactly | |
| 25 * once after constructor but before other functions. | |
| 26 */ | |
| 27 void init(Desktop desktop, Client client); | |
| 28 | |
| 29 /** | |
| 30 * Whilst an animation is in progress, this method is called repeatedly unti
l the animation is | |
| 31 * cancelled. After this method returns, the DesktopView will schedule a rep
aint. | |
| 32 */ | |
| 33 void processAnimation(); | |
| 34 } | |
| OLD | NEW |