Fix stop crashing with UIWidget::moveChildToIndex.

This commit is contained in:
BenDol 2014-04-04 11:33:17 +13:00
parent 01e6169cfb
commit a02c091376
1 changed files with 1 additions and 1 deletions

View File

@ -418,7 +418,7 @@ void UIWidget::moveChildToIndex(const UIWidgetPtr& child, int index)
if(!child)
return;
if((uint)index - 1 > m_children.size()) {
if((uint)index - 1 >= m_children.size()) {
g_logger.traceError(stdext::format("moving %s to index %d on %s", child->getId(), index, m_id));
return;
}