Bug 24854

Summary: Rename PositionIterator members in hope of further clarity
Product: WebKit Reporter: Eric Seidel (no email) <eric>
Component: HTML EditingAssignee: Eric Seidel (no email) <eric>
Status: RESOLVED FIXED    
Severity: Normal CC: darin, justin.garcia
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: OS X 10.5   
Attachments:
Description Flags
Rename PositionIterator members in hope of futher clarity
darin: review+
Rename PositionIterator::atStart/atEnd atStartOfTree/atEndOfTree
none
More cleanup and renaming to PositionIterator none

Description Eric Seidel (no email) 2009-03-26 13:44:07 PDT
I'm going to make a bunch more small position cleanups today, before I start my 5th attempt to re-write positions. :)  Hopefully these cleanups will continue to clarify and simplify the code, and continue to solidify my understanding of the mess that is position handling code. ;)
Comment 1 Eric Seidel (no email) 2009-03-26 13:51:14 PDT
Created attachment 28981 [details]
Rename PositionIterator members in hope of futher clarity

 WebCore/ChangeLog                |   28 ++++++++++
 WebCore/dom/PositionIterator.cpp |  112 +++++++++++++++++++-------------------
 WebCore/dom/PositionIterator.h   |   22 ++++----
 3 files changed, 95 insertions(+), 67 deletions(-)
Comment 2 Eric Seidel (no email) 2009-03-26 13:51:17 PDT
Created attachment 28982 [details]
Rename PositionIterator::atStart/atEnd atStartOfTree/atEndOfTree

 WebCore/ChangeLog                |   20 ++++++++++++++++++++
 WebCore/dom/Position.cpp         |    4 ++--
 WebCore/dom/PositionIterator.cpp |    4 ++--
 WebCore/dom/PositionIterator.h   |    4 ++--
 WebCore/editing/htmlediting.cpp  |    4 ++--
 5 files changed, 28 insertions(+), 8 deletions(-)
Comment 3 Eric Seidel (no email) 2009-03-26 15:31:39 PDT
Comment on attachment 28982 [details]
Rename PositionIterator::atStart/atEnd atStartOfTree/atEndOfTree

Gonna remake this second patch to include more renames.
Comment 4 Eric Seidel (no email) 2009-03-26 15:31:56 PDT
Created attachment 28990 [details]
More cleanup and renaming to PositionIterator

 WebCore/ChangeLog                 |   35 +++++++++++++-
 WebCore/dom/Position.cpp          |   14 +++---
 WebCore/dom/PositionIterator.cpp  |   98 +++++++++++++++++++++++--------------
 WebCore/dom/PositionIterator.h    |   14 +++--
 WebCore/editing/VisiblePosition.h |    5 ++
 WebCore/editing/htmlediting.cpp   |    4 +-
 6 files changed, 118 insertions(+), 52 deletions(-)
Comment 5 Eric Seidel (no email) 2009-03-26 15:53:53 PDT
Comment on attachment 28990 [details]
More cleanup and renaming to PositionIterator

There is a missing return.  Will upload fixed patch.
Comment 6 Maciej Stachowiak 2009-05-21 20:04:42 PDT
It would be good for someone familiar with PositionIterator such as Justin or Darin to chime in,
Comment 7 Darin Adler 2009-05-22 09:08:50 PDT
Comment on attachment 28981 [details]
Rename PositionIterator members in hope of futher clarity

I think "anchor" is a little vague, but the names seem fine here.
Comment 8 David Levin 2009-05-29 11:06:33 PDT
Assigned to Eric for landing his own patch.
Comment 9 Eric Seidel (no email) 2009-06-02 16:10:11 PDT
Committing to http://svn.webkit.org/repository/webkit/trunk ...
	M	WebCore/ChangeLog
	M	WebCore/dom/PositionIterator.cpp
	M	WebCore/dom/PositionIterator.h
Committed r44374