Bug 43437

Summary: extractAndNegateTextDecorationStyle and maxRangeOffset in ApplyStyleCommand.cpp should be deleted
Product: WebKit Reporter: Ryosuke Niwa <rniwa>
Component: HTML EditingAssignee: Ryosuke Niwa <rniwa>
Status: RESOLVED FIXED    
Severity: Enhancement CC: darin, enrica, eric, justin.garcia, ojan, tony
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
Patch
none
Also removed pushDownTextDecorationStyleAtBoundaries eric: review+

Description Ryosuke Niwa 2010-08-03 11:27:48 PDT
Per the discussion on the bug 27809, we never push down text decorations added by stylesheets.
Thus extractAndNegateTextDecorationStyle is completely redundant and should be removed.

As FIXME suggests, maxRangeOffset is a redundant static function that must be replaced by lastOffsetForEditing.
Comment 1 Ryosuke Niwa 2010-08-03 11:34:15 PDT
Created attachment 63359 [details]
Patch
Comment 2 Eric Seidel (no email) 2010-08-03 11:35:30 PDT
You changelog doesn't explain what your'e doing here.  Is this dead code?
Comment 3 Ryosuke Niwa 2010-08-03 11:42:41 PDT
(In reply to comment #2)
> You changelog doesn't explain what your'e doing here.  Is this dead code?

Yes. extractAndNegateTextDecorationStyle was not doing anything because the method was there solely to push down nodes with text-decoration CSS rule but we decided not to push them later.
Comment 4 Ryosuke Niwa 2010-08-03 12:15:28 PDT
Created attachment 63366 [details]
Also removed pushDownTextDecorationStyleAtBoundaries
Comment 5 Eric Seidel (no email) 2010-08-03 12:16:51 PDT
Comment on attachment 63366 [details]
Also removed pushDownTextDecorationStyleAtBoundaries

Yay!  Thanks!
Comment 6 Ryosuke Niwa 2010-08-03 18:19:26 PDT
Committed r64610: <http://trac.webkit.org/changeset/64610>
Comment 7 Ryosuke Niwa 2010-08-03 18:23:13 PDT
(In reply to comment #5)
> (From update of attachment 63366 [details])
> Yay!  Thanks!

Thanks for the responsive review.  It makes my life easier to tackle 27818.