|
|
@ -1963,17 +1963,30 @@ void on_log_path_append(GtkWidget *self, add_log_window *window){
|
|
|
|
if (box){
|
|
|
|
if (box){
|
|
|
|
path_widgets = gtk_container_get_children(GTK_CONTAINER(box));
|
|
|
|
path_widgets = gtk_container_get_children(GTK_CONTAINER(box));
|
|
|
|
entry = (GtkWidget*)g_list_nth_data(path_widgets,1);
|
|
|
|
entry = (GtkWidget*)g_list_nth_data(path_widgets,1);
|
|
|
|
|
|
|
|
char *entry_path=(char*)gtk_entry_get_text(GTK_ENTRY(entry));
|
|
|
|
|
|
|
|
|
|
|
|
if (!gtk_widget_get_sensitive(box)||!strcmp(gtk_entry_get_text(GTK_ENTRY(entry)),"")){
|
|
|
|
if (!gtk_widget_get_sensitive(box)||!strcmp(entry_path,"")){
|
|
|
|
return;
|
|
|
|
return;
|
|
|
|
// } else if (){
|
|
|
|
}else {
|
|
|
|
|
|
|
|
GList *list = gtk_container_get_children(GTK_CONTAINER(window->LogPathsBox));
|
|
|
|
}else
|
|
|
|
for (int i=0;i<g_list_length(list);i++){
|
|
|
|
|
|
|
|
GList *wids = gtk_container_get_children(GTK_CONTAINER((GtkWidget*)g_list_nth_data(list,i)));
|
|
|
|
|
|
|
|
char *check_path = (char*)gtk_entry_get_text((GtkEntry*)g_list_nth_data(wids,1));
|
|
|
|
|
|
|
|
if (!strcmp(entry_path,check_path)&&entry!=(GtkWidget*)g_list_nth_data(wids,1)){
|
|
|
|
|
|
|
|
yon_ubl_status_highlight_incorrect(entry);
|
|
|
|
|
|
|
|
yon_ubl_status_highlight_incorrect((GtkWidget*)g_list_nth_data(wids,1));
|
|
|
|
|
|
|
|
yon_ubl_status_box_spawn(GTK_CONTAINER(window->StatusBox),REPEATED_PATHS_LABEL,5,BACKGROUND_IMAGE_FAIL_TYPE);
|
|
|
|
|
|
|
|
gtk_entry_set_text(GTK_ENTRY(entry),"");
|
|
|
|
|
|
|
|
return;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
g_list_free(wids);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
g_list_free(list);
|
|
|
|
gtk_widget_hide(self);
|
|
|
|
gtk_widget_hide(self);
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
GtkBuilder *builder = gtk_builder_new_from_resource(glade_add_path_path);
|
|
|
|
GtkBuilder *builder = gtk_builder_new_from_resource(glade_add_path_path);
|
|
|
|
GtkWidget *box_path = yon_gtk_builder_get_widget(builder,"PathBox");
|
|
|
|
GtkWidget *box_path = yon_gtk_builder_get_widget(builder,"PathBox");
|
|
|
|
GtkWidget *entry_path = yon_gtk_builder_get_widget(builder,"PathEntry");
|
|
|
|
|
|
|
|
GtkWidget *AppendButton = yon_gtk_builder_get_widget(builder,"AppendButton");
|
|
|
|
GtkWidget *AppendButton = yon_gtk_builder_get_widget(builder,"AppendButton");
|
|
|
|
GtkWidget *SearchButton = yon_gtk_builder_get_widget(builder,"SearchButton");
|
|
|
|
GtkWidget *SearchButton = yon_gtk_builder_get_widget(builder,"SearchButton");
|
|
|
|
GtkWidget *RemoveButton = yon_gtk_builder_get_widget(builder,"RemoveButton");
|
|
|
|
GtkWidget *RemoveButton = yon_gtk_builder_get_widget(builder,"RemoveButton");
|
|
|
|