|
|
|
Lines 796-825
nsBidiPresUtils::TraverseFrames(nsBlockF
|
Link Here
|
|---|
|
| 796 |
if (frame == nextSibling) { |
796 |
if (frame == nextSibling) { |
| 797 |
nextSibling = frame->GetNextSibling(); |
797 |
nextSibling = frame->GetNextSibling(); |
| 798 |
} |
798 |
} |
| 799 |
} |
799 |
} |
| 800 |
|
800 |
|
| 801 |
mBuffer.Append(Substring(text, start, endLine - start)); |
801 |
mBuffer.Append(Substring(text, start, endLine - start)); |
| 802 |
|
802 |
|
| 803 |
if (PRUint32(endLine) < text.Length()) { |
803 |
if (PRUint32(endLine) < text.Length()) { |
| 804 |
nsTextFrame* textFrame = static_cast<nsTextFrame*>(frame); |
|
|
| 805 |
textFrame->SetLength(endLine - start, nsnull); |
| 806 |
next = frame->GetNextInFlow(); |
804 |
next = frame->GetNextInFlow(); |
| 807 |
if (!next) { |
805 |
if (!next) { |
| 808 |
// If the frame already has a bidi continuation, make it fluid |
806 |
// If the frame already has a bidi continuation, make it fluid |
| 809 |
next = frame->GetNextContinuation(); |
807 |
next = frame->GetNextContinuation(); |
| 810 |
if (next) { |
808 |
if (next) { |
| 811 |
MakeContinuationFluid(frame, next); |
809 |
MakeContinuationFluid(frame, next); |
| 812 |
JoinInlineAncestors(frame); |
810 |
JoinInlineAncestors(frame); |
| 813 |
} else { |
811 |
} else { |
| 814 |
// If the frame has no next in flow, create one |
812 |
// If the frame has no next in flow, create one |
| 815 |
CreateContinuation(frame, &next, PR_TRUE); |
813 |
CreateContinuation(frame, &next, PR_TRUE); |
| 816 |
} |
814 |
} |
| 817 |
} |
815 |
} |
|
|
816 |
nsTextFrame* textFrame = static_cast<nsTextFrame*>(frame); |
| 817 |
textFrame->SetLength(endLine - start, nsnull); |
| 818 |
} |
818 |
} |
| 819 |
ResolveParagraphWithinBlock(aBlockFrame); |
819 |
ResolveParagraphWithinBlock(aBlockFrame); |
| 820 |
|
820 |
|
| 821 |
if (next) { |
821 |
if (next) { |
| 822 |
frame = next; |
822 |
frame = next; |
| 823 |
mLogicalFrames.AppendElement(frame); |
823 |
mLogicalFrames.AppendElement(frame); |
| 824 |
} |
824 |
} |
| 825 |
|
825 |
|