If more than 8 items have to be resized in a stacked theme layout, abort with an error (instead of silently trashing the stack)

svn-id: r35549
This commit is contained in:
Max Horn 2008-12-26 01:13:08 +00:00
parent 131cb5a05a
commit 751df013e1

View File

@ -161,6 +161,7 @@ void ThemeLayoutStacked::reflowLayoutV() {
_children[i]->setWidth((_w == -1 ? getParentW() : _w) - _padding.left - _padding.right);
if (_children[i]->getHeight() == -1) {
assert(rescount < ARRAYSIZE(resize));
resize[rescount++] = i;
_children[i]->setHeight(0);
}
@ -209,6 +210,7 @@ void ThemeLayoutStacked::reflowLayoutH() {
_children[i]->setHeight((_h == -1 ? getParentH() : _h) - _padding.top - _padding.bottom);
if (_children[i]->getWidth() == -1) {
assert(rescount < ARRAYSIZE(resize));
resize[rescount++] = i;
_children[i]->setWidth(0);
}