AccessibilityUIElementManx.cpp 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806
  1. /*
  2. * Copyright (C) 2008 Apple Inc. All Rights Reserved.
  3. * Copyright (C) 2009 Jan Michael Alonzo
  4. *
  5. * Redistribution and use in source and binary forms, with or without
  6. * modification, are permitted provided that the following conditions
  7. * are met:
  8. * 1. Redistributions of source code must retain the above copyright
  9. * notice, this list of conditions and the following disclaimer.
  10. * 2. Redistributions in binary form must reproduce the above copyright
  11. * notice, this list of conditions and the following disclaimer in the
  12. * documentation and/or other materials provided with the distribution.
  13. *
  14. * THIS SOFTWARE IS PROVIDED BY APPLE INC. ``AS IS'' AND ANY
  15. * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
  16. * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
  17. * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR
  18. * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
  19. * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
  20. * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
  21. * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY
  22. * OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
  23. * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
  24. * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
  25. */
  26. #include "config.h"
  27. #include "AccessibilityUIElement.h"
  28. #include "WebCoreSupport/DumpRenderTreeSupportManx.h"
  29. #include <JavaScriptCore/JSStringRef.h>
  30. #include <wtf/Assertions.h>
  31. #include <wtf/gobject/GOwnPtr.h>
  32. #include <wtf/gobject/GRefPtr.h>
  33. // dummy
  34. #define ATK_ACTION(x) (0)
  35. #define ATK_IS_ACTION(x) (1)
  36. #define ATK_OBJECT(x) (0)
  37. #define ATK_COMPONENT(x) (0)
  38. #define ATK_IS_VALUE(x) (1)
  39. #define ATK_VALUE(x) (0)
  40. #define ATK_XY_SCREEN (1)
  41. #define G_VALUE_HOLDS_DOUBLE(x) (0)
  42. #define G_VALUE_HOLDS_INT(x) (0)
  43. #define ATK_IS_OBJECT(x) (0)
  44. #define ATK_ROLE_DOCUMENT_FRAME (0)
  45. static void atk_action_do_action(int, int)
  46. {
  47. }
  48. static void* atk_object_ref_accessible_child(int, int)
  49. {
  50. return 0;
  51. }
  52. static void atk_component_get_position(int, int*, int*, int)
  53. {
  54. }
  55. static void atk_component_get_size(int, int*, int*)
  56. {
  57. }
  58. // - dummy
  59. AccessibilityUIElement::AccessibilityUIElement(PlatformUIElement element)
  60. : m_element(element)
  61. {
  62. }
  63. AccessibilityUIElement::AccessibilityUIElement(const AccessibilityUIElement& other)
  64. : m_element(other.m_element)
  65. {
  66. }
  67. AccessibilityUIElement::~AccessibilityUIElement()
  68. {
  69. }
  70. void AccessibilityUIElement::getLinkedUIElements(Vector<AccessibilityUIElement>&)
  71. {
  72. }
  73. void AccessibilityUIElement::getDocumentLinks(Vector<AccessibilityUIElement>&)
  74. {
  75. }
  76. void AccessibilityUIElement::getChildren(Vector<AccessibilityUIElement>&)
  77. {
  78. #if 0
  79. int count = childrenCount();
  80. for (int i = 0; i < count; i++) {
  81. AtkObject* child = atk_object_ref_accessible_child(ATK_OBJECT(m_element), i);
  82. children.append(AccessibilityUIElement(child));
  83. }
  84. #endif
  85. }
  86. void AccessibilityUIElement::getChildrenWithRange(Vector<AccessibilityUIElement>&, unsigned location, unsigned length)
  87. {
  88. #if 0
  89. for (unsigned i = start; i < end; i++) {
  90. AtkObject* child = atk_object_ref_accessible_child(ATK_OBJECT(m_element), i);
  91. elementVector.append(AccessibilityUIElement(child));
  92. }
  93. #endif
  94. }
  95. AccessibilityUIElement AccessibilityUIElement::elementAtPoint(int x, int y)
  96. {
  97. return 0;
  98. }
  99. AccessibilityUIElement AccessibilityUIElement::getChildAtIndex(unsigned index)
  100. {
  101. Vector<AccessibilityUIElement> children;
  102. getChildrenWithRange(children, index, index + 1);
  103. if (children.size() == 1)
  104. return children.at(0);
  105. return 0;
  106. }
  107. unsigned AccessibilityUIElement::indexOfChild(AccessibilityUIElement*)
  108. {
  109. return 0;
  110. }
  111. int AccessibilityUIElement::childrenCount()
  112. {
  113. if (!m_element)
  114. return 0;
  115. ASSERT(ATK_IS_OBJECT(m_element));
  116. // return atk_object_get_n_accessible_children(ATK_OBJECT(m_element))
  117. }
  118. AccessibilityUIElement AccessibilityUIElement::titleUIElement()
  119. {
  120. return 0;
  121. }
  122. AccessibilityUIElement AccessibilityUIElement::parentElement()
  123. {
  124. if (!m_element)
  125. return 0;
  126. ASSERT(ATK_IS_OBJECT(m_element));
  127. void* parent = 0;
  128. // AtkObject* parent = atk_object_get_parent(ATK_OBJECT(m_element));
  129. return parent ? AccessibilityUIElement(parent) : 0;
  130. }
  131. void AccessibilityUIElement::takeFocus()
  132. {
  133. }
  134. void AccessibilityUIElement::takeSelection()
  135. {
  136. }
  137. void AccessibilityUIElement::addSelection()
  138. {
  139. }
  140. void AccessibilityUIElement::removeSelection()
  141. {
  142. }
  143. JSStringRef AccessibilityUIElement::allAttributes()
  144. {
  145. if (!m_element)
  146. return JSStringCreateWithCharacters(0, 0);
  147. ASSERT(ATK_IS_OBJECT(m_element));
  148. // return JSStringCreateWithUTF8CString(attributeSetToString(atk_object_get_attributes(ATK_OBJECT(m_element))));
  149. }
  150. JSStringRef AccessibilityUIElement::attributesOfLinkedUIElements()
  151. {
  152. return JSStringCreateWithCharacters(0, 0);
  153. }
  154. AccessibilityUIElement AccessibilityUIElement::linkedUIElementAtIndex(unsigned)
  155. {
  156. return 0;
  157. }
  158. JSStringRef AccessibilityUIElement::attributesOfDocumentLinks()
  159. {
  160. return JSStringCreateWithCharacters(0, 0);
  161. }
  162. JSStringRef AccessibilityUIElement::attributesOfChildren()
  163. {
  164. return JSStringCreateWithCharacters(0, 0);
  165. }
  166. JSStringRef AccessibilityUIElement::parameterizedAttributeNames()
  167. {
  168. return JSStringCreateWithCharacters(0, 0);
  169. }
  170. void AccessibilityUIElement::increment()
  171. {
  172. if (!m_element)
  173. return;
  174. ASSERT(ATK_IS_OBJECT(m_element));
  175. // DumpRenderTreeSupportGtk::incrementAccessibilityValue(ATK_OBJECT(m_element));
  176. }
  177. void AccessibilityUIElement::decrement()
  178. {
  179. if (!m_element)
  180. return;
  181. ASSERT(ATK_IS_OBJECT(m_element));
  182. // DumpRenderTreeSupportGtk::decrementAccessibilityValue(ATK_OBJECT(m_element));
  183. }
  184. void AccessibilityUIElement::showMenu()
  185. {
  186. }
  187. void AccessibilityUIElement::press()
  188. {
  189. if (!m_element)
  190. return;
  191. ASSERT(ATK_IS_OBJECT(m_element));
  192. if (!ATK_IS_ACTION(m_element))
  193. return;
  194. // Only one action per object is supported so far.
  195. atk_action_do_action(ATK_ACTION(m_element), 0);
  196. }
  197. JSStringRef AccessibilityUIElement::stringAttributeValue(JSStringRef attribute)
  198. {
  199. return JSStringCreateWithCharacters(0, 0);
  200. }
  201. double AccessibilityUIElement::numberAttributeValue(JSStringRef attribute)
  202. {
  203. return 0.0f;
  204. }
  205. bool AccessibilityUIElement::boolAttributeValue(JSStringRef attribute)
  206. {
  207. return false;
  208. }
  209. bool AccessibilityUIElement::isAttributeSupported(JSStringRef attribute)
  210. {
  211. return false;
  212. }
  213. bool AccessibilityUIElement::isAttributeSettable(JSStringRef attribute)
  214. {
  215. return false;
  216. }
  217. bool AccessibilityUIElement::isActionSupported(JSStringRef action)
  218. {
  219. return false;
  220. }
  221. JSStringRef AccessibilityUIElement::role()
  222. {
  223. return JSStringRef();
  224. #if 0
  225. AtkRole role = atk_object_get_role(ATK_OBJECT(m_element));
  226. if (!role)
  227. return JSStringCreateWithCharacters(0, 0);
  228. const gchar* roleName = atk_role_get_name(role);
  229. GOwnPtr<gchar> axRole(g_strdup_printf("AXRole: %s", roleName));
  230. return JSStringCreateWithUTF8CString(axRole.get());
  231. #endif
  232. }
  233. JSStringRef AccessibilityUIElement::subrole()
  234. {
  235. return 0;
  236. }
  237. JSStringRef AccessibilityUIElement::roleDescription()
  238. {
  239. return 0;
  240. }
  241. JSStringRef AccessibilityUIElement::title()
  242. {
  243. return JSStringRef();
  244. #if 0
  245. const gchar* name = atk_object_get_name(ATK_OBJECT(m_element));
  246. if (!name)
  247. return JSStringCreateWithCharacters(0, 0);
  248. GOwnPtr<gchar> axTitle(g_strdup_printf("AXTitle: %s", name));
  249. return JSStringCreateWithUTF8CString(axTitle.get());
  250. #endif
  251. }
  252. JSStringRef AccessibilityUIElement::description()
  253. {
  254. return JSStringCreateWithUTF8CString("AccessibilityUIElement::description");
  255. #if 0
  256. const gchar* description = atk_object_get_description(ATK_OBJECT(m_element));
  257. if (!description)
  258. return JSStringCreateWithCharacters(0, 0);
  259. GOwnPtr<gchar> axDesc(g_strdup_printf("AXDescription: %s", description));
  260. return JSStringCreateWithUTF8CString(axDesc.get());
  261. #endif
  262. }
  263. JSStringRef AccessibilityUIElement::language()
  264. {
  265. return JSStringCreateWithCharacters(0, 0);
  266. }
  267. JSStringRef AccessibilityUIElement::stringValue()
  268. {
  269. return JSStringCreateWithCharacters(0, 0);
  270. }
  271. JSStringRef AccessibilityUIElement::accessibilityValue() const
  272. {
  273. return JSStringCreateWithCharacters(0, 0);
  274. }
  275. JSStringRef AccessibilityUIElement::helpText() const
  276. {
  277. return JSStringRef();
  278. #if 0
  279. if (!m_element)
  280. return JSStringCreateWithCharacters(0, 0);
  281. ASSERT(ATK_IS_OBJECT(m_element));
  282. CString helpText = DumpRenderTreeSupportGtk::accessibilityHelpText(ATK_OBJECT(m_element));
  283. GOwnPtr<gchar> axHelpText(g_strdup_printf("AXHelp: %s", helpText.data()));
  284. return JSStringCreateWithUTF8CString(axHelpText.get());
  285. #endif
  286. }
  287. JSStringRef AccessibilityUIElement::orientation() const
  288. {
  289. return 0;
  290. }
  291. double AccessibilityUIElement::x()
  292. {
  293. int x, y;
  294. atk_component_get_position(ATK_COMPONENT(m_element), &x, &y, ATK_XY_SCREEN);
  295. return x;
  296. }
  297. double AccessibilityUIElement::y()
  298. {
  299. int x, y;
  300. atk_component_get_position(ATK_COMPONENT(m_element), &x, &y, ATK_XY_SCREEN);
  301. return y;
  302. }
  303. double AccessibilityUIElement::width()
  304. {
  305. int width, height;
  306. atk_component_get_size(ATK_COMPONENT(m_element), &width, &height);
  307. return width;
  308. }
  309. double AccessibilityUIElement::height()
  310. {
  311. int width, height;
  312. atk_component_get_size(ATK_COMPONENT(m_element), &width, &height);
  313. return height;
  314. }
  315. double AccessibilityUIElement::intValue() const
  316. {
  317. return 0.0f;
  318. #if 0
  319. GValue value = {0, {{0}}};
  320. if (!ATK_IS_VALUE(m_element))
  321. return 0.0f;
  322. atk_value_get_current_value(ATK_VALUE(m_element), &value);
  323. if (G_VALUE_HOLDS_DOUBLE(&value))
  324. return g_value_get_double(&value);
  325. else if (G_VALUE_HOLDS_INT(&value))
  326. return static_cast<double>(g_value_get_int(&value));
  327. else
  328. return 0.0f;
  329. #endif
  330. }
  331. double AccessibilityUIElement::minValue()
  332. {
  333. return 0.0f;
  334. #if 0
  335. GValue value = {0, {{0}}};
  336. if (!ATK_IS_VALUE(m_element))
  337. return 0.0f;
  338. atk_value_get_minimum_value(ATK_VALUE(m_element), &value);
  339. if (G_VALUE_HOLDS_DOUBLE(&value))
  340. return g_value_get_double(&value);
  341. else if (G_VALUE_HOLDS_INT(&value))
  342. return static_cast<double>(g_value_get_int(&value));
  343. else
  344. return 0.0f;
  345. #endif
  346. }
  347. double AccessibilityUIElement::maxValue()
  348. {
  349. return 0.0f;
  350. #if 0
  351. GValue value = {0, {{0}}};
  352. if (!ATK_IS_VALUE(m_element))
  353. return 0.0f;
  354. atk_value_get_maximum_value(ATK_VALUE(m_element), &value);
  355. if (G_VALUE_HOLDS_DOUBLE(&value))
  356. return g_value_get_double(&value);
  357. else if (G_VALUE_HOLDS_INT(&value))
  358. return static_cast<double>(g_value_get_int(&value));
  359. else
  360. return 0.0f;
  361. #endif
  362. }
  363. JSStringRef AccessibilityUIElement::valueDescription()
  364. {
  365. // FIXME: implement
  366. return JSStringCreateWithCharacters(0, 0);
  367. }
  368. int AccessibilityUIElement::insertionPointLineNumber()
  369. {
  370. return 0;
  371. }
  372. JSStringRef AccessibilityUIElement::selectedTextRange()
  373. {
  374. return JSStringCreateWithCharacters(0, 0);
  375. }
  376. bool AccessibilityUIElement::isEnabled()
  377. {
  378. return false;
  379. // return checkElementState(m_element, ATK_STATE_ENABLED);
  380. }
  381. bool AccessibilityUIElement::isRequired() const
  382. {
  383. return false;
  384. }
  385. bool AccessibilityUIElement::isFocused() const
  386. {
  387. return false;
  388. #if 0
  389. if (!ATK_IS_OBJECT(m_element))
  390. return false;
  391. GRefPtr<AtkStateSet> stateSet = adoptGRef(atk_object_ref_state_set(ATK_OBJECT(m_element)));
  392. gboolean isFocused = atk_state_set_contains_state(stateSet.get(), ATK_STATE_FOCUSED);
  393. return isFocused;
  394. #endif
  395. }
  396. bool AccessibilityUIElement::isFocusable() const
  397. {
  398. return false;
  399. #if 0
  400. if (!ATK_IS_OBJECT(m_element))
  401. return false;
  402. GRefPtr<AtkStateSet> stateSet = adoptGRef(atk_object_ref_state_set(ATK_OBJECT(m_element)));
  403. gboolean isFocusable = atk_state_set_contains_state(stateSet.get(), ATK_STATE_FOCUSABLE);
  404. return isFocusable;
  405. #endif
  406. }
  407. bool AccessibilityUIElement::isSelected() const
  408. {
  409. return false;
  410. // return checkElementState(m_element, ATK_STATE_SELECTED);
  411. }
  412. bool AccessibilityUIElement::isSelectable() const
  413. {
  414. return false;
  415. }
  416. bool AccessibilityUIElement::isMultiSelectable() const
  417. {
  418. return false;
  419. }
  420. bool AccessibilityUIElement::isSelectedOptionActive() const
  421. {
  422. return false;
  423. }
  424. bool AccessibilityUIElement::isExpanded() const
  425. {
  426. return false;
  427. #if 0
  428. if (!ATK_IS_OBJECT(m_element))
  429. return false;
  430. GRefPtr<AtkStateSet> stateSet = adoptGRef(atk_object_ref_state_set(ATK_OBJECT(m_element)));
  431. gboolean isExpanded = atk_state_set_contains_state(stateSet.get(), ATK_STATE_EXPANDED);
  432. return isExpanded;
  433. #endif
  434. }
  435. bool AccessibilityUIElement::isChecked() const
  436. {
  437. return false;
  438. #if 0
  439. if (!ATK_IS_OBJECT(m_element))
  440. return false;
  441. GRefPtr<AtkStateSet> stateSet = adoptGRef(atk_object_ref_state_set(ATK_OBJECT(m_element)));
  442. gboolean isChecked = atk_state_set_contains_state(stateSet.get(), ATK_STATE_CHECKED);
  443. return isChecked;
  444. #endif
  445. }
  446. bool AccessibilityUIElement::isVisible() const
  447. {
  448. return false;
  449. }
  450. bool AccessibilityUIElement::isOffScreen() const
  451. {
  452. return false;
  453. }
  454. bool AccessibilityUIElement::isCollapsed() const
  455. {
  456. return false;
  457. }
  458. bool AccessibilityUIElement::isIgnored() const
  459. {
  460. return false;
  461. }
  462. bool AccessibilityUIElement::hasPopup() const
  463. {
  464. return false;
  465. }
  466. int AccessibilityUIElement::hierarchicalLevel() const
  467. {
  468. return 0;
  469. }
  470. double AccessibilityUIElement::clickPointX()
  471. {
  472. return 0.f;
  473. }
  474. double AccessibilityUIElement::clickPointY()
  475. {
  476. return 0.f;
  477. }
  478. JSStringRef AccessibilityUIElement::documentEncoding()
  479. {
  480. return JSStringRef();
  481. #if 0
  482. AtkRole role = atk_object_get_role(ATK_OBJECT(m_element));
  483. if (role != ATK_ROLE_DOCUMENT_FRAME)
  484. return JSStringCreateWithCharacters(0, 0);
  485. return JSStringCreateWithUTF8CString(atk_document_get_attribute_value(ATK_DOCUMENT(m_element), "Encoding"));
  486. #endif
  487. }
  488. JSStringRef AccessibilityUIElement::documentURI()
  489. {
  490. return JSStringRef();
  491. #if 0
  492. AtkRole role = atk_object_get_role(ATK_OBJECT(m_element));
  493. if (role != ATK_ROLE_DOCUMENT_FRAME)
  494. return JSStringCreateWithCharacters(0, 0);
  495. return JSStringCreateWithUTF8CString(atk_document_get_attribute_value(ATK_DOCUMENT(m_element), "URI"));
  496. #endif
  497. }
  498. JSStringRef AccessibilityUIElement::url()
  499. {
  500. return JSStringCreateWithCharacters(0, 0);
  501. }
  502. JSStringRef AccessibilityUIElement::attributesOfColumnHeaders()
  503. {
  504. return JSStringCreateWithCharacters(0, 0);
  505. }
  506. JSStringRef AccessibilityUIElement::attributesOfRowHeaders()
  507. {
  508. return JSStringCreateWithCharacters(0, 0);
  509. }
  510. JSStringRef AccessibilityUIElement::attributesOfColumns()
  511. {
  512. return JSStringCreateWithCharacters(0, 0);
  513. }
  514. JSStringRef AccessibilityUIElement::attributesOfRows()
  515. {
  516. return JSStringCreateWithCharacters(0, 0);
  517. }
  518. JSStringRef AccessibilityUIElement::attributesOfVisibleCells()
  519. {
  520. return JSStringCreateWithCharacters(0, 0);
  521. }
  522. JSStringRef AccessibilityUIElement::attributesOfHeader()
  523. {
  524. return JSStringCreateWithCharacters(0, 0);
  525. }
  526. int AccessibilityUIElement::indexInTable()
  527. {
  528. return 0;
  529. }
  530. JSStringRef AccessibilityUIElement::rowIndexRange()
  531. {
  532. // Range in table for rows.
  533. // return indexRangeInTable(m_element, true);
  534. return JSStringRef();
  535. }
  536. JSStringRef AccessibilityUIElement::columnIndexRange()
  537. {
  538. // Range in table for columns.
  539. // return indexRangeInTable(m_element, false);
  540. return JSStringRef();
  541. }
  542. int AccessibilityUIElement::rowCount()
  543. {
  544. return 0;
  545. #if 0
  546. if (!m_element)
  547. return 0;
  548. ASSERT(ATK_IS_TABLE(m_element));
  549. return atk_table_get_n_rows(ATK_TABLE(m_element));
  550. #endif
  551. }
  552. int AccessibilityUIElement::columnCount()
  553. {
  554. return 0;
  555. #if 0
  556. if (!m_element)
  557. return 0;
  558. ASSERT(ATK_IS_TABLE(m_element));
  559. return atk_table_get_n_columns(ATK_TABLE(m_element));
  560. #endif
  561. }
  562. AccessibilityUIElement AccessibilityUIElement::selectedRowAtIndex(unsigned)
  563. {
  564. return 0;
  565. }
  566. AccessibilityUIElement AccessibilityUIElement::disclosedByRow()
  567. {
  568. return 0;
  569. }
  570. AccessibilityUIElement AccessibilityUIElement::disclosedRowAtIndex(unsigned)
  571. {
  572. return 0;
  573. }
  574. AccessibilityUIElement AccessibilityUIElement::rowAtIndex(unsigned)
  575. {
  576. return 0;
  577. }
  578. AccessibilityUIElement AccessibilityUIElement::ariaOwnsElementAtIndex(unsigned index)
  579. {
  580. return 0;
  581. }
  582. AccessibilityUIElement AccessibilityUIElement::ariaFlowToElementAtIndex(unsigned index)
  583. {
  584. return 0;
  585. }
  586. bool AccessibilityUIElement::ariaIsGrabbed() const
  587. {
  588. return false;
  589. }
  590. JSStringRef AccessibilityUIElement::ariaDropEffects() const
  591. {
  592. return 0;
  593. }
  594. int AccessibilityUIElement::lineForIndex(int)
  595. {
  596. return 0;
  597. }
  598. void AccessibilityUIElement::setSelectedTextRange(unsigned location, unsigned length)
  599. {
  600. }
  601. JSStringRef AccessibilityUIElement::stringForRange(unsigned, unsigned)
  602. {
  603. return JSStringCreateWithCharacters(0, 0);
  604. }
  605. JSStringRef AccessibilityUIElement::attributedStringForRange(unsigned, unsigned)
  606. {
  607. return JSStringCreateWithCharacters(0, 0);
  608. }
  609. bool AccessibilityUIElement::attributedStringRangeIsMisspelled(unsigned location, unsigned length)
  610. {
  611. return false;
  612. }
  613. AccessibilityUIElement AccessibilityUIElement::uiElementForSearchPredicate(AccessibilityUIElement* startElement, bool isDirectionNext, JSStringRef searchKey, JSStringRef searchText)
  614. {
  615. return 0;
  616. }
  617. AccessibilityUIElement AccessibilityUIElement::cellForColumnAndRow(unsigned column, unsigned row)
  618. {
  619. return 0;
  620. #if 0
  621. if (!m_element)
  622. return 0;
  623. ASSERT(ATK_IS_TABLE(m_element));
  624. AtkObject* foundCell = atk_table_ref_at(ATK_TABLE(m_element), row, column);
  625. return foundCell ? AccessibilityUIElement(foundCell) : 0;
  626. #endif
  627. }
  628. void AccessibilityUIElement::scrollToMakeVisible()
  629. {
  630. }
  631. void AccessibilityUIElement::scrollToMakeVisibleWithSubFocus(int x, int y, int width, int height)
  632. {
  633. }
  634. void AccessibilityUIElement::scrollToGlobalPoint(int x, int y)
  635. {
  636. }
  637. bool AccessibilityUIElement::addNotificationListener(JSObjectRef functionCallback)
  638. {
  639. return false;
  640. }
  641. void AccessibilityUIElement::removeNotificationListener()
  642. {
  643. }
  644. JSStringRef AccessibilityUIElement::boundsForRange(unsigned location, unsigned length)
  645. {
  646. return JSStringCreateWithCharacters(0, 0);
  647. }