-
Benjamin Beaudry authored
This change makes the AXPlatformNodeTextRangeProviderWin endpoints helper class a tree observer, allowing it to keep its stored |start_| and |end_| position valid. By observing the trees that the |start_| and |end_| position are in, the AXPlatformNodeTextRangeProviderWin::TextRangeEndpoints can adjust its endpoints if the node they are on is deleted. When this is the case, the position is then moved to the parent node. Known issue: In some cases, a node can get deleted alongside its parent. When this is the case, moving the position to its parent wouldn't solve the issue of the invalid position as the parent, itself deleted, wouldn't be a valid anchor. I have not observed this issue in practice, but I think it could be a good idea to keep that in mind. Change-Id: Ib0fd7bef9040b8744a0b1e0d7ea2d6b58c7477d8 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2432805 Commit-Queue: Benjamin Beaudry <benjamin.beaudry@microsoft.com> Reviewed-by:
Dominic Mazzoni <dmazzoni@chromium.org> Reviewed-by:
Kurt Catti-Schmidt <kschmi@microsoft.com> Reviewed-by:
Jacques Newman <janewman@microsoft.com> Cr-Commit-Position: refs/heads/master@{#815656}
eef7f43d