Changeset 200855 in webkit
- Timestamp:
- May 13, 2016, 6:41:00 AM (9 years ago)
- Location:
- releases/WebKitGTK/webkit-2.12
- Files:
-
- 5 edited
Legend:
- Unmodified
- Added
- Removed
-
releases/WebKitGTK/webkit-2.12/LayoutTests/ChangeLog
r200854 r200855 1 2016-05-07 Joanmarie Diggs <jdiggs@igalia.com> 2 3 REGRESSION(r196222): [AX][GTK] accessibility/gtk/caret-offsets.html failing 4 https://bugs.webkit.org/show_bug.cgi?id=153956 5 6 Reviewed by Chris Fleizach. 7 8 Change the test to run asynchronously and update the expectations. 9 10 * accessibility/gtk/caret-offsets-expected.txt: Updated. 11 * accessibility/gtk/caret-offsets.html: Updated. 12 * platform/gtk/TestExpectations: Unskipped the previously-failing test. 13 1 14 2016-05-05 Zalan Bujtas <zalan@apple.com> 2 15 -
releases/WebKitGTK/webkit-2.12/LayoutTests/accessibility/gtk/caret-offsets-expected.txt
r187777 r200855 24 24 PASS caretMovedData is "Paragraph|5" 25 25 PASS caretMovedData is "Paragraph|20" 26 PASS caretMovedData is"Paragraph|30"26 PASS caretMovedData became "Paragraph|30" 27 27 PASS setCaretOffset(link, 5) is true 28 28 PASS caretMovedData is "Paragraph|17" … … 31 31 PASS setCaretOffset(listItem, 1) is false 32 32 PASS setCaretOffset(listItem, 5) is true 33 PASS caretMovedData is "ListItem| 2"33 PASS caretMovedData is "ListItem|5" 34 34 PASS comboBox.role is "AXRole: AXComboBox" 35 35 PASS menuPopup.role is "AXRole: AXMenu" … … 42 42 PASS row.role is "AXRole: AXRow" 43 43 PASS tableCell.role is "AXRole: AXCell" 44 PASS caretMovedData is"Cell|2"44 PASS caretMovedData became "Cell|2" 45 45 PASS successfullyParsed is true 46 46 -
releases/WebKitGTK/webkit-2.12/LayoutTests/accessibility/gtk/caret-offsets.html
r187804 r200855 55 55 56 56 if (window.accessibilityController) { 57 window.jsTestIsAsync = true; 58 57 59 accessibilityController.addNotificationListener(globalListener); 58 60 root = accessibilityController.accessibleElementById('firstChild').parentElement(); … … 72 74 shouldBeEqualToString('caretMovedData', 'Paragraph|20'); 73 75 resetCaretOffsetForObject(p1, 30); 74 shouldBe EqualToString('caretMovedData', 'Paragraph|30');75 link = p1.childAtIndex(0);76 caretMovedData = '';77 shouldBeTrue('setCaretOffset(link, 5)');78 /* Positions inside links are reported relative to the paragraph. */79 shouldBeEqualToString('caretMovedData', 'Paragraph|17');76 shouldBecomeEqualToString('caretMovedData', 'Paragraph|30', function () { 77 caretMovedData = ''; 78 link = p1.childAtIndex(0); 79 shouldBeTrue('setCaretOffset(link, 5)'); 80 /* Positions inside links are reported relative to the paragraph. */ 81 shouldBeEqualToString('caretMovedData', 'Paragraph|17'); 80 82 81 list = root.childAtIndex(2);82 shouldBeEqualToString('list.role', 'AXRole: AXList');83 shouldBe('list.childrenCount', '3');84 listItem = list.childAtIndex(2);85 /* It's not possible to place the caret inside an item's marker. */86 shouldBe('setCaretOffset(listItem, 1)', 'false');87 /* It should be possible to place the caret inside an item's text. */88 caretMovedData = '';89 shouldBe('setCaretOffset(listItem, 5)', 'true');90 shouldBeEqualToString('caretMovedData', 'ListItem|2');83 list = root.childAtIndex(2); 84 shouldBeEqualToString('list.role', 'AXRole: AXList'); 85 shouldBe('list.childrenCount', '3'); 86 listItem = list.childAtIndex(2); 87 /* It's not possible to place the caret inside an item's marker. */ 88 shouldBe('setCaretOffset(listItem, 1)', 'false'); 89 /* It should be possible to place the caret inside an item's text. */ 90 caretMovedData = ''; 91 shouldBe('setCaretOffset(listItem, 5)', 'true'); 92 shouldBeEqualToString('caretMovedData', 'ListItem|5'); 91 93 92 panel = root.childAtIndex(3);93 comboBox = panel.childAtIndex(0);94 shouldBeEqualToString('comboBox.role', 'AXRole: AXComboBox');95 menuPopup = comboBox.childAtIndex(0);96 shouldBeEqualToString('menuPopup.role', 'AXRole: AXMenu');97 comboBoxOption = menuPopup.childAtIndex(0);98 shouldBeEqualToString('comboBoxOption.role', 'AXRole: AXMenuItem');99 /* It's not possible to place the caret inside an option for a combobox. */100 shouldBe('setCaretOffset(comboBoxOption, 1)', 'false');101 textEntry = panel.childAtIndex(1);102 shouldBeEqualToString('textEntry.role', 'AXRole: AXTextField');103 resetCaretOffsetForObject(textEntry, 5);104 shouldBeEqualToString('caretMovedData', 'TextField|5');94 panel = root.childAtIndex(3); 95 comboBox = panel.childAtIndex(0); 96 shouldBeEqualToString('comboBox.role', 'AXRole: AXComboBox'); 97 menuPopup = comboBox.childAtIndex(0); 98 shouldBeEqualToString('menuPopup.role', 'AXRole: AXMenu'); 99 comboBoxOption = menuPopup.childAtIndex(0); 100 shouldBeEqualToString('comboBoxOption.role', 'AXRole: AXMenuItem'); 101 /* It's not possible to place the caret inside an option for a combobox. */ 102 shouldBe('setCaretOffset(comboBoxOption, 1)', 'false'); 103 textEntry = panel.childAtIndex(1); 104 shouldBeEqualToString('textEntry.role', 'AXRole: AXTextField'); 105 resetCaretOffsetForObject(textEntry, 5); 106 shouldBeEqualToString('caretMovedData', 'TextField|5'); 105 107 106 table = root.childAtIndex(4); 107 shouldBeEqualToString('table.role', 'AXRole: AXTable'); 108 shouldBe('table.childrenCount', '1'); 109 row = table.childAtIndex(0); 110 shouldBeEqualToString('row.role', 'AXRole: AXRow'); 111 tableCell = row.childAtIndex(0); 112 shouldBeEqualToString('tableCell.role', 'AXRole: AXCell'); 113 resetCaretOffsetForObject(tableCell, 2); 114 shouldBeEqualToString('caretMovedData', 'Cell|2'); 108 table = root.childAtIndex(4); 109 shouldBeEqualToString('table.role', 'AXRole: AXTable'); 110 shouldBe('table.childrenCount', '1'); 111 row = table.childAtIndex(0); 112 shouldBeEqualToString('row.role', 'AXRole: AXRow'); 113 tableCell = row.childAtIndex(0); 114 shouldBeEqualToString('tableCell.role', 'AXRole: AXCell'); 115 resetCaretOffsetForObject(tableCell, 2); 116 shouldBecomeEqualToString('caretMovedData', 'Cell|2', finishJSTest); 117 }); 115 118 } 116 119 -
releases/WebKitGTK/webkit-2.12/Source/WebCore/ChangeLog
r200854 r200855 1 2016-05-07 Joanmarie Diggs <jdiggs@igalia.com> 2 3 REGRESSION(r196222): [AX][GTK] accessibility/gtk/caret-offsets.html failing 4 https://bugs.webkit.org/show_bug.cgi?id=153956 5 6 Reviewed by Chris Fleizach. 7 8 The reason the test began failing is that it was checking the new caret offset 9 synchronously. For most of the test cases, this was not a problem. But when the 10 caret was moved out of a focused link, the focus change (and associated repainting) 11 delayed the caret-moved event long enough to cause the associated test case to fail. 12 The test now uses shouldBecomeEqualToString() instead of shouldBeEqualToString(). 13 14 The test also had a supposedly-correct expectation which was wrong: When moving the 15 caret to a valid accessible offset, the caret-moved event should be for that offset. 16 This was not the case for the list item test case because emitTextSelectionChange() 17 was not adjusting the offset for the RenderListMarker, the text of which is exposed 18 as part of the ATK_ROLE_LIST_ITEM object. This bug was also fixed and the test case 19 updated accordingly. 20 21 No new tests are needed. The previously-failing test is now passing. 22 23 * editing/atk/FrameSelectionAtk.cpp: 24 (WebCore::emitTextSelectionChange): 25 1 26 2016-05-05 Zalan Bujtas <zalan@apple.com> 2 27 -
releases/WebKitGTK/webkit-2.12/Source/WebCore/editing/atk/FrameSelectionAtk.cpp
r183368 r200855 26 26 #include "Document.h" 27 27 #include "Frame.h" 28 #include "RenderListItem.h" 28 29 #include "WebKitAccessibleWrapperAtk.h" 29 30 #include <glib.h> … … 38 39 if (!axObject || !ATK_IS_TEXT(axObject)) 39 40 return; 41 42 // We need to adjust the offset for the list item marker in Left-To-Right text because 43 // the list item marker is exposed through the text of the accessible list item rather 44 // than through a separate accessible object. 45 RenderObject* renderer = object->renderer(); 46 if (is<RenderListItem>(renderer) && renderer->style().direction() == LTR) 47 offset += downcast<RenderListItem>(*renderer).markerTextWithSuffix().length(); 40 48 41 49 g_signal_emit_by_name(axObject, "text-caret-moved", offset);
Note:
See TracChangeset
for help on using the changeset viewer.