Changeset 50342 in webkit
- Timestamp:
- Oct 30, 2009 10:35:12 AM (15 years ago)
- Location:
- trunk/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebCore/ChangeLog
r50341 r50342 12 12 * rendering/RenderBox.cpp: 13 13 (WebCore::RenderBox::positionForPoint): 14 15 2009-10-30 Joanmarie Diggs <joanmarie.diggs@gmail.com> 16 17 Reviewed by Xan Lopez. 18 19 https://bugs.webkit.org/show_bug.cgi?id=25534 20 [GTK] Objects of ROLE_TABLE should implement the accessible table interface 21 22 Third part of the implementation of AtkTable. 23 24 * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp: 25 (nameFromChildren): 26 (webkit_accessible_get_name): 27 New convenience function to construct an object's name using the name(s) of 28 any children it has. 29 30 (atk_table_interface_init): 31 (webkit_accessible_table_get_column_description): 32 (webkit_accessible_table_get_row_description): 33 Implemented. 34 35 (webkit_accessible_table_get_column_header): 36 Stub function added so that webkit_accessible_table_get_column_description 37 could be implemented in the meantime. 14 38 15 39 2009-10-30 Joanmarie Diggs <joanmarie.diggs@gmail.com> -
trunk/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
r50339 r50342 138 138 } 139 139 140 static const gchar* nameFromChildren(AccessibilityObject* object) 141 { 142 if (!object) 143 return 0; 144 145 AccessibilityRenderObject::AccessibilityChildrenVector children = object->children(); 146 // Currently, object->stringValue() should be an empty String. This might not be the case down the road. 147 String name = object->stringValue(); 148 for (unsigned i = 0; i < children.size(); ++i) 149 name += children.at(i).get()->stringValue(); 150 return returnString(name); 151 } 152 140 153 static const gchar* webkit_accessible_get_name(AtkObject* object) 141 154 { … … 144 157 AccessibilityRenderObject* renderObject = static_cast<AccessibilityRenderObject*>(coreObject); 145 158 AccessibilityObject* label = renderObject->correspondingLabelForControlElement(); 146 if (label) { 147 AccessibilityRenderObject::AccessibilityChildrenVector children = label->children(); 148 // Currently, label->stringValue() should be an empty String. This 149 // might not be the case down the road. 150 String name = label->stringValue(); 151 for (unsigned i = 0; i < children.size(); ++i) 152 name += children.at(i).get()->stringValue(); 153 return returnString(name); 154 } 159 if (label) 160 return returnString(nameFromChildren(label)); 155 161 } 156 162 return returnString(coreObject->stringValue()); … … 1328 1334 } 1329 1335 1336 static AtkObject* webkit_accessible_table_get_column_header(AtkTable* table, gint column) 1337 { 1338 // FIXME: This needs to be implemented. 1339 notImplemented(); 1340 return 0; 1341 } 1342 1330 1343 static AtkObject* webkit_accessible_table_get_row_header(AtkTable* table, gint row) 1331 1344 { … … 1359 1372 } 1360 1373 1374 static const gchar* webkit_accessible_table_get_column_description(AtkTable* table, gint column) 1375 { 1376 AtkObject* columnHeader = atk_table_get_column_header(table, column); 1377 if (columnHeader) 1378 return returnString(nameFromChildren(core(columnHeader))); 1379 1380 return 0; 1381 } 1382 1383 static const gchar* webkit_accessible_table_get_row_description(AtkTable* table, gint row) 1384 { 1385 AtkObject* rowHeader = atk_table_get_row_header(table, row); 1386 if (rowHeader) 1387 return returnString(nameFromChildren(core(rowHeader))); 1388 1389 return 0; 1390 } 1391 1361 1392 static void atk_table_interface_init(AtkTableIface* iface) 1362 1393 { … … 1369 1400 iface->get_column_extent_at = webkit_accessible_table_get_column_extent_at; 1370 1401 iface->get_row_extent_at = webkit_accessible_table_get_row_extent_at; 1402 iface->get_column_header = webkit_accessible_table_get_column_header; 1371 1403 iface->get_row_header = webkit_accessible_table_get_row_header; 1372 1404 iface->get_caption = webkit_accessible_table_get_caption; 1405 iface->get_column_description = webkit_accessible_table_get_column_description; 1406 iface->get_row_description = webkit_accessible_table_get_row_description; 1373 1407 } 1374 1408
Note: See TracChangeset
for help on using the changeset viewer.