check bidi frame before we call next sibling
check in for simon@softel.co.il
r/sr=kin
This commit is contained in:
ftang%netscape.com 2001-05-16 13:17:40 +00:00
Родитель 2fb2d3cc2a
Коммит d897428761
2 изменённых файлов: 26 добавлений и 4 удалений

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

@ -3677,11 +3677,22 @@ nsTextFrame::GetChildFrameContainingOffset(PRInt32 inContentOffset,
}
else {
#ifdef IBMBIDI // Simon
// There is no nextInFlow - check if there is a bidi
// continuation frame
if (mState & NS_FRAME_IS_BIDI)
{
nsIFrame *nextBidi;
GetNextSibling(&nextBidi);
if (nextBidi)
return nextBidi->GetChildFrameContainingOffset(inContentOffset, inHint, outFrameContentOffset, outChildFrame);
else
{
PRInt32 start, end;
if (NS_SUCCEEDED(nextBidi->GetOffsets(start, end)) && start > 0)
{
return nextBidi->GetChildFrameContainingOffset(inContentOffset,
inHint, outFrameContentOffset, outChildFrame);
}
}
}
#endif // IBMBIDI
{
if (contentOffset != mContentLength) //that condition was only for when there is a choice

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

@ -3677,11 +3677,22 @@ nsTextFrame::GetChildFrameContainingOffset(PRInt32 inContentOffset,
}
else {
#ifdef IBMBIDI // Simon
// There is no nextInFlow - check if there is a bidi
// continuation frame
if (mState & NS_FRAME_IS_BIDI)
{
nsIFrame *nextBidi;
GetNextSibling(&nextBidi);
if (nextBidi)
return nextBidi->GetChildFrameContainingOffset(inContentOffset, inHint, outFrameContentOffset, outChildFrame);
else
{
PRInt32 start, end;
if (NS_SUCCEEDED(nextBidi->GetOffsets(start, end)) && start > 0)
{
return nextBidi->GetChildFrameContainingOffset(inContentOffset,
inHint, outFrameContentOffset, outChildFrame);
}
}
}
#endif // IBMBIDI
{
if (contentOffset != mContentLength) //that condition was only for when there is a choice