diff options
author | Aleksander Morgado <aleksander@lanedo.com> | 2012-01-18 13:45:40 +0100 |
---|---|---|
committer | Aleksander Morgado <aleksander@lanedo.com> | 2012-03-15 14:14:53 +0100 |
commit | c753649361d0339f8b491aca2ef53cdc11727075 (patch) | |
tree | a0ec5465e7c38ad29cabbde3f204d0b7add8f8d5 /cli/mmcli-common.c | |
parent | a3532e7730b9f776c5590f2680f444306e411bdd (diff) |
cli: use new enums/flags string getters/builders
Diffstat (limited to 'cli/mmcli-common.c')
-rw-r--r-- | cli/mmcli-common.c | 91 |
1 files changed, 0 insertions, 91 deletions
diff --git a/cli/mmcli-common.c b/cli/mmcli-common.c index acbce994..766c3eb7 100644 --- a/cli/mmcli-common.c +++ b/cli/mmcli-common.c @@ -694,32 +694,6 @@ mmcli_get_sim_sync (GDBusConnection *connection, } const gchar * -mmcli_get_bearer_ip_method_string (MMBearerIpMethod method) -{ - static GEnumClass *enum_class = NULL; - GEnumValue *value; - - if (!enum_class) - enum_class = G_ENUM_CLASS (g_type_class_ref (MM_TYPE_BEARER_IP_METHOD)); - - value = g_enum_get_value (enum_class, method); - return value->value_nick; -} - -const gchar * -mmcli_get_state_string (MMModemState state) -{ - static GEnumClass *enum_class = NULL; - GEnumValue *value; - - if (!enum_class) - enum_class = G_ENUM_CLASS (g_type_class_ref (MM_TYPE_MODEM_STATE)); - - value = g_enum_get_value (enum_class, state); - return value->value_nick; -} - -const gchar * mmcli_get_state_reason_string (MMModemStateChangeReason reason) { switch (reason) { @@ -735,71 +709,6 @@ mmcli_get_state_reason_string (MMModemStateChangeReason reason) return NULL; } -const gchar * -mmcli_get_lock_string (MMModemLock lock) -{ - static GEnumClass *enum_class = NULL; - GEnumValue *value; - - if (!enum_class) - enum_class = G_ENUM_CLASS (g_type_class_ref (MM_TYPE_MODEM_LOCK)); - - value = g_enum_get_value (enum_class, lock); - return value->value_nick; -} - -const gchar * -mmcli_get_3gpp_network_availability_string (MMModem3gppNetworkAvailability availability) -{ - static GEnumClass *enum_class = NULL; - GEnumValue *value; - - if (!enum_class) - enum_class = G_ENUM_CLASS (g_type_class_ref (MM_TYPE_MODEM_3GPP_NETWORK_AVAILABILITY)); - - value = g_enum_get_value (enum_class, availability); - return value->value_nick; -} - -const gchar * -mmcli_get_3gpp_registration_state_string (MMModem3gppRegistrationState state) -{ - static GEnumClass *enum_class = NULL; - GEnumValue *value; - - if (!enum_class) - enum_class = G_ENUM_CLASS (g_type_class_ref (MM_TYPE_MODEM_3GPP_REGISTRATION_STATE)); - - value = g_enum_get_value (enum_class, state); - return value->value_nick; -} - -const gchar * -mmcli_get_cdma_registration_state_string (MMModemCdmaRegistrationState state) -{ - static GEnumClass *enum_class = NULL; - GEnumValue *value; - - if (!enum_class) - enum_class = G_ENUM_CLASS (g_type_class_ref (MM_TYPE_MODEM_CDMA_REGISTRATION_STATE)); - - value = g_enum_get_value (enum_class, state); - return value->value_nick; -} - -const gchar * -mmcli_get_cdma_rm_protocol_string (MMModemCdmaRmProtocol protocol) -{ - static GEnumClass *enum_class = NULL; - GEnumValue *value; - - if (!enum_class) - enum_class = G_ENUM_CLASS (g_type_class_ref (MM_TYPE_MODEM_CDMA_RM_PROTOCOL)); - - value = g_enum_get_value (enum_class, protocol); - return value->value_nick; -} - /* Common options */ static gchar *modem_str; static gchar *bearer_str; |