fix gui example issue in 0.3.x.

git-svn-id: https://rt-thread.googlecode.com/svn/trunk@939 bbd45198-f89e-11dd-88c7-29a3b14d5316
This commit is contained in:
bernard.xiong@gmail.com 2010-09-23 15:12:45 +00:00
parent d640fd4445
commit 916a730251
3 changed files with 6 additions and 4 deletions

View File

@ -4,6 +4,7 @@
#include <rtgui/widgets/view.h> #include <rtgui/widgets/view.h>
#include "demo_view.h" #include "demo_view.h"
#if RT_VERSION == 4
#define RAND(x1, x2) ((rand() % (x2 - x1)) + x1) #define RAND(x1, x2) ((rand() % (x2 - x1)) + x1)
static rtgui_view_t* view = RT_NULL; static rtgui_view_t* view = RT_NULL;
@ -107,3 +108,4 @@ rtgui_view_t *demo_view_benchmark(rtgui_workbench_t* workbench)
return view; return view;
} }
#endif

View File

@ -29,8 +29,6 @@ rt_bool_t instrument_panel_event_handler(rtgui_widget_t* widget, rtgui_event_t *
{ {
struct rtgui_dc* dc; struct rtgui_dc* dc;
rtgui_rect_t rect; rtgui_rect_t rect;
const int vx[] = {85, 85, 105, 105};
const int vy[] = {60, 100, 100, 60};
const int arrowx[] = {120+75, 120+75, 120+85}; const int arrowx[] = {120+75, 120+75, 120+85};
const int arrowy[] = {170-5, 170+5, 170}; const int arrowy[] = {170-5, 170+5, 170};

View File

@ -62,18 +62,20 @@ static void workbench_entry(void* parameter)
#endif #endif
#endif #endif
#ifndef RTGUI_USING_SMALL_SIZE
demo_view_dc_buffer(workbench); demo_view_dc_buffer(workbench);
#endif
demo_view_animation(workbench); demo_view_animation(workbench);
#ifndef RTGUI_USING_SMALL_SIZE
demo_view_buffer_animation(workbench); demo_view_buffer_animation(workbench);
demo_view_instrument_panel(workbench); demo_view_instrument_panel(workbench);
#endif
demo_view_window(workbench); demo_view_window(workbench);
demo_view_label(workbench); demo_view_label(workbench);
demo_view_button(workbench); demo_view_button(workbench);
demo_view_checkbox(workbench); demo_view_checkbox(workbench);
demo_view_progressbar(workbench); demo_view_progressbar(workbench);
#if RT_VERSION == 4
demo_view_scrollbar(workbench); demo_view_scrollbar(workbench);
#endif
demo_view_radiobox(workbench); demo_view_radiobox(workbench);
demo_view_textbox(workbench); demo_view_textbox(workbench);
demo_view_listbox(workbench); demo_view_listbox(workbench);