void ui_init(void) { log_info("Initialising UI"); initscr(); nonl(); cbreak(); noecho(); keypad(stdscr, TRUE); ui_load_colours(); refresh(); create_title_bar(); create_status_bar(); status_bar_active(1); create_input_window(); wins_init(); notifier_initialise(); cons_about(); #ifdef HAVE_LIBXSS display = XOpenDisplay(0); #endif ui_idle_time = g_timer_new(); inp_size = 0; ProfWin *window = wins_get_current(); win_update_virtual(window); }
void ui_init(void) { log_info("Initialising UI"); initscr(); raw(); keypad(stdscr, TRUE); if (prefs_get_boolean(PREF_MOUSE)) { mousemask(ALL_MOUSE_EVENTS, NULL); mouseinterval(5); } ui_load_colours(); refresh(); create_title_bar(); create_status_bar(); status_bar_active(1); create_input_window(); wins_init(); cons_about(); notifier_init(); #ifdef HAVE_LIBXSS display = XOpenDisplay(0); #endif ui_idle_time = g_timer_new(); wins_refresh_current(); }
/* * Delete the existing windows and recreate them with their new * size and placement. */ void wins_reinit (void) { delwin (win[CAL].p); delwin (win[APP].p); delwin (apad.ptrwin); delwin (win[TOD].p); delwin (win[STA].p); wins_get_config (); wins_init (); if (notify_bar ()) notify_reinit_bar (); }
void handle_offline_removes_chat_session(void **state) { plugins_init(); roster_create(); chat_sessions_init(); char *barejid = "*****@*****.**"; char *resource = "home"; roster_add(barejid, "bob", NULL, "both", FALSE); Resource *resourcep = resource_new(resource, RESOURCE_ONLINE, NULL, 10); roster_update_presence(barejid, resourcep, NULL); chat_session_recipient_active(barejid, resource, FALSE); ProfConsoleWin *console = malloc(sizeof(ProfConsoleWin)); will_return(win_create_console, &console->window); wins_init(); sv_ev_contact_offline(barejid, resource, NULL); ChatSession *session = chat_session_get(barejid); assert_null(session); roster_destroy(); chat_sessions_clear(); plugins_shutdown(); }