| Index: content/common/input/input_handler.mojom | 
| diff --git a/content/common/input/input_handler.mojom b/content/common/input/input_handler.mojom | 
| new file mode 100644 | 
| index 0000000000000000000000000000000000000000..fae10f96c1d3d7eacec511775e4f7800e2e404a8 | 
| --- /dev/null | 
| +++ b/content/common/input/input_handler.mojom | 
| @@ -0,0 +1,84 @@ | 
| +// Copyright 2017 The Chromium Authors. All rights reserved. | 
| +// Use of this source code is governed by a BSD-style license that can be | 
| +// found in the LICENSE file. | 
| + | 
| +module content.mojom; | 
| + | 
| +import "mojo/common/string16.mojom"; | 
| +import "services/ui/public/interfaces/ime/ime.mojom"; | 
| +import "ui/gfx/geometry/mojo/geometry.mojom"; | 
| + | 
| +interface WidgetInputHandler { | 
| +  // TODO(dtapuska): Implement me. | 
| +}; | 
| + | 
| +// This interface provides the input actions associated with the RenderFrame. | 
| +// Other input actions may also be dispatched via the WidgetInputHandler | 
| +// interface. If frame input actions are dispatched the WidgetInputHandler | 
| +// should be fetched via the associated interface request so that input calls | 
| +// remain in order. See https://goo.gl/x4ee8A for more details. | 
| +interface FrameInputHandler { | 
| +  // Sets the text composition to be between the given start and end offsets in | 
| +  // the currently focused editable field. | 
| +  SetCompositionFromExistingText( | 
| +      int32 start, int32 end, array<ui.mojom.CompositionUnderline> underlines); | 
| + | 
| +  // Deletes the current selection plus the specified number of characters | 
| +  // before and after the selection or caret. | 
| +  ExtendSelectionAndDelete(int32 before, int32 after); | 
| + | 
| +  // Deletes text before and after the current cursor position, excluding the | 
| +  // selection. The lengths are supplied in Java chars (UTF-16 Code Unit), | 
| +  // not in code points or in glyphs. | 
| +  DeleteSurroundingText(int32 before, int32 after); | 
| + | 
| +  // Deletes text before and after the current cursor position, excluding the | 
| +  // selection. The lengths are supplied in code points, not in Java chars | 
| +  // (UTF-16 Code Unit) or in glyphs. Does nothing if there are one or more | 
| +  // invalid surrogate pairs in the requested range | 
| +  DeleteSurroundingTextInCodePoints(int32 before, int32 after); | 
| + | 
| +  // Selects between the given start and end offsets in the currently focused | 
| +  // editable field. | 
| +  SetEditableSelectionOffsets(int32 start, int32 end); | 
| + | 
| +  // Message payload is the name/value of a WebCore edit command to execute. | 
| +  ExecuteEditCommand(string command, mojo.common.mojom.String16? value); | 
| + | 
| +  // These messages are typically generated from context menus and request the | 
| +  // renderer to apply the specified operation to the current selection. | 
| +  Undo(); | 
| +  Redo(); | 
| +  Cut(); | 
| +  Copy(); | 
| +  CopyToFindPboard(); | 
| +  Paste(); | 
| +  PasteAndMatchStyle(); | 
| +  Delete(); | 
| +  SelectAll(); | 
| +  CollapseSelection(); | 
| + | 
| +  // Replaces the selected region or a word around the cursor with the | 
| +  // specified string. | 
| +  Replace(mojo.common.mojom.String16 word); | 
| + | 
| +  // Replaces the misspelling in the selected region with the specified string. | 
| +  ReplaceMisspelling(mojo.common.mojom.String16 word); | 
| + | 
| +  // Requests the renderer to select the region between two points. | 
| +  // Expects a SelectRange_ACK message when finished. | 
| +  SelectRange(gfx.mojom.Point base, gfx.mojom.Point extent); | 
| + | 
| +  // Sent by the browser to ask the renderer to adjust the selection start and | 
| +  // end points by the given amounts. A negative amount moves the selection | 
| +  // towards the beginning of the document, a positive amount moves the | 
| +  // selection towards the end of the document. | 
| +  AdjustSelectionByCharacterOffset(int32 start, int32 end); | 
| + | 
| +  // Requests the renderer to move the selection extent point to a new position. | 
| +  // Expects a MoveRangeSelectionExtent_ACK message when finished. | 
| +  MoveRangeSelectionExtent(gfx.mojom.Point extent); | 
| + | 
| +  // TODO(dtapuska): Implement WidgetInputHandler. | 
| +  // GetWidgetInputHandler(associated WidgetInputHandler& interface_request); | 
| +}; | 
|  |