|
|
|
|
@ -71,6 +71,7 @@ void on_about(GtkWidget *self, char *version_application){
|
|
|
|
|
|
|
|
|
|
void on_save_window_parameter_switched(GtkCellRendererToggle *self, gchar *path, template_saving_window *window){
|
|
|
|
|
GtkTreeIter iter;
|
|
|
|
|
if (path)
|
|
|
|
|
if (gtk_tree_model_get_iter_from_string(GTK_TREE_MODEL(window->list),&iter,path)){
|
|
|
|
|
gboolean is_active;
|
|
|
|
|
gtk_tree_model_get(GTK_TREE_MODEL(window->list),&iter,0,&is_active,-1);
|
|
|
|
|
@ -248,7 +249,7 @@ template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
|
|
|
|
|
g_signal_connect(G_OBJECT(window->SaveButton),"clicked", G_CALLBACK(on_save_parameters),window);
|
|
|
|
|
g_signal_connect(G_OBJECT(window->ToggleCell),"toggled", G_CALLBACK(on_save_window_parameter_switched),window);
|
|
|
|
|
int config_size=0;
|
|
|
|
|
config_str config_strings = yon_config_get_all_no_ignored(&config_size);
|
|
|
|
|
config_str config_strings = yon_config_get_all(&config_size);
|
|
|
|
|
if (config_strings){
|
|
|
|
|
GtkTreeIter iter;
|
|
|
|
|
gtk_tree_view_set_model(GTK_TREE_VIEW(window->ParametersTree),NULL);
|
|
|
|
|
@ -257,7 +258,7 @@ template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
|
|
|
|
|
int compare_keys_size=compare_size;
|
|
|
|
|
yon_char_parsed_divide_search_full(compare_keys,compare_keys_size,"=",-1);
|
|
|
|
|
int config_keys_size=0;
|
|
|
|
|
config_str config_keys = yon_config_get_all_keys_no_ignored(&config_keys_size);
|
|
|
|
|
config_str config_keys = yon_config_get_all_keys(&config_keys_size);
|
|
|
|
|
int final_size=0;
|
|
|
|
|
GdkRGBA rgba;
|
|
|
|
|
rgba.alpha=0.8;
|
|
|
|
|
@ -266,7 +267,6 @@ template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
|
|
|
|
|
rgba.green=0.65;
|
|
|
|
|
char *rgba_string = gdk_rgba_to_string(&rgba);
|
|
|
|
|
for (int i=0;i<compare_keys_size;i++){
|
|
|
|
|
if (!yon_config_check_ignore(compare_keys[i])){
|
|
|
|
|
gtk_list_store_append(window->list,&iter);
|
|
|
|
|
gtk_list_store_set(window->list,&iter,0,0,1,compare_keys[i],5,1,-1);
|
|
|
|
|
for (int j=0;j<compare_size;j++){
|
|
|
|
|
@ -280,7 +280,11 @@ template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
|
|
|
|
|
free(compare_value);
|
|
|
|
|
free(compare_name);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
// if (!yon_config_check_ignore(compare_keys[i])){
|
|
|
|
|
|
|
|
|
|
// } else {
|
|
|
|
|
|
|
|
|
|
// }
|
|
|
|
|
}
|
|
|
|
|
char *name,*value;
|
|
|
|
|
for (int i=0;i<config_keys_size;i++){
|
|
|
|
|
@ -293,8 +297,8 @@ template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
|
|
|
|
|
gtk_tree_model_get(GTK_TREE_MODEL(window->list),&iter,1,&name,2,&value,-1);
|
|
|
|
|
if (!yon_char_is_empty(name)&&!strcmp(name,config_keys[i])){
|
|
|
|
|
gtk_list_store_set(window->list,&iter,3,compare_value,4,NULL,6,section,-1);
|
|
|
|
|
if (value&&!strcmp(value,compare_value)){
|
|
|
|
|
gtk_list_store_set(window->list,&iter,0,0,5,0,-1);
|
|
|
|
|
if ((value&&!strcmp(value,compare_value))||yon_char_is_empty(compare_value)){
|
|
|
|
|
gtk_list_store_set(window->list,&iter,0,0,3,value,5,0,-1);
|
|
|
|
|
}
|
|
|
|
|
found=1;
|
|
|
|
|
break;
|
|
|
|
|
@ -314,6 +318,7 @@ template_saving_window *yon_save_proceed(char *path,YON_CONFIG_TYPE type, ...){
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
gtk_widget_show(window->Window);
|
|
|
|
|
on_save_window_parameter_switched(NULL,NULL,window);
|
|
|
|
|
return window;
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|