aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/mm-broadband-modem-qmi.c6
-rw-r--r--src/mm-broadband-modem.c4
-rw-r--r--src/mm-iface-modem-voice.c312
-rw-r--r--src/mm-iface-modem-voice.h14
-rw-r--r--src/plugins/cinterion/mm-broadband-modem-cinterion.c8
-rw-r--r--src/plugins/cinterion/mm-broadband-modem-mbim-cinterion.c8
-rw-r--r--src/plugins/cinterion/mm-broadband-modem-qmi-cinterion.c8
-rw-r--r--src/plugins/cinterion/mm-shared-cinterion.c6
-rw-r--r--src/plugins/cinterion/mm-shared-cinterion.h2
-rw-r--r--src/plugins/huawei/mm-broadband-modem-huawei.c6
-rw-r--r--src/plugins/simtech/mm-broadband-modem-qmi-simtech.c8
-rw-r--r--src/plugins/simtech/mm-broadband-modem-simtech.c8
-rw-r--r--src/plugins/simtech/mm-shared-simtech.c16
-rw-r--r--src/plugins/simtech/mm-shared-simtech.h2
-rw-r--r--src/plugins/ublox/mm-broadband-modem-ublox.c8
15 files changed, 199 insertions, 217 deletions
diff --git a/src/mm-broadband-modem-qmi.c b/src/mm-broadband-modem-qmi.c
index cec24d8f..708ad6be 100644
--- a/src/mm-broadband-modem-qmi.c
+++ b/src/mm-broadband-modem-qmi.c
@@ -57,7 +57,7 @@ static void iface_modem_init (MMIfaceModemInterface
static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
static void iface_modem_3gpp_profile_manager_init (MMIfaceModem3gppProfileManagerInterface *iface);
static void iface_modem_3gpp_ussd_init (MMIfaceModem3gppUssdInterface *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_voice_init (MMIfaceModemVoiceInterface *iface);
static void iface_modem_cdma_init (MMIfaceModemCdma *iface);
static void iface_modem_messaging_init (MMIfaceModemMessagingInterface *iface);
static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
@@ -69,7 +69,7 @@ static void shared_qmi_init (MMSharedQmi
static MMIfaceModemLocationInterface *iface_modem_location_parent;
static MMIfaceModemMessagingInterface *iface_modem_messaging_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemVoiceInterface *iface_modem_voice_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemQmi, mm_broadband_modem_qmi, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -14005,7 +14005,7 @@ iface_modem_3gpp_ussd_init (MMIfaceModem3gppUssdInterface *iface)
}
static void
-iface_modem_voice_init (MMIfaceModemVoice *iface)
+iface_modem_voice_init (MMIfaceModemVoiceInterface *iface)
{
iface_modem_voice_parent = g_type_interface_peek_parent (iface);
diff --git a/src/mm-broadband-modem.c b/src/mm-broadband-modem.c
index 410b8e0b..ab2204ad 100644
--- a/src/mm-broadband-modem.c
+++ b/src/mm-broadband-modem.c
@@ -69,7 +69,7 @@ static void iface_modem_cdma_init (MMIfaceModemCdma
static void iface_modem_simple_init (MMIfaceModemSimpleInterface *iface);
static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
static void iface_modem_messaging_init (MMIfaceModemMessagingInterface *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_voice_init (MMIfaceModemVoiceInterface *iface);
static void iface_modem_time_init (MMIfaceModemTimeInterface *iface);
static void iface_modem_signal_init (MMIfaceModemSignalInterface *iface);
static void iface_modem_oma_init (MMIfaceModemOma *iface);
@@ -13703,7 +13703,7 @@ iface_modem_messaging_init (MMIfaceModemMessagingInterface *iface)
}
static void
-iface_modem_voice_init (MMIfaceModemVoice *iface)
+iface_modem_voice_init (MMIfaceModemVoiceInterface *iface)
{
iface->check_support = modem_voice_check_support;
iface->check_support_finish = modem_voice_check_support_finish;
diff --git a/src/mm-iface-modem-voice.c b/src/mm-iface-modem-voice.c
index 8fa1e182..fca14338 100644
--- a/src/mm-iface-modem-voice.c
+++ b/src/mm-iface-modem-voice.c
@@ -30,6 +30,8 @@
static GQuark call_list_polling_context_quark;
static GQuark in_call_event_context_quark;
+G_DEFINE_INTERFACE (MMIfaceModemVoice, mm_iface_modem_voice, MM_TYPE_IFACE_MODEM)
+
/*****************************************************************************/
void
@@ -153,9 +155,9 @@ create_incoming_call (MMIfaceModemVoice *self,
{
MMBaseCall *call;
- g_assert (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->create_call != NULL);
+ g_assert (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->create_call != NULL);
- call = MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->create_call (self, MM_CALL_DIRECTION_INCOMING, number);
+ call = MM_IFACE_MODEM_VOICE_GET_IFACE (self)->create_call (self, MM_CALL_DIRECTION_INCOMING, number);
update_audio_settings_in_call (self, call);
return call;
}
@@ -179,8 +181,8 @@ create_outgoing_call_from_properties (MMIfaceModemVoice *self,
}
/* Create a call object as defined by the interface */
- g_assert (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->create_call != NULL);
- call = MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->create_call (self, MM_CALL_DIRECTION_OUTGOING, number);
+ g_assert (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->create_call != NULL);
+ call = MM_IFACE_MODEM_VOICE_GET_IFACE (self)->create_call (self, MM_CALL_DIRECTION_OUTGOING, number);
update_audio_settings_in_call (self, call);
return call;
}
@@ -807,7 +809,7 @@ hold_and_accept_ready (MMIfaceModemVoice *self,
GError *error = NULL;
GList *l;
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hold_and_accept_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hold_and_accept_finish (self, res, &error)) {
mm_dbus_method_invocation_take_error (ctx->invocation, error);
handle_hold_and_accept_context_free (ctx);
return;
@@ -862,8 +864,8 @@ handle_hold_and_accept_auth_ready (MMBaseModem *self,
return;
}
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hold_and_accept ||
- !MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hold_and_accept_finish) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hold_and_accept ||
+ !MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hold_and_accept_finish) {
mm_dbus_method_invocation_return_error_literal (ctx->invocation, MM_CORE_ERROR, MM_CORE_ERROR_UNSUPPORTED,
"Cannot hold and accept: unsupported");
handle_hold_and_accept_context_free (ctx);
@@ -883,9 +885,10 @@ handle_hold_and_accept_auth_ready (MMBaseModem *self,
g_object_unref (list);
mm_obj_info (self, "processing user request to hold and accept voice call...");
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hold_and_accept (MM_IFACE_MODEM_VOICE (self),
- (GAsyncReadyCallback)hold_and_accept_ready,
- ctx);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hold_and_accept (
+ MM_IFACE_MODEM_VOICE (self),
+ (GAsyncReadyCallback)hold_and_accept_ready,
+ ctx);
}
static gboolean
@@ -937,7 +940,7 @@ hangup_and_accept_ready (MMIfaceModemVoice *self,
GError *error = NULL;
GList *l;
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hangup_and_accept_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hangup_and_accept_finish (self, res, &error)) {
mm_dbus_method_invocation_take_error (ctx->invocation, error);
handle_hangup_and_accept_context_free (ctx);
return;
@@ -992,8 +995,8 @@ handle_hangup_and_accept_auth_ready (MMBaseModem *self,
return;
}
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hangup_and_accept ||
- !MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hangup_and_accept_finish) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hangup_and_accept ||
+ !MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hangup_and_accept_finish) {
mm_dbus_method_invocation_return_error_literal (ctx->invocation, MM_CORE_ERROR, MM_CORE_ERROR_UNSUPPORTED,
"Cannot hangup and accept: unsupported");
handle_hangup_and_accept_context_free (ctx);
@@ -1013,9 +1016,10 @@ handle_hangup_and_accept_auth_ready (MMBaseModem *self,
g_object_unref (list);
mm_obj_info (self, "processing user request to hangup and accept voice call...");
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hangup_and_accept (MM_IFACE_MODEM_VOICE (self),
- (GAsyncReadyCallback)hangup_and_accept_ready,
- ctx);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hangup_and_accept (
+ MM_IFACE_MODEM_VOICE (self),
+ (GAsyncReadyCallback)hangup_and_accept_ready,
+ ctx);
}
static gboolean
@@ -1065,7 +1069,7 @@ hangup_all_ready (MMIfaceModemVoice *self,
GError *error = NULL;
GList *l;
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hangup_all_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hangup_all_finish (self, res, &error)) {
mm_dbus_method_invocation_take_error (ctx->invocation, error);
handle_hangup_all_context_free (ctx);
return;
@@ -1132,8 +1136,8 @@ handle_hangup_all_auth_ready (MMBaseModem *self,
return;
}
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hangup_all ||
- !MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hangup_all_finish) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hangup_all ||
+ !MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hangup_all_finish) {
mm_dbus_method_invocation_return_error_literal (ctx->invocation, MM_CORE_ERROR, MM_CORE_ERROR_UNSUPPORTED,
"Cannot hangup all: unsupported");
handle_hangup_all_context_free (ctx);
@@ -1153,9 +1157,10 @@ handle_hangup_all_auth_ready (MMBaseModem *self,
g_object_unref (list);
mm_obj_info (self, "processing user request to hangup all voice calls...");
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->hangup_all (MM_IFACE_MODEM_VOICE (self),
- (GAsyncReadyCallback)hangup_all_ready,
- ctx);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->hangup_all (
+ MM_IFACE_MODEM_VOICE (self),
+ (GAsyncReadyCallback)hangup_all_ready,
+ ctx);
}
static gboolean
@@ -1205,7 +1210,7 @@ transfer_ready (MMIfaceModemVoice *self,
GError *error = NULL;
GList *l;
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->transfer_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->transfer_finish (self, res, &error)) {
mm_dbus_method_invocation_take_error (ctx->invocation, error);
handle_transfer_context_free (ctx);
return;
@@ -1252,8 +1257,8 @@ handle_transfer_auth_ready (MMBaseModem *self,
return;
}
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->transfer ||
- !MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->transfer_finish) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->transfer ||
+ !MM_IFACE_MODEM_VOICE_GET_IFACE (self)->transfer_finish) {
mm_dbus_method_invocation_return_error_literal (ctx->invocation, MM_CORE_ERROR, MM_CORE_ERROR_UNSUPPORTED,
"Cannot transfer: unsupported");
handle_transfer_context_free (ctx);
@@ -1273,9 +1278,10 @@ handle_transfer_auth_ready (MMBaseModem *self,
g_object_unref (list);
mm_obj_info (self, "processing user request to transfer voice call...");
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->transfer (MM_IFACE_MODEM_VOICE (self),
- (GAsyncReadyCallback)transfer_ready,
- ctx);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->transfer (
+ MM_IFACE_MODEM_VOICE (self),
+ (GAsyncReadyCallback)transfer_ready,
+ ctx);
}
static gboolean
@@ -1323,7 +1329,7 @@ call_waiting_setup_ready (MMIfaceModemVoice *self,
{
GError *error = NULL;
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->call_waiting_setup_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->call_waiting_setup_finish (self, res, &error)) {
mm_dbus_method_invocation_take_error (ctx->invocation, error);
handle_call_waiting_setup_context_free (ctx);
return;
@@ -1346,8 +1352,8 @@ handle_call_waiting_setup_auth_ready (MMBaseModem *self,
return;
}
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->call_waiting_setup ||
- !MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->call_waiting_setup_finish) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->call_waiting_setup ||
+ !MM_IFACE_MODEM_VOICE_GET_IFACE (self)->call_waiting_setup_finish) {
mm_dbus_method_invocation_return_error_literal (ctx->invocation, MM_CORE_ERROR, MM_CORE_ERROR_UNSUPPORTED,
"Cannot setup call waiting: unsupported");
handle_call_waiting_setup_context_free (ctx);
@@ -1355,10 +1361,11 @@ handle_call_waiting_setup_auth_ready (MMBaseModem *self,
}
mm_obj_info (self, "processing user request to setup voice call waiting...");
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->call_waiting_setup (MM_IFACE_MODEM_VOICE (self),
- ctx->enable,
- (GAsyncReadyCallback)call_waiting_setup_ready,
- ctx);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->call_waiting_setup (
+ MM_IFACE_MODEM_VOICE (self),
+ ctx->enable,
+ (GAsyncReadyCallback)call_waiting_setup_ready,
+ ctx);
}
static gboolean
@@ -1409,7 +1416,7 @@ call_waiting_query_ready (MMIfaceModemVoice *self,
GError *error = NULL;
gboolean status = FALSE;
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->call_waiting_query_finish (self, res, &status, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->call_waiting_query_finish (self, res, &status, &error)) {
mm_dbus_method_invocation_take_error (ctx->invocation, error);
handle_call_waiting_query_context_free (ctx);
return;
@@ -1432,8 +1439,8 @@ handle_call_waiting_query_auth_ready (MMBaseModem *self,
return;
}
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->call_waiting_query ||
- !MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->call_waiting_query_finish) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->call_waiting_query ||
+ !MM_IFACE_MODEM_VOICE_GET_IFACE (self)->call_waiting_query_finish) {
mm_dbus_method_invocation_return_error_literal (ctx->invocation, MM_CORE_ERROR, MM_CORE_ERROR_UNSUPPORTED,
"Cannot query call waiting: unsupported");
handle_call_waiting_query_context_free (ctx);
@@ -1441,9 +1448,10 @@ handle_call_waiting_query_auth_ready (MMBaseModem *self,
}
mm_obj_info (self, "processing user request to query voice call waiting state...");
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->call_waiting_query (MM_IFACE_MODEM_VOICE (self),
- (GAsyncReadyCallback)call_waiting_query_ready,
- ctx);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->call_waiting_query (
+ MM_IFACE_MODEM_VOICE (self),
+ (GAsyncReadyCallback)call_waiting_query_ready,
+ ctx);
}
static gboolean
@@ -1529,7 +1537,7 @@ leave_multiparty_ready (MMIfaceModemVoice *self,
ctx = g_task_get_task_data (task);
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->leave_multiparty_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->leave_multiparty_finish (self, res, &error)) {
g_task_return_error (task, error);
g_object_unref (task);
return;
@@ -1588,8 +1596,8 @@ mm_iface_modem_voice_leave_multiparty (MMIfaceModemVoice *self,
return;
}
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->leave_multiparty ||
- !MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->leave_multiparty_finish) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->leave_multiparty ||
+ !MM_IFACE_MODEM_VOICE_GET_IFACE (self)->leave_multiparty_finish) {
g_task_return_new_error (task, MM_CORE_ERROR, MM_CORE_ERROR_UNSUPPORTED,
"Cannot leave multiparty: unsupported");
g_object_unref (task);
@@ -1613,10 +1621,11 @@ mm_iface_modem_voice_leave_multiparty (MMIfaceModemVoice *self,
mm_call_list_foreach (list, (MMCallListForeachFunc)prepare_leave_multiparty_foreach, ctx);
g_object_unref (list);
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->leave_multiparty (self,
- call,
- (GAsyncReadyCallback)leave_multiparty_ready,
- task);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->leave_multiparty (
+ self,
+ call,
+ (GAsyncReadyCallback)leave_multiparty_ready,
+ task);
}
/*****************************************************************************/
@@ -1680,7 +1689,7 @@ join_multiparty_ready (MMIfaceModemVoice *self,
ctx = g_task_get_task_data (task);
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->join_multiparty_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->join_multiparty_finish (self, res, &error)) {
g_task_return_error (task, error);
g_object_unref (task);
return;
@@ -1725,8 +1734,8 @@ mm_iface_modem_voice_join_multiparty (MMIfaceModemVoice *self,
return;
}
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->join_multiparty ||
- !MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->join_multiparty_finish) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->join_multiparty ||
+ !MM_IFACE_MODEM_VOICE_GET_IFACE (self)->join_multiparty_finish) {
g_task_return_new_error (task, MM_CORE_ERROR, MM_CORE_ERROR_UNSUPPORTED,
"Cannot join multiparty: unsupported");
g_object_unref (task);
@@ -1755,9 +1764,10 @@ mm_iface_modem_voice_join_multiparty (MMIfaceModemVoice *self,
/* NOTE: we do not give the call we want to join, because the join operation acts on all
* active/held calls. */
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->join_multiparty (self,
- (GAsyncReadyCallback)join_multiparty_ready,
- task);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->join_multiparty (
+ self,
+ (GAsyncReadyCallback)join_multiparty_ready,
+ task);
}
/*****************************************************************************/
@@ -1825,11 +1835,12 @@ setup_in_call_audio_channel_ready (MMIfaceModemVoice *self,
ctx = g_task_get_task_data (task);
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_in_call_audio_channel_finish (self,
- res,
- &ctx->audio_port,
- &ctx->audio_format,
- &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_in_call_audio_channel_finish (
+ self,
+ res,
+ &ctx->audio_port,
+ &ctx->audio_format,
+ &error)) {
mm_obj_warn (self, "couldn't setup in-call audio channel: %s", error->message);
g_clear_error (&error);
}
@@ -1848,7 +1859,7 @@ setup_in_call_unsolicited_events_ready (MMIfaceModemVoice *self,
ctx = g_task_get_task_data (task);
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_in_call_unsolicited_events_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_in_call_unsolicited_events_finish (self, res, &error)) {
mm_obj_warn (self, "couldn't setup in-call unsolicited events: %s", error->message);
g_clear_error (&error);
}
@@ -1876,9 +1887,9 @@ in_call_setup_context_step (GTask *task)
ctx->step++;
/* fall-through */
case IN_CALL_SETUP_STEP_UNSOLICITED_EVENTS:
- if (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_in_call_unsolicited_events &&
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_in_call_unsolicited_events_finish) {
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_in_call_unsolicited_events (
+ if (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_in_call_unsolicited_events &&
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_in_call_unsolicited_events_finish) {
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_in_call_unsolicited_events (
self,
(GAsyncReadyCallback) setup_in_call_unsolicited_events_ready,
task);
@@ -1887,9 +1898,9 @@ in_call_setup_context_step (GTask *task)
ctx->step++;
/* fall-through */
case IN_CALL_SETUP_STEP_AUDIO_CHANNEL:
- if (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_in_call_audio_channel &&
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_in_call_audio_channel_finish) {
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_in_call_audio_channel (
+ if (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_in_call_audio_channel &&
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_in_call_audio_channel_finish) {
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_in_call_audio_channel (
self,
(GAsyncReadyCallback) setup_in_call_audio_channel_ready,
task);
@@ -1964,7 +1975,7 @@ cleanup_in_call_unsolicited_events_ready (MMIfaceModemVoice *self,
ctx = g_task_get_task_data (task);
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_in_call_unsolicited_events_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_in_call_unsolicited_events_finish (self, res, &error)) {
mm_obj_warn (self, "couldn't cleanup in-call unsolicited events: %s", error->message);
g_clear_error (&error);
}
@@ -1983,7 +1994,7 @@ cleanup_in_call_audio_channel_ready (MMIfaceModemVoice *self,
ctx = g_task_get_task_data (task);
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_in_call_audio_channel_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_in_call_audio_channel_finish (self, res, &error)) {
mm_obj_warn (self, "couldn't cleanup in-call audio channel: %s", error->message);
g_clear_error (&error);
}
@@ -2011,9 +2022,9 @@ in_call_cleanup_context_step (GTask *task)
ctx->step++;
/* fall-through */
case IN_CALL_CLEANUP_STEP_AUDIO_CHANNEL:
- if (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_in_call_audio_channel &&
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_in_call_audio_channel_finish) {
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_in_call_audio_channel (
+ if (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_in_call_audio_channel &&
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_in_call_audio_channel_finish) {
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_in_call_audio_channel (
self,
(GAsyncReadyCallback) cleanup_in_call_audio_channel_ready,
task);
@@ -2022,9 +2033,9 @@ in_call_cleanup_context_step (GTask *task)
ctx->step++;
/* fall-through */
case IN_CALL_CLEANUP_STEP_UNSOLICITED_EVENTS:
- if (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_in_call_unsolicited_events &&
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_in_call_unsolicited_events_finish) {
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_in_call_unsolicited_events (
+ if (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_in_call_unsolicited_events &&
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_in_call_unsolicited_events_finish) {
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_in_call_unsolicited_events (
self,
(GAsyncReadyCallback) cleanup_in_call_unsolicited_events_ready,
task);
@@ -2395,8 +2406,8 @@ load_call_list_ready (MMIfaceModemVoice *self,
ctx = get_call_list_polling_context (self);
ctx->polling_ongoing = FALSE;
- g_assert (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->load_call_list_finish);
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->load_call_list_finish (self, res, &call_info_list, &error)) {
+ g_assert (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->load_call_list_finish);
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->load_call_list_finish (self, res, &call_info_list, &error)) {
mm_obj_warn (self, "couldn't load call list: %s", error->message);
g_error_free (error);
} else {
@@ -2461,10 +2472,10 @@ call_list_poll (MMIfaceModemVoice *self)
if (n_calls_establishing > 0) {
mm_obj_dbg (self, "%u calls being established: call list polling required", n_calls_establishing);
ctx->polling_ongoing = TRUE;
- g_assert (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->load_call_list);
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->load_call_list (self,
- (GAsyncReadyCallback)load_call_list_ready,
- NULL);
+ g_assert (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->load_call_list);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->load_call_list (self,
+ (GAsyncReadyCallback)load_call_list_ready,
+ NULL);
} else
mm_obj_dbg (self, "no calls being established: call list polling stopped");
@@ -2507,8 +2518,8 @@ reload_all_calls_ready (MMIfaceModemVoice *self,
GList *call_info_list = NULL;
GError *error = NULL;
- g_assert (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->load_call_list_finish);
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->load_call_list_finish (self, res, &call_info_list, &error)) {
+ g_assert (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->load_call_list_finish);
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->load_call_list_finish (self, res, &call_info_list, &error)) {
mm_obj_warn (self, "couldn't reload call list: %s", error->message);
g_task_return_error (task, error);
@@ -2531,9 +2542,9 @@ mm_iface_modem_voice_reload_all_calls (MMIfaceModemVoice *self,
GTask *task;
task = g_task_new (self, NULL, callback, user_data);
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->load_call_list (self,
- (GAsyncReadyCallback)reload_all_calls_ready,
- task);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->load_call_list (self,
+ (GAsyncReadyCallback)reload_all_calls_ready,
+ task);
}
/*****************************************************************************/
@@ -2610,7 +2621,7 @@ disable_unsolicited_events_ready (MMIfaceModemVoice *self,
DisablingContext *ctx;
GError *error = NULL;
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->disable_unsolicited_events_finish (self, res, &error);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->disable_unsolicited_events_finish (self, res, &error);
if (error) {
g_task_return_error (task, error);
g_object_unref (task);
@@ -2631,7 +2642,7 @@ cleanup_unsolicited_events_ready (MMIfaceModemVoice *self,
DisablingContext *ctx;
GError *error = NULL;
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_unsolicited_events_finish (self, res, &error);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_unsolicited_events_finish (self, res, &error);
if (error) {
g_task_return_error (task, error);
g_object_unref (task);
@@ -2660,9 +2671,9 @@ interface_disabling_step (GTask *task)
case DISABLING_STEP_DISABLE_UNSOLICITED_EVENTS:
/* Allow cleaning up unsolicited events */
- if (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->disable_unsolicited_events &&
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->disable_unsolicited_events_finish) {
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->disable_unsolicited_events (
+ if (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->disable_unsolicited_events &&
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->disable_unsolicited_events_finish) {
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->disable_unsolicited_events (
self,
(GAsyncReadyCallback)disable_unsolicited_events_ready,
task);
@@ -2673,9 +2684,9 @@ interface_disabling_step (GTask *task)
case DISABLING_STEP_CLEANUP_UNSOLICITED_EVENTS:
/* Allow cleaning up unsolicited events */
- if (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_unsolicited_events &&
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_unsolicited_events_finish) {
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->cleanup_unsolicited_events (
+ if (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_unsolicited_events &&
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_unsolicited_events_finish) {
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->cleanup_unsolicited_events (
self,
(GAsyncReadyCallback)cleanup_unsolicited_events_ready,
task);
@@ -2768,7 +2779,7 @@ setup_unsolicited_events_ready (MMIfaceModemVoice *self,
EnablingContext *ctx;
GError *error = NULL;
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_unsolicited_events_finish (self, res, &error);
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_unsolicited_events_finish (self, res, &error);
if (error) {
g_task_return_error (task, error);
g_object_unref (task);
@@ -2790,7 +2801,7 @@ enable_unsolicited_events_ready (MMIfaceModemVoice *self,
GError *error = NULL;
/* Not critical! */
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->enable_unsolicited_events_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->enable_unsolicited_events_finish (self, res, &error)) {
mm_obj_dbg (self, "couldn't enable unsolicited events: %s", error->message);
g_error_free (error);
}
@@ -2823,9 +2834,9 @@ interface_enabling_step (GTask *task)
case ENABLING_STEP_SETUP_UNSOLICITED_EVENTS:
/* Allow setting up unsolicited events to get notified of incoming calls */
- if (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_unsolicited_events &&
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_unsolicited_events_finish) {
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->setup_unsolicited_events (
+ if (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_unsolicited_events &&
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_unsolicited_events_finish) {
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->setup_unsolicited_events (
self,
(GAsyncReadyCallback)setup_unsolicited_events_ready,
task);
@@ -2836,9 +2847,9 @@ interface_enabling_step (GTask *task)
case ENABLING_STEP_ENABLE_UNSOLICITED_EVENTS:
/* Allow setting up unsolicited events to get notified of incoming calls */
- if (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->enable_unsolicited_events &&
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->enable_unsolicited_events_finish) {
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->enable_unsolicited_events (
+ if (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->enable_unsolicited_events &&
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->enable_unsolicited_events_finish) {
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->enable_unsolicited_events (
self,
(GAsyncReadyCallback)enable_unsolicited_events_ready,
task);
@@ -2922,7 +2933,7 @@ check_support_ready (MMIfaceModemVoice *self,
InitializationContext *ctx;
GError *error = NULL;
- if (!MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->check_support_finish (self, res, &error)) {
+ if (!MM_IFACE_MODEM_VOICE_GET_IFACE (self)->check_support_finish (self, res, &error)) {
if (error) {
mm_obj_dbg (self, "voice support check failed: %s", error->message);
g_error_free (error);
@@ -2961,9 +2972,9 @@ interface_initialization_step (GTask *task)
case INITIALIZATION_STEP_CHECK_SUPPORT:
/* Always check voice support when we run initialization, because
* the support may be different before and after SIM-PIN unlock. */
- if (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->check_support &&
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->check_support_finish) {
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->check_support (
+ if (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->check_support &&
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->check_support_finish) {
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->check_support (
self,
(GAsyncReadyCallback)check_support_ready,
task);
@@ -3007,8 +3018,8 @@ interface_initialization_step (GTask *task)
}
/* Unless we're told not to, setup call list polling logic */
- if (MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->load_call_list &&
- MM_IFACE_MODEM_VOICE_GET_INTERFACE (self)->load_call_list_finish) {
+ if (MM_IFACE_MODEM_VOICE_GET_IFACE (self)->load_call_list &&
+ MM_IFACE_MODEM_VOICE_GET_IFACE (self)->load_call_list_finish) {
gboolean periodic_call_list_check_disabled = FALSE;
/* Cleanup any previously configured handler, before checking if we need to
@@ -3136,68 +3147,45 @@ mm_iface_modem_voice_shutdown (MMIfaceModemVoice *self)
/*****************************************************************************/
static void
-iface_modem_voice_init (gpointer g_iface)
+mm_iface_modem_voice_default_init (MMIfaceModemVoiceInterface *iface)
{
- static gboolean initialized = FALSE;
+ static gsize initialized = 0;
- if (initialized)
+ if (!g_once_init_enter (&initialized))
return;
/* Properties */
- g_object_interface_install_property
- (g_iface,
- g_param_spec_object (MM_IFACE_MODEM_VOICE_DBUS_SKELETON,
- "Voice DBus skeleton",
- "DBus skeleton for the Voice interface",
- MM_GDBUS_TYPE_MODEM_VOICE_SKELETON,
+ g_object_interface_install_property (
+ iface,
+ g_param_spec_object (MM_IFACE_MODEM_VOICE_DBUS_SKELETON,
+ "Voice DBus skeleton",
+ "DBus skeleton for the Voice interface",
+ MM_GDBUS_TYPE_MODEM_VOICE_SKELETON,
+ G_PARAM_READWRITE));
+
+ g_object_interface_install_property (
+ iface,
+ g_param_spec_object (MM_IFACE_MODEM_VOICE_CALL_LIST,
+ "CALL list",
+ "List of CALL objects managed in the interface",
+ MM_TYPE_CALL_LIST,
+ G_PARAM_READWRITE));
+
+ g_object_interface_install_property (
+ iface,
+ g_param_spec_boolean (MM_IFACE_MODEM_VOICE_PERIODIC_CALL_LIST_CHECK_DISABLED,
+ "Periodic call list checks disabled",
+ "Whether periodic call list check are disabled.",
+ FALSE,
G_PARAM_READWRITE));
- g_object_interface_install_property
- (g_iface,
- g_param_spec_object (MM_IFACE_MODEM_VOICE_CALL_LIST,
- "CALL list",
- "List of CALL objects managed in the interface",
- MM_TYPE_CALL_LIST,
+ g_object_interface_install_property (
+ iface,
+ g_param_spec_boolean (MM_IFACE_MODEM_VOICE_INDICATION_CALL_LIST_RELOAD_ENABLED,
+ "Reload call list on call update",
+ "Ignore call updates and forcefully reload all calls.",
+ FALSE,
G_PARAM_READWRITE));
- g_object_interface_install_property
- (g_iface,
- g_param_spec_boolean (MM_IFACE_MODEM_VOICE_PERIODIC_CALL_LIST_CHECK_DISABLED,
- "Periodic call list checks disabled",
- "Whether periodic call list check are disabled.",
- FALSE,
- G_PARAM_READWRITE));
-
- g_object_interface_install_property
- (g_iface,
- g_param_spec_boolean (MM_IFACE_MODEM_VOICE_INDICATION_CALL_LIST_RELOAD_ENABLED,
- "Reload call list on call update",
- "Ignore call updates and forcefully reload all calls.",
- FALSE,
- G_PARAM_READWRITE));
-
- initialized = TRUE;
-}
-
-GType
-mm_iface_modem_voice_get_type (void)
-{
- static GType iface_modem_voice_type = 0;
-
- if (!G_UNLIKELY (iface_modem_voice_type)) {
- static const GTypeInfo info = {
- sizeof (MMIfaceModemVoice), /* class_size */
- iface_modem_voice_init, /* base_init */
- NULL, /* base_finalize */
- };
-
- iface_modem_voice_type = g_type_register_static (G_TYPE_INTERFACE,
- "MMIfaceModemVoice",
- &info,
- 0);
-
- g_type_interface_add_prerequisite (iface_modem_voice_type, MM_TYPE_IFACE_MODEM);
- }
-
- return iface_modem_voice_type;
+ g_once_init_leave (&initialized, 1);
}
diff --git a/src/mm-iface-modem-voice.h b/src/mm-iface-modem-voice.h
index f3164d64..2d8b5160 100644
--- a/src/mm-iface-modem-voice.h
+++ b/src/mm-iface-modem-voice.h
@@ -23,21 +23,18 @@
#define _LIBMM_INSIDE_MM
#include <libmm-glib.h>
+#include "mm-iface-modem.h"
#include "mm-base-call.h"
-#define MM_TYPE_IFACE_MODEM_VOICE (mm_iface_modem_voice_get_type ())
-#define MM_IFACE_MODEM_VOICE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), MM_TYPE_IFACE_MODEM_VOICE, MMIfaceModemVoice))
-#define MM_IS_IFACE_MODEM_VOICE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), MM_TYPE_IFACE_MODEM_VOICE))
-#define MM_IFACE_MODEM_VOICE_GET_INTERFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), MM_TYPE_IFACE_MODEM_VOICE, MMIfaceModemVoice))
+#define MM_TYPE_IFACE_MODEM_VOICE mm_iface_modem_voice_get_type ()
+G_DECLARE_INTERFACE (MMIfaceModemVoice, mm_iface_modem_voice, MM, IFACE_MODEM_VOICE, MMIfaceModem)
#define MM_IFACE_MODEM_VOICE_DBUS_SKELETON "iface-modem-voice-dbus-skeleton"
#define MM_IFACE_MODEM_VOICE_CALL_LIST "iface-modem-voice-call-list"
#define MM_IFACE_MODEM_VOICE_PERIODIC_CALL_LIST_CHECK_DISABLED "iface-modem-voice-periodic-call-list-check-disabled"
#define MM_IFACE_MODEM_VOICE_INDICATION_CALL_LIST_RELOAD_ENABLED "iface-modem-voice-indication-call-list-reload-enabled"
-typedef struct _MMIfaceModemVoice MMIfaceModemVoice;
-
-struct _MMIfaceModemVoice {
+struct _MMIfaceModemVoiceInterface {
GTypeInterface g_iface;
/* Check for Voice support (async) */
@@ -196,9 +193,6 @@ struct _MMIfaceModemVoice {
GError **error);
};
-GType mm_iface_modem_voice_get_type (void);
-G_DEFINE_AUTOPTR_CLEANUP_FUNC (MMIfaceModemVoice, g_object_unref)
-
/* Initialize Voice interface (async) */
void mm_iface_modem_voice_initialize (MMIfaceModemVoice *self,
GCancellable *cancellable,
diff --git a/src/plugins/cinterion/mm-broadband-modem-cinterion.c b/src/plugins/cinterion/mm-broadband-modem-cinterion.c
index 7ae1d9d1..387a9609 100644
--- a/src/plugins/cinterion/mm-broadband-modem-cinterion.c
+++ b/src/plugins/cinterion/mm-broadband-modem-cinterion.c
@@ -46,7 +46,7 @@ static void iface_modem_init (MMIfaceModemInterface *iface);
static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
static void iface_modem_messaging_init (MMIfaceModemMessagingInterface *iface);
static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_voice_init (MMIfaceModemVoiceInterface *iface);
static void iface_modem_time_init (MMIfaceModemTimeInterface *iface);
static void iface_modem_signal_init (MMIfaceModemSignalInterface *iface);
static void shared_cinterion_init (MMSharedCinterion *iface);
@@ -54,7 +54,7 @@ static void shared_cinterion_init (MMSharedCinterion *iface);
static MMIfaceModemInterface *iface_modem_parent;
static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
static MMIfaceModemLocationInterface *iface_modem_location_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemVoiceInterface *iface_modem_voice_parent;
static MMIfaceModemTimeInterface *iface_modem_time_parent;
static MMIfaceModemSignalInterface *iface_modem_signal_parent;
@@ -3554,7 +3554,7 @@ peek_parent_location_interface (MMSharedCinterion *self)
}
static void
-iface_modem_voice_init (MMIfaceModemVoice *iface)
+iface_modem_voice_init (MMIfaceModemVoiceInterface *iface)
{
iface_modem_voice_parent = g_type_interface_peek_parent (iface);
@@ -3572,7 +3572,7 @@ iface_modem_voice_init (MMIfaceModemVoice *iface)
iface->cleanup_unsolicited_events_finish = mm_shared_cinterion_voice_cleanup_unsolicited_events_finish;
}
-static MMIfaceModemVoice *
+static MMIfaceModemVoiceInterface *
peek_parent_voice_interface (MMSharedCinterion *self)
{
return iface_modem_voice_parent;
diff --git a/src/plugins/cinterion/mm-broadband-modem-mbim-cinterion.c b/src/plugins/cinterion/mm-broadband-modem-mbim-cinterion.c
index ea3adef1..e2d44479 100644
--- a/src/plugins/cinterion/mm-broadband-modem-mbim-cinterion.c
+++ b/src/plugins/cinterion/mm-broadband-modem-mbim-cinterion.c
@@ -32,13 +32,13 @@
static void iface_modem_init (MMIfaceModemInterface *iface);
static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_voice_init (MMIfaceModemVoiceInterface *iface);
static void iface_modem_time_init (MMIfaceModemTimeInterface *iface);
static void shared_cinterion_init (MMSharedCinterion *iface);
static MMIfaceModemInterface *iface_modem_parent;
static MMIfaceModemLocationInterface *iface_modem_location_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemVoiceInterface *iface_modem_voice_parent;
static MMIfaceModemTimeInterface *iface_modem_time_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemMbimCinterion, mm_broadband_modem_mbim_cinterion, MM_TYPE_BROADBAND_MODEM_MBIM, 0,
@@ -114,7 +114,7 @@ peek_parent_location_interface (MMSharedCinterion *self)
}
static void
-iface_modem_voice_init (MMIfaceModemVoice *iface)
+iface_modem_voice_init (MMIfaceModemVoiceInterface *iface)
{
iface_modem_voice_parent = g_type_interface_peek_parent (iface);
@@ -132,7 +132,7 @@ iface_modem_voice_init (MMIfaceModemVoice *iface)
iface->cleanup_unsolicited_events_finish = mm_shared_cinterion_voice_cleanup_unsolicited_events_finish;
}
-static MMIfaceModemVoice *
+static MMIfaceModemVoiceInterface *
peek_parent_voice_interface (MMSharedCinterion *self)
{
return iface_modem_voice_parent;
diff --git a/src/plugins/cinterion/mm-broadband-modem-qmi-cinterion.c b/src/plugins/cinterion/mm-broadband-modem-qmi-cinterion.c
index 6475d155..821f9e32 100644
--- a/src/plugins/cinterion/mm-broadband-modem-qmi-cinterion.c
+++ b/src/plugins/cinterion/mm-broadband-modem-qmi-cinterion.c
@@ -33,13 +33,13 @@
static void iface_modem_init (MMIfaceModemInterface *iface);
static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_voice_init (MMIfaceModemVoiceInterface *iface);
static void iface_modem_time_init (MMIfaceModemTimeInterface *iface);
static void shared_cinterion_init (MMSharedCinterion *iface);
static MMIfaceModemInterface *iface_modem_parent;
static MMIfaceModemLocationInterface *iface_modem_location_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemVoiceInterface *iface_modem_voice_parent;
static MMIfaceModemTimeInterface *iface_modem_time_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemQmiCinterion, mm_broadband_modem_qmi_cinterion, MM_TYPE_BROADBAND_MODEM_QMI, 0,
@@ -113,7 +113,7 @@ peek_parent_location_interface (MMSharedCinterion *self)
}
static void
-iface_modem_voice_init (MMIfaceModemVoice *iface)
+iface_modem_voice_init (MMIfaceModemVoiceInterface *iface)
{
iface_modem_voice_parent = g_type_interface_peek_parent (iface);
@@ -131,7 +131,7 @@ iface_modem_voice_init (MMIfaceModemVoice *iface)
iface->cleanup_unsolicited_events_finish = mm_shared_cinterion_voice_cleanup_unsolicited_events_finish;
}
-static MMIfaceModemVoice *
+static MMIfaceModemVoiceInterface *
peek_parent_voice_interface (MMSharedCinterion *self)
{
return iface_modem_voice_parent;
diff --git a/src/plugins/cinterion/mm-shared-cinterion.c b/src/plugins/cinterion/mm-shared-cinterion.c
index 47b86018..fe2651c9 100644
--- a/src/plugins/cinterion/mm-shared-cinterion.c
+++ b/src/plugins/cinterion/mm-shared-cinterion.c
@@ -53,9 +53,9 @@ typedef struct {
FeatureSupport sgpss_support;
FeatureSupport sgpsc_support;
/* voice */
- MMIfaceModemVoice *iface_modem_voice_parent;
- FeatureSupport slcc_support;
- GRegex *slcc_regex;
+ MMIfaceModemVoiceInterface *iface_modem_voice_parent;
+ FeatureSupport slcc_support;
+ GRegex *slcc_regex;
/* time */
MMIfaceModemTimeInterface *iface_modem_time_parent;
GRegex *ctzu_regex;
diff --git a/src/plugins/cinterion/mm-shared-cinterion.h b/src/plugins/cinterion/mm-shared-cinterion.h
index f26aac96..bc9fe986 100644
--- a/src/plugins/cinterion/mm-shared-cinterion.h
+++ b/src/plugins/cinterion/mm-shared-cinterion.h
@@ -47,7 +47,7 @@ struct _MMSharedCinterion {
MMIfaceModemLocationInterface * (* peek_parent_location_interface) (MMSharedCinterion *self);
/* Peek voice interface of the parent class of the object */
- MMIfaceModemVoice * (* peek_parent_voice_interface) (MMSharedCinterion *self);
+ MMIfaceModemVoiceInterface * (* peek_parent_voice_interface) (MMSharedCinterion *self);
/* Peek time interface of the parent class of the object */
MMIfaceModemTimeInterface * (* peek_parent_time_interface) (MMSharedCinterion *self);
diff --git a/src/plugins/huawei/mm-broadband-modem-huawei.c b/src/plugins/huawei/mm-broadband-modem-huawei.c
index 0b11f044..673f3f3d 100644
--- a/src/plugins/huawei/mm-broadband-modem-huawei.c
+++ b/src/plugins/huawei/mm-broadband-modem-huawei.c
@@ -56,14 +56,14 @@ static void iface_modem_3gpp_ussd_init (MMIfaceModem3gppUssdInterface *iface);
static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
static void iface_modem_cdma_init (MMIfaceModemCdma *iface);
static void iface_modem_time_init (MMIfaceModemTimeInterface *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_voice_init (MMIfaceModemVoiceInterface *iface);
static void iface_modem_signal_init (MMIfaceModemSignalInterface *iface);
static MMIfaceModemInterface *iface_modem_parent;
static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
static MMIfaceModemLocationInterface *iface_modem_location_parent;
static MMIfaceModemCdma *iface_modem_cdma_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemVoiceInterface *iface_modem_voice_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemHuawei, mm_broadband_modem_huawei, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -5085,7 +5085,7 @@ iface_modem_time_init (MMIfaceModemTimeInterface *iface)
}
static void
-iface_modem_voice_init (MMIfaceModemVoice *iface)
+iface_modem_voice_init (MMIfaceModemVoiceInterface *iface)
{
iface_modem_voice_parent = g_type_interface_peek_parent (iface);
diff --git a/src/plugins/simtech/mm-broadband-modem-qmi-simtech.c b/src/plugins/simtech/mm-broadband-modem-qmi-simtech.c
index 7ae1dde2..d670b26d 100644
--- a/src/plugins/simtech/mm-broadband-modem-qmi-simtech.c
+++ b/src/plugins/simtech/mm-broadband-modem-qmi-simtech.c
@@ -29,11 +29,11 @@
#include "mm-shared-simtech.h"
static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_voice_init (MMIfaceModemVoiceInterface *iface);
static void shared_simtech_init (MMSharedSimtech *iface);
static MMIfaceModemLocationInterface *iface_modem_location_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemVoiceInterface *iface_modem_voice_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemQmiSimtech, mm_broadband_modem_qmi_simtech, MM_TYPE_BROADBAND_MODEM_QMI, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM_LOCATION, iface_modem_location_init)
@@ -90,7 +90,7 @@ peek_parent_location_interface (MMSharedSimtech *self)
}
static void
-iface_modem_voice_init (MMIfaceModemVoice *iface)
+iface_modem_voice_init (MMIfaceModemVoiceInterface *iface)
{
iface_modem_voice_parent = g_type_interface_peek_parent (iface);
@@ -110,7 +110,7 @@ iface_modem_voice_init (MMIfaceModemVoice *iface)
iface->cleanup_in_call_audio_channel_finish = mm_shared_simtech_voice_cleanup_in_call_audio_channel_finish;
}
-static MMIfaceModemVoice *
+static MMIfaceModemVoiceInterface *
peek_parent_voice_interface (MMSharedSimtech *self)
{
return iface_modem_voice_parent;
diff --git a/src/plugins/simtech/mm-broadband-modem-simtech.c b/src/plugins/simtech/mm-broadband-modem-simtech.c
index e70dbd4a..49ac86e3 100644
--- a/src/plugins/simtech/mm-broadband-modem-simtech.c
+++ b/src/plugins/simtech/mm-broadband-modem-simtech.c
@@ -40,13 +40,13 @@
static void iface_modem_init (MMIfaceModemInterface *iface);
static void iface_modem_3gpp_init (MMIfaceModem3gppInterface *iface);
static void iface_modem_location_init (MMIfaceModemLocationInterface *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_voice_init (MMIfaceModemVoiceInterface *iface);
static void shared_simtech_init (MMSharedSimtech *iface);
static MMIfaceModemInterface *iface_modem_parent;
static MMIfaceModem3gppInterface *iface_modem_3gpp_parent;
static MMIfaceModemLocationInterface *iface_modem_location_parent;
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemVoiceInterface *iface_modem_voice_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemSimtech, mm_broadband_modem_simtech, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -1495,7 +1495,7 @@ peek_parent_location_interface (MMSharedSimtech *self)
}
static void
-iface_modem_voice_init (MMIfaceModemVoice *iface)
+iface_modem_voice_init (MMIfaceModemVoiceInterface *iface)
{
iface_modem_voice_parent = g_type_interface_peek_parent (iface);
@@ -1516,7 +1516,7 @@ iface_modem_voice_init (MMIfaceModemVoice *iface)
}
-static MMIfaceModemVoice *
+static MMIfaceModemVoiceInterface *
peek_parent_voice_interface (MMSharedSimtech *self)
{
return iface_modem_voice_parent;
diff --git a/src/plugins/simtech/mm-shared-simtech.c b/src/plugins/simtech/mm-shared-simtech.c
index 8992d7b8..117ea65e 100644
--- a/src/plugins/simtech/mm-shared-simtech.c
+++ b/src/plugins/simtech/mm-shared-simtech.c
@@ -49,14 +49,14 @@ typedef struct {
MMModemLocationSource enabled_sources;
FeatureSupport cgps_support;
/* voice */
- MMIfaceModemVoice *iface_modem_voice_parent;
- FeatureSupport cpcmreg_support;
- FeatureSupport clcc_urc_support;
- GRegex *clcc_urc_regex;
- GRegex *voice_call_regex;
- GRegex *missed_call_regex;
- GRegex *cring_regex;
- GRegex *rxdtmf_regex;
+ MMIfaceModemVoiceInterface *iface_modem_voice_parent;
+ FeatureSupport cpcmreg_support;
+ FeatureSupport clcc_urc_support;
+ GRegex *clcc_urc_regex;
+ GRegex *voice_call_regex;
+ GRegex *missed_call_regex;
+ GRegex *cring_regex;
+ GRegex *rxdtmf_regex;
} Private;
static void
diff --git a/src/plugins/simtech/mm-shared-simtech.h b/src/plugins/simtech/mm-shared-simtech.h
index 028c5894..13e0eee6 100644
--- a/src/plugins/simtech/mm-shared-simtech.h
+++ b/src/plugins/simtech/mm-shared-simtech.h
@@ -41,7 +41,7 @@ struct _MMSharedSimtech {
MMIfaceModemLocationInterface * (* peek_parent_location_interface) (MMSharedSimtech *self);
/* Peek voice interface of the parent class of the object */
- MMIfaceModemVoice * (* peek_parent_voice_interface) (MMSharedSimtech *self);
+ MMIfaceModemVoiceInterface * (* peek_parent_voice_interface) (MMSharedSimtech *self);
};
GType mm_shared_simtech_get_type (void);
diff --git a/src/plugins/ublox/mm-broadband-modem-ublox.c b/src/plugins/ublox/mm-broadband-modem-ublox.c
index f64240b0..86371bbc 100644
--- a/src/plugins/ublox/mm-broadband-modem-ublox.c
+++ b/src/plugins/ublox/mm-broadband-modem-ublox.c
@@ -34,10 +34,10 @@
#include "mm-modem-helpers-ublox.h"
#include "mm-ublox-enums-types.h"
-static void iface_modem_init (MMIfaceModemInterface *iface);
-static void iface_modem_voice_init (MMIfaceModemVoice *iface);
+static void iface_modem_init (MMIfaceModemInterface *iface);
+static void iface_modem_voice_init (MMIfaceModemVoiceInterface *iface);
-static MMIfaceModemVoice *iface_modem_voice_parent;
+static MMIfaceModemVoiceInterface *iface_modem_voice_parent;
G_DEFINE_TYPE_EXTENDED (MMBroadbandModemUblox, mm_broadband_modem_ublox, MM_TYPE_BROADBAND_MODEM, 0,
G_IMPLEMENT_INTERFACE (MM_TYPE_IFACE_MODEM, iface_modem_init)
@@ -2046,7 +2046,7 @@ iface_modem_init (MMIfaceModemInterface *iface)
}
static void
-iface_modem_voice_init (MMIfaceModemVoice *iface)
+iface_modem_voice_init (MMIfaceModemVoiceInterface *iface)
{
iface_modem_voice_parent = g_type_interface_peek_parent (iface);