[network-manager-applet] nm-c-e: silence initial message about editor initializing
- From: Thomas Haller <thaller src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [network-manager-applet] nm-c-e: silence initial message about editor initializing
- Date: Fri, 7 Oct 2016 12:01:30 +0000 (UTC)
commit 68dfd862da899a596ca78b4c8c8131b6cef63dca
Author: Thomas Haller <thaller redhat com>
Date: Fri Oct 7 13:48:35 2016 +0200
nm-c-e: silence initial message about editor initializing
Previously, we would always see:
** Message: Cannot save connection due to error: Editor initializing...
** Message: Connection validates and can be saved
when the editor starts. Hide these messages.
https://bugzilla.gnome.org/show_bug.cgi?id=772548
src/connection-editor/nm-connection-editor.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/connection-editor/nm-connection-editor.c b/src/connection-editor/nm-connection-editor.c
index aefe858..45a95b0 100644
--- a/src/connection-editor/nm-connection-editor.c
+++ b/src/connection-editor/nm-connection-editor.c
@@ -180,12 +180,12 @@ connection_editor_validate (NMConnectionEditor *editor)
{
NMSettingConnection *s_con;
GSList *iter;
- char *validation_error = NULL;
+ gs_free char *validation_error = NULL;
GError *error = NULL;
if (!editor_is_initialized (editor)) {
validation_error = g_strdup (_("Editor initializing…"));
- goto done;
+ goto done_silent;
}
s_con = nm_connection_get_setting_connection (editor->connection);
@@ -221,12 +221,12 @@ done:
g_free (editor->last_validation_error);
editor->last_validation_error = g_strdup (validation_error);
}
+
+done_silent:
ce_polkit_button_set_validation_error (CE_POLKIT_BUTTON (editor->ok_button), validation_error);
gtk_widget_set_sensitive (editor->export_button, !validation_error);
update_sensitivity (editor);
-
- g_free (validation_error);
}
static void
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]