Bug 680085 - Don't traverse dirty text frames when computing rendered text. r=roc

We now bail in GetRenderedText when we encounter dirty text frames. This shouldm be okay since dirty text frames should be reflowed at some point and we'll refresh our accessible text cache.
This commit is contained in:
David Bolter 2011-10-17 10:30:33 -04:00
Родитель e588d96fd3
Коммит 57e093059d
1 изменённых файлов: 5 добавлений и 0 удалений

Просмотреть файл

@ -7608,6 +7608,11 @@ nsresult nsTextFrame::GetRenderedText(nsAString* aAppendToString,
textFrame = static_cast<nsTextFrame*>(textFrame->GetNextContinuation())) {
// For each text frame continuation in this block ...
if (textFrame->GetStateBits() & NS_FRAME_IS_DIRTY) {
// We don't trust dirty frames, expecially when computing rendered text.
break;
}
// Ensure the text run and grab the gfxSkipCharsIterator for it
gfxSkipCharsIterator iter = textFrame->EnsureTextRun();
if (!textFrame->mTextRun)