Changeset 50054 in webkit
- Timestamp:
- Oct 26, 2009 4:42:42 AM (15 years ago)
- Location:
- trunk/WebCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/WebCore/ChangeLog
r50053 r50054 1 2009-10-26 Joanmarie Diggs <joanmarie.diggs@gmail.com> 2 3 Reviewed by Xan Lopez. 4 5 https://bugs.webkit.org/show_bug.cgi?id=25679 6 [Gtk] Improve accessibility of focusable lists 7 8 Fixes the issues with the Atk states exposed for ListBoxOption 9 10 * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp: 11 (setAtkStateSetFromCoreObject): 12 1 13 2009-10-26 Joanmarie Diggs <joanmarie.diggs@gmail.com> 2 14 -
trunk/WebCore/accessibility/gtk/AccessibilityObjectWrapperAtk.cpp
r49958 r50054 371 371 static void setAtkStateSetFromCoreObject(AccessibilityObject* coreObject, AtkStateSet* stateSet) 372 372 { 373 AccessibilityObject* parent = coreObject->parentObject(); 374 bool isListBoxOption = parent && parent->isListBox(); 375 373 376 // Please keep the state list in alphabetical order 374 375 377 if (coreObject->isChecked()) 376 378 atk_state_set_add_state(stateSet, ATK_STATE_CHECKED); 377 379 378 380 // FIXME: isReadOnly does not seem to do the right thing for 379 // controls, so check explicitly for them 380 if (!coreObject->isReadOnly() || 381 (coreObject->isControl() && coreObject->canSetValueAttribute())) 381 // controls, so check explicitly for them. In addition, because 382 // isReadOnly is false for listBoxOptions, we need to add one 383 // more check so that we do not present them as being "editable". 384 if ((!coreObject->isReadOnly() || 385 (coreObject->isControl() && coreObject->canSetValueAttribute())) && 386 !isListBoxOption) 382 387 atk_state_set_add_state(stateSet, ATK_STATE_EDITABLE); 383 388 … … 409 414 // TODO: ATK_STATE_SELECTABLE_TEXT 410 415 411 if (coreObject->isSelected()) 416 if (coreObject->canSetSelectedAttribute()) { 417 atk_state_set_add_state(stateSet, ATK_STATE_SELECTABLE); 418 // Items in focusable lists in Gtk have both STATE_SELECT{ABLE,ED} 419 // and STATE_FOCUS{ABLE,ED}. We'll fake the latter based on the 420 // former. 421 if (isListBoxOption) 422 atk_state_set_add_state(stateSet, ATK_STATE_FOCUSABLE); 423 } 424 425 if (coreObject->isSelected()) { 412 426 atk_state_set_add_state(stateSet, ATK_STATE_SELECTED); 427 // Items in focusable lists in Gtk have both STATE_SELECT{ABLE,ED} 428 // and STATE_FOCUS{ABLE,ED}. We'll fake the latter based on the 429 // former. 430 if (isListBoxOption) 431 atk_state_set_add_state(stateSet, ATK_STATE_FOCUSED); 432 } 413 433 414 434 // FIXME: Group both SHOWING and VISIBLE here for now
Note: See TracChangeset
for help on using the changeset viewer.