2007-03-27 16:17:11 +04:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
2012-05-21 15:12:37 +04:00
|
|
|
/* 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/. */
|
2007-03-27 16:17:11 +04:00
|
|
|
|
2008-10-16 05:52:58 +04:00
|
|
|
#ifndef nsCoreUtils_h_
|
|
|
|
#define nsCoreUtils_h_
|
2007-03-27 16:17:11 +04:00
|
|
|
|
2015-08-26 15:56:59 +03:00
|
|
|
#include "mozilla/EventForwards.h"
|
2016-01-21 04:52:43 +03:00
|
|
|
#include "nsIAccessibleEvent.h"
|
2007-05-09 01:44:04 +04:00
|
|
|
#include "nsIContent.h"
|
2020-04-15 04:01:12 +03:00
|
|
|
#include "mozilla/FlushType.h"
|
2020-05-01 07:28:35 +03:00
|
|
|
#include "mozilla/PresShellForwards.h"
|
2009-05-06 13:54:26 +04:00
|
|
|
|
2007-09-05 11:39:09 +04:00
|
|
|
#include "nsPoint.h"
|
2010-04-27 10:52:03 +04:00
|
|
|
#include "nsTArray.h"
|
2022-01-19 02:31:21 +03:00
|
|
|
#include "Units.h"
|
2007-03-27 16:17:11 +04:00
|
|
|
|
2012-04-06 22:08:24 +04:00
|
|
|
class nsRange;
|
2018-06-06 06:01:36 +03:00
|
|
|
class nsTreeColumn;
|
2012-08-01 22:31:10 +04:00
|
|
|
class nsIFrame;
|
2013-02-13 02:02:51 +04:00
|
|
|
class nsIDocShell;
|
2012-08-01 22:31:10 +04:00
|
|
|
class nsIWidget;
|
2012-04-06 22:08:24 +04:00
|
|
|
|
2018-12-04 19:25:30 +03:00
|
|
|
namespace mozilla {
|
2019-04-13 15:13:15 +03:00
|
|
|
class PresShell;
|
2018-12-04 19:25:30 +03:00
|
|
|
namespace dom {
|
2020-11-23 19:07:43 +03:00
|
|
|
class Document;
|
2018-12-04 19:25:30 +03:00
|
|
|
class XULTreeElement;
|
2020-11-23 19:07:43 +03:00
|
|
|
} // namespace dom
|
2018-12-04 19:25:30 +03:00
|
|
|
} // namespace mozilla
|
|
|
|
|
2010-04-27 10:52:03 +04:00
|
|
|
/**
|
|
|
|
* Core utils.
|
|
|
|
*/
|
2008-10-16 05:52:58 +04:00
|
|
|
class nsCoreUtils {
|
2007-03-27 16:17:11 +04:00
|
|
|
public:
|
2019-04-13 15:13:15 +03:00
|
|
|
typedef mozilla::PresShell PresShell;
|
2019-01-02 16:05:23 +03:00
|
|
|
typedef mozilla::dom::Document Document;
|
|
|
|
|
2016-01-14 23:37:15 +03:00
|
|
|
/**
|
|
|
|
* Return true if the given node is a label of a control.
|
|
|
|
*/
|
|
|
|
static bool IsLabelWithControl(nsIContent* aContent);
|
|
|
|
|
2007-07-05 20:02:55 +04:00
|
|
|
/**
|
2010-02-03 18:00:25 +03:00
|
|
|
* Return true if the given node has registered click, mousedown or mouseup
|
|
|
|
* event listeners.
|
2007-07-05 20:02:55 +04:00
|
|
|
*/
|
2011-09-29 10:19:26 +04:00
|
|
|
static bool HasClickListener(nsIContent* aContent);
|
2007-07-05 20:02:55 +04:00
|
|
|
|
2008-08-06 16:16:54 +04:00
|
|
|
/**
|
2009-08-20 10:45:19 +04:00
|
|
|
* Dispatch click event to XUL tree cell.
|
2008-08-06 16:16:54 +04:00
|
|
|
*
|
2018-12-04 19:25:30 +03:00
|
|
|
* @param aTree [in] tree
|
2009-08-20 10:45:19 +04:00
|
|
|
* @param aRowIndex [in] row index
|
|
|
|
* @param aColumn [in] column object
|
2018-12-04 19:25:30 +03:00
|
|
|
* @param aPseudoElm [in] pseudo element inside the cell, see
|
2019-03-01 20:26:37 +03:00
|
|
|
* XULTreeElement for available values
|
2009-08-20 10:45:19 +04:00
|
|
|
*/
|
2019-04-13 15:13:13 +03:00
|
|
|
MOZ_CAN_RUN_SCRIPT
|
2018-12-04 19:25:30 +03:00
|
|
|
static void DispatchClickEvent(mozilla::dom::XULTreeElement* aTree,
|
2018-06-06 06:01:36 +03:00
|
|
|
int32_t aRowIndex, nsTreeColumn* aColumn,
|
2020-09-23 18:17:15 +03:00
|
|
|
const nsAString& aPseudoElt = u""_ns);
|
2009-08-20 10:45:19 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Send mouse event to the given element.
|
|
|
|
*
|
2015-08-26 15:56:59 +03:00
|
|
|
* @param aMessage [in] an event message (see EventForwards.h)
|
2013-07-25 19:59:08 +04:00
|
|
|
* @param aX [in] x coordinate in dev pixels
|
|
|
|
* @param aY [in] y coordinate in dev pixels
|
|
|
|
* @param aContent [in] the element
|
|
|
|
* @param aFrame [in] frame of the element
|
|
|
|
* @param aPresShell [in] the presshell for the element
|
|
|
|
* @param aRootWidget [in] the root widget of the element
|
2008-08-06 16:16:54 +04:00
|
|
|
*/
|
2019-04-13 15:13:13 +03:00
|
|
|
MOZ_CAN_RUN_SCRIPT
|
2015-08-26 15:56:59 +03:00
|
|
|
static void DispatchMouseEvent(mozilla::EventMessage aMessage, int32_t aX,
|
2013-07-25 19:59:08 +04:00
|
|
|
int32_t aY, nsIContent* aContent,
|
2019-04-13 15:13:15 +03:00
|
|
|
nsIFrame* aFrame, PresShell* aPresShell,
|
2013-07-25 19:59:08 +04:00
|
|
|
nsIWidget* aRootWidget);
|
2008-08-06 16:16:54 +04:00
|
|
|
|
2009-08-20 10:45:19 +04:00
|
|
|
/**
|
2013-07-25 19:59:08 +04:00
|
|
|
* Send a touch event with a single touch point to the given element.
|
2009-08-20 10:45:19 +04:00
|
|
|
*
|
2015-08-26 15:56:59 +03:00
|
|
|
* @param aMessage [in] an event message (see EventForwards.h)
|
2009-08-20 10:45:19 +04:00
|
|
|
* @param aX [in] x coordinate in dev pixels
|
|
|
|
* @param aY [in] y coordinate in dev pixels
|
|
|
|
* @param aContent [in] the element
|
|
|
|
* @param aFrame [in] frame of the element
|
|
|
|
* @param aPresShell [in] the presshell for the element
|
|
|
|
* @param aRootWidget [in] the root widget of the element
|
|
|
|
*/
|
2019-04-13 15:13:13 +03:00
|
|
|
MOZ_CAN_RUN_SCRIPT
|
2015-08-26 15:56:59 +03:00
|
|
|
static void DispatchTouchEvent(mozilla::EventMessage aMessage, int32_t aX,
|
2013-07-25 19:59:08 +04:00
|
|
|
int32_t aY, nsIContent* aContent,
|
2019-04-13 15:13:15 +03:00
|
|
|
nsIFrame* aFrame, PresShell* aPresShell,
|
2013-07-25 19:59:08 +04:00
|
|
|
nsIWidget* aRootWidget);
|
2009-08-20 10:45:19 +04:00
|
|
|
|
2007-08-29 10:52:46 +04:00
|
|
|
/**
|
|
|
|
* Return an accesskey registered on the given element by
|
2014-04-01 08:09:23 +04:00
|
|
|
* EventStateManager or 0 if there is no registered accesskey.
|
2007-08-29 10:52:46 +04:00
|
|
|
*
|
|
|
|
* @param aContent - the given element.
|
|
|
|
*/
|
2012-08-22 19:56:38 +04:00
|
|
|
static uint32_t GetAccessKeyFor(nsIContent* aContent);
|
2007-08-29 10:52:46 +04:00
|
|
|
|
2008-07-17 16:06:24 +04:00
|
|
|
/**
|
|
|
|
* Return DOM element related with the given node, i.e.
|
|
|
|
* a) itself if it is DOM element
|
|
|
|
* b) parent element if it is text node
|
2012-07-30 18:20:58 +04:00
|
|
|
* c) otherwise nullptr
|
2008-07-17 16:06:24 +04:00
|
|
|
*
|
|
|
|
* @param aNode [in] the given DOM node
|
|
|
|
*/
|
2010-06-11 12:23:18 +04:00
|
|
|
static nsIContent* GetDOMElementFor(nsIContent* aContent);
|
2008-07-17 16:06:24 +04:00
|
|
|
|
2008-12-16 13:14:20 +03:00
|
|
|
/**
|
|
|
|
* Return DOM node for the given DOM point.
|
|
|
|
*/
|
2012-08-22 19:56:38 +04:00
|
|
|
static nsINode* GetDOMNodeFromDOMPoint(nsINode* aNode, uint32_t aOffset);
|
2010-05-25 12:12:43 +04:00
|
|
|
|
2007-08-14 22:47:49 +04:00
|
|
|
/**
|
|
|
|
* Is the first passed in node an ancestor of the second?
|
|
|
|
* Note: A node is not considered to be the ancestor of itself.
|
2010-01-27 14:43:25 +03:00
|
|
|
*
|
|
|
|
* @param aPossibleAncestorNode [in] node to test for ancestor-ness of
|
|
|
|
* aPossibleDescendantNode
|
|
|
|
* @param aPossibleDescendantNode [in] node to test for descendant-ness of
|
|
|
|
* aPossibleAncestorNode
|
2010-06-10 07:29:56 +04:00
|
|
|
* @param aRootNode [in, optional] the root node that search
|
|
|
|
* search should be performed within
|
2011-10-17 18:59:28 +04:00
|
|
|
* @return true if aPossibleAncestorNode is an ancestor of
|
2010-01-27 14:43:25 +03:00
|
|
|
* aPossibleDescendantNode
|
2007-08-14 22:47:49 +04:00
|
|
|
*/
|
2011-09-29 10:19:26 +04:00
|
|
|
static bool IsAncestorOf(nsINode* aPossibleAncestorNode,
|
2010-06-10 07:29:56 +04:00
|
|
|
nsINode* aPossibleDescendantNode,
|
2012-07-30 18:20:58 +04:00
|
|
|
nsINode* aRootNode = nullptr);
|
2007-08-21 07:16:27 +04:00
|
|
|
|
2007-08-24 08:54:45 +04:00
|
|
|
/**
|
|
|
|
* Helper method to scroll range into view, used for implementation of
|
|
|
|
* nsIAccessibleText::scrollSubstringTo().
|
|
|
|
*
|
|
|
|
* @param aFrame the frame for accessible the range belongs to.
|
2012-04-06 22:08:24 +04:00
|
|
|
* @param aRange the range to scroll to
|
2007-08-24 08:54:45 +04:00
|
|
|
* @param aScrollType the place a range should be scrolled to
|
|
|
|
*/
|
2020-03-13 18:46:13 +03:00
|
|
|
MOZ_CAN_RUN_SCRIPT_BOUNDARY static nsresult ScrollSubstringTo(
|
|
|
|
nsIFrame* aFrame, nsRange* aRange, uint32_t aScrollType);
|
2007-08-24 08:54:45 +04:00
|
|
|
|
2007-09-25 09:48:51 +04:00
|
|
|
/** Helper method to scroll range into view, used for implementation of
|
|
|
|
* nsIAccessibleText::scrollSubstringTo[Point]().
|
|
|
|
*
|
|
|
|
* @param aFrame the frame for accessible the range belongs to.
|
2012-04-06 22:08:24 +04:00
|
|
|
* @param aRange the range to scroll to
|
2012-03-20 06:09:50 +04:00
|
|
|
* @param aVertical how to align vertically, specified in percents, and
|
|
|
|
* when.
|
|
|
|
* @param aHorizontal how to align horizontally, specified in percents,
|
|
|
|
* and when.
|
2007-09-25 09:48:51 +04:00
|
|
|
*/
|
2020-03-13 18:46:13 +03:00
|
|
|
MOZ_CAN_RUN_SCRIPT_BOUNDARY static nsresult ScrollSubstringTo(
|
|
|
|
nsIFrame* aFrame, nsRange* aRange, mozilla::ScrollAxis aVertical,
|
|
|
|
mozilla::ScrollAxis aHorizontal);
|
2007-09-25 09:48:51 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Scrolls the given frame to the point, used for implememntation of
|
2012-02-07 17:18:33 +04:00
|
|
|
* nsIAccessible::scrollToPoint and nsIAccessibleText::scrollSubstringToPoint.
|
2007-09-25 09:48:51 +04:00
|
|
|
*
|
|
|
|
* @param aScrollableFrame the scrollable frame
|
|
|
|
* @param aFrame the frame to scroll
|
2022-01-19 02:31:21 +03:00
|
|
|
* @param aPoint the point scroll to (in dev pixels)
|
2007-09-25 09:48:51 +04:00
|
|
|
*/
|
|
|
|
static void ScrollFrameToPoint(nsIFrame* aScrollableFrame, nsIFrame* aFrame,
|
2022-01-19 02:31:21 +03:00
|
|
|
const mozilla::LayoutDeviceIntPoint& aPoint);
|
2007-09-25 09:48:51 +04:00
|
|
|
|
2007-08-24 08:54:45 +04:00
|
|
|
/**
|
|
|
|
* Converts scroll type constant defined in nsIAccessibleScrollType to
|
2012-03-20 06:09:50 +04:00
|
|
|
* vertical and horizontal parameters.
|
2007-08-24 08:54:45 +04:00
|
|
|
*/
|
2019-04-30 03:07:49 +03:00
|
|
|
static void ConvertScrollTypeToPercents(uint32_t aScrollType,
|
|
|
|
mozilla::ScrollAxis* aVertical,
|
|
|
|
mozilla::ScrollAxis* aHorizontal);
|
2007-09-05 11:39:09 +04:00
|
|
|
|
|
|
|
/**
|
2013-02-13 02:02:51 +04:00
|
|
|
* Return document shell for the given DOM node.
|
2007-09-05 11:39:09 +04:00
|
|
|
*/
|
2013-02-13 02:02:51 +04:00
|
|
|
static already_AddRefed<nsIDocShell> GetDocShellFor(nsINode* aNode);
|
2007-09-19 01:36:41 +04:00
|
|
|
|
2010-06-08 20:39:58 +04:00
|
|
|
/**
|
|
|
|
* Return true if the given document is root document.
|
|
|
|
*/
|
2019-01-02 16:05:23 +03:00
|
|
|
static bool IsRootDocument(Document* aDocument);
|
2010-06-08 20:39:58 +04:00
|
|
|
|
2011-07-22 04:49:35 +04:00
|
|
|
/**
|
2020-06-10 08:03:05 +03:00
|
|
|
* Return true if the given document is a top level content document in this
|
|
|
|
* process.
|
|
|
|
* This will be true for tab documents and out-of-process iframe documents.
|
2011-07-22 04:49:35 +04:00
|
|
|
*/
|
2020-06-10 08:03:05 +03:00
|
|
|
static bool IsTopLevelContentDocInProcess(Document* aDocumentNode);
|
2011-07-22 04:49:35 +04:00
|
|
|
|
2010-06-08 20:39:58 +04:00
|
|
|
/**
|
|
|
|
* Return true if the given document is an error page.
|
|
|
|
*/
|
2019-01-02 16:05:23 +03:00
|
|
|
static bool IsErrorPage(Document* aDocument);
|
2010-06-08 20:39:58 +04:00
|
|
|
|
2008-10-17 14:10:43 +04:00
|
|
|
/**
|
|
|
|
* Return presShell for the document containing the given DOM node.
|
|
|
|
*/
|
2020-11-23 19:07:43 +03:00
|
|
|
static PresShell* GetPresShellFor(nsINode* aNode);
|
2008-10-17 14:10:43 +04:00
|
|
|
|
2007-09-19 01:36:41 +04:00
|
|
|
/**
|
|
|
|
* Get the ID for an element, in some types of XML this may not be the ID
|
|
|
|
* attribute
|
|
|
|
* @param aContent Node to get the ID for
|
|
|
|
* @param aID Where to put ID string
|
2011-10-17 18:59:28 +04:00
|
|
|
* @return true if there is an ID set for this node
|
2007-09-19 01:36:41 +04:00
|
|
|
*/
|
2011-09-29 10:19:26 +04:00
|
|
|
static bool GetID(nsIContent* aContent, nsAString& aID);
|
2007-09-25 05:19:03 +04:00
|
|
|
|
2010-01-12 22:07:38 +03:00
|
|
|
/**
|
|
|
|
* Convert attribute value of the given node to positive integer. If no
|
|
|
|
* attribute or wrong value then false is returned.
|
|
|
|
*/
|
2017-10-03 01:05:19 +03:00
|
|
|
static bool GetUIntAttr(nsIContent* aContent, nsAtom* aAttr, int32_t* aUInt);
|
2010-01-12 22:07:38 +03:00
|
|
|
|
2008-07-17 16:06:24 +04:00
|
|
|
/**
|
|
|
|
* Returns language for the given node.
|
|
|
|
*
|
|
|
|
* @param aContent [in] the given node
|
|
|
|
* @param aRootContent [in] container of the given node
|
|
|
|
* @param aLanguage [out] language
|
|
|
|
*/
|
|
|
|
static void GetLanguageFor(nsIContent* aContent, nsIContent* aRootContent,
|
|
|
|
nsAString& aLanguage);
|
|
|
|
|
2009-08-20 10:45:19 +04:00
|
|
|
/**
|
2018-12-04 19:25:30 +03:00
|
|
|
* Return tree from any levels DOMNode under the XUL tree.
|
2009-08-20 10:45:19 +04:00
|
|
|
*/
|
2018-12-04 19:25:30 +03:00
|
|
|
static mozilla::dom::XULTreeElement* GetTree(nsIContent* aContent);
|
2009-08-20 10:45:19 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Return first sensible column for the given tree box object.
|
|
|
|
*/
|
2018-06-06 06:01:36 +03:00
|
|
|
static already_AddRefed<nsTreeColumn> GetFirstSensibleColumn(
|
2020-04-15 04:01:12 +03:00
|
|
|
mozilla::dom::XULTreeElement* aTree,
|
|
|
|
mozilla::FlushType = mozilla::FlushType::Frames);
|
2009-08-20 10:45:19 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Return sensible columns count for the given tree box object.
|
|
|
|
*/
|
2018-12-04 19:25:30 +03:00
|
|
|
static uint32_t GetSensibleColumnCount(mozilla::dom::XULTreeElement* aTree);
|
2009-08-20 10:45:19 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Return sensible column at the given index for the given tree box object.
|
|
|
|
*/
|
2018-06-06 06:01:36 +03:00
|
|
|
static already_AddRefed<nsTreeColumn> GetSensibleColumnAt(
|
2018-12-04 19:25:30 +03:00
|
|
|
mozilla::dom::XULTreeElement* aTree, uint32_t aIndex);
|
2009-08-20 10:45:19 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Return next sensible column for the given column.
|
|
|
|
*/
|
2018-06-06 06:01:36 +03:00
|
|
|
static already_AddRefed<nsTreeColumn> GetNextSensibleColumn(
|
2018-06-06 06:01:37 +03:00
|
|
|
nsTreeColumn* aColumn);
|
2009-08-20 10:45:19 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Return previous sensible column for the given column.
|
|
|
|
*/
|
2018-06-06 06:01:36 +03:00
|
|
|
static already_AddRefed<nsTreeColumn> GetPreviousSensibleColumn(
|
2018-06-06 06:01:37 +03:00
|
|
|
nsTreeColumn* aColumn);
|
2009-08-20 10:45:19 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Return true if the given column is hidden (i.e. not sensible).
|
|
|
|
*/
|
2018-06-06 06:01:37 +03:00
|
|
|
static bool IsColumnHidden(nsTreeColumn* aColumn);
|
2009-08-20 10:45:19 +04:00
|
|
|
|
2012-04-10 04:39:00 +04:00
|
|
|
/**
|
|
|
|
* Scroll content into view.
|
|
|
|
*/
|
2019-04-13 15:13:13 +03:00
|
|
|
MOZ_CAN_RUN_SCRIPT
|
2019-04-13 15:13:15 +03:00
|
|
|
static void ScrollTo(PresShell* aPresShell, nsIContent* aContent,
|
2012-08-22 19:56:38 +04:00
|
|
|
uint32_t aScrollType);
|
2012-04-10 04:39:00 +04:00
|
|
|
|
2009-05-14 09:31:09 +04:00
|
|
|
/**
|
|
|
|
* Return true if the given node is table header element.
|
|
|
|
*/
|
2020-11-23 19:08:40 +03:00
|
|
|
static bool IsHTMLTableHeader(nsIContent* aContent);
|
2011-05-30 22:23:36 +04:00
|
|
|
|
2013-07-18 19:09:45 +04:00
|
|
|
/**
|
|
|
|
* Returns true if the given string is empty or contains whitespace symbols
|
|
|
|
* only. In contrast to nsWhitespaceTokenizer class it takes into account
|
|
|
|
* non-breaking space (0xa0).
|
|
|
|
*/
|
2017-06-20 12:19:52 +03:00
|
|
|
static bool IsWhitespaceString(const nsAString& aString);
|
2013-07-18 19:09:45 +04:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Returns true if the given character is whitespace symbol.
|
|
|
|
*/
|
2014-01-04 19:02:17 +04:00
|
|
|
static bool IsWhitespace(char16_t aChar) {
|
2013-07-18 19:09:45 +04:00
|
|
|
return aChar == ' ' || aChar == '\n' || aChar == '\r' || aChar == '\t' ||
|
|
|
|
aChar == 0xa0;
|
|
|
|
}
|
2016-01-21 04:52:43 +03:00
|
|
|
|
|
|
|
/*
|
|
|
|
* Return true if there are any observers of accessible events.
|
|
|
|
*/
|
|
|
|
static bool AccEventObserversExist();
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Notify accessible event observers of an event.
|
|
|
|
*/
|
|
|
|
static void DispatchAccEvent(RefPtr<nsIAccessibleEvent> aEvent);
|
2019-08-01 19:19:06 +03:00
|
|
|
|
|
|
|
static bool IsDisplayContents(nsIContent* aContent);
|
Bug 1744009 - Accessibility fixes for new combobox layout code. r=eeejay
In terms of the C++ code, this patch does basically one thing, which is
allowing creating option / optgroup accessibles without a frame for
comboboxes, and tracking mutations like layout does.
It seems this should be straight-forward, but handling mutations got a
bit complicated. We don't want to forcibly re-create accessibles, so we
want to re-use the PruneOrInsertSubtree logic that ContentInserted uses.
But determining whether we need to create the accessible requires
having flushed styles, so I added a ScheduleAccessibilitySubtreeUpdate
API to trigger that from WillRefresh once style and layout are
up-to-date.
The rest of the test updates should be sort of straight-forward. They
reflect two changes:
* <option> accessibles are leaves now (so they don't have text
children). Note that we still have the right native name and so on,
using the same logic we use to render the label.
* In 1proc tests, the focus no longer goes to the <option>, and uses
the same code-path that e10s does (moving focus to a <menulist> in
the parent process). Since that wasn't easy to test for (afaict) and
we have browser tests to cover that
(browser_treeupdate_select_dropdown.js, etc), I've decided to just
remove the tests that relied on the previous code-path, as they were
testing for a codepath that users weren't hitting anyways.
I've tested this with JAWS and Orca and behavior seems unchanged to my
knowledge.
Differential Revision: https://phabricator.services.mozilla.com/D133098
2022-01-17 14:10:05 +03:00
|
|
|
static bool CanCreateAccessibleWithoutFrame(nsIContent* aContent);
|
2021-02-09 03:44:21 +03:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Return whether the document and all its in-process ancestors are visible in
|
|
|
|
* the sense of pageshow / hide.
|
|
|
|
*/
|
|
|
|
static bool IsDocumentVisibleConsideringInProcessAncestors(
|
|
|
|
const Document* aDocument);
|
2007-03-27 16:17:11 +04:00
|
|
|
};
|
|
|
|
|
2007-03-31 11:14:03 +04:00
|
|
|
#endif
|