Commit Graph

11296 Commits

Author SHA1 Message Date
serge-sans-paille
e54774d573 Bug 1922838 - Replace ArrayLength, ArrayEnd and MOZ_ARRAY_LENGTH by standard alternative r=glandium,necko-reviewers,jgilbert,application-update-reviewers,media-playback-reviewers,credential-management-reviewers,anti-tracking-reviewers,places-reviewers,profiler-reviewers,win-reviewers,dom-storage-reviewers,bytesized,janv,dimi,daisuke,karlt,gstoll,canaltinova,timhuang
Namely std::size, std::end and std::size. This drops C support for
MOZ_ARRAY_LENGTH but it wasn't used anyway.

Differential Revision: https://phabricator.services.mozilla.com/D224611
2024-10-28 08:21:19 +00:00
Adi
015c2e805d Backed out 2 changesets (bug 1926214, bug 1926198) for causing ba failures. CLOSED TREE
Backed out changeset ada40589ff0c (bug 1926214)
Backed out changeset fbb2bce6d562 (bug 1926198)
2024-10-28 09:34:01 +02:00
James Teh
5c25abc060 Bug 1926214: Fire a11y scrolling start events on a text leaf node when navigating to text fragments. r=jjaschke,morgan
Previously, scrolling start events always fired on an Accessible for an element, never a text leaf.
However, a text fragment starts in a text leaf node and there may be many other children of the parent element prior to the start of the text fragment.
We want to get a11y clients as close as possible to the fragment, so fire the event on the text leaf node instead.

Unfortunately, we can't fire the Windows event on text leaf nodes, so we have to override this to use the parent in Windows specific code.
Fortunately, we can expose the highlight on Windows via text attributes, so clients can find out exactly what is highlighted, albeit with a bit more work.
This text leaf change is of most benefit on Android, where we can't expose the highlight, but we can move accessibility focus to a text leaf.

Differential Revision: https://phabricator.services.mozilla.com/D226587
2024-10-28 06:42:30 +00:00
James Teh
103194150c Bug 1926198: Use GetAccessibleOrContainer in nsAccessibilityService::NotifyOfAnchorJumpTo. r=morgan
The target might be an element for which we don't create an Accessible; e.g. a <b> element.
Previously, we wouldn't fire an event in NotifyOfAnchorJumpTo and would instead defer the event until the next document focus.
However, the document might already have focus, in which case we won't fire this event when the user expects it (if ever).
Instead, use GetAccessibleOrContainer, which is also consistent with the deferred anchor jump code in FocusManager.
This means we will fire the event on the correct container Accessible immediately.

Differential Revision: https://phabricator.services.mozilla.com/D226437
2024-10-28 06:42:30 +00:00
Emilio Cobos Álvarez
0ec8679a90 Bug 1927138 - Remove popover prefs. r=webidl,smaug
Differential Revision: https://phabricator.services.mozilla.com/D226956
2024-10-27 08:47:00 +00:00
Alexandru Marc
191ccbe7fe Backed out changeset d92f391b3b0c (bug 1922838) for backing out bug 1915351 2024-10-25 16:42:33 +03:00
serge-sans-paille
53068cdf31 Bug 1922838 - Replace ArrayLength, ArrayEnd and MOZ_ARRAY_LENGTH by standard alternative r=glandium,necko-reviewers,jgilbert,application-update-reviewers,media-playback-reviewers,credential-management-reviewers,anti-tracking-reviewers,places-reviewers,profiler-reviewers,win-reviewers,dom-storage-reviewers,bytesized,janv,dimi,daisuke,karlt,gstoll,canaltinova,timhuang
Namely std::size, std::end and std::size. This drops C support for
MOZ_ARRAY_LENGTH but it wasn't used anyway.

Differential Revision: https://phabricator.services.mozilla.com/D224611
2024-10-24 09:06:01 +00:00
Alexandru Marc
83543f20f2 Backed out changeset 448597bce69d (bug 1922838) for causing build bustages. CLOSED TREE 2024-10-24 11:37:49 +03:00
serge-sans-paille
c7a369b29a Bug 1922838 - Replace ArrayLength, ArrayEnd and MOZ_ARRAY_LENGTH by standard alternative r=glandium,necko-reviewers,jgilbert,application-update-reviewers,media-playback-reviewers,credential-management-reviewers,anti-tracking-reviewers,places-reviewers,profiler-reviewers,win-reviewers,dom-storage-reviewers,bytesized,janv,dimi,daisuke,karlt,gstoll,canaltinova,timhuang
Namely std::size, std::end and std::size. This drops C support for
MOZ_ARRAY_LENGTH but it wasn't used anyway.

Differential Revision: https://phabricator.services.mozilla.com/D224611
2024-10-24 07:38:30 +00:00
Vincent Hilla
d3c8be80cd Bug 1694789 - Map accessible value for input type color and password. r=dom-core,sefeng,Jamie,bolsson
Differential Revision: https://phabricator.services.mozilla.com/D216042
2024-10-22 13:23:18 +00:00
Emilio Cobos Álvarez
227e943b78 Bug 1926031 - Make Selection::ScrollIntoView take ScrollFlags. r=jjaschke,masayuki
Differential Revision: https://phabricator.services.mozilla.com/D226389
2024-10-22 09:58:02 +00:00
Emilio Cobos Álvarez
b5d2263c26 Bug 1925866 - NS_NewLocalFile's aFollowSymlinks arg is unused. r=xpcom-reviewers,necko-reviewers,valentin,media-playback-reviewers,win-reviewers,karlt,nika,rkraesig
Remove it and related functions, and update the callers.

Differential Revision: https://phabricator.services.mozilla.com/D226261
2024-10-22 09:38:16 +00:00
Emilio Cobos Álvarez
2272866855 Bug 1926031 - Remove unused SCROLL_FOR_CARET_MOVE. r=jjaschke,masayuki
No point in keeping the code around.

Differential Revision: https://phabricator.services.mozilla.com/D226387
2024-10-22 09:34:28 +00:00
James Teh
d648744f28 Bug 1837126: Don't set the selection range when HyperTextAccessibleBase::PasteText is called with TEXT_OFFSET_CARET. r=eeejay
If no text is selected, this is the same as passing the caret offset, since the selection range is already where we want it.
However, if text is selected, this allows the caller to replace it, just as it would be when pasting using the keyboard or GUI.
Note that this doesn't break any existing expectations because TEXT_OFFSET_CARET was never supported for this method previously.

This allows us to remove the DeleteText call from Android SessionAccessibility::Paste.
This separate DeleteText call was causing problems because it could result in the deletion and the insertion happening in two separate ticks, resulting in incorrect events.
Now, this should always happen in a single tick.

Differential Revision: https://phabricator.services.mozilla.com/D226108
2024-10-20 22:35:34 +00:00
Dale Harvey
0974234a5b Bug 1923212 - Skip tests that fail with ScotchBonnet enabled. r=mak,settings-reviewers,sessionstore-reviewers,urlbar-reviewers,dao,Gijs
Differential Revision: https://phabricator.services.mozilla.com/D224633
2024-10-20 08:35:05 +00:00
Norisz Fay
d0b8be820a Backed out changeset 4ef6f0f9300d (bug 1923212) for causing bc failures on browser_searchModeSwitcher_basic.js CLOSED TREE 2024-10-18 20:41:04 +03:00
Ryan VanderMeulen
99ca3a577a Backed out changeset 2488ab222143 (bug 1919155) because it depends on bug 1769586 which was backed out.
CLOSED TREE
2024-10-18 11:07:36 -04:00
Dale Harvey
94124a5dad Bug 1923212 - Skip tests that fail with ScotchBonnet enabled. r=mak,settings-reviewers,sessionstore-reviewers,urlbar-reviewers,dao,Gijs
Differential Revision: https://phabricator.services.mozilla.com/D224633
2024-10-18 13:25:17 +00:00
Ryan VanderMeulen
f6e7f621c2 Backed out 3 changesets (bug 1769586) for causing Bug 1920082.
Backed out changeset d684010261d6 (bug 1769586)
Backed out changeset b3264bc533e2 (bug 1769586)
Backed out changeset 049fd286ce0f (bug 1769586)
2024-10-17 16:44:16 -04:00
Collin Richards
d4fecde3c9 Bug 1086524 - Focus window on Esc in address bar r=dao,urlbar-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D218893
2024-10-17 11:56:34 +00:00
Eitan Isaacson
4ea553fb6c Bug 1919087 - Defer PushNameOrDescriptionChange to WillRefresh tick. r=Jamie
Since the method is deferred we need to do extra guesswork for possible
situtations where the name has changed because we don't have the
privilege to calculate the name in-line when content is deleted.

I tried to account for all cases as we have in our test coverage. I
hope that if there are edge cases they are false positives, and we are
firing extra name changes and not the opposite.

Differential Revision: https://phabricator.services.mozilla.com/D223877
2024-10-17 04:46:20 +00:00
Cosmin Sabou
fe50ea1fee Backed out changeset c3560df7c73f (bug 1086524) for causing bc failures on browser_searchModeSwitcher_basic. 2024-10-17 00:49:27 +03:00
Florian Quèze
30480aefff Bug 1923028 - Migrate scalars to use Glean APIs for a11.*, r=chutten.
Differential Revision: https://phabricator.services.mozilla.com/D225366
2024-10-16 20:46:06 +00:00
Collin Richards
3c01bc72a3 Bug 1086524 - Focus window on Esc in address bar r=dao,urlbar-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D218893
2024-10-16 15:55:01 +00:00
Adi
259ae08b09 Backed out changeset c03123359b41 (bug 1086524) for causing browser_persist_searchMode.js failures. CLOSED TREE 2024-10-16 16:54:55 +03:00
Collin Richards
13b116cb50 Bug 1086524 - Focus window on Esc in address bar r=dao,urlbar-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D218893
2024-10-16 11:47:11 +00:00
Timothy Nikkel
c758cf216b Bug 1923790. Skip a matrix PostTranslate in GetResultingTransformMatrix when it's useless. r=gfx-reviewers,layout-reviewers,lsalzman,emilio
Differential Revision: https://phabricator.services.mozilla.com/D225169
2024-10-16 09:52:03 +00:00
Nathan LaPre
91c9ad7516 Bug 1922696: Opt AccAttributes into ToString via operator<<, r=eeejay
This revision adds an operator<< that writes a text representation of an
AccAttributes object to an ostream object. This makes it possible to call
ToString on an AccAttributes object, which is useful for printing AccAttributes
objects embedded in AccAttributes objects, and relevant to how Gecko stores
ARIA and text attributes. This revision rewrites DebugPrint in terms of ToString
and uses ToString in StringFromNameAndValue to print AccAttributes in AccAttributes.

Differential Revision: https://phabricator.services.mozilla.com/D224558
2024-10-16 01:07:59 +00:00
Stanca Serban
79c7562770 Backed out changeset cbbe203e630b (bug 1919087) for causing build bustages in EventQueue.cpp. CLOSED TREE 2024-10-16 00:51:51 +03:00
Eitan Isaacson
1c72aec179 Bug 1919087 - Defer PushNameOrDescriptionChange to WillRefresh tick. r=Jamie
Since the method is deferred we need to do extra guesswork for possible
situtations where the name has changed because we don't have the
privilege to calculate the name in-line when content is deleted.

I tried to account for all cases as we have in our test coverage. I
hope that if there are edge cases they are false positives, and we are
firing extra name changes and not the opposite.

Differential Revision: https://phabricator.services.mozilla.com/D223877
2024-10-15 20:21:06 +00:00
Olli Pettay
7e528b126f Bug 1911736 - Enable dom.popup.experimental on Nightly, r=edgar
Differential Revision: https://phabricator.services.mozilla.com/D225518
2024-10-15 19:06:51 +00:00
Iulian Moraru
a0094cf0d3 Backed out 4 changesets (bug 1923790) for causing mass assertion failures. CLOSED TREE
Backed out changeset c77fbdd69b94 (bug 1923790)
Backed out changeset f81a6af120f5 (bug 1923790)
Backed out changeset 776dcd89f572 (bug 1923790)
Backed out changeset d68b9d899217 (bug 1923790)
2024-10-14 16:49:58 +03:00
Timothy Nikkel
72090a3700 Bug 1923790. Skip a matrix PostTranslate in GetResultingTransformMatrix when it's useless. r=gfx-reviewers,layout-reviewers,lsalzman,emilio
Differential Revision: https://phabricator.services.mozilla.com/D225169
2024-10-14 10:43:06 +00:00
Nathan LaPre
ba44465146 Bug 1922691: Avoid crash in BundleFieldsForCache with null check on mBounds, r=Jamie
This revision adds a null check on mBounds in BundleFieldsForCache, in order to
avoid crashing in release when mBounds is empty.

Differential Revision: https://phabricator.services.mozilla.com/D225273
2024-10-11 17:31:13 +00:00
Eitan Isaacson
949bd3acfe Bug 1915262 - Fire queued live region event from content in MacOS. r=morgan
Introduce a gecko live region changed event and fire it from within content.
This way it gets coalesced in the case of many insertions/deletions.

Also, rely on text insert/delete instead of reorder because there can be cases
where the text in a leaf changes as opposed to a tree mutation.
We get text insert/delete on mutations too, so that should cover it.

Differential Revision: https://phabricator.services.mozilla.com/D224388
2024-10-10 17:36:26 +00:00
Butkovits Atila
40d6013a5d Backed out changeset e05604fb874e (bug 1922696) for causing bustages at AccAttributes.cpp. CLOSED TREE 2024-10-10 00:07:25 +03:00
Nathan LaPre
28881b1a75 Bug 1921917: Create startup pref to enable all cache domains, r=eeejay
This revision adds a pref, read only on startup, that enables all cache domains.
By default, cache domains are only enabled as-needed. This pref is uesful for
test environments, such as fuzzing.

Differential Revision: https://phabricator.services.mozilla.com/D224187
2024-10-09 19:27:32 +00:00
Nathan LaPre
fe6f936431 Bug 1922696: Opt AccAttributes into ToString via operator<<, r=eeejay
This revision adds an operator<< that writes a text representation of an
AccAttributes object to an ostream object. This makes it possible to call
ToString on an AccAttributes object, which is useful for printing AccAttributes
objects embedded in AccAttributes objects, and relevant to how Gecko stores
ARIA and text attributes. This revision rewrites DebugPrint in terms of ToString
and uses ToString in StringFromNameAndValue to print AccAttributes in AccAttributes.

Differential Revision: https://phabricator.services.mozilla.com/D224558
2024-10-09 19:25:40 +00:00
Cosmin Sabou
b2778dfb92 Backed out changeset 3cefab965a7c (bug 1915262) for causing accessible related assertion failures on macOS. 2024-10-09 10:43:37 +03:00
Eitan Isaacson
4d81a9a27a Bug 1915262 - Fire queued live region event from content in MacOS. r=morgan
Introduce a gecko live region changed event and fire it from within content.
This way it gets coalesced in the case of many insertions/deletions.

Also, rely on text insert/delete instead of reorder because there can be cases
where the text in a leaf changes as opposed to a tree mutation.
We get text insert/delete on mutations too, so that should cover it.

Differential Revision: https://phabricator.services.mozilla.com/D224388
2024-10-09 05:36:21 +00:00
Nathan LaPre
a0e532f923 Bug 1919366: Force cache domain queries for test platform exceptions on Linux, r=Jamie
These exceptions exist because of Linux platform code which can cause caching of
certain domains before the test begins. Previously, we thought that these
platform issues were 100% consistent, but it turns out that they only happen
most of the time, and can fail to happen in test verify, causing test failure.
To ensure that we don't fail in unexpected situations, call the query function
even for these Linux platform exceptions. In the best case, it won't affect
anything, and in the worst case, it'll save us from TV failure.

Differential Revision: https://phabricator.services.mozilla.com/D222880
2024-10-08 04:22:05 +00:00
Gregory Pappas
f7b1e37259 Bug 71895 - Create the hidden window on macOS only r=firefox-desktop-core-reviewers ,mossop
Differential Revision: https://phabricator.services.mozilla.com/D219834
2024-09-24 23:45:09 +00:00
Butkovits Atila
3ec57a37b8 Backed out changeset 76c285a906b6 (bug 71895) as requested by dev. CLOSED TREE 2024-09-24 12:28:38 +03:00
David Shin
9619207abf Bug 1900232: Part 4 - Add anchor-size() to margin properties. r=firefox-style-system-reviewers,emilio
Differential Revision: https://phabricator.services.mozilla.com/D222533
2024-09-23 13:58:38 +00:00
Gregory Pappas
9d49a34acb Bug 71895 - Create the hidden window on macOS only r=firefox-desktop-core-reviewers ,mossop
Differential Revision: https://phabricator.services.mozilla.com/D219834
2024-09-20 00:54:07 +00:00
Dão Gottwald
8bc680f6d2 Bug 1919262 - Remove --button-color. r=desktop-theme-reviewers,reusable-components-reviewers,emilio,hjones
Differential Revision: https://phabricator.services.mozilla.com/D222439
2024-09-18 06:04:39 +00:00
Nathan LaPre
48bc589112 Bug 1901462: Implement UIA ITextRangeProvider::GetBoundingRectangles, r=Jamie
This revision implements GetBoundingRectangles by walking the text range line by
line, adding each line rect to an output array, then returning that array to UIA
clients. Since this logic was tied up in TextLeafRange::Bounds, this revision
first creates function WalkLineRects which encapsulates the logic of walking
a TextLeafRange line-by-line. Then, it uses that function to rewrite Bounds and
implement new function LineRects, which stores all non-empty onscreen line rects
in an nsTArray and returns them. The implementation of GetBoundingRectangles has
been filled out; it's mostly straightforward but contains some SAFEARRAY work
since UIA expects rects as doubles, rather than our internal uint32_t
representation. Finally, this revision adds a test for GetBoundingRectangles.

Differential Revision: https://phabricator.services.mozilla.com/D222198
2024-09-17 21:38:26 +00:00
Nathan LaPre
82e1685960 Bug 1901463: Implement UIA ITextProvider::RangeFromPoint, r=Jamie
This revision implements RangeFromPoint by hittesting the screen location with
ChildAtPoint. Though the UIA documentation suggests that it may be correct to
find the closest text leaf to the screen coordinate, this revision restricts the
search to nodes under the screen coordinate directly. To accomplish this, it
creates two new functions: TextLeafPointAtScreenPoint, which manages the logic for
hit testing within a TextLeafRange, and FromAccessible, which creates a
TextLeafRange spanning the entire text leaf. Finally, this revision adds Windows
platform tests for the new functionality.

Differential Revision: https://phabricator.services.mozilla.com/D221902
2024-09-17 21:38:26 +00:00
Nathan LaPre
a13db27562 Bug 1917741: Restrict viewport cache domain check on macOS, r=Jamie
Per Bug 1916578, some cache domains may be present before the document is
finished loading. This can be triggered by platform-level code event handling.
This issue makes cache absence checks unreliable on macOS. We are intermittently
seeing failures on macOS where viewport is cached before doc load, despite not
explicitly requesting it. As we've done with other such issues, this revision
excludes the cache absence check on macOS.

Differential Revision: https://phabricator.services.mozilla.com/D222367
2024-09-17 15:51:15 +00:00
Eitan Isaacson
b1b95fe1bc Bug 1919155 - Use RelatedAccIterator in RelocateARIAOwnedIfNeeded. r=Jamie
This allows non-ID refs to be included too.

Differential Revision: https://phabricator.services.mozilla.com/D222370
2024-09-17 15:18:32 +00:00