5 AccessibleCaret is a pair of raindrop shape handles at both ends of selection
6 highlight, or it is a single handle at the blinking caret in a text area. It
7 assists the user to change the range of the selection highlight or the position
8 of the blinking caret on platforms with touch-event support.
14 `Bug 1124074 <https://bugzilla.mozilla.org/show_bug.cgi?id=1124074>`__ tracks all the open issues.
17 Gecko implementation details
18 ============================
22 * ``layout.accessiblecaret.enabled_on_touch`` (Enabled on Firefox with touch-event support since 51.)
23 * ``layout.accessiblecaret.enabled`` (Defaults off, but it can be turn on to force enable AccessibleCaret.)
24 * ``layout.accessiblecaret.hide_carets_for_mouse_input`` (Defaults on. Turn
25 this on to debug AccessibleCaret on desktop browser with mouse events.)
27 AccessibleCaretEventHub State Transition Diagram
28 ------------------------------------------------
30 This diagram depicts the state transition of the state machine in
31 AccessibleCaretEventHub, which handles external events and callbacks.
33 Note that the diagram omits some callbacks which do not cause a state transition
34 such as ``NotifySelectionChanged`` or ``Reflow``.
36 This table is a mapping of the real events and callback to the actions described
37 on the edge of the diagram:
39 +---------------------------------------------------+--------------+
40 | Real events or callbacks | Actions |
41 +===================================================+==============+
42 | ``eMouseDown`` or ``eTouchStart`` | Press |
43 +---------------------------------------------------+--------------+
44 | ``eMouseMove`` or ``eTouchMove`` | Move |
45 +---------------------------------------------------+--------------+
46 | ``eMouseUp`` or ``eTouchEnd`` or ``eTouchCancel`` | Release |
47 +---------------------------------------------------+--------------+
48 | ``eMouseLongTap`` | Long tap |
49 +---------------------------------------------------+--------------+
50 | ``AsyncPanZoomStarted()`` | Scroll start |
51 +---------------------------------------------------+--------------+
52 | ``AsyncPanZoomStopped()`` | Scroll end |
53 +---------------------------------------------------+--------------+
54 | ``NotifyBlur()`` | Blur |
55 +---------------------------------------------------+--------------+
57 .. image:: AccessibleCaretEventHubStates.png
62 * Dump AccessibleCaret log from command line: run ``MOZ_LOG=AccessibleCaret:5 ./mach run``.
63 * Dump AccessibleCaret log by using a preference: Open ``about:config`` and add a pref ``logging.AccessibleCaret`` with value ``debug`` or ``verbose`` (case matters).
64 * ``AC_LOG()`` is useful to add new logs.
73 * Ting-Yu Lin <aethanyc@gmail.com>
78 * Morris Tseng <mtseng@mozilla.com>
79 * Jeremy Chen <jeremychen@mozilla.com>
80 * Boris Chiou <boris@mozilla.com>*