fix clip info event in small size mode.

git-svn-id: https://rt-thread.googlecode.com/svn/trunk@343 bbd45198-f89e-11dd-88c7-29a3b14d5316
This commit is contained in:
bernard.xiong 2010-01-27 09:40:02 +00:00
parent 5805cbfd33
commit 646db738d5
8 changed files with 15 additions and 10 deletions

View File

@ -41,6 +41,7 @@ widgets/container.c
widgets/iconbox.c
widgets/label.c
widgets/progressbar.c
widgets/radiobox.c
widgets/slider.c
widgets/staticline.c
widgets/textbox.c

View File

@ -131,6 +131,9 @@ static void rtgui_event_dump(rt_thread_t tid, rtgui_event_t* event)
if(info->wid != RT_NULL)
rt_kprintf("win: %s", info->wid->title);
#ifdef RTGUI_USING_SMALL_SIZE
rt_kprintf(" clip no. %d", info->num_rect);
#endif
}
break;
@ -325,6 +328,8 @@ rt_err_t rtgui_thread_send(rt_thread_t tid, rtgui_event_t* event, rt_size_t even
struct rtgui_thread* thread;
rtgui_event_dump(tid, event);
if (event->type != RTGUI_EVENT_TIMER)
rt_kprintf("event size: %d\n", event_size);
/* find rtgui_thread */
thread = (struct rtgui_thread*) (tid->user_data);
@ -338,6 +343,7 @@ rt_err_t rtgui_thread_send_urgent(rt_thread_t tid, rtgui_event_t* event, rt_size
struct rtgui_thread* thread;
rtgui_event_dump(tid, event);
rt_kprintf("event size: %d\n", event_size);
/* find rtgui_thread */
thread = (struct rtgui_thread*) (tid->user_data);
@ -354,6 +360,7 @@ rt_err_t rtgui_thread_send_sync(rt_thread_t tid, rtgui_event_t* event, rt_size_t
struct rt_mailbox ack_mb;
rtgui_event_dump(tid, event);
rt_kprintf("event size: %d\n", event_size);
/* init ack mailbox */
r = rt_mb_init(&ack_mb, "ack", &ack_buffer, 1, 0);

View File

@ -172,9 +172,6 @@ struct rtgui_event_win_create
{
struct rtgui_event parent;
/* the window event mask */
rt_uint32_t mask;
/* the window flag */
rt_uint32_t flag;

View File

@ -18,19 +18,17 @@
/* RTGUI options */
/* name length of RTGUI object */
#define RTGUI_NAME_MAX 16
#define RTGUI_NAME_MAX 12
/* #define RTGUI_USING_MOUSE_CURSOR */
// #define RTGUI_USING_FONT12
#define RTGUI_USING_FONT16
#define RTGUI_USING_FONTHZ
#ifdef _WIN32
#define RTGUI_USING_STDIO_FILERW
#define RTGUI_IMAGE_PNG
#define RTGUI_IMAGE_JPG
#define RTGUI_IMAGE_JPEG
#define RTGUI_USING_FONT12
#else

View File

@ -75,7 +75,6 @@ rt_err_t rtgui_topwin_add(struct rtgui_event_win_create* event)
topwin->wid = event->wid;
topwin->extent = event->extent;
topwin->tid = event->parent.sender;
topwin->mask = event->mask;
topwin->flag = 0;
if (event->flag & RTGUI_WIN_STYLE_NO_TITLE) topwin->flag |= WINTITLE_NO;
@ -279,6 +278,7 @@ void rtgui_topwin_raise(struct rtgui_win* wid, rt_thread_t sender)
rt_int32_t count;
struct rtgui_list_node* node;
struct rtgui_event_clip_info eclip;
RTGUI_EVENT_CLIP_INFO_INIT(&eclip);
/* the window is already placed in front */
if (&(topwin->list) == _rtgui_topwin_show_list.next)
@ -741,6 +741,8 @@ static void rtgui_topwin_update_clip()
struct rtgui_event_clip_info eclip;
struct rtgui_list_node* node = _rtgui_topwin_show_list.next;
RTGUI_EVENT_CLIP_INFO_INIT(&eclip);
rtgui_list_foreach(node, &_rtgui_topwin_show_list)
{
struct rtgui_topwin* wnd;

View File

@ -688,6 +688,6 @@ void rtgui_filelist_get_fullpath(rtgui_filelist_view_t* view, char* path, rt_siz
{
RT_ASSERT(view != RT_NULL);
rt_sprintf(path, "%s/%s", view->current_directory,
rt_sprintf(path, "%s%c%s", view->current_directory, PATH_SEPARATOR,
view->items[view->current_item].name);
}

View File

@ -80,7 +80,6 @@ static rt_bool_t _rtgui_win_create_in_server(rtgui_win_t* win)
ecreate.wid = win;
ecreate.extent = RTGUI_WIDGET(win)->extent;
ecreate.flag = win->style;
ecreate.mask = 0;
rt_strncpy((char*)ecreate.title, (char*)win->title, RTGUI_NAME_MAX);
if (rtgui_thread_send_sync(server, RTGUI_EVENT(&ecreate),

View File

@ -24,6 +24,7 @@ static void _rtgui_workbench_constructor(rtgui_workbench_t *workbench)
workbench->panel = RT_NULL;
workbench->flag = RTGUI_WORKBENCH_FLAG_DEFAULT;
workbench->modal_code = RTGUI_MODAL_OK;
workbench->title = RT_NULL;
workbench->current_view = RT_NULL;
}