aboutsummaryrefslogtreecommitdiff
path: root/src/mm-base-call.c
diff options
context:
space:
mode:
authorAleksander Morgado <aleksander@aleksander.es>2018-07-03 14:49:40 +0200
committerDan Williams <dcbw@redhat.com>2018-10-16 17:09:21 +0000
commit44413308b295bd52c1b24eba69bc8e9eed6b4fb5 (patch)
treebc33d93a8627a4d4725ba43fe3b4c71dd65c7717 /src/mm-base-call.c
parentfc0feee65481f7edf1118e8dd74a5352901f677f (diff)
iface-modem-voice: always create plugin-specified call objects
The Voice interface logic must always use the create_call() object from its own interface to create call objects, as that is the method that plugins can subclass to provide plugin-specific call objects. This applies to both incoming and outgoing calls.
Diffstat (limited to 'src/mm-base-call.c')
-rw-r--r--src/mm-base-call.c42
1 files changed, 0 insertions, 42 deletions
diff --git a/src/mm-base-call.c b/src/mm-base-call.c
index a26b0768..b3c6aeb5 100644
--- a/src/mm-base-call.c
+++ b/src/mm-base-call.c
@@ -939,48 +939,6 @@ mm_base_call_new (MMBaseModem *modem)
NULL));
}
-MMBaseCall *
-mm_base_call_new_from_properties (MMBaseModem *modem,
- MMCallProperties *properties,
- GError **error)
-{
- MMBaseCall *self;
- const gchar *number;
- MMCallDirection direction;
-
- g_assert (MM_IS_IFACE_MODEM_VOICE (modem));
-
- number = mm_call_properties_get_number (properties);
- direction = mm_call_properties_get_direction (properties);
-
- /* Don't create CALL from properties if either number is missing */
- if (!number) {
- g_set_error (error,
- MM_CORE_ERROR,
- MM_CORE_ERROR_INVALID_ARGS,
- "Cannot create call: mandatory parameter 'number' is missing");
- return NULL;
- }
-
- /* if no direction is specified force to outgoing */
- if (direction == MM_CALL_DIRECTION_UNKNOWN)
- direction = MM_CALL_DIRECTION_OUTGOING;
-
- /* Create a call object as defined by the interface */
- self = mm_iface_modem_voice_create_call (MM_IFACE_MODEM_VOICE (modem));
- g_object_set (self,
- "state", mm_call_properties_get_state (properties),
- "state-reason", mm_call_properties_get_state_reason (properties),
- "direction", direction,
- "number", number,
- NULL);
-
- /* Only export once properly created */
- mm_base_call_export (self);
-
- return self;
-}
-
/*****************************************************************************/
static void