示例#1
0
void
on_quit ()
{
    stop_web_server();
    stop_ccnet ();
    if (applet->icon)
        trayicon_delete_icon(applet->icon);
}
示例#2
0
/* Kill ccnet/seaf/web, and restart them. */
void restart_all (void)
{
    trayicon_set_tip ("Seafile");
    
    applet_message ("Restarting ccnet ...\n");
    stop_open_browser_timer();
    stop_web_server();
    
    if (applet->client->connected) {
        stop_ccnet();
    }
    
    spawn_ccnet_daemon();
    
    start_conn_daemon_timer (1000, NULL);
}
示例#3
0
void fATWP(void *arg){
	unsigned int parm = atoi((const char *)(arg));
        printf("[ATWP]: _AT_WLAN_POWER_[%s]\n\r", parm?"ON":"OFF");
	if(parm == 1){
		if(wifi_on(RTW_MODE_STA)<0){
			printf("\n\rERROR: Wifi on failed!\n");
		}
	}
	else if(parm == 0)
	{
#if CONFIG_WEBSERVER
		stop_web_server();
#endif
		wifi_off();		
	}
        else
          printf("[ATWP]Usage: ATWP=0/1\n\r");
}
示例#4
0
void on_quit ()
{
    stop_ccnet ();
    stop_web_server ();
    gtk_main_quit ();
}