diff --git a/source/ubl-settings-system.c b/source/ubl-settings-system.c index 6b2d56d..18b926b 100644 --- a/source/ubl-settings-system.c +++ b/source/ubl-settings-system.c @@ -534,7 +534,7 @@ gboolean on_main_window_domain_status_update(connection_window *window){ return 1; } -gboolean yon_update_thread(connection_window *window){ +gboolean yon_update_thread(GtkWidget *self, GdkEvent *event, connection_window *window){ pthread_t thread_id; pthread_create(&thread_id, NULL, (void *)on_main_window_domain_status_update,window); return 1; @@ -561,7 +561,8 @@ connection_window *yon_connection_window_new(){ g_signal_connect(G_OBJECT(window->CancelButton),"clicked",G_CALLBACK(on_subwindow_close),NULL); g_signal_connect(G_OBJECT(window->StatusEntry),"clicked",G_CALLBACK(on_status_clicked),window); g_signal_connect(G_OBJECT(window->FindEntry),"clicked",G_CALLBACK(on_find_domains_clicked),window); - window->timer_id = g_timeout_add(1000,(GSourceFunc)yon_update_thread,window); + g_signal_connect(G_OBJECT(window->AdressEntry),"focus-out",G_CALLBACK(yon_update_thread),window); + yon_update_thread(NULL,NULL,window); return window; } @@ -748,7 +749,7 @@ main_window *yon_main_window_complete(main_window *widgets){ // g_timeout_add(1000,(GSourceFunc)on_check_domain_connected,widgets); on_check_domain_connected(NULL, widgets); - + main_config.localeslist = gtk_list_store_new(3,G_TYPE_STRING,G_TYPE_STRING,G_TYPE_BOOLEAN); int size; config_str locales = yon_file_open(get_locales_command,&size);