Patch by Alex Wilson as part of GSoC 2010 : fix a crashing bug in BTwoDimensionalLayout::AlignWith() (ticket #6244).
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@37348 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -539,7 +539,7 @@ BTwoDimensionalLayout::CompoundLayouter::AbsorbCompoundLayouter(
|
|||||||
return;
|
return;
|
||||||
|
|
||||||
int32 count = other->fLocalLayouters.CountItems();
|
int32 count = other->fLocalLayouters.CountItems();
|
||||||
for (int32 i = 0; i < count; i++) {
|
for (int32 i = count - 1; i >= 0; i--) {
|
||||||
LocalLayouter* layouter
|
LocalLayouter* layouter
|
||||||
= (LocalLayouter*)other->fLocalLayouters.ItemAt(i);
|
= (LocalLayouter*)other->fLocalLayouters.ItemAt(i);
|
||||||
AddLocalLayouter(layouter);
|
AddLocalLayouter(layouter);
|
||||||
@@ -1169,7 +1169,7 @@ BTwoDimensionalLayout::LocalLayouter::SetCompoundLayouter(
|
|||||||
fHLayouter = compoundLayouter;
|
fHLayouter = compoundLayouter;
|
||||||
} else {
|
} else {
|
||||||
oldCompoundLayouter = fVLayouter;
|
oldCompoundLayouter = fVLayouter;
|
||||||
fVLayouter = (VerticalCompoundLayouter*)compoundLayouter;
|
fVLayouter = static_cast<VerticalCompoundLayouter*>(compoundLayouter);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (compoundLayouter == oldCompoundLayouter)
|
if (compoundLayouter == oldCompoundLayouter)
|
||||||
|
|||||||
Reference in New Issue
Block a user