Bug 470455 - test_database_sync_embed_visits.js leaks, r=sdwilsh
[wine-gecko.git] / accessible / public / msaa / ISimpleDOMNode.idl
blobb40c78fcc25d61330de170c6a2a89248261e23ae
1 /* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
2 /* ***** BEGIN LICENSE BLOCK *****
3 * Version: MPL 1.1/GPL 2.0/LGPL 2.1
5 * The contents of this file are subject to the Mozilla Public License Version
6 * 1.1 (the "License"); you may not use this file except in compliance with
7 * the License. You may obtain a copy of the License at
8 * http://www.mozilla.org/MPL/
10 * Software distributed under the License is distributed on an "AS IS" basis,
11 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
12 * for the specific language governing rights and limitations under the
13 * License.
15 * The Original Code is mozilla.org code.
17 * The Initial Developer of the Original Code is
18 * Netscape Communications Corporation.
19 * Portions created by the Initial Developer are Copyright (C) 1998
20 * the Initial Developer. All Rights Reserved.
22 * Contributor(s):
23 * Author: Aaron Leventhal (aaronl@netscape.com)
25 * Alternatively, the contents of this file may be used under the terms of
26 * either of the GNU General Public License Version 2 or later (the "GPL"),
27 * or the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
28 * in which case the provisions of the GPL or the LGPL are applicable instead
29 * of those above. If you wish to allow use of your version of this file only
30 * under the terms of either the GPL or the LGPL, and not to allow others to
31 * use your version of this file under the terms of the MPL, indicate your
32 * decision by deleting the provisions above and replace them with the notice
33 * and other provisions required by the GPL or the LGPL. If you do not delete
34 * the provisions above, a recipient may use your version of this file under
35 * the terms of any one of the MPL, the GPL or the LGPL.
37 * ***** END LICENSE BLOCK ***** */
39 cpp_quote("///////////////////////////////////////////////////////////////////////////////////////////////////////")
40 cpp_quote("//")
41 cpp_quote("// ISimpleDOMNode")
42 cpp_quote("// ---------------------------------------------------------------------------------------------------=")
43 cpp_quote("// An interface that extends MSAA's IAccessible to provide readonly DOM node information via cross-process COM.")
44 cpp_quote("//")
45 cpp_quote("// @STATUS UNDER_REVIEW")
46 cpp_quote("//")
47 cpp_quote("// get_nodeInfo(")
48 cpp_quote("// /* [out] */ BSTR *nodeName, // For elements, this is the tag name")
49 cpp_quote("// /* [out] */ short *nameSpaceID,")
50 cpp_quote("// /* [out] */ BSTR *nodeValue, ")
51 cpp_quote("// /* [out] */ unsigned int *numChildren); ")
52 cpp_quote("// /* [out] */ unsigned int *uniqueID; // In Win32 accessible events we generate, the target's childID matches to this")
53 cpp_quote("// /* [out] */ unsigned short *nodeType,")
54 cpp_quote("// ---------------------------------------------------------------------------------------------------=")
55 cpp_quote("// Get the basic information about a node.")
56 cpp_quote("// The namespace ID can be mapped to an URI using nsISimpleDOMDocument::get_nameSpaceURIForID()")
57 cpp_quote("//")
58 cpp_quote("// get_attributes(")
59 cpp_quote("// /* [in] */ unsigned short maxAttribs,")
60 cpp_quote("// /* [out] */ unsigned short *numAttribs,")
61 cpp_quote("// /* [out] */ BSTR *attribNames,")
62 cpp_quote("// /* [out] */ short *nameSpaceID,")
63 cpp_quote("// /* [out] */ BSTR *attribValues);")
64 cpp_quote("// ---------------------------------------------------------------------------------------------------=")
65 cpp_quote("// Returns 3 arrays - the attribute names and values, and a namespace ID for each")
66 cpp_quote("// If the namespace ID is 0, it's the same namespace as the node's namespace")
67 cpp_quote("//")
68 cpp_quote("// get_attributesForNames(")
69 cpp_quote("// /* [in] */ unsigned short numAttribs,")
70 cpp_quote("// /* [in] */ BSTR *attribNames,")
71 cpp_quote("// /* [in] */ short *nameSpaceID,")
72 cpp_quote("// /* [out] */ BSTR *attribValues);")
73 cpp_quote("// ---------------------------------------------------------------------------------------------------=")
74 cpp_quote("// Takes 2 arrays - the attribute names and namespace IDs, and returns an array of corresponding values")
75 cpp_quote("// If the namespace ID is 0, it's the same namespace as the node's namespace")
76 cpp_quote("//")
77 cpp_quote("// computedStyle( ")
78 cpp_quote("// /* [in] */ unsigned short maxStyleProperties,")
79 cpp_quote("// /* [out] */ unsigned short *numStyleProperties, ")
80 cpp_quote("// /* [in] */ boolean useAlternateView, // If TRUE, returns properites for media as set in nsIDOMDocument::set_alternateViewMediaTypes")
81 cpp_quote("// /* [out] */ BSTR *styleProperties, ")
82 cpp_quote("// /* [out] */ BSTR *styleValues);")
83 cpp_quote("// ---------------------------------------------------------------------------------------------------=")
84 cpp_quote("// Returns 2 arrays -- the style properties and their values")
85 cpp_quote("// useAlternateView=FALSE: gets properties for the default media type (usually screen)")
86 cpp_quote("// useAlternateView=TRUE: properties for media types set w/ nsIDOMSimpleDocument::set_alternateViewMediaTypes()")
87 cpp_quote("//")
88 cpp_quote("// computedStyleForProperties( ")
89 cpp_quote("// /* [in] */ unsigned short numStyleProperties, ")
90 cpp_quote("// /* [in] */ boolean useAlternateView, // If TRUE, returns properites for media as set in nsIDOMDocument::set_alternateViewMediaTypes")
91 cpp_quote("// /* [in] */ BSTR *styleProperties, ")
92 cpp_quote("// /* [out] */ BSTR *styleValues);")
93 cpp_quote("// ---------------------------------------------------------------------------------------------------=")
94 cpp_quote("// Scroll the current view so that this dom node is visible.")
95 cpp_quote("// placeTopLeft=TRUE: scroll until the top left corner of the dom node is at the top left corner of the view.")
96 cpp_quote("// placeTopLeft=FALSE: scroll minimally to make the dom node visible. Don't scroll at all if already visible.")
97 cpp_quote("//")
98 cpp_quote("// scrollTo( ")
99 cpp_quote("// /* [in] */ boolean placeTopLeft); ")
100 cpp_quote("// ---------------------------------------------------------------------------------------------------=")
101 cpp_quote("// Returns style property values for those properties in the styleProperties [in] array")
102 cpp_quote("// Returns 2 arrays -- the style properties and their values")
103 cpp_quote("// useAlternateView=FALSE: gets properties for the default media type (usually screen)")
104 cpp_quote("// useAlternateView=TRUE: properties for media types set w/ nsIDOMSimpleDocument::set_alternateViewMediaTypes()")
105 cpp_quote("//")
106 cpp_quote("// get_parentNode (/* [out] */ ISimpleDOMNode **newNodePtr);")
107 cpp_quote("// get_firstChild (/* [out] */ ISimpleDOMNode **newNodePtr);")
108 cpp_quote("// get_lastChild (/* [out] */ ISimpleDOMNode **newNodePtr);")
109 cpp_quote("// get_previousSibling(/* [out] */ ISimpleDOMNode **newNodePtr);")
110 cpp_quote("// get_nextSibling (/* [out] */ ISimpleDOMNode **newNodePtr);")
111 cpp_quote("// get_childAt (/* [in] */ unsigned childIndex, /* [out] */ ISimpleDOMNode **newNodePtr);")
112 cpp_quote("// ---------------------------------------------------------------------------------------------------=")
113 cpp_quote("// DOM navigation - get a different node.")
114 cpp_quote("//")
115 cpp_quote("// get_innerHTML(/* [out] */ BSTR *htmlText);")
116 cpp_quote("// ---------------------------------------------------------------------------------------------------=")
117 cpp_quote("// Returns HTML of this DOM node's subtree. Does not include the start and end tag for this node/element.")
118 cpp_quote("//")
119 cpp_quote("//")
120 cpp_quote("// get_localInterface(/* [out] */ void **localInterface);")
121 cpp_quote("// ---------------------------------------------------------------------------------------------------=")
122 cpp_quote("// Only available in Gecko's process - casts to an XPCOM nsIAccessNode interface pointer")
123 cpp_quote("//")
124 cpp_quote("//")
125 cpp_quote("// get_language(/* [out] */ BSTR *htmlText);")
126 cpp_quote("// ---------------------------------------------------------------------------------------------------=")
127 cpp_quote("// Returns the computed language for this node, or empty string if unknown.")
128 cpp_quote("//")
129 cpp_quote("//")
130 cpp_quote("///////////////////////////////////////////////////////////////////////////////////////////////////////")
131 cpp_quote("")
132 cpp_quote("")
134 import "objidl.idl";
135 import "oaidl.idl";
137 import "ISimpleDOMText.idl";
138 import "ISimpleDOMDocument.idl";
140 [object, uuid(1814ceeb-49e2-407f-af99-fa755a7d2607)]
141 interface ISimpleDOMNode : IUnknown
143 const unsigned short NODETYPE_ELEMENT = 1;
144 const unsigned short NODETYPE_ATTRIBUTE = 2;
145 const unsigned short NODETYPE_TEXT = 3;
146 const unsigned short NODETYPE_CDATA_SECTION = 4;
147 const unsigned short NODETYPE_ENTITY_REFERENCE = 5;
148 const unsigned short NODETYPE_ENTITY = 6;
149 const unsigned short NODETYPE_PROCESSING_INSTRUCTION = 7;
150 const unsigned short NODETYPE_COMMENT = 8;
151 const unsigned short NODETYPE_DOCUMENT = 9;
152 const unsigned short NODETYPE_DOCUMENT_TYPE = 10;
153 const unsigned short NODETYPE_DOCUMENT_FRAGMENT = 11;
154 const unsigned short NODETYPE_NOTATION = 12;
156 [propget] HRESULT nodeInfo(
157 [out] BSTR *nodeName, // for performance returns NULL for text nodes (true nodeName would be "#text")
158 [out] short *nameSpaceID,
159 [out] BSTR *nodeValue,
160 [out] unsigned int *numChildren,
161 [out] unsigned int *uniqueID, // In Win32 accessible events we generate, the target's childID matches to this
162 [out, retval] unsigned short *nodeType
165 [propget] HRESULT attributes(
166 [in] unsigned short maxAttribs,
167 [out, size_is(maxAttribs), length_is(*numAttribs)] BSTR *attribNames,
168 [out, size_is(maxAttribs), length_is(*numAttribs)] short *nameSpaceID,
169 [out, size_is(maxAttribs), length_is(*numAttribs)] BSTR *attribValues,
170 [out, retval] unsigned short *numAttribs
173 [propget] HRESULT attributesForNames(
174 [in] unsigned short numAttribs,
175 [in, size_is(numAttribs), length_is(numAttribs)] BSTR *attribNames,
176 [in, size_is(numAttribs), length_is(numAttribs)] short *nameSpaceID,
177 [out, retval, size_is(numAttribs), length_is(numAttribs)] BSTR *attribValues
180 [propget] HRESULT computedStyle(
181 [in] unsigned short maxStyleProperties,
182 [in] boolean useAlternateView, // If TRUE, returns properites for media as set in nsIDOMDocument::set_alternateViewMediaTypes
183 [out, size_is(maxStyleProperties), length_is(*numStyleProperties)] BSTR *styleProperties,
184 [out, size_is(maxStyleProperties), length_is(*numStyleProperties)] BSTR *styleValues,
185 [out, retval] unsigned short *numStyleProperties
188 [propget] HRESULT computedStyleForProperties(
189 [in] unsigned short numStyleProperties,
190 [in] boolean useAlternateView, // If TRUE, returns properites for media as set in nsIDOMDocument::set_alternateViewMediaTypes
191 [in, size_is(numStyleProperties), length_is(numStyleProperties)] BSTR *styleProperties,
192 [out, retval, size_is(numStyleProperties), length_is(numStyleProperties)] BSTR *styleValues
195 HRESULT scrollTo([in] boolean placeTopLeft);
197 [propget] HRESULT parentNode([out, retval] ISimpleDOMNode **node);
198 [propget] HRESULT firstChild([out, retval] ISimpleDOMNode **node);
199 [propget] HRESULT lastChild([out, retval] ISimpleDOMNode **node);
200 [propget] HRESULT previousSibling([out, retval] ISimpleDOMNode **node);
201 [propget] HRESULT nextSibling([out, retval] ISimpleDOMNode **node);
202 [propget] HRESULT childAt([in] unsigned childIndex,
203 [out, retval] ISimpleDOMNode **node);
205 [propget] HRESULT innerHTML([out, retval] BSTR *innerHTML);
207 [propget, local] HRESULT localInterface([out][retval] void **localInterface);
209 [propget] HRESULT language([out, retval] BSTR *language);
214 uuid(a6245497-9c0b-4449-85a5-bd6ad07df8ea),
215 helpstring("ISimpleDOM Type Library")
217 library ISimpleDOM
219 interface ISimpleDOMNode;
220 interface ISimpleDOMText;
221 interface ISimpleDOMDocument;