Include rich output for intra-line changes in ChromeVox

Previously, when ChromeVox encounters a change in editable text that remains within a single line, e.g. move by one character, it would compare the plain text diffs of the previous and current lines.

This would miss the rich structure of automation including images.

The logic prior to this change would sometimes emit output accidentally when the move within line was detected as a move across lines.

This change makes it so whenever either side of the selection (while within a single line) is not on a text node, ChromeVox will describe the entire DOM selection.

Test: browser_tests --gtest_filter=ChromeVoxEditing*.*ImageByCharacter
Change-Id: I53f7d9e15edfaa13c90fb4cc498d83f140cbdf35
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1596194
Commit-Queue: David Tseng <dtseng@chromium.org>
Reviewed-by: Nektarios Paisios <nektar@chromium.org>
Cr-Commit-Position: refs/heads/master@{#657611}
4 files changed