fix widget clip update when set widget's extent.

git-svn-id: https://rt-thread.googlecode.com/svn/trunk@866 bbd45198-f89e-11dd-88c7-29a3b14d5316
This commit is contained in:
bernard.xiong 2010-08-19 14:16:36 +00:00
parent c188bba485
commit 188bad3b6f
1 changed files with 5 additions and 0 deletions

View File

@ -131,6 +131,11 @@ void rtgui_widget_set_rect(rtgui_widget_t* widget, rtgui_rect_t* rect)
/* reset clip info */ /* reset clip info */
rtgui_region_init_with_extents(&(widget->clip), rect); rtgui_region_init_with_extents(&(widget->clip), rect);
if ((widget->parent != RT_NULL) && (widget->toplevel != RT_NULL))
{
/* update widget clip */
rtgui_widget_update_clip(widget);
}
} }
#ifndef RTGUI_USING_SMALL_SIZE #ifndef RTGUI_USING_SMALL_SIZE