clean code and mirror change for desktop application
git-svn-id: https://rt-thread.googlecode.com/svn/trunk@1552 bbd45198-f89e-11dd-88c7-29a3b14d5316
This commit is contained in:
parent
cfd580edf4
commit
ce01644d0d
|
@ -75,6 +75,12 @@ void rtgui_box_append(struct rtgui_box* box, rtgui_widget_t* widget)
|
||||||
rtgui_container_add_child(RTGUI_CONTAINER(box), widget);
|
rtgui_container_add_child(RTGUI_CONTAINER(box), widget);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void rtgui_box_delete(struct rtgui_box* box, rtgui_widget_t* widget)
|
||||||
|
{
|
||||||
|
/* remove from box's children list */
|
||||||
|
rtgui_container_remove_child(RTGUI_CONTAINER(box), widget);
|
||||||
|
}
|
||||||
|
|
||||||
static void rtgui_box_layout_vertical(rtgui_box_t* box)
|
static void rtgui_box_layout_vertical(rtgui_box_t* box)
|
||||||
{
|
{
|
||||||
rtgui_list_t *node;
|
rtgui_list_t *node;
|
||||||
|
|
|
@ -207,13 +207,11 @@ rt_bool_t rtgui_combobox_event_handler(struct rtgui_widget* widget, struct rtgui
|
||||||
case RTGUI_EVENT_FOCUSED:
|
case RTGUI_EVENT_FOCUSED:
|
||||||
{
|
{
|
||||||
/* item focused */
|
/* item focused */
|
||||||
struct rtgui_item* item;
|
|
||||||
struct rtgui_event_focused* focused;
|
struct rtgui_event_focused* focused;
|
||||||
|
|
||||||
focused = (struct rtgui_event_focused*) event;
|
focused = (struct rtgui_event_focused*) event;
|
||||||
|
|
||||||
item = (struct rtgui_item*) (focused->widget);
|
if (focused->widget != RT_NULL)
|
||||||
if (item != RT_NULL)
|
|
||||||
{
|
{
|
||||||
/* hide pull down window */
|
/* hide pull down window */
|
||||||
rtgui_win_hiden(RTGUI_WIN(box->pd_win));
|
rtgui_win_hiden(RTGUI_WIN(box->pd_win));
|
||||||
|
|
|
@ -147,6 +147,7 @@ void rtgui_workbench_close(rtgui_workbench_t* workbench)
|
||||||
|
|
||||||
/* detach from panel */
|
/* detach from panel */
|
||||||
edetach.panel = workbench->panel;
|
edetach.panel = workbench->panel;
|
||||||
|
edetach.workbench = workbench;
|
||||||
|
|
||||||
/* send PANEL DETACH to server */
|
/* send PANEL DETACH to server */
|
||||||
if (rtgui_thread_send_sync(RTGUI_TOPLEVEL(workbench)->server,
|
if (rtgui_thread_send_sync(RTGUI_TOPLEVEL(workbench)->server,
|
||||||
|
|
Loading…
Reference in New Issue