[New Multicolumn] columnNumberForOffset is not patched for new multicolumn code yet.
authorhyatt@apple.com <hyatt@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 17 Apr 2014 18:48:15 +0000 (18:48 +0000)
committerhyatt@apple.com <hyatt@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 17 Apr 2014 18:48:15 +0000 (18:48 +0000)
commita2f97de135a712d77f518d6da810195b785ed2fc
treec137eba13c0099b8f03f5f2f8f449bd1c4ad4ebe
parentbf5377299e0a404550639e3b4bcffcc8f3db7de1
[New Multicolumn] columnNumberForOffset is not patched for new multicolumn code yet.
https://bugs.webkit.org/show_bug.cgi?id=131740

Reviewed by Enrica Casucci.

I took the opportunity to clean this code up while adding support for the new columns.
columnNumberForOffset only applied for paginated RenderViews and was really about
pages and not columns. It also only returns an actual page number if the columns are
block progressed (e.g., right-to-left vertical Japanese books).

Therefore I renamed columnNumberForOffset to pageNumberForBlockProgressionOffset and
moved it to RenderView.

I also renamed the member variable of SelectionRect to be pageNumber instead of
columnNumber in order to make it more obvious that this isn't about columns per se
(since the fact that we implemented RenderView's pagination mode using columns is an
implementation detail).

* dom/Range.cpp:
(WebCore::coalesceSelectionRects):
(WebCore::Range::collectSelectionRects):
* platform/ios/SelectionRect.h:
(WebCore::SelectionRect::pageNumber):
(WebCore::SelectionRect::columnNumber): Deleted.
* rendering/RenderImage.cpp:
(WebCore::RenderImage::collectSelectionRects):
* rendering/RenderObject.cpp:
(WebCore::RenderObject::collectSelectionRects):
(WebCore::RenderObject::columnNumberForOffset): Deleted.
* rendering/RenderObject.h:
* rendering/RenderText.cpp:
(WebCore::RenderText::collectSelectionRects):
* rendering/RenderView.cpp:
(WebCore::RenderView::pageNumberForBlockProgressionOffset):
* rendering/RenderView.h:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@167444 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/dom/Range.cpp
Source/WebCore/platform/ios/SelectionRect.h
Source/WebCore/rendering/RenderImage.cpp
Source/WebCore/rendering/RenderObject.cpp
Source/WebCore/rendering/RenderObject.h
Source/WebCore/rendering/RenderText.cpp
Source/WebCore/rendering/RenderView.cpp
Source/WebCore/rendering/RenderView.h