Tue, 06 Jan 2015 21:39:09 +0100
Conditionally force memory storage according to privacy.thirdparty.isolate;
This solves Tor bug #9701, complying with disk avoidance documented in
https://www.torproject.org/projects/torbrowser/design/#disk-avoidance.
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* vim: set ts=2 et sw=2 tw=80: */
3 /* This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
7 #ifndef mozilla_a11y_ia2Accessible_h_
8 #define mozilla_a11y_ia2Accessible_h_
10 #include "nsISupports.h"
12 #include "Accessible2_2.h"
14 namespace mozilla {
15 namespace a11y {
17 class ia2Accessible : public IAccessible2_2
18 {
19 public:
21 // IUnknown
22 STDMETHODIMP QueryInterface(REFIID, void**);
24 // IAccessible2
25 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_nRelations(
26 /* [retval][out] */ long* nRelations);
28 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_relation(
29 /* [in] */ long relationIndex,
30 /* [retval][out] */ IAccessibleRelation** relation);
32 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_relations(
33 /* [in] */ long maxRelations,
34 /* [length_is][size_is][out] */ IAccessibleRelation** relation,
35 /* [retval][out] */ long* nRelations);
37 virtual HRESULT STDMETHODCALLTYPE role(
38 /* [retval][out] */ long* role);
40 virtual HRESULT STDMETHODCALLTYPE scrollTo(
41 /* [in] */ enum IA2ScrollType scrollType);
43 virtual HRESULT STDMETHODCALLTYPE scrollToPoint(
44 /* [in] */ enum IA2CoordinateType coordinateType,
45 /* [in] */ long x,
46 /* [in] */ long y);
48 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_groupPosition(
49 /* [out] */ long* groupLevel,
50 /* [out] */ long* similarItemsInGroup,
51 /* [retval][out] */ long* positionInGroup);
53 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_states(
54 /* [retval][out] */ AccessibleStates* states);
56 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_extendedRole(
57 /* [retval][out] */ BSTR* extendedRole);
59 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_localizedExtendedRole(
60 /* [retval][out] */ BSTR* localizedExtendedRole);
62 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_nExtendedStates(
63 /* [retval][out] */ long* nExtendedStates);
65 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_extendedStates(
66 /* [in] */ long maxExtendedStates,
67 /* [length_is][length_is][size_is][size_is][out] */ BSTR** extendedStates,
68 /* [retval][out] */ long* nExtendedStates);
70 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_localizedExtendedStates(
71 /* [in] */ long maxLocalizedExtendedStates,
72 /* [length_is][length_is][size_is][size_is][out] */ BSTR** localizedExtendedStates,
73 /* [retval][out] */ long* nLocalizedExtendedStates);
75 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_uniqueID(
76 /* [retval][out] */ long* uniqueID);
78 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_windowHandle(
79 /* [retval][out] */ HWND* windowHandle);
81 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_indexInParent(
82 /* [retval][out] */ long* indexInParent);
84 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_locale(
85 /* [retval][out] */ IA2Locale* locale);
87 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_attributes(
88 /* [retval][out] */ BSTR* attributes);
90 // IAccessible2_2
91 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_attribute(
92 /* [in] */ BSTR name,
93 /* [out, retval] */ VARIANT* attribute);
95 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_accessibleWithCaret(
96 /* [out] */ IUnknown** accessible,
97 /* [out, retval] */ long* caretOffset);
99 virtual /* [propget] */ HRESULT STDMETHODCALLTYPE get_relationTargetsOfType(
100 /* [in] */ BSTR type,
101 /* [in] */ long maxTargets,
102 /* [out, size_is(,*nTargets)] */ IUnknown*** targets,
103 /* [out, retval] */ long* nTargets
104 );
106 // Helper method
107 static HRESULT ConvertToIA2Attributes(nsIPersistentProperties* aAttributes,
108 BSTR* aIA2Attributes);
109 };
111 } // namespace a11y
112 } // namespace mozilla
114 #endif