/***************************************************************************** * FUNCTION * wgui_show_horizontal_tab_bar * DESCRIPTION * Show the horizontal tab bar * PARAMETERS * void * RETURNS * void *****************************************************************************/ void wgui_show_horizontal_tab_bar(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ gui_lock_double_buffer(); gui_show_horizontal_tab_bar(&MMI_horizontal_tab_bar, MMI_FALSE, MMI_FALSE); gui_unlock_double_buffer(); gui_BLT_double_buffer( MMI_horizontal_tab_bar.x, MMI_horizontal_tab_bar.y, MMI_horizontal_tab_bar.x + MMI_horizontal_tab_bar.width - 1, MMI_horizontal_tab_bar.y + MMI_horizontal_tab_bar.height - 1); if (MMI_horizontal_tab_bar.theme->hint_bg_image && title_bg_id == 0) { title_bg_id = MMI_horizontal_tab_bar.theme->hint_bg_image; gui_add_cleanup_hook(wgui_horizontal_tab_bar_reset_title_bg_id); } gui_horizontal_tab_bar_start_blinking(&MMI_horizontal_tab_bar); }
/***************************************************************************** * FUNCTION * gui_panel_show * DESCRIPTION * Show a panel component * PARAMETERS * panel [IN/OUT] panel * RETURNS * void *****************************************************************************/ void gui_panel_show(gui_panel_struct *panel) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ S32 x1, y1, x2, y2; S32 elem_idx; /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ x1 = panel->x; y1 = panel->y; x2 = panel->x + panel->width - 1; y2 = panel->y + panel->height - 1; gui_lock_double_buffer(); gui_util_painter_show(&panel->background, x1, y1, x2, y2); for (elem_idx = 0; elem_idx < panel->element_count; elem_idx++) { gui_panel_element_struct *e = &panel->elements[elem_idx]; gui_panel_elem_state_enum state; if (e->disabled_state) { state = GUI_PANEL_ELEM_STATE_DISABLED; } else if (e->down_state) { state = GUI_PANEL_ELEM_STATE_DOWN; } else if (panel->display_focus && elem_idx == panel->element_focus_index) { state = GUI_PANEL_ELEM_STATE_FOCUSSED; } else { state = GUI_PANEL_ELEM_STATE_NORMAL; } gui_util_painter_show(&e->painters[state], e->x1, e->y1, e->x2, e->y2); } gui_unlock_double_buffer(); gui_BLT_double_buffer(x1, y1, x2, y2); /* Add cleanup handler */ gui_add_cleanup_hook(gui_panel_reset_state); }
/***************************************************************************** * FUNCTION * wgui_show_horizontal_tab_bar_hint_area * DESCRIPTION * * PARAMETERS * void * RETURNS * void *****************************************************************************/ void wgui_show_horizontal_tab_bar_hint_area(void) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ gui_lock_double_buffer(); gui_show_horizontal_tab_bar(&MMI_horizontal_tab_bar, MMI_TRUE, MMI_FALSE); gui_unlock_double_buffer(); gui_BLT_double_buffer( MMI_horizontal_tab_bar.x, MMI_horizontal_tab_bar.y + MMI_horizontal_tab_bar.tab_area_height, MMI_horizontal_tab_bar.x + MMI_horizontal_tab_bar.width - 1, MMI_horizontal_tab_bar.y + MMI_horizontal_tab_bar.height - 1); }
/***************************************************************************** * FUNCTION * gui_panel_show_element * DESCRIPTION * Draw a painter element * PARAMETERS * panel [IN/OUT] panel * element [IN] panel element * state [IN] state of panel element * bg_is_already_drawn [IN] whether the panel background is already drawn. * RETURNS * void *****************************************************************************/ static void gui_panel_show_element( gui_panel_struct *panel, gui_panel_element_struct *element, gui_panel_elem_state_enum state, MMI_BOOL bg_is_already_drawn) { /*----------------------------------------------------------------*/ /* Local Variables */ /*----------------------------------------------------------------*/ /*----------------------------------------------------------------*/ /* Code Body */ /*----------------------------------------------------------------*/ gui_lock_double_buffer(); if (!bg_is_already_drawn && element->redraw_bg_after_state_changed) { gui_util_painter_show_clipped( &panel->background, panel->x, panel->y, element->x1, element->y1, element->x2, element->y2); } gui_util_painter_show( &element->painters[state], element->x1, element->y1, element->x2, element->y2); gui_unlock_double_buffer(); gui_BLT_double_buffer(element->x1, element->y1, element->x2, element->y2); }