Update Widget_UpdateChildrenSize()
@@ -873,8 +873,14 @@ static void Widget_UpdateChildrenSize( LCUI_Widget w )
for( LinkedList_Each( node, &w->children ) ) {
LCUI_Widget child = node->data;
LCUI_Style s = child->style->sheet;
- if( s[key_width].type == SVT_SCALE ||
- s[key_height].type == SVT_SCALE ) {
+ if( child->computed_style.display == SV_BLOCK ) {
+ if( CheckStyleType( s, key_width, AUTO ) ||
+ CheckStyleType( s, key_height, AUTO ) ) {
+ Widget_AddTask( child, WTT_RESIZE );
+ }
+ }
+ if( CheckStyleType( s, key_width, SCALE ) ||
+ CheckStyleType( s, key_height, SCALE ) ) {
Widget_AddTask( child, WTT_RESIZE );
}
if( child->computed_style.position == SV_ABSOLUTE ) {
