| Index: remoting/client/input_strategy.h
|
| diff --git a/remoting/client/input_strategy.h b/remoting/client/input_strategy.h
|
| index 5f171681a61f96514eab8f3d795be789ed2ef1f1..8f14581b4cbf424422783b0493c48e2526432755 100644
|
| --- a/remoting/client/input_strategy.h
|
| +++ b/remoting/client/input_strategy.h
|
| @@ -13,6 +13,11 @@ class DesktopViewport;
|
| // are handled.
|
| class InputStrategy {
|
| public:
|
| + enum InputFeedbackType {
|
| + TAP_FEEDBACK,
|
| + LONG_PRESS_FEEDBACK,
|
| + };
|
| +
|
| virtual ~InputStrategy() {}
|
|
|
| // Called when the GestureInterpreter receives a pinch gesture. The
|
| @@ -33,14 +38,21 @@ class InputStrategy {
|
| bool is_dragging_mode,
|
| DesktopViewport* viewport) = 0;
|
|
|
| - // Called when a gesture is done at location (touch_x, touch_y) and the
|
| - // GestureInterpreter needs to get back the cursor position to inject mouse
|
| - // the mouse event.
|
| - virtual void FindCursorPositions(float touch_x,
|
| - float touch_y,
|
| - const DesktopViewport& viewport,
|
| - float* cursor_x,
|
| - float* cursor_y) = 0;
|
| + // Called when a touch input (which will end up injecting a mouse event at
|
| + // certain position in the host) is done at location (touch_x, touch_y).
|
| + // The implementation should move the cursor to proper position.
|
| + virtual void TrackTouchInput(float touch_x,
|
| + float touch_y,
|
| + const DesktopViewport& viewport) = 0;
|
| +
|
| + // Writes the cursor position to cursor_x and cursor_y.
|
| + virtual void GetCursorPosition(float* cursor_x, float* cursor_y) const = 0;
|
| +
|
| + // Returns the maximum radius of the feedback animation on the surface's
|
| + // coordinate for the given input type. The feedback will then be shown on the
|
| + // cursor positions returned by FindCursorPositions(). Return 0 if no feedback
|
| + // should be shown.
|
| + virtual float GetFeedbackRadius(InputFeedbackType type) const = 0;
|
|
|
| // Returns true if the input strategy maintains a visible cursor on the
|
| // desktop.
|
|
|