|
|
|
|
@ -581,9 +581,19 @@ void yon_set_sensitive_from_combo_box(GtkComboBox *toggle, GtkWidget *target){
|
|
|
|
|
gtk_widget_set_sensitive(target,active>1 ? 1 : 0);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void on_database_update(void *,void *widgets){
|
|
|
|
|
terminal_window_struct *window = yon_terminal_window_launch(GTK_WINDOW(((main_window*)widgets)->Window),pacman_update_command,yon_char_get_localised_from_lib(SUCCESS_LABEL),OPERATION_FAIL_LABEL);
|
|
|
|
|
g_signal_connect(G_OBJECT(window->window),"destroy",G_CALLBACK(yon_proprietary_get_thread),widgets);
|
|
|
|
|
gboolean on_db_update_done(GtkWidget *,gint ,main_window *widgets){
|
|
|
|
|
yon_proprietary_get_thread(NULL,(main_window*)widgets);
|
|
|
|
|
g_signal_handlers_disconnect_by_func(G_OBJECT(widgets->InstallTerminal),G_CALLBACK(on_db_update_done),widgets);
|
|
|
|
|
return 0;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void on_database_update(void *,main_window *widgets){
|
|
|
|
|
// terminal_window_struct *window = yon_terminal_window_launch(GTK_WINDOW(((main_window*)widgets)->Window),pacman_update_command,yon_char_get_localised_from_lib(SUCCESS_LABEL),OPERATION_FAIL_LABEL);
|
|
|
|
|
yon_terminal_integrated_start_shell(widgets->InstallTerminal,yon_debug_output("%s\n",pacman_update_command),NULL,NULL);
|
|
|
|
|
g_signal_connect(G_OBJECT(widgets->InstallTerminal),"child-exited",G_CALLBACK(on_db_update_done),widgets);
|
|
|
|
|
gtk_button_clicked(GTK_BUTTON(widgets->MoreButton));
|
|
|
|
|
gtk_notebook_set_current_page(GTK_NOTEBOOK(widgets->MenusTab),1);
|
|
|
|
|
// g_signal_connect(G_OBJECT(window->window),"destroy",G_CALLBACK(yon_proprietary_get_thread),widgets);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void on_gapfix_changed(GtkWidget*, main_window *widgets){
|
|
|
|
|
@ -960,6 +970,7 @@ int main(int argc, char *argv[]){
|
|
|
|
|
template_main_window *widgets = yon_ubl_window_setup();
|
|
|
|
|
config_init();
|
|
|
|
|
widgets = yon_main_window_complete((main_window*)widgets);
|
|
|
|
|
yon_packages_init();
|
|
|
|
|
yon_root_button_setup(widgets,argv,argc);
|
|
|
|
|
|
|
|
|
|
if (system(yon_check_database_command)){
|
|
|
|
|
@ -967,14 +978,13 @@ int main(int argc, char *argv[]){
|
|
|
|
|
data->action_text=DATABASE_UNACCESSIBLE_LABEL;
|
|
|
|
|
GtkResponseType resp = yon_confirmation_dialog_call(widgets->HeadOverlay,data);
|
|
|
|
|
if (resp){
|
|
|
|
|
on_database_update(NULL,widgets);
|
|
|
|
|
on_database_update(NULL,(main_window*)widgets);
|
|
|
|
|
} else {
|
|
|
|
|
yon_proprietary_get_thread(NULL,(main_window*)widgets);
|
|
|
|
|
}
|
|
|
|
|
} else {
|
|
|
|
|
yon_proprietary_get_thread(NULL,(main_window*)widgets);
|
|
|
|
|
}
|
|
|
|
|
yon_packages_init();
|
|
|
|
|
gtk_main();
|
|
|
|
|
yon_packages_finish();
|
|
|
|
|
return 0;
|
|
|
|
|
|