X-Git-Url: http://git.dolda2000.com/gitweb/?a=blobdiff_plain;f=config%2Futil%2Fdolconf.c;h=75d89c7f25542826785316e07bd1dfd1dae8b1e3;hb=8af979f318c0e3d1d00a35996f6b5fecb055ac33;hp=1d09c339076c05e5c8a97e8a3c1e7af69be14688;hpb=b1099f1fdf1bd3885a73fc6c087dfe816aa63e5c;p=doldaconnect.git diff --git a/config/util/dolconf.c b/config/util/dolconf.c index 1d09c33..75d89c7 100644 --- a/config/util/dolconf.c +++ b/config/util/dolconf.c @@ -639,7 +639,8 @@ void cb_ast_shareadd_clicked(GtkWidget *widget, gpointer uudata) void cb_cfw_shareadd_clicked(GtkWidget *widget, gpointer uudata) { - shareadd(); + if(shareadd()) + dirty = 1; } void cb_ast_sharerem_clicked(GtkWidget *widget, gpointer uudata) @@ -656,8 +657,10 @@ void cb_cfw_sharerem_clicked(GtkWidget *widget, gpointer uudata) { GtkTreeIter iter; - if(gtk_tree_selection_get_selected(gtk_tree_view_get_selection(GTK_TREE_VIEW(cfw_sharelist)), NULL, &iter)) + if(gtk_tree_selection_get_selected(gtk_tree_view_get_selection(GTK_TREE_VIEW(cfw_sharelist)), NULL, &iter)) { gtk_list_store_remove(shares, &iter); + dirty = 1; + } } void cb_ast_checkports(GtkWidget *widget, gpointer uudata) @@ -760,7 +763,7 @@ int main(int argc, char **argv) gtk_init(&argc, &argv); state = -1; - while((c = getopt(argc, argv, "haw")) != -1) { + while((c = getopt(argc, argv, "hawV")) != -1) { switch(c) { case 'a': state = 1; @@ -773,9 +776,13 @@ int main(int argc, char **argv) printf("\t-h\tDisplay this help message\n"); printf("\t-a\tGo directly to the assistant\n"); printf("\t-w\tGo directly to the standard window\n"); + printf("\t-V\tDisplay version info and exit\n"); + exit(0); + case 'V': + printf("%s", RELEASEINFO); exit(0); default: - fprintf(stderr, "usage: dolconf [-haw]\n"); + fprintf(stderr, "usage: dolconf [-hawV]\n"); exit(1); } } @@ -837,8 +844,8 @@ int main(int argc, char **argv) } else if(state == 2) { for(i = 3; i < FD_SETSIZE; i++) close(i); - execlp("dolcon", "dolcon", NULL); - perror("dolcon"); + execlp("dolcon-launch", "dolcon-launch", NULL); + perror("dolcon-launch"); exit(127); } else { msgbox(GTK_MESSAGE_ERROR, GTK_BUTTONS_OK, _("Internal error (Unknown state)"));