mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
bug 1196460 - add method to get wrapper of proxy for document containing this proxied accessible r=surkov
This commit is contained in:
parent
83f4e2a702
commit
06230447cd
@ -9,12 +9,14 @@
|
||||
|
||||
#include "Compatibility.h"
|
||||
#include "DocAccessible-inl.h"
|
||||
#include "mozilla/a11y/DocAccessibleParent.h"
|
||||
#include "EnumVariant.h"
|
||||
#include "nsAccUtils.h"
|
||||
#include "nsCoreUtils.h"
|
||||
#include "nsIAccessibleEvent.h"
|
||||
#include "nsWinUtils.h"
|
||||
#include "mozilla/a11y/ProxyAccessible.h"
|
||||
#include "ProxyWrappers.h"
|
||||
#include "ServiceProvider.h"
|
||||
#include "Relation.h"
|
||||
#include "Role.h"
|
||||
@ -1274,6 +1276,22 @@ AccessibleWrap::HandleAccEvent(AccEvent* aEvent)
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
DocProxyAccessibleWrap*
|
||||
AccessibleWrap::DocProxyWrapper() const
|
||||
{
|
||||
MOZ_ASSERT(IsProxy());
|
||||
|
||||
ProxyAccessible* proxy = Proxy();
|
||||
if (!proxy) {
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
AccessibleWrap* acc = WrapperFor(proxy->Document());
|
||||
MOZ_ASSERT(acc->IsDoc());
|
||||
|
||||
return static_cast<DocProxyAccessibleWrap*>(acc);
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
// AccessibleWrap
|
||||
|
||||
|
@ -26,6 +26,7 @@
|
||||
|
||||
namespace mozilla {
|
||||
namespace a11y {
|
||||
class DocProxyAccessibleWrap;
|
||||
|
||||
class AccessibleWrap : public Accessible,
|
||||
public ia2Accessible,
|
||||
@ -183,6 +184,11 @@ protected:
|
||||
uint32_t mID;
|
||||
#endif
|
||||
|
||||
/**
|
||||
* Return the wrapper for the document's proxy.
|
||||
*/
|
||||
DocProxyAccessibleWrap* DocProxyWrapper() const;
|
||||
|
||||
/**
|
||||
* Creates ITypeInfo for LIBID_Accessibility if it's needed and returns it.
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user