[Webkit-unassigned] [Bug 36741] Duplicate, slightly divergent implementation of Position[Iterator]::isCandidate()

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Mar 29 00:23:14 PDT 2010


https://bugs.webkit.org/show_bug.cgi?id=36741


Roland Steiner <rolandsteiner at chromium.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |ASSIGNED
         AssignedTo|webkit-unassigned at lists.web |rolandsteiner at chromium.org
                   |kit.org                     |
  Attachment #51879|                            |review?
               Flag|                            |




--- Comment #1 from Roland Steiner <rolandsteiner at chromium.org>  2010-03-29 00:23:14 PST ---
Created an attachment (id=51879)
 --> (https://bugs.webkit.org/attachment.cgi?id=51879)
patch - consolidate implementations into PositionIterator::isCandidate()

As stated in the ChangeLog, the rationale for using
PositionIterator::isCandidate() over Position::isCandidate() is that a
PositionIterator is cheaper to construct from a Position than vice versa (no
call to nodeIndex()). Also, PositionIterator::isCandidate is called in a tight
loop within next/previousCandidate (editing/htmlediting.cpp).

The code as is doesn't look very nice though, and I believe that
PositionIterator and Position should be merged at some point. But that is
another story, for another 1001 commits...

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list