fix studio json reader percentage mode bug

This commit is contained in:
andyque 2015-06-25 16:14:22 +08:00
parent 76eb095f32
commit 0c1ee8b26a
1 changed files with 2 additions and 2 deletions

View File

@ -1412,7 +1412,7 @@ Widget* WidgetPropertiesReader0300::widgetFromBinary(CocoLoader* cocoLoader, st
}
else
{
if (dynamic_cast<Layout*>(widget))
if (nullptr == dynamic_cast<Layout*>(widget))
{
if (child->getPositionType() == ui::Widget::PositionType::PERCENT)
{
@ -1504,7 +1504,7 @@ Widget* WidgetPropertiesReader0300::widgetFromJsonDictionary(const rapidjson::Va
}
else
{
if (dynamic_cast<Layout*>(widget))
if (nullptr == dynamic_cast<Layout*>(widget))
{
if (child->getPositionType() == ui::Widget::PositionType::PERCENT)
{