PageRenderTime 45ms CodeModel.GetById 14ms RepoModel.GetById 1ms app.codeStats 0ms

/mozilla/mozilla/dist/include/accessibility/nsIAccessNode.h

http://kmbrasil.codeplex.com
C++ Header | 306 lines | 145 code | 51 blank | 110 comment | 0 complexity | b38dc3c3896527a79c28580b127016ed MD5 | raw file
Possible License(s): MPL-2.0-no-copyleft-exception, GPL-2.0
  1. /*
  2. * DO NOT EDIT. THIS FILE IS GENERATED FROM h:/projects/mozilla/mozilla/accessible/public/nsIAccessNode.idl
  3. */
  4. #ifndef __gen_nsIAccessNode_h__
  5. #define __gen_nsIAccessNode_h__
  6. #ifndef __gen_nsISupports_h__
  7. #include "nsISupports.h"
  8. #endif
  9. /* For IDL files that don't want to include root IDL files. */
  10. #ifndef NS_NO_VTABLE
  11. #define NS_NO_VTABLE
  12. #endif
  13. class nsIDOMNode; /* forward declaration */
  14. class nsIAccessibleDocument; /* forward declaration */
  15. /* starting interface: nsIAccessNode */
  16. #define NS_IACCESSNODE_IID_STR "46820f9b-3088-4046-ab0f-56fdacdc7a82"
  17. #define NS_IACCESSNODE_IID \
  18. {0x46820f9b, 0x3088, 0x4046, \
  19. { 0xab, 0x0f, 0x56, 0xfd, 0xac, 0xdc, 0x7a, 0x82 }}
  20. /**
  21. * An interface used by in-process accessibility clients
  22. * to get style, window, markup and other information about
  23. * a DOM node. When accessibility is active in Gecko,
  24. * every DOM node can have one nsIAccessNode for each
  25. * pres shell the DOM node is rendered in.
  26. * The nsIAccessNode implementations are instantiated lazily.
  27. * The nsIAccessNode tree for a given dom window
  28. * has a one to one relationship to the DOM tree.
  29. * If the DOM node for this access node is "accessible",
  30. * then a QueryInterface to nsIAccessible will succeed.
  31. *
  32. * @status UNDER_REVIEW
  33. */
  34. class NS_NO_VTABLE nsIAccessNode : public nsISupports {
  35. public:
  36. NS_DEFINE_STATIC_IID_ACCESSOR(NS_IACCESSNODE_IID)
  37. /**
  38. * The DOM node this nsIAccessNode is associated with.
  39. */
  40. /* readonly attribute nsIDOMNode DOMNode; */
  41. NS_IMETHOD GetDOMNode(nsIDOMNode * *aDOMNode) = 0;
  42. /**
  43. * The number of DOM children for the DOM node, which
  44. * matches the number of nsIAccessNode children for this
  45. * nsIAccessNode.
  46. */
  47. /* readonly attribute long numChildren; */
  48. NS_IMETHOD GetNumChildren(PRInt32 *aNumChildren) = 0;
  49. /**
  50. * Get the nth child of this node
  51. * @param childNum Zero-based child index
  52. * @return The nth nsIAccessNode child
  53. */
  54. /* nsIAccessNode getChildNodeAt (in long childNum); */
  55. NS_IMETHOD GetChildNodeAt(PRInt32 childNum, nsIAccessNode **_retval) = 0;
  56. /**
  57. * The parent nsIAccessNode
  58. */
  59. /* readonly attribute nsIAccessNode parentNode; */
  60. NS_IMETHOD GetParentNode(nsIAccessNode * *aParentNode) = 0;
  61. /**
  62. * The first nsIAccessNode child
  63. */
  64. /* readonly attribute nsIAccessNode firstChildNode; */
  65. NS_IMETHOD GetFirstChildNode(nsIAccessNode * *aFirstChildNode) = 0;
  66. /**
  67. * The last nsIAccessNode child
  68. */
  69. /* readonly attribute nsIAccessNode lastChildNode; */
  70. NS_IMETHOD GetLastChildNode(nsIAccessNode * *aLastChildNode) = 0;
  71. /**
  72. * The previous nsIAccessNode sibling
  73. */
  74. /* readonly attribute nsIAccessNode previousSiblingNode; */
  75. NS_IMETHOD GetPreviousSiblingNode(nsIAccessNode * *aPreviousSiblingNode) = 0;
  76. /**
  77. * The next nsIAccessNode sibling
  78. */
  79. /* readonly attribute nsIAccessNode nextSiblingNode; */
  80. NS_IMETHOD GetNextSiblingNode(nsIAccessNode * *aNextSiblingNode) = 0;
  81. /**
  82. * The nsIAccessibleDocument that this nsIAccessNode
  83. * resides in.
  84. */
  85. /* readonly attribute nsIAccessibleDocument accessibleDocument; */
  86. NS_IMETHOD GetAccessibleDocument(nsIAccessibleDocument * *aAccessibleDocument) = 0;
  87. /**
  88. * The innerHTML for the DOM node
  89. * This is a text string of all the markup inside the DOM
  90. * node, not including the start and end tag for the node.
  91. */
  92. /* readonly attribute DOMString innerHTML; */
  93. NS_IMETHOD GetInnerHTML(nsAString & aInnerHTML) = 0;
  94. /**
  95. * The OS window handle for the window this node
  96. * is being displayed in.
  97. */
  98. /* [noscript] readonly attribute voidPtr ownerWindow; */
  99. NS_IMETHOD GetOwnerWindow(void * *aOwnerWindow) = 0;
  100. /**
  101. * A unique ID calculated for this DOM node, for the
  102. * purposes of caching and referencing this object.
  103. */
  104. /* [noscript] readonly attribute voidPtr uniqueID; */
  105. NS_IMETHOD GetUniqueID(void * *aUniqueID) = 0;
  106. /**
  107. * Retrieve the computed style value for this DOM node, if it is a DOM element.
  108. * Note: the meanings of width, height and other size measurements depend
  109. * on the version of CSS being used. Therefore, for bounds information,
  110. * it is better to use nsIAccessible::accGetBounds.
  111. * @param pseudoElt The pseudo element to retrieve style for, or NULL
  112. * for general computed style information for this node.
  113. * @param propertyName Retrieve the computed style value for this property name,
  114. * for example "border-bottom".
  115. */
  116. /* DOMString getComputedStyleValue (in DOMString pseudoElt, in DOMString propertyName); */
  117. NS_IMETHOD GetComputedStyleValue(const nsAString & pseudoElt, const nsAString & propertyName, nsAString & _retval) = 0;
  118. };
  119. /* Use this macro when declaring classes that implement this interface. */
  120. #define NS_DECL_NSIACCESSNODE \
  121. NS_IMETHOD GetDOMNode(nsIDOMNode * *aDOMNode); \
  122. NS_IMETHOD GetNumChildren(PRInt32 *aNumChildren); \
  123. NS_IMETHOD GetChildNodeAt(PRInt32 childNum, nsIAccessNode **_retval); \
  124. NS_IMETHOD GetParentNode(nsIAccessNode * *aParentNode); \
  125. NS_IMETHOD GetFirstChildNode(nsIAccessNode * *aFirstChildNode); \
  126. NS_IMETHOD GetLastChildNode(nsIAccessNode * *aLastChildNode); \
  127. NS_IMETHOD GetPreviousSiblingNode(nsIAccessNode * *aPreviousSiblingNode); \
  128. NS_IMETHOD GetNextSiblingNode(nsIAccessNode * *aNextSiblingNode); \
  129. NS_IMETHOD GetAccessibleDocument(nsIAccessibleDocument * *aAccessibleDocument); \
  130. NS_IMETHOD GetInnerHTML(nsAString & aInnerHTML); \
  131. NS_IMETHOD GetOwnerWindow(void * *aOwnerWindow); \
  132. NS_IMETHOD GetUniqueID(void * *aUniqueID); \
  133. NS_IMETHOD GetComputedStyleValue(const nsAString & pseudoElt, const nsAString & propertyName, nsAString & _retval);
  134. /* Use this macro to declare functions that forward the behavior of this interface to another object. */
  135. #define NS_FORWARD_NSIACCESSNODE(_to) \
  136. NS_IMETHOD GetDOMNode(nsIDOMNode * *aDOMNode) { return _to GetDOMNode(aDOMNode); } \
  137. NS_IMETHOD GetNumChildren(PRInt32 *aNumChildren) { return _to GetNumChildren(aNumChildren); } \
  138. NS_IMETHOD GetChildNodeAt(PRInt32 childNum, nsIAccessNode **_retval) { return _to GetChildNodeAt(childNum, _retval); } \
  139. NS_IMETHOD GetParentNode(nsIAccessNode * *aParentNode) { return _to GetParentNode(aParentNode); } \
  140. NS_IMETHOD GetFirstChildNode(nsIAccessNode * *aFirstChildNode) { return _to GetFirstChildNode(aFirstChildNode); } \
  141. NS_IMETHOD GetLastChildNode(nsIAccessNode * *aLastChildNode) { return _to GetLastChildNode(aLastChildNode); } \
  142. NS_IMETHOD GetPreviousSiblingNode(nsIAccessNode * *aPreviousSiblingNode) { return _to GetPreviousSiblingNode(aPreviousSiblingNode); } \
  143. NS_IMETHOD GetNextSiblingNode(nsIAccessNode * *aNextSiblingNode) { return _to GetNextSiblingNode(aNextSiblingNode); } \
  144. NS_IMETHOD GetAccessibleDocument(nsIAccessibleDocument * *aAccessibleDocument) { return _to GetAccessibleDocument(aAccessibleDocument); } \
  145. NS_IMETHOD GetInnerHTML(nsAString & aInnerHTML) { return _to GetInnerHTML(aInnerHTML); } \
  146. NS_IMETHOD GetOwnerWindow(void * *aOwnerWindow) { return _to GetOwnerWindow(aOwnerWindow); } \
  147. NS_IMETHOD GetUniqueID(void * *aUniqueID) { return _to GetUniqueID(aUniqueID); } \
  148. NS_IMETHOD GetComputedStyleValue(const nsAString & pseudoElt, const nsAString & propertyName, nsAString & _retval) { return _to GetComputedStyleValue(pseudoElt, propertyName, _retval); }
  149. /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
  150. #define NS_FORWARD_SAFE_NSIACCESSNODE(_to) \
  151. NS_IMETHOD GetDOMNode(nsIDOMNode * *aDOMNode) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetDOMNode(aDOMNode); } \
  152. NS_IMETHOD GetNumChildren(PRInt32 *aNumChildren) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetNumChildren(aNumChildren); } \
  153. NS_IMETHOD GetChildNodeAt(PRInt32 childNum, nsIAccessNode **_retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetChildNodeAt(childNum, _retval); } \
  154. NS_IMETHOD GetParentNode(nsIAccessNode * *aParentNode) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetParentNode(aParentNode); } \
  155. NS_IMETHOD GetFirstChildNode(nsIAccessNode * *aFirstChildNode) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetFirstChildNode(aFirstChildNode); } \
  156. NS_IMETHOD GetLastChildNode(nsIAccessNode * *aLastChildNode) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetLastChildNode(aLastChildNode); } \
  157. NS_IMETHOD GetPreviousSiblingNode(nsIAccessNode * *aPreviousSiblingNode) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetPreviousSiblingNode(aPreviousSiblingNode); } \
  158. NS_IMETHOD GetNextSiblingNode(nsIAccessNode * *aNextSiblingNode) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetNextSiblingNode(aNextSiblingNode); } \
  159. NS_IMETHOD GetAccessibleDocument(nsIAccessibleDocument * *aAccessibleDocument) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetAccessibleDocument(aAccessibleDocument); } \
  160. NS_IMETHOD GetInnerHTML(nsAString & aInnerHTML) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetInnerHTML(aInnerHTML); } \
  161. NS_IMETHOD GetOwnerWindow(void * *aOwnerWindow) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetOwnerWindow(aOwnerWindow); } \
  162. NS_IMETHOD GetUniqueID(void * *aUniqueID) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetUniqueID(aUniqueID); } \
  163. NS_IMETHOD GetComputedStyleValue(const nsAString & pseudoElt, const nsAString & propertyName, nsAString & _retval) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetComputedStyleValue(pseudoElt, propertyName, _retval); }
  164. #if 0
  165. /* Use the code below as a template for the implementation class for this interface. */
  166. /* Header file */
  167. class nsAccessNode : public nsIAccessNode
  168. {
  169. public:
  170. NS_DECL_ISUPPORTS
  171. NS_DECL_NSIACCESSNODE
  172. nsAccessNode();
  173. private:
  174. ~nsAccessNode();
  175. protected:
  176. /* additional members */
  177. };
  178. /* Implementation file */
  179. NS_IMPL_ISUPPORTS1(nsAccessNode, nsIAccessNode)
  180. nsAccessNode::nsAccessNode()
  181. {
  182. /* member initializers and constructor code */
  183. }
  184. nsAccessNode::~nsAccessNode()
  185. {
  186. /* destructor code */
  187. }
  188. /* readonly attribute nsIDOMNode DOMNode; */
  189. NS_IMETHODIMP nsAccessNode::GetDOMNode(nsIDOMNode * *aDOMNode)
  190. {
  191. return NS_ERROR_NOT_IMPLEMENTED;
  192. }
  193. /* readonly attribute long numChildren; */
  194. NS_IMETHODIMP nsAccessNode::GetNumChildren(PRInt32 *aNumChildren)
  195. {
  196. return NS_ERROR_NOT_IMPLEMENTED;
  197. }
  198. /* nsIAccessNode getChildNodeAt (in long childNum); */
  199. NS_IMETHODIMP nsAccessNode::GetChildNodeAt(PRInt32 childNum, nsIAccessNode **_retval)
  200. {
  201. return NS_ERROR_NOT_IMPLEMENTED;
  202. }
  203. /* readonly attribute nsIAccessNode parentNode; */
  204. NS_IMETHODIMP nsAccessNode::GetParentNode(nsIAccessNode * *aParentNode)
  205. {
  206. return NS_ERROR_NOT_IMPLEMENTED;
  207. }
  208. /* readonly attribute nsIAccessNode firstChildNode; */
  209. NS_IMETHODIMP nsAccessNode::GetFirstChildNode(nsIAccessNode * *aFirstChildNode)
  210. {
  211. return NS_ERROR_NOT_IMPLEMENTED;
  212. }
  213. /* readonly attribute nsIAccessNode lastChildNode; */
  214. NS_IMETHODIMP nsAccessNode::GetLastChildNode(nsIAccessNode * *aLastChildNode)
  215. {
  216. return NS_ERROR_NOT_IMPLEMENTED;
  217. }
  218. /* readonly attribute nsIAccessNode previousSiblingNode; */
  219. NS_IMETHODIMP nsAccessNode::GetPreviousSiblingNode(nsIAccessNode * *aPreviousSiblingNode)
  220. {
  221. return NS_ERROR_NOT_IMPLEMENTED;
  222. }
  223. /* readonly attribute nsIAccessNode nextSiblingNode; */
  224. NS_IMETHODIMP nsAccessNode::GetNextSiblingNode(nsIAccessNode * *aNextSiblingNode)
  225. {
  226. return NS_ERROR_NOT_IMPLEMENTED;
  227. }
  228. /* readonly attribute nsIAccessibleDocument accessibleDocument; */
  229. NS_IMETHODIMP nsAccessNode::GetAccessibleDocument(nsIAccessibleDocument * *aAccessibleDocument)
  230. {
  231. return NS_ERROR_NOT_IMPLEMENTED;
  232. }
  233. /* readonly attribute DOMString innerHTML; */
  234. NS_IMETHODIMP nsAccessNode::GetInnerHTML(nsAString & aInnerHTML)
  235. {
  236. return NS_ERROR_NOT_IMPLEMENTED;
  237. }
  238. /* [noscript] readonly attribute voidPtr ownerWindow; */
  239. NS_IMETHODIMP nsAccessNode::GetOwnerWindow(void * *aOwnerWindow)
  240. {
  241. return NS_ERROR_NOT_IMPLEMENTED;
  242. }
  243. /* [noscript] readonly attribute voidPtr uniqueID; */
  244. NS_IMETHODIMP nsAccessNode::GetUniqueID(void * *aUniqueID)
  245. {
  246. return NS_ERROR_NOT_IMPLEMENTED;
  247. }
  248. /* DOMString getComputedStyleValue (in DOMString pseudoElt, in DOMString propertyName); */
  249. NS_IMETHODIMP nsAccessNode::GetComputedStyleValue(const nsAString & pseudoElt, const nsAString & propertyName, nsAString & _retval)
  250. {
  251. return NS_ERROR_NOT_IMPLEMENTED;
  252. }
  253. /* End of implementation class template. */
  254. #endif
  255. #endif /* __gen_nsIAccessNode_h__ */