[network-manager-vpnc/th/vpn-editor-split-bgo766170] properties/trivial: rename VPNC_EDITOR_PLUGIN_ERROR to NMV_EDITOR_PLUGIN_ERROR



commit e639edaaa4b1ccab761b06d3db096f3d0786b1c7
Author: Thomas Haller <thaller redhat com>
Date:   Mon May 9 13:40:30 2016 +0200

    properties/trivial: rename VPNC_EDITOR_PLUGIN_ERROR to NMV_EDITOR_PLUGIN_ERROR
    
    nm-openvpn has OPENVPN_EDITOR_PLUGIN_ERROR. Rename those defines that
    serve the same purpose.

 properties/nm-vpnc-editor.c |   14 +++++++-------
 shared/nm-default.h         |   28 ++++++++++++++--------------
 2 files changed, 21 insertions(+), 21 deletions(-)
---
diff --git a/properties/nm-vpnc-editor.c b/properties/nm-vpnc-editor.c
index f379520..3b0efd0 100644
--- a/properties/nm-vpnc-editor.c
+++ b/properties/nm-vpnc-editor.c
@@ -71,8 +71,8 @@ check_validity (VpncEditor *self, GError **error)
        str = (char *) gtk_entry_get_text (GTK_ENTRY (widget));
        if (!str || !strlen (str) || strstr (str, " ") || strstr (str, "\t")) {
                g_set_error (error,
-                            VPNC_EDITOR_PLUGIN_ERROR,
-                            VPNC_EDITOR_PLUGIN_ERROR_INVALID_PROPERTY,
+                            NMV_EDITOR_PLUGIN_ERROR,
+                            NMV_EDITOR_PLUGIN_ERROR_INVALID_PROPERTY,
                             NM_VPNC_KEY_GATEWAY);
                return FALSE;
        }
@@ -81,8 +81,8 @@ check_validity (VpncEditor *self, GError **error)
        str = (char *) gtk_entry_get_text (GTK_ENTRY (widget));
        if (!str || !strlen (str)) {
                g_set_error (error,
-                            VPNC_EDITOR_PLUGIN_ERROR,
-                            VPNC_EDITOR_PLUGIN_ERROR_INVALID_PROPERTY,
+                            NMV_EDITOR_PLUGIN_ERROR,
+                            NMV_EDITOR_PLUGIN_ERROR_INVALID_PROPERTY,
                             NM_VPNC_KEY_ID);
                return FALSE;
        }
@@ -948,7 +948,7 @@ nm_vpnc_editor_new (NMConnection *connection, GError **error)
 
        object = g_object_new (VPNC_TYPE_EDITOR, NULL);
        if (!object) {
-               g_set_error (error, VPNC_EDITOR_PLUGIN_ERROR, VPNC_EDITOR_PLUGIN_ERROR_FAILED,
+               g_set_error (error, NMV_EDITOR_PLUGIN_ERROR, NMV_EDITOR_PLUGIN_ERROR_FAILED,
                             "could not create vpnc object");
                return NULL;
        }
@@ -964,7 +964,7 @@ nm_vpnc_editor_new (NMConnection *connection, GError **error)
                g_warning ("Couldn't load builder file: %s",
                           error && *error ? (*error)->message : "(unknown)");
                g_clear_error (error);
-               g_set_error (error, VPNC_EDITOR_PLUGIN_ERROR, VPNC_EDITOR_PLUGIN_ERROR_FAILED,
+               g_set_error (error, NMV_EDITOR_PLUGIN_ERROR, NMV_EDITOR_PLUGIN_ERROR_FAILED,
                             "could not load required resources at %s", ui_file);
                g_free (ui_file);
                g_object_unref (object);
@@ -974,7 +974,7 @@ nm_vpnc_editor_new (NMConnection *connection, GError **error)
 
        priv->widget = GTK_WIDGET (gtk_builder_get_object (priv->builder, "vpnc-vbox"));
        if (!priv->widget) {
-               g_set_error (error, VPNC_EDITOR_PLUGIN_ERROR, VPNC_EDITOR_PLUGIN_ERROR_FAILED,
+               g_set_error (error, NMV_EDITOR_PLUGIN_ERROR, NMV_EDITOR_PLUGIN_ERROR_FAILED,
                             "could not load UI widget");
                g_object_unref (object);
                return NULL;
diff --git a/shared/nm-default.h b/shared/nm-default.h
index 9c78374..40da48c 100644
--- a/shared/nm-default.h
+++ b/shared/nm-default.h
@@ -90,25 +90,25 @@
 #define nm_setting_ip_config_get_num_dns            nm_setting_ip4_config_get_num_dns
 #define NM_SETTING_IP_CONFIG_NEVER_DEFAULT          NM_SETTING_IP4_CONFIG_NEVER_DEFAULT
 
-#define VPNC_EDITOR_PLUGIN_ERROR                     NM_SETTING_VPN_ERROR
-#define VPNC_EDITOR_PLUGIN_ERROR_FAILED              NM_SETTING_VPN_ERROR_UNKNOWN
-#define VPNC_EDITOR_PLUGIN_ERROR_INVALID_PROPERTY    NM_SETTING_VPN_ERROR_INVALID_PROPERTY
-#define VPNC_EDITOR_PLUGIN_ERROR_MISSING_PROPERTY    NM_SETTING_VPN_ERROR_MISSING_PROPERTY
-#define VPNC_EDITOR_PLUGIN_ERROR_FILE_NOT_VPNC       NM_SETTING_VPN_ERROR_UNKNOWN
-#define VPNC_EDITOR_PLUGIN_ERROR_FILE_NOT_READABLE   NM_SETTING_VPN_ERROR_UNKNOWN
-#define VPNC_EDITOR_PLUGIN_ERROR_FILE_INVALID        NM_SETTING_VPN_ERROR_UNKNOWN
+#define NMV_EDITOR_PLUGIN_ERROR                     NM_SETTING_VPN_ERROR
+#define NMV_EDITOR_PLUGIN_ERROR_FAILED              NM_SETTING_VPN_ERROR_UNKNOWN
+#define NMV_EDITOR_PLUGIN_ERROR_INVALID_PROPERTY    NM_SETTING_VPN_ERROR_INVALID_PROPERTY
+#define NMV_EDITOR_PLUGIN_ERROR_MISSING_PROPERTY    NM_SETTING_VPN_ERROR_MISSING_PROPERTY
+#define NMV_EDITOR_PLUGIN_ERROR_FILE_NOT_VPNC       NM_SETTING_VPN_ERROR_UNKNOWN
+#define NMV_EDITOR_PLUGIN_ERROR_FILE_NOT_READABLE   NM_SETTING_VPN_ERROR_UNKNOWN
+#define NMV_EDITOR_PLUGIN_ERROR_FILE_INVALID        NM_SETTING_VPN_ERROR_UNKNOWN
 
 #else /* !NM_VPN_OLD */
 
 #include <NetworkManager.h>
 
-#define VPNC_EDITOR_PLUGIN_ERROR                     NM_CONNECTION_ERROR
-#define VPNC_EDITOR_PLUGIN_ERROR_FAILED              NM_CONNECTION_ERROR_FAILED
-#define VPNC_EDITOR_PLUGIN_ERROR_INVALID_PROPERTY    NM_CONNECTION_ERROR_INVALID_PROPERTY
-#define VPNC_EDITOR_PLUGIN_ERROR_MISSING_PROPERTY    NM_CONNECTION_ERROR_MISSING_PROPERTY
-#define VPNC_EDITOR_PLUGIN_ERROR_FILE_NOT_VPNC       NM_CONNECTION_ERROR_FAILED
-#define VPNC_EDITOR_PLUGIN_ERROR_FILE_NOT_READABLE   NM_CONNECTION_ERROR_FAILED
-#define VPNC_EDITOR_PLUGIN_ERROR_FILE_INVALID        NM_CONNECTION_ERROR_FAILED
+#define NMV_EDITOR_PLUGIN_ERROR                     NM_CONNECTION_ERROR
+#define NMV_EDITOR_PLUGIN_ERROR_FAILED              NM_CONNECTION_ERROR_FAILED
+#define NMV_EDITOR_PLUGIN_ERROR_INVALID_PROPERTY    NM_CONNECTION_ERROR_INVALID_PROPERTY
+#define NMV_EDITOR_PLUGIN_ERROR_MISSING_PROPERTY    NM_CONNECTION_ERROR_MISSING_PROPERTY
+#define NMV_EDITOR_PLUGIN_ERROR_FILE_NOT_VPNC       NM_CONNECTION_ERROR_FAILED
+#define NMV_EDITOR_PLUGIN_ERROR_FILE_NOT_READABLE   NM_CONNECTION_ERROR_FAILED
+#define NMV_EDITOR_PLUGIN_ERROR_FILE_INVALID        NM_CONNECTION_ERROR_FAILED
 
 #endif /* NM_VPN_OLD */
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]