mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-26 22:32:46 +00:00
Bug 1794974
: Part 6: Add xpcAccessibilityService::setCacheDomains, r=Jamie
This revision implements a simple way to set cache domains from XPCOM, which is crucial for testing caching granularity. Differential Revision: https://phabricator.services.mozilla.com/D220040
This commit is contained in:
parent
9d832bd02b
commit
50578506c1
@ -78,6 +78,15 @@ interface nsIAccessibilityService : nsISupports
|
||||
*/
|
||||
nsIAccessible getAccessibleFromCache(in Node aNode);
|
||||
|
||||
/**
|
||||
* Set the active cache domains. If any given domains are not currently
|
||||
* active, then the accessibility service will enable them in all content
|
||||
* processes, causing them to be cached.
|
||||
*
|
||||
* @param aCacheDomains [in] the cache domains to set
|
||||
*/
|
||||
void setCacheDomains(in unsigned long long aCacheDomains);
|
||||
|
||||
/**
|
||||
* Create a new pivot for tracking a position and traversing a subtree.
|
||||
*
|
||||
|
@ -229,6 +229,17 @@ xpcAccessibilityService::GetAccessibleFromCache(nsINode* aNode,
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
xpcAccessibilityService::SetCacheDomains(uint64_t aCacheDomains) {
|
||||
nsAccessibilityService* accService = GetAccService();
|
||||
if (!accService) {
|
||||
return NS_ERROR_SERVICE_NOT_AVAILABLE;
|
||||
}
|
||||
|
||||
accService->SetCacheDomains(aCacheDomains);
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
NS_IMETHODIMP
|
||||
xpcAccessibilityService::CreateAccessiblePivot(nsIAccessible* aRoot,
|
||||
nsIAccessiblePivot** aPivot) {
|
||||
|
Loading…
Reference in New Issue
Block a user