Changeset 53466 in webkit
- Timestamp:
- Jan 19, 2010 6:04:21 AM (14 years ago)
- Location:
- trunk/LayoutTests
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r53463 r53466 1 2010-01-19 MORITA Hajime <morrita@gmail.com> 2 3 Reviewed by Shinichiro Hamaji. 4 5 [Chromium] layout_test on linux fails on doubleclick-beside-cr-span.html 6 7 Place larger margins before clicking position to grab certain words 8 instead of clicking blank, whitespaces or tabs before that words. 9 Note that widths of rendered tab characters are hard to predict, 10 So such margins are particularly helpful with them. 11 12 https://bugs.webkit.org/show_bug.cgi?id=33769 13 14 * editing/selection/doubleclick-beside-cr-span.html: 15 Fix to compute click position using actual character width. 16 1 17 2010-01-19 Csaba Osztrogonác <ossy@webkit.org> 2 18 -
trunk/LayoutTests/editing/selection/doubleclick-beside-cr-span.html
r52235 r53466 23 23 function doubleClickPosition(pos) 24 24 { 25 eventSender.mouseMoveTo(pos.x + 2, pos.y + 2); 25 // Our test cases will have at most a single leading tab or four spaces, 26 // followed by a word which is wider than 4 "X"s. 27 // So, pos.x + CHAR_WIDTH * 4 always hits the words. 28 eventSender.mouseMoveTo(pos.x + CHAR_WIDTH * 4, pos.y + LINE_HEIGHT / 2); 26 29 eventSender.mouseDown(); 27 30 eventSender.leapForward(1); … … 134 137 } 135 138 136 function getPositionForward(spanId, ncharacters)137 {138 var pos = getPositionOfNode(spanId)139 pos.x += CHAR_WIDTH*ncharacters;140 return pos;141 }142 143 139 function runTests() 144 140 { … … 161 157 doTest("totest_word_before_here_in_line", "select10 "); 162 158 doTest("totest_span_first_half", "select11 "); 163 doTest("totest_span_second_half", "select 12 ");159 doTest("totest_span_second_half", "selectHere12 "); 164 160 165 161 doTest("totest_linebreak_out_pre", "select1"); … … 168 164 doTest("totest_linebreak_in_pre", "select4", getPositionOfNextLineHeadOf("totest_linebreak_in_pre")); 169 165 doTest("totest_tab_in_pre", "select5\t"); 170 doTest("totest_multiple_whitespaces_in_pre", "select6 " , getPositionForward("totest_multiple_whitespaces_in_pre", " ".length));166 doTest("totest_multiple_whitespaces_in_pre", "select6 "); 171 167 172 168 doTest("totest_linebreak_out_prewrap", "select1"); … … 187 183 doTest("totest_tab_out_nowrap", "select2\t"); 188 184 doTest("totest_multiple_whitespaces_out_nowrap", "select3 "); 189 doTest("totest_linebreak_in_nowrap", "select4\n" , getPositionForward("totest_linebreak_in_nowrap", 1));190 doTest("totest_tab_in_nowrap", "select5\t" , getPositionForward("totest_tab_in_nowrap", 1));191 doTest("totest_multiple_whitespaces_in_nowrap", "select6 " , getPositionForward("totest_multiple_whitespaces_in_nowrap", 1));185 doTest("totest_linebreak_in_nowrap", "select4\n"); 186 doTest("totest_tab_in_nowrap", "select5\t"); 187 doTest("totest_multiple_whitespaces_in_nowrap", "select6 "); 192 188 193 189 } … … 286 282 <div class="case"> 287 283 <h3>a second half of word is inside b element</h3> 288 <div style="width:100pt"> 289 abcd efgh ijkl mnop qrst sel<b id="totest_span_second_half">ect12</b> notyet 284 <!-- We choose selectHere12 instead select12 here 285 because <b>ect12</b> would be too short to be clicked by doubleClickPosition(). --> 286 <div style="width:150pt"> 287 abcd efgh ijkl mnop qrst uvwx yz123 sel<b id="totest_span_second_half">ectHere12</b> notyet 290 288 </div> 291 289 </div>
Note: See TracChangeset
for help on using the changeset viewer.