Commit Graph

355 Commits

Author SHA1 Message Date
James Teh
aebc388fb6 Bug 1416986 part 2: Include interfaces the client is likely to request in the accessible handler payload. r=aklotz
Now that virtual buffers have to render across processes, we want to eliminate as many cross-process calls as possible.
This includes QueryInterface calls, since buffers query for several interfaces on every node they visit.
To avoid these cross-process QI calls, we include interfaces clients are likely to request in the handler payload.
This way, they get marshaled in the single call used to retrieve the object.

This patch does the following:

1. Passes the interceptor when building the payload.
We need this so we can get interceptors for other interfaces.

2. Splits the payload into two main parts: a static part and a dynamic part.
The (new) static part contains the interface pointers. The dynamic part contains the rest.
This is necessary because the refresh call cannot pass the interceptor, but the interceptor is needed to build the static part.
Also, re-building the static part is pointless when refreshing.

3. Includes the interface pointers in the payload (BuildStaticIA2Data).
The pointers also have to be cleaned up after marshaling.

4. Releases the interface pointers in the handler after the payload is received.
We do this because they're aggregated by the proxy manager as they're unmarshaled.

MozReview-Commit-ID: 6VRLMNScgwW

--HG--
extra : rebase_source : 249589643b7a69e870962ea55a44849bf03a2693
2017-11-15 12:18:18 +10:00
Chris Peterson
0c6b205207 Bug 1415470 - a11y: Fix VS2017 initializer list order warnings. r=yzen
Reorder DocAccessibleParent's and DocAccessibleChild's constructor initializer lists to fix these VS2017 warnings:

a11y/DocAccessibleParent.h(32): warning C5038: data member 'mozilla::a11y::DocAccessibleParent::mShutdown' will be initialized after data member 'mozilla::a11y::DocAccessibleParent::mEmulatedWindowHandle'

accessible/ipc/win/DocAccessibleChild.cpp(22): warning C5038: data member 'mozilla::a11y::DocAccessibleChild::mEmulatedWindowHandle' will be initialized after data member 'mozilla::a11y::DocAccessibleChild::mIsRemoteConstructed'

MozReview-Commit-ID: 8flWtpe13ob

--HG--
extra : rebase_source : 96528a886c099897df691623948d755eecda119f
2017-11-06 23:54:53 -08:00
James Teh
67c58fedf0 Bug 1414118: Update handler's AccessibleTextTearoff for IAccessibleHypertext2. r=MarcoZ
Bug 873444 implemented support for IAccessibleHypertext2.
AccessibleHandler's AccessibleTextTearoff needs to be updated accordingly, thus eliminating an additional cross-process QueryInterface for IAHypertext2 when the client also wants IAText.

MozReview-Commit-ID: EGqYX7jY9Cp

--HG--
extra : rebase_source : cc79b605bf75538bebc10b104e5f6771bc52d2f4
2017-10-30 21:24:15 +10:00
Aaron Klotz
5c0d27a5e4 Bug 1410159: Add additional IUnknown resolution to a11y::HandlerProvider; r=Jamie
MozReview-Commit-ID: 4duTGCN9xJ6

--HG--
extra : rebase_source : f3338181ac309a6255596a751ddeb7a7d70a3d1e
2017-11-02 15:37:57 -06:00
James Teh
f95226e22b Bug 1413072: Eliminate pointless cross-process QueryInterface for IAccessibleText in AccessibleHandler. r=MarcoZ
AccessibleHandler's AccessibleTextTearoff currently makes separate queries for the IAccessibleText and IAccessibleHypertext interfaces.
However, IAccessibleHypertext inherits from IAccessibleText, and wherever one of these interfaces are present, Gecko always implements both.
Therefore, we should just query for and use IAccessibleHypertext for all of these methods, thus saving a cross-process call should a client want both interfaces.

MozReview-Commit-ID: Fb5P7IGDAZZ

--HG--
extra : rebase_source : 08c9484989eaf8b810ef6f9ababf354eee8fa7f8
2017-10-31 12:11:39 +10:00
James Teh
627fc4f0b6 Bug 1409928: Use e10s a11y handler cache for accessibles retrieved via IAccessibleHypertext. r=aklotz
IAccessibleHypertext::hyperlink returns an IAccessibleHyperlink, not an IAccessible2.
previously, the handler didn't know about this interface, so it wasn't used.
Thus, any accessibles retrieved in this way did not benefit from the cache.
This patch teaches the handler about IAccessibleHyperlink so the handler gets used in this case.

MozReview-Commit-ID: 17CxxGyCLrE

--HG--
extra : rebase_source : 7f933bfd880c9ee009eafe8cee4ece4ef83004cd
2017-10-13 17:01:20 +10:00
James Teh
d11dfce827 Bug 1409916: Eliminate pointless cross-process call for IAccessible2_2::get_attribute. r=aklotz
IAccessible2_2::get_attribute is not implemented yet in Gecko.
However, the handler still passes this through, thus resulting in a pointless cross-process call.
Instead, just return E_NOTIMPL in the handler for this method.

MozReview-Commit-ID: 5XHieUC4cuz

--HG--
extra : rebase_source : 814ceda6d9dd4ec26f05a4ff90bbd4af2a6eb84e
2017-10-19 09:22:44 +10:00
Aaron Klotz
5a394f86cf Bug 1411439: Pass reference to owning interceptor into HandlerProvider for payload creation; r=Jamie
MozReview-Commit-ID: GUW4DrsJEn

--HG--
extra : amend_source : 755ff37c8bc40de408f8668e9e44ebfd41bd9136
2017-10-24 17:48:51 -06:00
Aaron Klotz
be5782c8e7 Bug 1412103: Use VARIANT for storing MSAA role in a11y handler cache; r=Jamie
MozReview-Commit-ID: 6dPxrckm8FM
2017-10-26 14:34:02 -06:00
Aaron Klotz
b594b508ec Bug 1363595: Add support for COM handler invalidation events to msaa AccessibleWrap; r=eeejay
MozReview-Commit-ID: OIiUiILiEW

--HG--
extra : rebase_source : 457399a703b6daf0341fcdb3dd058cd21f5dfc8c
2017-03-27 15:45:44 -06:00
Aaron Klotz
c7e3c01c5e Bug 1363595: Add additional fields to accessible handler cache; r=eeejay
MozReview-Commit-ID: GFNtt5MtPjx

--HG--
extra : rebase_source : 52bab1c8205266228e59d23a2db2a865884e6780
2017-08-08 15:12:46 -06:00
Aaron Klotz
7570c7a401 Bug 1409541 - Replace IID_IUnknown with expected interfaces for outparams in a11y content ArrayData. r=Jamie
MozReview-Commit-ID: 4t0h8zH2hsB
2017-10-17 15:03:40 -06:00
Aaron Klotz
743c2cb58b Bug 1406822: Implement a11y::HandlerProvider::GetEffectiveOutParamIid; r=Jamie
MozReview-Commit-ID: BKH3ooMQvN1

--HG--
extra : rebase_source : 50b666c3366e4f354b61ec2c3a37bf7f83c5f362
2017-10-17 15:01:27 -06:00
Nicholas Nethercote
d225f7151b Bug 1400460 - Rename nsIAtom as nsAtom. r=hiro.
(Path is actually r=froydnj.)

Bug 1400459 devirtualized nsIAtom so that it is no longer a subclass of
nsISupports. This means that nsAtom is now a better name for it than nsIAtom.

MozReview-Commit-ID: 91U22X2NydP

--HG--
rename : xpcom/ds/nsIAtom.h => xpcom/ds/nsAtom.h
extra : rebase_source : ac3e904a21b8b48e74534fff964f1623ee937c67
2017-10-03 09:05:19 +11:00
Aaron Klotz
aab52dc8f2 Bug 1383501 - Do not crash when TabParent::RecvPDocAccessibleConstructor receives a null COM proxy sent to the parent process. r=jimm
MozReview-Commit-ID: 5IOuLXc375T
2017-10-04 09:12:25 -06:00
Aaron Klotz
aa44e53f36 Bug 1393600: Ensure that the handler sends a known interface to external clients; r=jimm
MozReview-Commit-ID: F5vxF2pB347
2017-09-24 14:32:36 -06:00
Alexander Surkov
848867821c Bug 1402951 - no show events for content on document load complete, r=aklotz, yzen 2017-10-03 10:58:27 -04:00
Aaron Klotz
f88fa2ef6c Bug 1399557: Add Environment to mscom::ProxyStream and define it for IAccessible; r=jimm
MozReview-Commit-ID: 4wBjnFW9GRa

--HG--
extra : rebase_source : 43308d5c1d926300be222cb59d4913f61cc6c060
2017-09-29 15:41:28 -06:00
Aaron Klotz
abc6376ae3 Bug 1403687: Prevent use of SendSyncTextChangeEvent when replaying text changes from DocAccessibleChild deferred event queue; r=Jamie
MozReview-Commit-ID: 6itBBycWb0h
2017-09-27 15:34:56 -04:00
Aaron Klotz
c0a1a84af9 Bug 1399557: Add diagnostic asserts to interceptor creation code; r=jimm
MozReview-Commit-ID: 9fJxHbxCmgh
2017-09-18 10:49:15 -06:00
Chris Manchester
c0a229d4c3 Bug 1386876 - Replace all uses of DISABLE_STL_WRAPPING with a template, remove DISABLE_STL_WRAPPING. r=glandium
MozReview-Commit-ID: FMEtb5PY7iP

--HG--
extra : rebase_source : 3cdee7528846462c758e623d6bcd2e6e17dbabff
2017-09-11 11:33:26 -07:00
Aaron Klotz
5921c2115b Bug 1393589: Refactor NOPING marshaling into its own class, mscom::FastMarshaler, and use it with IGeckoBackChannel; r=jimm
MozReview-Commit-ID: 9osDoYcvtWV

--HG--
extra : rebase_source : 9ead42f1b0c79f11b15121274a996d33d7ad4830
2017-08-17 15:54:28 -06:00
Aaron Klotz
d7d645f5c4 Bug 1390652: Part 3 - Add proxy wrapper that passes its inner proxy through content as a blob; r=jimm
MozReview-Commit-ID: A4pAyiuJUlz
2017-08-21 15:47:44 -06:00
Aaron Klotz
7319740647 Bug 1390652: Part 1 - Send parent COM proxies to content as IDispatch instead of IAccessible to match the outparam type of IAccessible::get_accParent; r=yzen
MozReview-Commit-ID: 1CplfZrIt6l
2017-08-16 10:56:00 -06:00
Aaron Klotz
24cb1e1776 Bug 1379643: When running under sandbox level >= 3, parent should retain IStream of marshaled interface to be destroyed later; r=jimm
MozReview-Commit-ID: Egb6Yahdbxm

--HG--
extra : rebase_source : a59cfdfdbd1203b89822e68765bd5a0f35b67ada
2017-07-19 12:07:45 -06:00
Aaron Klotz
5e6827da6d Bug 1380214: Ensure that if the handler payload fails to serialize that we may still marshal the accessible itself; r=eeejay
MozReview-Commit-ID: VH06GAR7Ph
2017-07-17 17:19:58 -06:00
Aaron Klotz
22d6b8c708 Bug 1380471: Move follow-up initialization for emulated windows into a callback invoked by the emulated window's WM_CREATE handler; r=yzen
--HG--
extra : rebase_source : d8742fc08cea75e994c9ee4f7c5eca50d40aeac1
2017-07-12 18:01:43 -06:00
Sylvestre Ledru
4e9cf83ee8 Bug 1378712 - Remove all trailing whitespaces r=Ehsan
MozReview-Commit-ID: Kdz2xtTF9EG

--HG--
extra : rebase_source : 7235b3802f25bab29a8c6ba40a181a722f3df0ce
2017-07-06 14:00:35 +02:00
Aaron Klotz
6ac7e2f671 Bug 1378141: Make 32-bit a11y builds make more thorough checks to determine which manifest to load; r=eeejay
MozReview-Commit-ID: 6Hx7ggqt9Ck

--HG--
extra : histedit_source : 28db28e939c947361988cb8e3c8d7932787cf47e
2017-07-04 16:04:35 -07:00
Aaron Klotz
44e203215a Bug 1374792: Modify a11y handler to only invoke IGeckoBackChannel::put_HandlerControl once; r=eeejay
MozReview-Commit-ID: Bxo0IsAuhBh
2017-06-30 12:04:02 -07:00
Aaron Klotz
a129f378f7 Bug 1377195: Remove redundant main thread activation context from a11y::PlatformChild; r=eeejay
--HG--
extra : rebase_source : f8ff2ab8ca7eaf7c0dea9b082af7180f1a6d9208
2017-06-29 10:47:15 -07:00
Aaron Klotz
091386062e Bug 1354077: Modify a11y platform initialization to select and enable appropriate IAccessible manifest; r=eeejay
MozReview-Commit-ID: 1ODOm4Vc4UH
2017-06-06 12:19:17 -06:00
Aaron Klotz
9db0de2b03 Bug 1354077: Add manifests for IAccessible variants: 32-bit and 64-bit; r=jimm
MozReview-Commit-ID: CoHASAsg5tf
2017-06-06 12:19:12 -06:00
Aaron Klotz
d5cffb7895 Bug 1375590: Replace NS_ERROR + IPC_FAIL_NO_REASON with IPC_FAIL in DocAccessibleParent; r=eeejay
--HG--
extra : rebase_source : 3859abca294230d6bc7061ee8b807191790f822b
2017-06-27 11:52:55 -07:00
Bill McCloskey
f115503a0b Bug 1372405 - Provide names for all runnables in the tree (r=froydnj)
MozReview-Commit-ID: DKR6ROiHRS7
2017-06-26 14:19:58 -07:00
Eitan Isaacson
71c52fe020 Bug 1375348 - Include last role as a good role to recieve from child. r=davidb 2017-06-23 08:55:38 -07:00
Carsten "Tomcat" Book
8a1350b5a6 Backed out changeset 4f6302a98ae4 (bug 1372405)
--HG--
extra : rebase_source : 41632f3158e88e692809731394a683d065a73dfb
2017-06-21 13:59:26 +02:00
Bill McCloskey
6b3e84ed5f Bug 1372405 - Provide names for all runnables in the tree (r=froydnj)
MozReview-Commit-ID: DKR6ROiHRS7
2017-06-20 21:44:11 -07:00
Aaron Klotz
a33d941b4e Bug 1374643: Use IID instead of REFIID for a11y::HandlerProvider::mTargetUnkIid; r=jimm
MozReview-Commit-ID: IMFMxhHsbp6

--HG--
extra : amend_source : 10f8b88b0ba538241b59e88ad145db7479d64c07
2017-06-20 12:32:21 -06:00
Carsten "Tomcat" Book
ea1b86680c Backed out changeset 9846de3bd954 (bug 1372405)
--HG--
extra : rebase_source : 5d4a48e8ec394c329994689d938d2a6e9b2752b0
2017-06-20 08:27:02 +02:00
Bill McCloskey
4592152411 Bug 1372405 - Provide names for all runnables in the tree (r=froydnj)
MozReview-Commit-ID: DKR6ROiHRS7
2017-06-19 22:25:47 -07:00
Eitan Isaacson
109fff34b9 Bug 1366374 - Check if AccessibleHandler.dll is registered before using. r=aklotz 2017-06-15 15:55:06 -07:00
Wes Kocher
3ee39c3f47 Backed out 3 changesets (bug 1354077) for assertions in AccessibleWrap.cpp a=backout CLOSED TREE
Backed out changeset 1380fe0f701b (bug 1354077)
Backed out changeset 2b5602bd352a (bug 1354077)
Backed out changeset a0fc3a1a9122 (bug 1354077)

MozReview-Commit-ID: ABHV3evXKrG
2017-06-12 16:54:10 -07:00
Aaron Klotz
da19e2296f Bug 1354077: Modify a11y platform initialization to select and enable appropriate IAccessible manifest; r=eeejay
MozReview-Commit-ID: 1ODOm4Vc4UH

--HG--
extra : rebase_source : 6bac99f6e5e6318cf856f860edb373930979c92a
2017-06-06 12:19:17 -06:00
Aaron Klotz
05e5a2e310 Bug 1354077: Add manifests for IAccessible variants: 32-bit and 64-bit; r=jimm
MozReview-Commit-ID: CoHASAsg5tf

--HG--
extra : rebase_source : 84e30f4601c5f628cc731e1796601381cc012b6c
2017-06-06 12:19:12 -06:00
Aaron Klotz
230ddb60a5 Bug 1368571: Modify handler and interceptor marshaling code so that it strips out any handlers from proxies that are destined for non-Gecko processes; r=jimm
MozReview-Commit-ID: A1lCqvbQYAF

There is no clean API-based solution to this, so instead I went grovelling
through the DCOM wire protocol and was able to write a function that converts
handler OBJREFs into standard OBJREFs.

See also:
https://msdn.microsoft.com/en-us/library/cc226801

--HG--
extra : rebase_source : a650055c4adda3a1d99262e47f2b463074c6b935
2017-06-06 17:35:51 -06:00
Jim Mathies
10b72ec89d Bug 1309271 - Fire accessibility focus events from focused content elements when focus changes from chrome to content. r=surkov
MozReview-Commit-ID: 5Iu2TQ58kGa
2017-06-06 06:09:01 -05:00
Aaron Klotz
570cbae5c4 Bug 1364544: Ensure that proxied CARET_MOVED and FOCUS events update the Win32 system caret before firing their WinEvents; r=eeejay
MozReview-Commit-ID: LVML7EZaSYD

In non-e10s AccessibleWrap::HandleAccEvent, we special case our handling of
CARET_MOVED and FOCUS events with a call to UpdateSystemCaretFor. In e10s mode
we were not doing the same thing for proxied events sent from content. This
threw JAWS for a loop and presumably messes up other ATs as well.

This patch modifies the IPDL messages for these two events so that we may
send the caret rect along with the event, thus allowing us to update the
system caret for proxied events as well.

--HG--
extra : rebase_source : e1502c12b038739520afd5c7078d011e25ea669e
2017-05-15 14:11:46 -06:00
David Parks
cff8d258a2 Bug 1330484 - Part 2: Remove invalid assert that checked that removed a11y child documents have no children. r=jimm
Here is a scenario under which the assert is invalid:

RecvHideEvent is received on a DocAccessibleParent DAP1 that has a child document DAP2... that in turn has a child document DAP3.  DAP1::RecvHideEvent calls Shutdown on its root ProxyAccessible.  This recursively calls Shutdown on child ProxyAccessibles until it reaches the one that is the parent of the child document DAP2.  ProxyAccessibleBase::Shutdown then attempts to Unbind DAP2, which calls DAP1::RemoveChildDoc, which trips the assert because DAP2 has child document DAP3.
2017-05-22 02:39:11 -07:00
David Parks
1810e88c32 Bug 1359129 - Use the most recent RootDocAccessible when delaying DocAccessibleChild messages. r=aklotz
We sometimes briefly have more than one root DocAccessible associated with a TabChild, for example, while navigating links in a page.  This patch makes sure that we use the correct accessible when delaying messages that we forward to the parent process.
2017-05-01 14:04:55 -07:00