|
|
|
|
@ -157,6 +157,22 @@ void on_add_packages_accept(GtkWidget *self, dictionary *dict){
|
|
|
|
|
const char *repo = gtk_combo_box_get_active_id(GTK_COMBO_BOX(window->RepositoryCombo));
|
|
|
|
|
const char *arch = gtk_combo_box_get_active_id(GTK_COMBO_BOX(window->ArchitectureCombo));
|
|
|
|
|
|
|
|
|
|
if (yon_char_is_empty(storage)||yon_char_is_empty(repo)||yon_char_is_empty(arch)){
|
|
|
|
|
yon_ubl_status_box_spawn(GTK_CONTAINER(window->StatusBox),EMPTY_IMPORTANT_LABEL,5,BACKGROUND_IMAGE_FAIL_TYPE);
|
|
|
|
|
yon_ubl_status_highlight_incorrect(window->StorageCombo);
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if (yon_char_is_empty(repo)){
|
|
|
|
|
yon_ubl_status_box_spawn(GTK_CONTAINER(window->StatusBox),EMPTY_IMPORTANT_LABEL,5,BACKGROUND_IMAGE_FAIL_TYPE);
|
|
|
|
|
yon_ubl_status_highlight_incorrect(window->RepositoryCombo);
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if (yon_char_is_empty(arch)){
|
|
|
|
|
yon_ubl_status_box_spawn(GTK_CONTAINER(window->StatusBox),EMPTY_IMPORTANT_LABEL,5,BACKGROUND_IMAGE_FAIL_TYPE);
|
|
|
|
|
yon_ubl_status_highlight_incorrect(window->ArchitectureCombo);
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
const char *repo_sign = gtk_combo_box_get_active_id(GTK_COMBO_BOX(window->RepoSignCombo));
|
|
|
|
|
const char *package_sign = gtk_combo_box_get_active_id(GTK_COMBO_BOX(window->PackageSignCombo));
|
|
|
|
|
GtkTreeIter iter;
|
|
|
|
|
@ -169,6 +185,12 @@ void on_add_packages_accept(GtkWidget *self, dictionary *dict){
|
|
|
|
|
yon_char_parsed_add_or_create_if_exists(parsed, &size,path);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
if (!size){
|
|
|
|
|
yon_ubl_status_box_spawn(GTK_CONTAINER(window->StatusBox),PACKAGES_REMOVE_ERROR_LABEL,5,BACKGROUND_IMAGE_FAIL_TYPE);
|
|
|
|
|
yon_ubl_status_highlight_incorrect(window->PackagesTree);
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
char *packages = yon_char_parsed_to_string(parsed,size," ");
|
|
|
|
|
char *command = NULL;
|
|
|
|
|
if (repo_sign&&package_sign){
|
|
|
|
|
@ -220,6 +242,11 @@ void yon_add_window_set_selected(main_window *widgets, repo_add_window *window){
|
|
|
|
|
storage = ((arch_struct*)storage_str)->storage_path;
|
|
|
|
|
repo = ((arch_struct*)storage_str)->repo_name;
|
|
|
|
|
arch = ((arch_struct*)storage_str)->name;
|
|
|
|
|
} else if (depth==1){
|
|
|
|
|
storage = ((repo_struct*)storage_str)->storage_path;
|
|
|
|
|
repo = ((arch_struct*)storage_str)->name;
|
|
|
|
|
} else if (depth == 0){
|
|
|
|
|
storage = storage_str->path;
|
|
|
|
|
}
|
|
|
|
|
if (!yon_char_is_empty(storage)) gtk_combo_box_set_active_id(GTK_COMBO_BOX(window->StorageCombo),storage);
|
|
|
|
|
while(gtk_events_pending()) gtk_main_iteration();
|
|
|
|
|
|