Граф коммитов

708 Коммитов

Автор SHA1 Сообщение Дата
Eitan Isaacson df40116d6f Bug 1572829 - Remove explicit children too when node has a shadow root. r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D43488

--HG--
extra : moz-landing-system : lando
2019-08-28 23:02:19 +00:00
kriswright be316b6bf9 Bug 1573992 - Convert 3 ui.key.* prefs to static prefs. r=njn
Converts ui.key.generalAccessKey, ui.key.chromeAccess, and ui.key.contentAccess to static prefs. Updates usages.

Differential Revision: https://phabricator.services.mozilla.com/D42392

--HG--
extra : moz-landing-system : lando
2019-08-26 20:25:42 +00:00
Gautham Velchuru 0b2b2ab7b2 Bug 1357100 - change implicit val for aria-level on a heading to 2 r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D35616

--HG--
extra : moz-landing-system : lando
2019-08-23 01:28:13 +00:00
Mike Hommey 66d7fe943e Bug 1575420 - Replace MOZ_WIDGET_TOOLKIT value of "gtk3" with "gtk". r=froydnj
Differential Revision: https://phabricator.services.mozilla.com/D42765

--HG--
extra : moz-landing-system : lando
2019-08-21 12:25:42 +00:00
Noemi Erli 6b80a780ed Backed out changeset 067d47e20a94 (bug 1572811) for causing failures in CharacterData.cpp CLOSED TREE 2019-08-15 20:30:45 +03:00
Eitan Isaacson 212dd05514 Bug 1572811 - Explicitly check for removed anonymous children in reframe. r=Jamie
The DOM mutation observer method is called during frame destruction
which is not a good state to be in when constructing and dispatching events.

Differential Revision: https://phabricator.services.mozilla.com/D41825

--HG--
extra : moz-landing-system : lando
2019-08-15 16:06:33 +00:00
Alexander Surkov cfb8c8aef7 Bug 1573337 - remove XBL anon content filtering support from accessible tree traversal r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D42022

--HG--
extra : moz-landing-system : lando
2019-08-15 00:58:28 +00:00
Brendan Dahl b474db77c6 Bug 1551344 - Part 1: Remove XULDocument code. r=smaug,Jamie
All .xul files have been loading as HTMLDocuments for a few weeks now, so
it should be safe to remove the XULDocument implementation.

Differential Revision: https://phabricator.services.mozilla.com/D41238

--HG--
extra : moz-landing-system : lando
2019-08-09 19:57:50 +00:00
James Teh 76dff37c45 Bug 1572317: When removing an Accessible because it lost its frame, remove Accessibles for DOM descendants as well. r=eeejay
Removing an Accessible removes descendants in the a11y tree.
However, there may be DOM descendants which have been relocated elsewhere in the a11y tree.
Their DOM nodes are now hidden as well, so we need to remove those Accessibles too.
In addition to Accessibles remaining in the tree when they shouldn't, failing to remove relocated Accessibles caused problems later on when a relocated Accessible was shown with new descendants.

Differential Revision: https://phabricator.services.mozilla.com/D41178

--HG--
extra : moz-landing-system : lando
2019-08-09 01:21:54 +00:00
Eitan Isaacson 09554268a2 Bug 1571616 - Prune or reinsert accessibles in non-accessible container. r=Jamie
We need to visit the descendants of a container that has no accessible,
but has accessible children.

Also added a test for delayed removal where we can put all these nasty
cases.

Differential Revision: https://phabricator.services.mozilla.com/D41059

--HG--
extra : moz-landing-system : lando
2019-08-08 16:47:14 +00:00
Kannan Vijayan e53a880b1c Bug 1569262 - Rename nsIDocShellTreeItem::GetRootTreeItem to GetInProcessRootTreeItem for Fission marking. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D41064

--HG--
extra : moz-landing-system : lando
2019-08-07 19:24:00 +00:00
Eitan Isaacson 67c11960cc Bug 686400 - Delay accessible removal on frame reconstruction. r=Jamie,emilio
We naively remove and then recreate accessibles when their content's
frame is reconstructed. By delaying the removal until we are certain the
content does not have a new layout frame, we can cut down on redundant
recreations.

When reconstructed content is re-inserted we can check it and its
subtree for missing frames and prune those accessibles from the tree.

Differential Revision: https://phabricator.services.mozilla.com/D38380

--HG--
extra : moz-landing-system : lando
2019-08-02 22:13:28 +00:00
Kris Maglione 22592538f5 Bug 1561015: Part 1 - Use BrowsingContext in window provider APIs. r=bzbarsky,mossop
This is the first step in making it possible to return remote WindowProxy
objects from window.open() and related APIs.

This patch also incidentally fixes a bug where getContentWindowOrOpenURI
returned the top-level browser window rather than the new content window when
passed OPEN_NEWWINDOW for the `aWhere` parameter. This was not the expected
behavior, and was a potentially major footgun for any new users who expected
to always get the content window for the URL they were loading, rather than
sometimes getting a chrome browser window instead.

For now, that case just returns null, which is only a minor footgun, rather
than the major one we had before.

Differential Revision: https://phabricator.services.mozilla.com/D35688

--HG--
extra : moz-landing-system : lando
2019-08-02 20:48:33 +00:00
Masayuki Nakano 765e91b497 Bug 1569902 - part 1: Stop using attribute to consider whether a `<br>` element is an editor bogus node or not r=m_kato,smaug
Editor creates a `<br>` element when it's root element is empty.
Then, it's stored by `TextEditRules::mBogusNode` and used for checking
whether the editor is empty quickly.  However, this `<br>` element has
`mozeditorbogusnode` attribute whose value is `true`.  However, adding or
removing the attribute is not cheap and web apps can refer such illegal
attribute.

Therefore, this patch makes `HTMLBRElement` take a specific flag whether
it's a bogus node or not.  However, this means that this hacky thing will be
exposed outside editor module.  For making what is the bogus node clearer,
this patch calls the such `<br>` elements as "padding `<br>` element for
empty editor".  So, this patch also includes a lot of renaming methods and
variables, and modifying related comments.

Differential Revision: https://phabricator.services.mozilla.com/D39857

--HG--
extra : moz-landing-system : lando
2019-08-02 05:44:40 +00:00
James Teh e7f4ed385b Bug 1570848: When an OuterDocAccessible is constructed, send it as the parent COM proxy for its remote document (if any). r=MarcoZ
Normally, the OuterDocAccessible is created first and the DocAccessibleParent for a remote document is created after that.
So, we get the OuterDocAccessible and call DocAccessibleParent::SendParentCOMProxy when the DocAccessibleParent is constructed (BrowserParent::RecvPDocAccessibleConstructor).
However, sometimes, the OuterDocAccessible is created *after* the DocAccessibleParent.
This sometimes happens for extension popups, for example.
In that case, we previously never sent the parent COM proxy.
Aside from leaving the remote document with a null parent, this also meant we never sent any events for the document, since events are buffered for remote documents until the parent COM proxy is received.
This effectively left the remote document (e.g. extension popup) inaccessible.

Now, we also call SendParentCOMProxy in the OuterDocAccessible constructor.
Note that this doesn't result in duplicates because if the OuterDocAccessible was created first, there won't be a DocAccessibleParent for the remote document yet, so this code won't run.

That said, if the OuterDocAccessible is recreated (e.g. due to frame reconstruction), we may call SendParentCOMProxy again.
This should be okay, but it required an assertion in DocAccessibleChild::RecvParentCOMProxy to be tweaked.

Differential Revision: https://phabricator.services.mozilla.com/D40358

--HG--
extra : moz-landing-system : lando
2019-08-02 04:24:54 +00:00
Eitan Isaacson 6d094c687d Bug 686400 - Filter content insertions in DocAccessible. r=Jamie
It seems a bit more sensible to me that if any filtering needs to happen
from content insertions, it should happen in the doc and not the
notification controller.

Differential Revision: https://phabricator.services.mozilla.com/D40132

--HG--
extra : moz-landing-system : lando
2019-08-01 16:19:15 +00:00
Eitan Isaacson aeb736599d Bug 686400 - Add function to nsCoreUtils for display: contents. r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D40131

--HG--
extra : moz-landing-system : lando
2019-08-01 16:19:06 +00:00
Kannan Vijayan 3fb6190ec6 Bug 1559414 - Rename unaudited pre-fission methods with SameProcess for future audit burndown. r=nika
Differential Revision: https://phabricator.services.mozilla.com/D39378

--HG--
extra : moz-landing-system : lando
2019-07-26 16:48:31 +00:00
Marco Zehe b999f08200 Bug 1568360 - Don't calculate the accessible names for table or grid rows unless they have an explicit ARIA role, r=Jamie
Previously, we would always calculate the name for tr elements from their descendants unconditionally. Assistive technologies aren't using this information, moreover, it causes problems if the name gets too long, for example in layout tables.

We now only calculate the name if the tr element has an explicit ARIA role.

Differential Revision: https://phabricator.services.mozilla.com/D39314

--HG--
extra : moz-landing-system : lando
2019-07-26 09:14:55 +00:00
James Teh dc0f1ef531 Bug 1566324 part 2: Respect shadow DOM for aria-activedescendant. r=eeejay
Previously, the target element for aria-activedescendant was retrieved by calling GetElementById on the owner document.
This meant that aria-activedescendant inside shadow DOM looked for ids in the owner document instead of the shadow DOM.
To fix this, use IDRefsIterator::GetElem instead.

Differential Revision: https://phabricator.services.mozilla.com/D38833

--HG--
extra : moz-landing-system : lando
2019-07-25 20:44:18 +00:00
James Teh 1ace808723 Bug 1568163: Don't return proxy wrappers from OuterDocAccessible::ChildAtPoint with eDeepestChild to prevent crashes when hit testing via XPCOM. r=yzen
On Windows, OuterDocAccessible::GetChildAt can return a proxy wrapper for a remote document.
These aren't real Accessibles and shouldn't be returned except to the Windows a11y code (which doesn't use eDeepestChild).
Calling ChildAtPoint on these will crash!
Therefore, just return null in this case.

Differential Revision: https://phabricator.services.mozilla.com/D39135

--HG--
extra : moz-landing-system : lando
2019-07-24 13:32:22 +00:00
Noemi Erli 2f99f5d875 Merge mozilla-central to autoland. a=merge CLOSED TREE 2019-07-16 00:48:17 +03:00
Mirko Brodesser 2f40f072ab Bug 1565584: move `nsIContentUtils::ContentIsDescendantOf` to `nsINode::IsInclusiveDescendantOf`. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D37880
2019-07-15 10:02:21 +02:00
Boris Zbarsky 374137e8d8 Bug 1565767 part 5. Remove some unnecesary refcounting at nsIContent::GetBaseURI callsites. r=peterv
Differential Revision: https://phabricator.services.mozilla.com/D37973

--HG--
extra : moz-landing-system : lando
2019-07-15 18:29:05 +00:00
Mirko Brodesser 6b67de025f Bug 1562876: rename `Selection::RemoveRange` to `Selection::RemoveRangeAndUnselectFramesAndNotifyListeners`. r=smaug
The name of the corresponding webidl interface of course remains unchanged.

Differential Revision: https://phabricator.services.mozilla.com/D36607
2019-07-03 13:26:14 +02:00
Mirko Brodesser 63b4627d28 Bug 1562876: rename `Selection::AddRange` to `Selection::AddRangeAndSelectFramesAndNotifyListeners`. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D36602
2019-07-03 13:26:13 +02:00
Cameron McCormack 0a6fb940c5 Bug 1553705 - Use a cheaper to compute state key for parser inserted form controls. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D32259

--HG--
extra : moz-landing-system : lando
2019-07-01 10:06:16 +00:00
Narcis Beleuzu cc10ed7ce5 Backed out 2 changesets (bug 1553705) for causing Bug1562142 . CLOSED TREE
Backed out changeset fbb26a04ec1f (bug 1553705)
Backed out changeset dd6e7c0970d5 (bug 1553705)
2019-06-29 02:39:01 +03:00
Cameron McCormack 4d1517b69f Bug 1553705 - Use a cheaper to compute state key for parser inserted form controls. r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D32259

--HG--
extra : moz-landing-system : lando
2019-06-26 21:44:11 +00:00
James Teh 788fa105b8 Bug 1558390: For OOP iframes, also send the embedder accessible when the BrowserBridgeChild is created. r=yzen,nika
Previously, BrowserBridgeChild::SendSetEmbedderAccessible was only called when an OuterDocAccessible was constructed.
However, it's also possible that the BrowserBridgeChild is created *after* the OuterDocAccessible.
Therefore, we must also do this when a BrowserBridgeChild is created if the OuterDocAccessible already exists.

Differential Revision: https://phabricator.services.mozilla.com/D34474

--HG--
extra : moz-landing-system : lando
2019-06-13 02:19:42 +00:00
Andreea Pavel ab94a895b6 Backed out changeset b5df002db72c (bug 1558390) for build bustages on a CLOSED TREE 2019-06-13 03:33:45 +03:00
James Teh 98c9b833d0 Bug 1558390: For OOP iframes, also send the embedder accessible when the BrowserBridgeChild is created. r=yzen,nika
Previously, BrowserBridgeChild::SendSetEmbedderAccessible was only called when an OuterDocAccessible was constructed.
However, it's also possible that the BrowserBridgeChild is created *after* the OuterDocAccessible.
Therefore, we must also do this when a BrowserBridgeChild is created if the OuterDocAccessible already exists.

Differential Revision: https://phabricator.services.mozilla.com/D34474

--HG--
extra : moz-landing-system : lando
2019-06-12 14:57:40 +00:00
Brendan Dahl da359a0016 Bug 1558686 - Enable XUL default button behavior for any doc that allows XUL. r=Jamie
Fixes test 'accessible/tests/mochitest/relations/test_general.xul' when
loaded as XHTML.

Differential Revision: https://phabricator.services.mozilla.com/D34655

--HG--
extra : moz-landing-system : lando
2019-06-12 03:16:33 +00:00
James Teh c0a638e74c Bug 1543313 part 3: For out-of-process iframes on Windows, send the embedder accessible COM proxy to be used as the parent of the embedded document. r=eeejay,yzen
Aside from the parent being needed by the client, this is also important because events from the embedded document are deferred until the parent COM proxy is received.

As part of this, we no longer try to send the parent COM proxy during construction of an OuterDocAccessible in the parent process.
This was previously a no-op anyway, as DocAccessibleParent::SendParentCOMProxy called DocAccessible::GetAccessible for the frame element, which would have returned null because the accessible isn't bound to the document until *after* it is constructed.
Changing this to directly pass the OuterDocAccessible was causing assertions in content processes, since it sometimes meant the parent COM proxy was sent twice, which is precisely what the assertion is protecting against.
Instead, the parent proxy is sent in Browserparent::RecvPDocAccessibleConstructor as it always was.

Differential Revision: https://phabricator.services.mozilla.com/D32284

--HG--
extra : moz-landing-system : lando
2019-06-03 14:29:37 +00:00
Noemi Erli d831a07840 Backed out 4 changesets (bug 1553706, bug 1543313) for failures in DocAccessibleChild.cpp
Backed out changeset 1a8bea02205d (bug 1553706)
Backed out changeset 15f3e6bb3ba9 (bug 1543313)
Backed out changeset 30b106088985 (bug 1543313)
Backed out changeset 85d11dab6b63 (bug 1543313)
2019-05-31 06:24:44 +03:00
James Teh 381c2b2f93 Bug 1543313 part 3: For out-of-process iframes on Windows, send the embedder accessible COM proxy to be used as the parent of the embedded document. r=eeejay
Aside from the parent being needed by the client, this is also important because events from the embedded document are deferred until the parent COM proxy is received.

Differential Revision: https://phabricator.services.mozilla.com/D32284

--HG--
extra : moz-landing-system : lando
2019-05-24 06:14:24 +00:00
James Teh bffe0db8cf Bug 1543307: For out-of-process iframes on Windows, return the embedded document as a child of the OuterDocAccessible. r=eeejay
Windows accessibility clients talk directly to the content process via COM.
In order to expose an OOP iframe document accessible as a child of the embedder iframe accessible via COM, the embedder process needs a COM proxy for the iframe document accessible.
This is exposed on the embedder's BrowserBridgeChild, so we can use this when a client asks for the child of the OuterDocAccessible.

Differential Revision: https://phabricator.services.mozilla.com/D32281

--HG--
extra : moz-landing-system : lando
2019-05-23 19:54:37 +00:00
Edgar Chen 4b1ff2f791 Bug 1543439 - Part 1: Move special handling for MouseDown/Up event out of AutoHandlingUserInputStatePusher; r=masayuki
PresShell::EventHandler::HandleEventWithCurrentEventInfo is the only possible
place will do such handling; other places pass either a nullptr or a
non-MouseDown/Up event.

Differential Revision: https://phabricator.services.mozilla.com/D32431

--HG--
extra : moz-landing-system : lando
2019-05-29 07:48:16 +00:00
James Teh 25b9e2f1f5 Bug 1543282 part 3: For iframes rendered in other processes, tell the parent the embedder iframe accessible. r=eeejay
We do this when the OuterDocAccessible is constructed.
This will be used later in the parent process to link the trees together when the iframe's embedded document accessible is added.

Differential Revision: https://phabricator.services.mozilla.com/D31394

--HG--
extra : moz-landing-system : lando
2019-05-29 04:42:55 +00:00
Eitan Isaacson 291dfad17d Bug 1548362 - Include visual viewport offsets in bounds and hittest calculations. r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D30385

--HG--
extra : moz-landing-system : lando
2019-05-15 00:06:30 +00:00
Daniel Varga 4cbc287f63 Merge mozilla-inbound to mozilla-central. a=merge 2019-05-23 18:54:21 +03:00
Eitan Isaacson f9b6430779 Bug 1551825 - Release mAnchorJumpElm and mInvalidationList in DocAccessible::Shutdown. r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D32197

--HG--
extra : moz-landing-system : lando
2019-05-22 22:03:44 +00:00
Eitan Isaacson 661bd00c42 Bug 1506514 - Don't create accessibles for unselected deck panel descendants. r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D31656

--HG--
extra : moz-landing-system : lando
2019-05-20 15:54:56 +00:00
James Teh 67fb859dcb Bug 1190882: If the focused accessible is removed from the tree, fire a11y focus on the document. r=eeejay
If the DOM focus is removed before something else is focused, the document gets DOM focus, but no blur event is fired (bug 559561).
This means that no a11y focus event is fired, so clients aren't notified.
This is particularly problematic for screen readers when dismissing some ARIA dialogs, as the screen reader doesn't know that focus has returned to the top level document.

Differential Revision: https://phabricator.services.mozilla.com/D31024

--HG--
extra : moz-landing-system : lando
2019-05-15 00:31:16 +00:00
Hiroyuki Ikezoe ddb35d3718 Bug 1541253 - Check PresShell::IsUnderHiddenEmbedderElement where we need to check CSS visibility state across the document boundary. r=tnikkel
Depends on D26252

Differential Revision: https://phabricator.services.mozilla.com/D26253

--HG--
extra : moz-landing-system : lando
2019-05-10 11:22:28 +00:00
Masayuki Nakano 0925cb9a70 Bug 1549155 - Mark EditorBase::DeleteNodeWithTransaction() as MOZ_CAN_RUN_SCRIPT r=m_kato
Differential Revision: https://phabricator.services.mozilla.com/D30038

--HG--
extra : moz-landing-system : lando
2019-05-07 22:27:29 +00:00
Ryan Hunt 4683a8b07a Bug 1525720, part 13 - Stop inheriting nsIRemoteTab interface in BrowserParent. r=nika
This commit removes nsIRemoteTab as a parent class from BrowserParent,
so that BrowserHost is the only concrete implementation of nsIRemoteTab.

Some static_cast's are updated to cast to BrowserHost, and other places
have to be updated to pass a BrowserHost instead of a BrowserParent.

WindowGlobalParent had a getter to return it's managing BrowserParent
as a nsIRemoteTab. I couldn't find a use of this in-tree, so I've just
opt-ed to remove it. If there's a use-case, we can add something back
in.

Differential Revision: https://phabricator.services.mozilla.com/D31444

--HG--
extra : source : 810b7371987139844429d0206f9da6a7701a1efc
2019-05-08 14:34:47 -05:00
Gurzau Raul 57f573a6ff Backed out 18 changesets (bug 1525720) for mass failures on Windows platform e.g ProcessPriorityManager.cpp on a CLOSED TREE.
Backed out changeset 1f2e86c2d691 (bug 1525720)
Backed out changeset 9b79caa460a0 (bug 1525720)
Backed out changeset e65cb2d4c5a5 (bug 1525720)
Backed out changeset 99f971a02d87 (bug 1525720)
Backed out changeset d25963c72ff7 (bug 1525720)
Backed out changeset 810b73719871 (bug 1525720)
Backed out changeset ee10a8254481 (bug 1525720)
Backed out changeset 1bcf9f586c55 (bug 1525720)
Backed out changeset d3b2ac8d5ca4 (bug 1525720)
Backed out changeset 697774dd8984 (bug 1525720)
Backed out changeset eadeacbe4483 (bug 1525720)
Backed out changeset 32eeee79d628 (bug 1525720)
Backed out changeset 07678a2fa9e7 (bug 1525720)
Backed out changeset 757b4f595cc4 (bug 1525720)
Backed out changeset b255e0a84e12 (bug 1525720)
Backed out changeset 9a255864f75d (bug 1525720)
Backed out changeset 5f1c1b609ec1 (bug 1525720)
Backed out changeset 00d83f1d02e0 (bug 1525720)
2019-05-23 01:57:16 +03:00
Ryan Hunt 93d6ab4ec4 Bug 1525720, part 13 - Stop inheriting nsIRemoteTab interface in BrowserParent. r=nika
This commit removes nsIRemoteTab as a parent class from BrowserParent,
so that BrowserHost is the only concrete implementation of nsIRemoteTab.

Some static_cast's are updated to cast to BrowserHost, and other places
have to be updated to pass a BrowserHost instead of a BrowserParent.

WindowGlobalParent had a getter to return it's managing BrowserParent
as a nsIRemoteTab. I couldn't find a use of this in-tree, so I've just
opt-ed to remove it. If there's a use-case, we can add something back
in.

Differential Revision: https://phabricator.services.mozilla.com/D31444

--HG--
extra : rebase_source : 63070e3c2b90c9134f9106028e124935c8dad009
extra : histedit_source : 807f2ff684d86008077be07b0894f39a925fe778
2019-05-08 14:34:47 -05:00
Masayuki Nakano bad5d5bfe9 Bug 1547416 - Move nsIPresShell::ScrollAxis to PresShellForwards.h r=smaug
`nsIPresShell::ScrollAxis` can be used anywhere and it's used by some
utils actually. So, it should be in `mozilla` namespace and perhaps,
 `PresShellForwards.h` is a good place to move it rather than creating
new header file.

Differential Revision: https://phabricator.services.mozilla.com/D29110

--HG--
extra : moz-landing-system : lando
2019-04-30 00:07:49 +00:00
Sylvestre Ledru 96da5036ad Bug 1519636 - Reformat recent changes to the Google coding style r=Ehsan
# ignore-this-changeset

Differential Revision: https://phabricator.services.mozilla.com/D28948

--HG--
extra : moz-landing-system : lando
2019-04-28 09:30:05 +00:00
Emilio Cobos Álvarez e67a519741 Bug 1546697 - followup: Fix a typo introduced in the last commit. r=a11y-orange 2019-04-26 02:29:04 +02:00
Emilio Cobos Álvarez 11ea945833 Bug 1546697 - Use a consistent style for enum classes in layout. r=dholbert
Per the discussion in:

  https://groups.google.com/d/msg/mozilla.dev.platform/P79pwa9z5m8/iPYPAWPHCAAJ

They should be CamelCase, and that's what most of them already do. This converts
the rest, which are a few.

For the ones that already used `e` or `k` prefixes, I've mostly done:

 for file in $(rg Type::e layout | cut -d : -f 1 | sort | uniq); do sed -i 's#Type::e#Type::#g' $file; done

For the ones that used uppercase, I've removed the prefix if it was already in
the type name, and turn them into CamelCase.

Depends on D28680

Differential Revision: https://phabricator.services.mozilla.com/D28681

--HG--
extra : moz-landing-system : lando
2019-04-25 23:03:04 +00:00
Masayuki Nakano 3622509485 Bug 1545342 - part 2: Make some public enum of nsIPresShell move to mozilla namespace and defined as enum class in PresShellForwards.h r=smaug
This patch moves some `enum` in `nsIPresShell` which are in public scope into
`mozilla` namespace and change them as `enum class`es.

Unfortunately, only "where to scroll" enum is just defines constants of
percentages of scroll destination.  Therefore, this patch makes only them
as `static const`.

Differential Revision: https://phabricator.services.mozilla.com/D28606

--HG--
extra : moz-landing-system : lando
2019-04-25 05:04:15 +00:00
Ryan Hunt d6509bb237 Bug 1534395 - Rename TabChild to BrowserChild. r=nika
This commit renames TabChild to BrowserChild.

Differential Revision: https://phabricator.services.mozilla.com/D28135

--HG--
rename : dom/base/InProcessTabChildMessageManager.cpp => dom/base/InProcessBrowserChildMessageManager.cpp
rename : dom/base/InProcessTabChildMessageManager.h => dom/base/InProcessBrowserChildMessageManager.h
rename : dom/ipc/TabChild.cpp => dom/ipc/BrowserChild.cpp
rename : dom/ipc/TabChild.h => dom/ipc/BrowserChild.h
extra : rebase_source : e7fcfb845a971a2760e73d517e24da18ce2551b5
extra : histedit_source : d1991334ccb107fe56e478865f22fd97b041a317
2019-04-09 17:39:01 -05:00
Ryan Hunt 0eeced87be Bug 1534395 - Rename TabParent to BrowserParent. r=nika
This commit renames TabParent to BrowserParent.

Differential Revision: https://phabricator.services.mozilla.com/D28133

--HG--
rename : dom/ipc/TabParent.cpp => dom/ipc/BrowserParent.cpp
rename : dom/ipc/TabParent.h => dom/ipc/BrowserParent.h
extra : rebase_source : d2706b9f42177d8de16068b7b1d088a44b8720a4
extra : histedit_source : a617ddac45c58050ef799116a67d2d983f2a8f6d%2C1d1dabd8761a32d548a6fbf1027be960698f6a5e
2019-04-09 16:38:15 -05:00
Ryan Hunt 3675f2449b Bug 1534395 - Rename nsITabParent to nsIRemoteTab. r=nika,mconley
nsITabParent is exposed to frontend code and is generally used as a representation of a remote tab. We could just rename the interface to nsIBrowserParent and worry about it later, but I think it's better to rename the interface to nsIRemoteTab so that we can later work on splitting the interface away from the PBrowser protocol.

Note: Some frontend code refers to a TabParentId. This commit renames this to RemoteTabId. We need to figure out the purpose of TabId with fission.

Differential Revision: https://phabricator.services.mozilla.com/D28132

--HG--
rename : dom/interfaces/base/nsITabParent.idl => dom/interfaces/base/nsIRemoteTab.idl
extra : rebase_source : 9d8a1790a7bb10195ad063644d1a93d63b2afb72
2019-04-09 15:59:37 -05:00
Magnus Melin 3f542151f4 Bug 1530207 - fix crash [@ InvalidArrayIndex_CRASH | mozilla::a11y::Accessible::InsertChildAt] . r=surkov
For XULTreeAccessible, the ChildCount() is not only the mChildren, so check mChildren directly to make sure we stay within bounds

Differential Revision: https://phabricator.services.mozilla.com/D27553

--HG--
extra : moz-landing-system : lando
2019-04-18 09:39:59 +00:00
Emilio Cobos Álvarez baf580cdfa Bug 1545107 - Remove nsIDocumentObserver::DocumentStatesChanged. r=smaug
It's a bit useless, only has one implementation. Call into the shell directly
instead.

Differential Revision: https://phabricator.services.mozilla.com/D27910

--HG--
extra : moz-landing-system : lando
2019-04-17 19:29:59 +00:00
James Teh 5abb32cecd Bug 1543561: Expose the focusable state on a node focused by aria-activedescendant, even if that node isn't a descendant. r=eeejay
Sometimes, we use aria-activedescendant targeting something which isn't actually a descendant.
This is technically a spec violation, but it's a useful hack which makes certain things much easier.
For example, we use this for "fake focus" for multi select browser tabs and Quantumbar autocomplete suggestions.

This already worked previously; the accessible received a focus event and the focused state.
However, it did *not* receive the focusable state.
This is because the code which applies the focusable state for potential active descendants only works for descendants.

It really doesn't make sense for something to be focused when it isn't focusable.
In fact, this is an a11y test failure when it occurs.
So, if the active item has the focused state, ensure we expose the focusable state too.

Differential Revision: https://phabricator.services.mozilla.com/D27021

--HG--
extra : moz-landing-system : lando
2019-04-17 23:13:10 +00:00
Masayuki Nakano d8d0bcab65 Bug 1543013 - part 2: Make accessible use mozilla::PresShell directly rather than via nsIPresShell r=Jamie
This patch makes accessible module use `mozilla::PresShell` directly rather
than via `nsIPresShell`.  Additionally, renames `DocAccessible::PresShell()`
to `DocAccessible::PresShellPtr()` for avoiding conflict with using
`PresShell` in it and its sub classes.

Differential Revision: https://phabricator.services.mozilla.com/D26663

--HG--
extra : moz-landing-system : lando
2019-04-13 12:13:15 +00:00
Masayuki Nakano 09fd54444c Bug 1543013 - part 1: Mark some methods of nsCoreUtils as MOZ_CAN_RUN_SCRIPT r=Jamie
This patch marks some methods of nsCoreUtils which are found at writing the
following patches, as `MOZ_CAN_RUN_SCRIPT`.

Due to bug 1543294, some of them are marked as `MOZ_CAN_RUN_SCRIPT_BOUNDARY`
because `MOZ_CAN_RUN_SCRIPT` requires to change base class, but that's
other licenses header or used in our code too many places.

Differential Revision: https://phabricator.services.mozilla.com/D26926

--HG--
extra : moz-landing-system : lando
2019-04-13 12:13:13 +00:00
Masayuki Nakano 0986fb819b Bug 1542506 - Make nsDocShell use mozilla::PresShell* directly rather than nsIPresShell* r=bzbarsky
This patch makes `nsDocShell::GetPresShell()` and
`nsDocShell::GetEldestPresShell()` return `mozilla::PresShell*` and
some non-public methods use `mozilla::PresShell*` directly.

Differential Revision: https://phabricator.services.mozilla.com/D26424

--HG--
extra : moz-landing-system : lando
2019-04-13 01:03:13 +00:00
Brian Grinstead dd5a4c95c6 Bug 1495861 - Convert <radio> to a Custom Element r=surkov
Differential Revision: https://phabricator.services.mozilla.com/D8121

--HG--
extra : moz-landing-system : lando
2019-04-05 21:16:24 +00:00
Masayuki Nakano 5e41233499 Bug 1540990 - Get rid of unnecessary nsIPresShell.h inclusions r=emilio
A lot of files include `nsIPresShell.h` even though currently they don't
need it.  This patch removes the unnecessary inclusions.

Differential Revision: https://phabricator.services.mozilla.com/D25744

--HG--
extra : moz-landing-system : lando
2019-04-04 00:19:48 +00:00
Razvan Maries 1cd564b971 Backed out changeset 3b94c20ba873 (bug 1540990) for build bustages. CLOSED TREE 2019-04-04 02:44:00 +03:00
Masayuki Nakano b2bba953cc Bug 1540990 - Get rid of unnecessary nsIPresShell.h inclusions r=emilio
A lot of files include `nsIPresShell.h` even though currently they don't
need it.  This patch removes the unnecessary inclusions.

Differential Revision: https://phabricator.services.mozilla.com/D25744

--HG--
extra : moz-landing-system : lando
2019-04-03 23:29:38 +00:00
Masayuki Nakano 8329e8382e Bug 1540962 - Make nsICommandManager builtinclass and make users use nsCommandManager directly r=bzbarsky
`nsICommandManager` isn't implemented by JS even in comm-central nor
BlueGriffon.  Therefore, we can make it a builtinclass.

Additionally, this patch makes all users in C++ use `nsCommandManager` which is
the only implementation of `nsICommandManager`.  This avoids QI from
`nsICommandManager` to `nsPICommandUpdater`.

Differential Revision: https://phabricator.services.mozilla.com/D25726

--HG--
extra : moz-landing-system : lando
2019-04-03 12:51:38 +00:00
Masayuki Nakano 9165a150a1 Bug 1540930 - Make nsPresContext use mozilla::PresShell directly rather than via nsIPresShell r=emilio
`nsPresContext` should use `mozilla::PresShell` directly instead of
`nsIPresShell`.  This patch makes it.

Unfortunately, `nsPresContext` and `nsIFrame` have `PresShell()`.  Therefore,
we cannot use `PresShell*` in its methods so that this patch uses `mozilla::`
namespace prefix.

It might be better to rename them as `PresShellPtr()` in another bug.

Differential Revision: https://phabricator.services.mozilla.com/D25721

--HG--
extra : moz-landing-system : lando
2019-04-03 12:40:26 +00:00
Masayuki Nakano de2d589e58 Bug 1540015 - part 3: Rename Document::GetShell() to Document::GetPresShell() and make it return PresShell* rather than nsIPresShell* r=smaug,emilio
This makes `Document::GetShell()` return `PresShell*` instead of `nsIPresShell`.

Additonally, "shell" is unclear ("docshell" vs. "presshell").  Therefore, this
also renames `Document::GetShell()` to `Document::GetPresShell()`.

Similarly, some other method names of `Document` are also renamed from
`*Shell*` to `*PresShell*`.

Differential Revision: https://phabricator.services.mozilla.com/D25338

--HG--
extra : moz-landing-system : lando
2019-03-29 15:12:47 +00:00
Dorel Luca 5a0fa68b78 Backed out 3 changesets (bug 1540015) for build bustage. CLOSED TREE
Backed out changeset 7b71c9da0214 (bug 1540015)
Backed out changeset 5723ddbc5c44 (bug 1540015)
Backed out changeset 9561d2c36fa5 (bug 1540015)
2019-03-29 16:14:26 +02:00
Masayuki Nakano 9273f25ce2 Bug 1540015 - part 3: Rename Document::GetShell() to Document::GetPresShell() and make it return PresShell* rather than nsIPresShell* r=smaug,emilio
This makes `Document::GetShell()` return `PresShell*` instead of `nsIPresShell`.

Additonally, "shell" is unclear ("docshell" vs. "presshell").  Therefore, this
also renames `Document::GetShell()` to `Document::GetPresShell()`.

Similarly, some other method names of `Document` are also renamed from
`*Shell*` to `*PresShell*`.

Differential Revision: https://phabricator.services.mozilla.com/D25338

--HG--
extra : moz-landing-system : lando
2019-03-29 13:09:26 +00:00
James Teh ef2bda893e Bug 1473234: make a11y listen to DOM events from iframes and shadow DOM. r=eeejay
1. Register with the root document window's parent target, since this receives events for iframes and shadow DOM. (The root document itself doesn't.)
2. Hold onto the target node when scheduling processing of the DOM event, as GetOriginalTarget returns null when we process shadow DOM events async.

Depends on D21349

Differential Revision: https://phabricator.services.mozilla.com/D21350

--HG--
extra : moz-landing-system : lando
2019-03-25 05:04:36 +00:00
James Teh 1911fb04f0 Bug 1530931: Correctly handle retrieving a container accessible for a shadow root. r=eeejay
This can happen, for example, when GetAccessibleOrContainer is called within SelectionManager::ProcessSelectionChanged due to focusing a direct child of a shadow root.
In this case, the common ancestor is the shadow root itself.
Previously, we returned null in this case because GetFlattenedTreeParent doesn't work on the shadow root itself.
Now, we check if the given node is the shadow root, and if so, we use the shadow host instead.
This prevents the "We must reach document accessible implementing text interface!" assertion in SelectionManager::ProcessSelectionChanged when a direct child of a shadow root gets focus.

Differential Revision: https://phabricator.services.mozilla.com/D21349

--HG--
extra : moz-landing-system : lando
2019-03-25 05:04:29 +00:00
Narcis Beleuzu 8f2eeb4b40 Backed out 2 changesets (bug 1530931, bug 1473234) for crashtest failures on RootAccessible::RemoveEventListeners . CLOSED TREE
Backed out changeset 54057e1121b5 (bug 1473234)
Backed out changeset faa43bdd3347 (bug 1530931)
2019-03-21 05:53:57 +02:00
James Teh 44f8fe46e4 Bug 1473234: make a11y listen to DOM events from iframes and shadow DOM. r=eeejay
1. Register with the root document window's parent target, since this receives events for iframes and shadow DOM. (The root document itself doesn't.)
2. Hold onto the target node when scheduling processing of the DOM event, as GetOriginalTarget returns null when we process shadow DOM events async.

Differential Revision: https://phabricator.services.mozilla.com/D21350

--HG--
extra : moz-landing-system : lando
2019-03-01 02:48:47 +00:00
James Teh d4b9670c0d Bug 1530931: Correctly handle retrieving a container accessible for a shadow root. r=eeejay
This can happen, for example, when GetAccessibleOrContainer is called within SelectionManager::ProcessSelectionChanged due to focusing a direct child of a shadow root.
In this case, the common ancestor is the shadow root itself.
Previously, we returned null in this case because GetFlattenedTreeParent doesn't work on the shadow root itself.
Now, we check if the given node is the shadow root, and if so, we use the shadow host instead.

This prevents the "We must reach document accessible implementing text interface!" assertion in SelectionManager::ProcessSelectionChanged when a direct child of a shadow root gets focus.

Differential Revision: https://phabricator.services.mozilla.com/D21349

--HG--
extra : moz-landing-system : lando
2019-03-20 15:19:44 +00:00
Boris Zbarsky 9a4ba73134 Bug 1534370 part 3. Mark InsertFromTransferable as MOZ_CAN_RUN_SCRIPT. r=masayuki
Differential Revision: https://phabricator.services.mozilla.com/D23042

--HG--
extra : moz-landing-system : lando
2019-03-12 01:55:03 +00:00
Eitan Isaacson 9559a7c4a2 Bug 1531346 - Check for cyclical relationship with aria-activedescendant. r=MarcoZ
Differential Revision: https://phabricator.services.mozilla.com/D22633

--HG--
extra : moz-landing-system : lando
2019-03-08 07:55:13 +00:00
Eitan Isaacson 130d8fe6b2 Bug 1512567 - Check that we didn't already create an IPCDoc for the DocAccessible. r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D20594

--HG--
extra : moz-landing-system : lando
2019-02-26 17:05:47 +00:00
Samuel Thibault fb05007f2c Bug 919508 - layout: Do not trim spaces when inspected from accessibility layer r=jfkthame
--HG--
extra : histedit_source : 3fbe469291ddca0344d6fd88dcadb6282f1ca846
2019-02-22 22:12:48 +01:00
Masatoshi Kimura e25fbce870 Bug 1528651 - Re-enable warnings-as-errors on Windows in some directories. r=dmajor
--HG--
extra : source : ba86ea25070b37f4725834e1c2d9ec4c0783e119
2019-02-17 15:03:02 +09:00
Markus Stange 0b151b8c2b Bug 1500692 - Centralize profiling category definition and add infrastructure for subcategories. r=njn
The actual subcategories will be added in later patches, so that there are no
unused categories.

Differential Revision: https://phabricator.services.mozilla.com/D11334

--HG--
extra : moz-landing-system : lando
2019-02-16 17:37:43 +00:00
Eitan Isaacson 773b9d611a Bug 1525980 - Make announcement events work over IPC. r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D19061

--HG--
extra : moz-landing-system : lando
2019-02-14 17:42:47 +00:00
Eitan Isaacson baa769abf9 Bug 1525980 - Introduce nsIAccessibleAnnouncementEvent. r=Jamie
Differential Revision: https://phabricator.services.mozilla.com/D19060

--HG--
extra : moz-landing-system : lando
2019-02-14 17:42:45 +00:00
Eitan Isaacson bb5af5a481 Bug 1527254 - Don't rely on tabpanels xul element in Android for offcreen state. r=MarcoZ
Differential Revision: https://phabricator.services.mozilla.com/D19710

--HG--
extra : moz-landing-system : lando
2019-02-14 08:01:36 +00:00
Marco Zehe c0bdc14cea Bug 1525849 - Guard against 0 columns or out of bounds indexes for ARIA grid accessibles, r=Jamie
When returning the column or row index of a given cell, guard against the column count being 0 or the given index being out of bounds of the current grid or table. The MSAA code already did this previously, but now the upper bounds check has been moved to the base classes and an additional guard for the column count been put in place so a division by 0 crash canot happen.

A return value for RowIndexAt and ColIndexAt of -1 indicates an error condition. ATK will automatically deal with this, and the IA2 code has been adjusted to check for this and return an invalid argument error in such cases, too.

Differential Revision: https://phabricator.services.mozilla.com/D18931

--HG--
extra : moz-landing-system : lando
2019-02-07 21:06:42 +00:00
Marco Zehe 91fe1bab37 Bug 1524919 - When getting the cell-index object attribute, make sure to only return positive values, r=Jamie
When getting the cell-index object attribute, now take into account that the row index might be invalid, and bail if that's the case. This should prevent negative index values which were one of the causes of Occasional crashes on Linux with weirdly formed tables like in Gmail.

Differential Revision: https://phabricator.services.mozilla.com/D18546

--HG--
extra : moz-landing-system : lando
2019-02-07 01:12:22 +00:00
garvitdelhi 6bd950c37a Bug 1519185: Remove AttributeWillChange aNewValue parameter r=emilio,bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D17073
2019-01-29 17:59:38 +01:00
Cosmin Sabou 6b126c3ff0 Backed out 2 changesets (bug 1519185) build bustages on nsMenuGroupOwnerX.mm. CLOSED TREE
Backed out changeset e1de5282e21a (bug 1519185)
Backed out changeset 00d8afb01890 (bug 1519185)

--HG--
extra : rebase_source : d92a7d4606992503f24c66093d35676e12a84ff0
2019-01-29 18:22:46 +02:00
garvitdelhi 3b6550b93f Bug 1519185: Remove AttributeWillChange aNewValue parameter r=emilio,bzbarsky
Differential Revision: https://phabricator.services.mozilla.com/D17073

--HG--
extra : moz-landing-system : lando
2019-01-29 15:27:02 +00:00
Cosmin Sabou 7ccc9d8b0b Merge mozilla-inbound to mozilla-central. a=merge 2019-01-19 11:57:49 +02:00
Greg Tatum 7042c8f1c3 Bug 1520526 - Add categories to all profiler markers; r=mstange
This commit adds categories to all markers. This way the profiler's
marker categories and frame label categories agree. There are a few
duplicate category properties on some of the marker payloads, but
this could be cleaned up in a follow-up if needed.

Differential Revision: https://phabricator.services.mozilla.com/D16864

--HG--
extra : moz-landing-system : lando
2019-01-18 15:40:15 +00:00
Marco Zehe b4ebbe90ae Bug 1515186 - Always calculate group position for all children of an accessible after a tree mutation, r=Jamie
Previously, if we had children a, b, c, and d, then removed b, the group position for c and d would potentially be marked as dirty, but a would not. This caused the check for the availability of previous group info to return outdated information.

This patch now always forces the update of all children's group position when a children move has occurred, since it potentially affects all the children, not just the ones after it. In addition, accGroupInfo::Update() now checks if the previous and next siblings that are being used as shortcuts have dirty group info, and are being used only if they do not.

Differential Revision: https://phabricator.services.mozilla.com/D16059

--HG--
extra : moz-landing-system : lando
2019-01-10 05:59:01 +00:00
Ehsan Akhgari e5e885ae31 Bug 1521000 - Part 2: Adjust our clang-format rules to include spaces after the hash for nested preprocessor directives r=sylvestre
# ignore-this-changeset

--HG--
extra : amend_source : 7221c8d15a765df71171099468e7c7faa648f37c
extra : histedit_source : a0cce6015636202bff09e35a13f72e03257a7695
2019-01-18 10:16:18 +01:00
Emilio Cobos Álvarez d2ed260822 Bug 1517241 - Rename nsIDocument to mozilla::dom::Document. r=smaug
Summary: Really sorry for the size of the patch. It's mostly automatic
s/nsIDocument/Document/ but I had to fix up in a bunch of places manually to
add the right namespacing and such.

Overall it's not a very interesting patch I think.

nsDocument.cpp turns into Document.cpp, nsIDocument.h into Document.h and
nsIDocumentInlines.h into DocumentInlines.h.

I also changed a bunch of nsCOMPtr usage to RefPtr, but not all of it.

While fixing up some of the bits I also removed some unneeded OwnerDoc() null
checks and such, but I didn't do anything riskier than that.
2019-01-03 17:48:33 +01:00
James Teh 850ee9ea2b Bug 1515294: Only use SendSyncTextChangeEvent for live regions. r=MarcoZ
In order to support IA2 live regions with e10s (bug 1322532), text change events sent from the child process to the parent process use sync IPC.
That comes at a slight performance cost: the content process is blocked until the parent returns from sending and handling the event.
However, there is no reason to do this if the event is not for an accessible inside a live region; current clients don't need the sync behaviour outside of live regions.

Differential Revision: https://phabricator.services.mozilla.com/D15183

--HG--
extra : source : 415f827cb9ce211c48b0c6625e917582bc81fd3a
2018-12-21 09:16:38 +00:00
arthur.iakab 70a4778dd8 Backed out changeset 415f827cb9ce (bug 1515294) on suspicion of causing content process hangs a=backout CLOSED TREE 2018-12-23 00:04:39 +02:00
James Teh f9cba89c57 Bug 1515294: Only use SendSyncTextChangeEvent for live regions. r=MarcoZ
In order to support IA2 live regions with e10s (bug 1322532), text change events sent from the child process to the parent process use sync IPC.
That comes at a slight performance cost: the content process is blocked until the parent returns from sending and handling the event.
However, there is no reason to do this if the event is not for an accessible inside a live region; current clients don't need the sync behaviour outside of live regions.

Differential Revision: https://phabricator.services.mozilla.com/D15183

--HG--
extra : moz-landing-system : lando
2018-12-21 09:16:38 +00:00
Neil Deakin 9397165b4e Bug 1492326, use Element helper methods in accessibility instead of QueryInterface to get interface implementations that might be implemented by custom elements, r=surkov 2018-12-04 11:32:15 -05:00