From bbae86d3d2997a853ca0365e8eb7a3ca7489ee09 Mon Sep 17 00:00:00 2001 From: Sebastien Bacher Date: Fri, 25 Jan 2019 11:24:41 +0100 Subject: New upstream version 1.15.2 --- libnm-core/nm-setting.h | 41 +++++++++++++++++++++++++++-------------- 1 file changed, 27 insertions(+), 14 deletions(-) (limited to 'libnm-core/nm-setting.h') diff --git a/libnm-core/nm-setting.h b/libnm-core/nm-setting.h index a7a0f81f..0f0ac8f3 100644 --- a/libnm-core/nm-setting.h +++ b/libnm-core/nm-setting.h @@ -64,7 +64,7 @@ G_BEGIN_DECLS * should be requested from the user each time it is needed * @NM_SETTING_SECRET_FLAG_NOT_REQUIRED: in situations where it cannot be * automatically determined that the secret is required (some VPNs and PPP - * providers dont require all secrets) this flag indicates that the specific + * providers don't require all secrets) this flag indicates that the specific * secret is not required * * These flags indicate specific behavior related to handling of a secret. Each @@ -169,6 +169,7 @@ typedef gboolean (*NMSettingClearSecretsWithFlagsFn) (NMSetting *setting, gpointer user_data); struct _NMMetaSettingInfo; +struct _NMSettInfoSetting; typedef struct { GObjectClass parent; @@ -191,32 +192,44 @@ typedef struct { gboolean (*get_secret_flags) (NMSetting *setting, const char *secret_name, - gboolean verify_secret, NMSettingSecretFlags *out_flags, GError **error); gboolean (*set_secret_flags) (NMSetting *setting, const char *secret_name, - gboolean verify_secret, NMSettingSecretFlags flags, GError **error); - gboolean (*clear_secrets_with_flags) (NMSetting *setting, - GParamSpec *pspec, - NMSettingClearSecretsWithFlagsFn func, - gpointer user_data); + /*< private >*/ + gboolean (*clear_secrets) (const struct _NMSettInfoSetting *sett_info, + guint property_idx, + NMSetting *setting, + NMSettingClearSecretsWithFlagsFn func, + gpointer user_data); + + /* compare_property() returns a ternary, where DEFAULT means that the property should not + * be compared due to the compare @flags. A TRUE/FALSE result means that the property is + * equal/not-equal. + * + * @other may be %NULL, in which case the function only determines whether + * the setting should be compared (TRUE) or not (DEFAULT). */ + /*< private >*/ + NMTernary (*compare_property) (const struct _NMSettInfoSetting *sett_info, + guint property_idx, + NMSetting *setting, + NMSetting *other, + NMSettingCompareFlags flags); - /* Returns TRUE if the given property contains the same value in both settings */ - gboolean (*compare_property) (NMSetting *setting, - NMSetting *other, - const GParamSpec *prop_spec, - NMSettingCompareFlags flags); + /*< private >*/ + void (*duplicate_copy_properties) (const struct _NMSettInfoSetting *sett_info, + NMSetting *src, + NMSetting *dst); /*< private >*/ const struct _NMMetaSettingInfo *setting_info; /*< private >*/ - gpointer padding[6]; + gpointer padding[5]; } NMSettingClass; /** @@ -272,7 +285,7 @@ typedef enum { NM_SETTING_DIFF_RESULT_IN_A = 0x00000001, NM_SETTING_DIFF_RESULT_IN_B = 0x00000002, NM_SETTING_DIFF_RESULT_IN_A_DEFAULT = 0x00000004, - NM_SETTING_DIFF_RESULT_IN_B_DEFAULT = 0x00000004, + NM_SETTING_DIFF_RESULT_IN_B_DEFAULT = 0x00000008, } NMSettingDiffResult; gboolean nm_setting_diff (NMSetting *a, -- cgit 1.3.0-6-gf8a5