Bug 1885489 - Part 5: Add SnapshotIterator::readInt32(). r=iain
[gecko.git] / dom / webidl / CaretStateChangedEvent.webidl
blob0a661fe737331f496c379cfe38cbdf313dca6aca
1 /* -*- Mode: IDL; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* This Source Code Form is subject to the terms of the Mozilla Public
3  * License, v. 2.0. If a copy of the MPL was not distributed with this file,
4  * You can obtain one at http://mozilla.org/MPL/2.0/.
5  */
7 enum CaretChangedReason {
8   "visibilitychange",
9   "updateposition",
10   "longpressonemptycontent",
11   "taponcaret",
12   "presscaret",
13   "releasecaret",
14   "scroll",
15   "dragcaret"
18 dictionary CaretStateChangedEventInit : EventInit {
19   boolean collapsed = true;
20   DOMRectReadOnly? boundingClientRect = null;
21   CaretChangedReason reason = "visibilitychange";
22   boolean caretVisible = false;
23   boolean caretVisuallyVisible = false;
24   boolean selectionVisible = false;
25   boolean selectionEditable = false;
26   DOMString selectedTextContent = "";
27   long clientX = 0;
28   long clientY = 0;
31 [ChromeOnly,
32  Exposed=Window]
33 interface CaretStateChangedEvent : Event {
34   constructor(DOMString type,
35               optional CaretStateChangedEventInit eventInit = {});
37   readonly attribute boolean collapsed;
38   /* The bounding client rect is relative to the visual viewport. */
39   readonly attribute DOMRectReadOnly? boundingClientRect;
40   readonly attribute CaretChangedReason reason;
41   readonly attribute boolean caretVisible;
42   readonly attribute boolean caretVisuallyVisible;
43   readonly attribute boolean selectionVisible;
44   readonly attribute boolean selectionEditable;
45   readonly attribute DOMString selectedTextContent;
46   [Pref="layout.accessiblecaret.magnifier.enabled"]
47   readonly attribute long clientX;
48   [Pref="layout.accessiblecaret.magnifier.enabled"]
49   readonly attribute long clientY;