Commit e7eaaf56 authored by Sylvain Berfini's avatar Sylvain Berfini 🎩
Browse files

Small improvement in friend migration + removed useless code in gtk app

parent 2628dfc3
......@@ -1378,11 +1378,10 @@ void linphone_core_migrate_friends_from_rc_to_db(LinphoneCore *lc) {
if (!linphone_friend_create_vcard(lf, displayName)) {
ms_warning("Couldn't create vCard for friend %s", linphone_address_as_string(addr));
linphone_friend_unref(lf);
continue;
} else {
linphone_vcard_add_sip_address(linphone_friend_get_vcard(lf), linphone_address_as_string_uri_only(addr));
}
linphone_vcard_add_sip_address(linphone_friend_get_vcard(lf), linphone_address_as_string_uri_only(addr));
linphone_friend_list_add_friend(lfl, lf);
linphone_friend_unref(lf);
......
......@@ -1841,7 +1841,6 @@ void linphone_gtk_import_contacts(void) {
GtkWidget *mw = linphone_gtk_get_main_window();
GtkWidget *dialog = gtk_file_chooser_dialog_new("Open vCard file", (GtkWindow *)mw, GTK_FILE_CHOOSER_ACTION_OPEN, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, GTK_STOCK_OPEN, GTK_RESPONSE_ACCEPT, NULL);
gtk_widget_show(dialog);
if (gtk_dialog_run(GTK_DIALOG (dialog)) == GTK_RESPONSE_ACCEPT) {
LinphoneCore *lc = linphone_gtk_get_core();
char *filename = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(dialog));
......@@ -1858,7 +1857,6 @@ void linphone_gtk_export_contacts(void) {
GtkWidget *dialog = gtk_file_chooser_dialog_new("Save vCards as", (GtkWindow *)mw, GTK_FILE_CHOOSER_ACTION_SAVE, GTK_STOCK_CANCEL, GTK_RESPONSE_CANCEL, GTK_STOCK_SAVE, GTK_RESPONSE_ACCEPT, NULL);
gtk_file_chooser_set_do_overwrite_confirmation(GTK_FILE_CHOOSER(dialog), TRUE);
gtk_widget_show(dialog);
if (gtk_dialog_run(GTK_DIALOG (dialog)) == GTK_RESPONSE_ACCEPT) {
LinphoneCore *lc = linphone_gtk_get_core();
char *filename = gtk_file_chooser_get_filename(GTK_FILE_CHOOSER(dialog));
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment