mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager
synced 2024-07-22 18:54:36 +00:00
libnm-util: remove deprecated GSM bits
This commit is contained in:
parent
0e6a5365d4
commit
89fcc757a4
|
@ -92,9 +92,7 @@ enum {
|
|||
PROP_APN,
|
||||
PROP_NETWORK_ID,
|
||||
PROP_NETWORK_TYPE,
|
||||
PROP_BAND,
|
||||
PROP_PIN,
|
||||
PROP_PUK,
|
||||
PROP_ALLOWED_BANDS,
|
||||
PROP_HOME_ONLY,
|
||||
|
||||
|
@ -164,13 +162,6 @@ nm_setting_gsm_get_network_type (NMSettingGsm *setting)
|
|||
return NM_SETTING_GSM_GET_PRIVATE (setting)->network_type;
|
||||
}
|
||||
|
||||
int
|
||||
nm_setting_gsm_get_band (NMSettingGsm *setting)
|
||||
{
|
||||
g_warning ("Tried to get deprecated property " NM_SETTING_GSM_SETTING_NAME "/" NM_SETTING_GSM_BAND);
|
||||
return -1;
|
||||
}
|
||||
|
||||
guint32
|
||||
nm_setting_gsm_get_allowed_bands (NMSettingGsm *setting)
|
||||
{
|
||||
|
@ -187,13 +178,6 @@ nm_setting_gsm_get_pin (NMSettingGsm *setting)
|
|||
return NM_SETTING_GSM_GET_PRIVATE (setting)->pin;
|
||||
}
|
||||
|
||||
const char *
|
||||
nm_setting_gsm_get_puk (NMSettingGsm *setting)
|
||||
{
|
||||
g_warning ("Tried to get deprecated property " NM_SETTING_GSM_SETTING_NAME "/" NM_SETTING_GSM_PUK);
|
||||
return NULL;
|
||||
}
|
||||
|
||||
gboolean
|
||||
nm_setting_gsm_get_home_only (NMSettingGsm *setting)
|
||||
{
|
||||
|
@ -343,7 +327,6 @@ set_property (GObject *object, guint prop_id,
|
|||
const GValue *value, GParamSpec *pspec)
|
||||
{
|
||||
NMSettingGsmPrivate *priv = NM_SETTING_GSM_GET_PRIVATE (object);
|
||||
const char *str;
|
||||
char *tmp;
|
||||
|
||||
switch (prop_id) {
|
||||
|
@ -376,10 +359,6 @@ set_property (GObject *object, guint prop_id,
|
|||
case PROP_NETWORK_TYPE:
|
||||
priv->network_type = g_value_get_int (value);
|
||||
break;
|
||||
case PROP_BAND:
|
||||
if (g_value_get_int (value) != -1)
|
||||
g_warning ("Tried to set deprecated property " NM_SETTING_GSM_SETTING_NAME "/" NM_SETTING_GSM_BAND);
|
||||
break;
|
||||
case PROP_ALLOWED_BANDS:
|
||||
priv->allowed_bands = g_value_get_uint (value);
|
||||
break;
|
||||
|
@ -387,11 +366,6 @@ set_property (GObject *object, guint prop_id,
|
|||
g_free (priv->pin);
|
||||
priv->pin = g_value_dup_string (value);
|
||||
break;
|
||||
case PROP_PUK:
|
||||
str = g_value_get_string (value);
|
||||
if (str && strlen (str))
|
||||
g_warning ("Tried to set deprecated property " NM_SETTING_GSM_SETTING_NAME "/" NM_SETTING_GSM_PUK);
|
||||
break;
|
||||
case PROP_HOME_ONLY:
|
||||
priv->home_only = g_value_get_boolean (value);
|
||||
break;
|
||||
|
@ -432,14 +406,6 @@ get_property (GObject *object, guint prop_id,
|
|||
case PROP_PIN:
|
||||
g_value_set_string (value, nm_setting_gsm_get_pin (setting));
|
||||
break;
|
||||
case PROP_PUK:
|
||||
/* deprecated */
|
||||
g_value_set_string (value, NULL);
|
||||
break;
|
||||
case PROP_BAND:
|
||||
/* deprecated */
|
||||
g_value_set_int (value, -1);
|
||||
break;
|
||||
case PROP_HOME_ONLY:
|
||||
g_value_set_boolean (value, nm_setting_gsm_get_home_only (setting));
|
||||
break;
|
||||
|
@ -654,31 +620,4 @@ nm_setting_gsm_class_init (NMSettingGsmClass *setting_class)
|
|||
"not be made.",
|
||||
FALSE,
|
||||
G_PARAM_READWRITE | NM_SETTING_PARAM_SERIALIZE));
|
||||
|
||||
/* Deprecated properties */
|
||||
/**
|
||||
* NMSettingGsm:puk:
|
||||
*
|
||||
* DEPRECATED
|
||||
**/
|
||||
g_object_class_install_property
|
||||
(object_class, PROP_PUK,
|
||||
g_param_spec_string (NM_SETTING_GSM_PUK,
|
||||
"PUK (DEPRECATED and UNUSED)",
|
||||
"PUK (DEPRECATED and UNUSED)",
|
||||
NULL,
|
||||
G_PARAM_READWRITE | NM_SETTING_PARAM_SERIALIZE | NM_SETTING_PARAM_SECRET));
|
||||
|
||||
/**
|
||||
* NMSettingGsm:band:
|
||||
*
|
||||
* DEPRECATED
|
||||
**/
|
||||
g_object_class_install_property
|
||||
(object_class, PROP_BAND,
|
||||
g_param_spec_int (NM_SETTING_GSM_BAND,
|
||||
"Band (DEPRECATED and UNUSED)",
|
||||
"Band (DEPRECATED and UNUSED)",
|
||||
-1, 5, -1,
|
||||
G_PARAM_READWRITE | G_PARAM_CONSTRUCT | NM_SETTING_PARAM_SERIALIZE));
|
||||
}
|
||||
|
|
|
@ -63,17 +63,6 @@ GQuark nm_setting_gsm_error_quark (void);
|
|||
#define NM_SETTING_GSM_PIN "pin"
|
||||
#define NM_SETTING_GSM_HOME_ONLY "home-only"
|
||||
|
||||
/* DEPRECATED & UNUSED */
|
||||
#define NM_SETTING_GSM_PUK "puk"
|
||||
#define NM_SETTING_GSM_BAND "band"
|
||||
|
||||
/* DEPRECATED, use NM_SETTING_NETWORK_TYPE_* instead */
|
||||
#define NM_GSM_NETWORK_ANY NM_SETTING_GSM_NETWORK_TYPE_ANY
|
||||
#define NM_GSM_NETWORK_UMTS_HSPA NM_SETTING_GSM_NETWORK_TYPE_UMTS_HSPA
|
||||
#define NM_GSM_NETWORK_GPRS_EDGE NM_SETTING_GSM_NETWORK_TYPE_GPRS_EDGE
|
||||
#define NM_GSM_NETWORK_PREFER_UMTS_HSPA NM_SETTING_GSM_NETWORK_TYPE_PREFER_UMTS_HSPA
|
||||
#define NM_GSM_NETWORK_PREFER_GPRS_EDGE NM_SETTING_GSM_NETWORK_TYPE_PREFER_GPRS_EDGE
|
||||
|
||||
typedef enum {
|
||||
NM_SETTING_GSM_NETWORK_TYPE_ANY = -1,
|
||||
NM_SETTING_GSM_NETWORK_TYPE_UMTS_HSPA = 0,
|
||||
|
@ -126,10 +115,6 @@ guint32 nm_setting_gsm_get_allowed_bands (NMSettingGsm *setting);
|
|||
const char *nm_setting_gsm_get_pin (NMSettingGsm *setting);
|
||||
gboolean nm_setting_gsm_get_home_only (NMSettingGsm *setting);
|
||||
|
||||
/* DEPRECATED & UNUSED */
|
||||
const char *nm_setting_gsm_get_puk (NMSettingGsm *setting);
|
||||
int nm_setting_gsm_get_band (NMSettingGsm *setting);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* NM_SETTING_GSM_H */
|
||||
|
|
Loading…
Reference in a new issue