[New Multicolumn] Correct localPoint when hitting an anonymous child block.

If Layer::hitTestContents() detects a hit, but we have failed to pinpoint it to
a DOM node (because we only found anonymous layout objects), there's code to
locate the nearest ancestor DOM node above the layer, and store it. But there's
no code to actually set the corresponding localPoint (and that sounds like a
tricky task, anyway), which means that text selecting and caretRangeFromPoint()
will suffer.

Add a work-around for flow thread layers. We can just report that didn't hit
anything so that we continue and hit a sibling column set instead, and thus set
the right localPoint (because the column set is in the same layer as the
multicol container, and the multicol container does have a DOM node).

Note that we should no longer get here for positioned generated content, like
the old comment suggested, because generated content now inserts pseudo nodes,
instead of creating anonymous layout objects. So it's actually a bit unclear if
we can end up here at all in other cases than multicol (which is now handled
properly-ish).

Re-enable an old test that now passes, and add some new ones.

BUG=461352
R=dsinclair@chromium.org,jchaffraix@chromium.org

Review URL: https://codereview.chromium.org/1003303005

git-svn-id: svn://svn.chromium.org/blink/trunk@192173 bbb929c8-8fbe-4397-9dbb-9b2b20218538
14 files changed
tree: ea093ce8569df0a7359fcc6d86a35de2db1336bd
  1. third_party/