diff options
| author | bernard.xiong <[email protected]> | 2010-09-09 11:37:32 +0000 |
|---|---|---|
| committer | bernard.xiong <[email protected]> | 2010-09-09 11:37:32 +0000 |
| commit | 7659f790ea01aff86d952dee8d60a7015a52a809 (patch) | |
| tree | 8beaf56247e42534b9480ebab5dd82c0c6227f0d | |
| parent | 347d1edb30983f404171fac8f78776fd57716c84 (diff) | |
fix button hide bug.
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@897 bbd45198-f89e-11dd-88c7-29a3b14d5316
| -rw-r--r-- | components/rtgui/widgets/button.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/components/rtgui/widgets/button.c b/components/rtgui/widgets/button.c index ca89b5383b..35f910e213 100644 --- a/components/rtgui/widgets/button.c +++ b/components/rtgui/widgets/button.c @@ -86,6 +86,7 @@ rt_bool_t rtgui_button_event_handler(struct rtgui_widget* widget, struct rtgui_e { struct rtgui_event_kbd* ekbd = (struct rtgui_event_kbd*) event; + if (RTGUI_WIDGET_IS_HIDE(widget)) RT_FALSE; if ((ekbd->key == RTGUIK_RETURN) || (ekbd->key == RTGUIK_SPACE)) { if (RTGUI_KBD_IS_DOWN(ekbd)) @@ -110,6 +111,7 @@ rt_bool_t rtgui_button_event_handler(struct rtgui_widget* widget, struct rtgui_e break; case RTGUI_EVENT_MOUSE_BUTTON: + if (RTGUI_WIDGET_IS_HIDE(widget)) RT_FALSE; { struct rtgui_event_mouse* emouse = (struct rtgui_event_mouse*)event; |
