Test added new debg messages

pull/60/head
parent 2905c6ab5c
commit 499e1ce78a

@ -994,32 +994,32 @@ void *on_config_save(void *data){
fclose(file); fclose(file);
char *command = save_config_command(yon_char_parsed_to_string(parameters,size," ")); char *command = save_config_command(yon_char_parsed_to_string(parameters,size," "));
yon_char_parsed_free(parameters,size); yon_char_parsed_free(parameters,size);
yon_debug_output("$s\n","Entered installation"); yon_debug_output("%s\n","Entered installation");
if (system(yon_debug_output("%s\n",command))){ if (system(yon_debug_output("%s\n",command))){
yon_debug_output("$s\n","Entered installation failed"); yon_debug_output("%s\n","Entered installation failed");
g_thread_new("success func",(GThreadFunc)on_install_error,widgets); g_thread_new("success func",(GThreadFunc)on_install_error,widgets);
free(command); free(command);
main_config.config_save_thread=NULL; main_config.config_save_thread=NULL;
main_config.install_thread=0; main_config.install_thread=0;
main_config.install_complete=1; main_config.install_complete=1;
yon_debug_output("$s\n","Exit installation"); yon_debug_output("%s\n","Exit installation");
pthread_exit(NULL); pthread_exit(NULL);
return 0; return 0;
}; };
yon_debug_output("$s\n","Entered installation success"); yon_debug_output("%s\n","Entered installation success");
free(command); free(command);
main_config.install_thread=0; main_config.install_thread=0;
main_config.install_complete=1; main_config.install_complete=1;
yon_debug_output("Install set to: %s\n",yon_char_from_int(main_config.install_complete)); yon_debug_output("Install set to: %s\n",yon_char_from_int(main_config.install_complete));
yon_debug_output("Save state: %s\n",yon_char_from_int(main_config.save_done)); yon_debug_output("Save state: %s\n",yon_char_from_int(main_config.save_done));
if (main_config.save_done){ if (main_config.save_done){
yon_debug_output("$s\n","Entered installation page change"); yon_debug_output("%s\n","Entered installation page change");
g_thread_new("success func",(GThreadFunc)on_install_success,widgets); g_thread_new("success func",(GThreadFunc)on_install_success,widgets);
} }
main_config.config_save_thread=NULL; main_config.config_save_thread=NULL;
yon_debug_output("$s\n","Exit installation"); yon_debug_output("%s\n","Exit installation");
pthread_exit(NULL); pthread_exit(NULL);
} }
@ -1152,6 +1152,7 @@ void on_page_changed(GtkWidget *,GtkWidget *,int page, main_window *widgets){
} break; } break;
case YON_PAGE_COMPLETION:{ case YON_PAGE_COMPLETION:{
yon_debug_output("%s\n","Enter completion");
yon_switch_page_render(widgets,7); yon_switch_page_render(widgets,7);
gtk_widget_set_sensitive(widgets->BackButton,0); gtk_widget_set_sensitive(widgets->BackButton,0);
gtk_widget_hide(gtk_widget_get_parent(widgets->PackageInstallationProgress)); gtk_widget_hide(gtk_widget_get_parent(widgets->PackageInstallationProgress));
@ -1159,13 +1160,16 @@ void on_page_changed(GtkWidget *,GtkWidget *,int page, main_window *widgets){
gtk_widget_hide(widgets->PackageInstallationLabel); gtk_widget_hide(widgets->PackageInstallationLabel);
gtk_widget_set_sensitive(widgets->NextButton,1); gtk_widget_set_sensitive(widgets->NextButton,1);
gtk_widget_set_sensitive(widgets->CancelInstallButton,1); gtk_widget_set_sensitive(widgets->CancelInstallButton,1);
yon_debug_output("%s\n","Done widgets");
main_config.install_complete=0; main_config.install_complete=0;
main_config.save_done=0; main_config.save_done=0;
yon_debug_output("%s\n","Done variables");
textdomain(LocaleName); textdomain(LocaleName);
gtk_button_set_label(GTK_BUTTON(widgets->NextButton),RESTART_LABEL); gtk_button_set_label(GTK_BUTTON(widgets->NextButton),RESTART_LABEL);
gtk_button_set_label(GTK_BUTTON(widgets->CancelInstallButton),EXIT_LABEL); gtk_button_set_label(GTK_BUTTON(widgets->CancelInstallButton),EXIT_LABEL);
gtk_image_set_from_icon_name(GTK_IMAGE(gtk_button_get_image(GTK_BUTTON(widgets->NextButton))), gtk_image_set_from_icon_name(GTK_IMAGE(gtk_button_get_image(GTK_BUTTON(widgets->NextButton))),
"com.ublinux.ubinstall-gtk.sync-symbolic",GTK_ICON_SIZE_BUTTON); "com.ublinux.ubinstall-gtk.sync-symbolic",GTK_ICON_SIZE_BUTTON);
yon_debug_output("%s\n","Done labels and button icon");
} }
break; break;
@ -1224,7 +1228,7 @@ void *on_install_error(main_window *widgets){
void *on_setup_system_configuration(void *data); void *on_setup_system_configuration(void *data);
void *on_setup_system_configuration(void * data){ void *on_setup_system_configuration(void * data){
yon_debug_output("$s\n","Entered thread"); yon_debug_output("%s\n","Entered thread");
main_window *widgets = (main_window*)data; main_window *widgets = (main_window*)data;
if (widgets){}; if (widgets){};
int size; int size;
@ -1246,7 +1250,7 @@ void *on_setup_system_configuration(void * data){
if (all_parameters){ if (all_parameters){
char *parameter_string = yon_char_parsed_to_string(all_parameters,size," "); char *parameter_string = yon_char_parsed_to_string(all_parameters,size," ");
char *command = set_user_config_command(parameter_string); char *command = set_user_config_command(parameter_string);
if (system(yon_debug_output("$s\n",command))){}; if (system(yon_debug_output("%s\n",command))){};
yon_char_parsed_free(all_parameters,size); yon_char_parsed_free(all_parameters,size);
free(command); free(command);
if (parameter_string) free(parameter_string); if (parameter_string) free(parameter_string);
@ -1775,12 +1779,12 @@ void on_page_navigation_clicked(GtkWidget *self, main_window *widgets){
} }
if (!main_config.configure_mode){ if (!main_config.configure_mode){
yon_debug_output("$s\n","Entered saving"); yon_debug_output("%s\n","Entered saving");
if (!main_config.install_complete){ if (!main_config.install_complete){
gtk_notebook_set_current_page(GTK_NOTEBOOK(widgets->Notebook),YON_PAGE_INSTALLATION); gtk_notebook_set_current_page(GTK_NOTEBOOK(widgets->Notebook),YON_PAGE_INSTALLATION);
} }
if (gtk_progress_bar_get_fraction(GTK_PROGRESS_BAR(widgets->InstallationProgress))>0.9){ if (gtk_progress_bar_get_fraction(GTK_PROGRESS_BAR(widgets->InstallationProgress))>0.9){
yon_debug_output("$s\n","Entered saving before installation done"); yon_debug_output("%s\n","Entered saving before installation done");
gtk_notebook_set_current_page(GTK_NOTEBOOK(widgets->Notebook),YON_PAGE_INSTALLATION); gtk_notebook_set_current_page(GTK_NOTEBOOK(widgets->Notebook),YON_PAGE_INSTALLATION);
gtk_label_set_text(GTK_LABEL(widgets->InstallationLabel),CONFIGURATION_LABEL); gtk_label_set_text(GTK_LABEL(widgets->InstallationLabel),CONFIGURATION_LABEL);
pthread_t tid; pthread_t tid;

Loading…
Cancel
Save