After applying corner radius, WidgetView create widget visual per frame.
this point makes call relayout() every frame.
To avoid this problem, WidgetView check its size and call
widget_instance_resize only when the size is changed.
Change-Id: Icff97b88cbf6b70a508fe0cf2b10493dce60b081
// in this case, we just save the size and do resize when instance is created.
if( mCreated )
{
- widget_instance_resize(mInstanceId.c_str(), size.x, size.y);
+ if( (mWidth != size.x) || (mHeight != size.y))
+ {
+ widget_instance_resize(mInstanceId.c_str(), size.x, size.y);
+ mWidth = size.x;
+ mHeight = size.y;
+ }
}
else
{