/* -*- Mode: IDL; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /* This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. */ #include "nsISelectionDisplay.idl" %{C++ using SelectionRegion = short; namespace mozilla { namespace dom { class Selection; } // namespace dom struct ScrollAxis; enum class ScrollFlags : uint8_t; enum class SelectionScrollMode : uint8_t; // RawSelectionType should be used to store nsISelectionController::SELECTION_*. using RawSelectionType = short; // SelectionTypeMask should be used to store bit-mask of selection types. // The value can be retrieved with ToSelectionTypeMask() and checking if // a selection type is in a mask with |SelectionType & SelectionTypeMask|. using SelectionTypeMask = uint16_t; // SelectionType should be used in internal handling because of type safe. enum class SelectionType : RawSelectionType; } // namespace mozilla %} interface nsIContent; interface nsISelectionDisplay; webidl Node; webidl Selection; [builtinclass, scriptable, uuid(3801c9d4-8e69-4bfc-9edb-b58278621f8f)] interface nsISelectionController : nsISelectionDisplay { // Begin of RawSelectionType values. const short SELECTION_NONE = 0; // Corresponds to the Selection exposed via window.getSelection() and // document.getSelection(). const short SELECTION_NORMAL = 1; // Corresponds to the Selection used for spellchecking in