Check the correct frame when iterating over continuations in nsTextFrame::GetRenderedText.
For clarity, we refactor body of the loop-over-continuations in
nsTextFrame::GetRenderedText into a helper method AppendRenderedText
that handles a single continuation in the chain.
This avoids the footgun of an nsTextFrame method iterating over its
continuations (using the textFrame variable) but potentially calling
methods of the primary frame within the loop, instead of the current
frame being processed.
Differential Revision: https://phabricator.services.mozilla.com/D225686
bugzilla-url: https://bugzilla.mozilla.org/show_bug.cgi?id=1923829
gecko-commit: f2f6cefad4a196e4c78ceb4c6bd4699c5e6a4cb0
gecko-reviewers: dshin