api,dbus: remove the option to send the SMS in the Create() call
An SMS must be first created with the Messaging interface, and then sent using the Send() method from the SMS-specific interface.
This commit is contained in:
@@ -272,7 +272,6 @@ get_modem_ready (GObject *source,
|
|||||||
g_debug ("Asynchronously creating new SMS in modem...");
|
g_debug ("Asynchronously creating new SMS in modem...");
|
||||||
mm_modem_messaging_create (ctx->modem_messaging,
|
mm_modem_messaging_create (ctx->modem_messaging,
|
||||||
properties,
|
properties,
|
||||||
FALSE, /* never send it here */
|
|
||||||
ctx->cancellable,
|
ctx->cancellable,
|
||||||
(GAsyncReadyCallback)create_ready,
|
(GAsyncReadyCallback)create_ready,
|
||||||
NULL);
|
NULL);
|
||||||
@@ -349,7 +348,6 @@ mmcli_modem_messaging_run_synchronous (GDBusConnection *connection)
|
|||||||
g_debug ("Synchronously creating new SMS in modem...");
|
g_debug ("Synchronously creating new SMS in modem...");
|
||||||
sms = mm_modem_messaging_create_sync (ctx->modem_messaging,
|
sms = mm_modem_messaging_create_sync (ctx->modem_messaging,
|
||||||
properties,
|
properties,
|
||||||
FALSE, /* never send it here */
|
|
||||||
NULL,
|
NULL,
|
||||||
&error);
|
&error);
|
||||||
g_object_unref (properties);
|
g_object_unref (properties);
|
||||||
|
@@ -374,7 +374,6 @@ create_sms_ready (MMModemMessaging *self,
|
|||||||
* mm_modem_messaging_create_sms:
|
* mm_modem_messaging_create_sms:
|
||||||
* @self: A #MMModemMessaging.
|
* @self: A #MMModemMessaging.
|
||||||
* @properties: A ##MMSmsProperties object with the properties to use.
|
* @properties: A ##MMSmsProperties object with the properties to use.
|
||||||
* @send: #TRUE if the SMS should be also sent, #FALSE otherwise.
|
|
||||||
* @cancellable: (allow-none): A #GCancellable or %NULL.
|
* @cancellable: (allow-none): A #GCancellable or %NULL.
|
||||||
* @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
|
* @callback: A #GAsyncReadyCallback to call when the request is satisfied or %NULL.
|
||||||
* @user_data: User data to pass to @callback.
|
* @user_data: User data to pass to @callback.
|
||||||
@@ -389,7 +388,6 @@ create_sms_ready (MMModemMessaging *self,
|
|||||||
void
|
void
|
||||||
mm_modem_messaging_create (MMModemMessaging *self,
|
mm_modem_messaging_create (MMModemMessaging *self,
|
||||||
MMSmsProperties *properties,
|
MMSmsProperties *properties,
|
||||||
gboolean send,
|
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GAsyncReadyCallback callback,
|
GAsyncReadyCallback callback,
|
||||||
gpointer user_data)
|
gpointer user_data)
|
||||||
@@ -412,7 +410,6 @@ mm_modem_messaging_create (MMModemMessaging *self,
|
|||||||
mm_gdbus_modem_messaging_call_create (
|
mm_gdbus_modem_messaging_call_create (
|
||||||
self,
|
self,
|
||||||
dictionary,
|
dictionary,
|
||||||
send,
|
|
||||||
cancellable,
|
cancellable,
|
||||||
(GAsyncReadyCallback)create_sms_ready,
|
(GAsyncReadyCallback)create_sms_ready,
|
||||||
ctx);
|
ctx);
|
||||||
@@ -424,7 +421,6 @@ mm_modem_messaging_create (MMModemMessaging *self,
|
|||||||
* mm_modem_create_sms_sync:
|
* mm_modem_create_sms_sync:
|
||||||
* @self: A #MMModemMessaging.
|
* @self: A #MMModemMessaging.
|
||||||
* @properties: A ##MMSmsProperties object with the properties to use.
|
* @properties: A ##MMSmsProperties object with the properties to use.
|
||||||
* @send: #TRUE if the SMS should be also sent, #FALSE otherwise.
|
|
||||||
* @cancellable: (allow-none): A #GCancellable or %NULL.
|
* @cancellable: (allow-none): A #GCancellable or %NULL.
|
||||||
* @error: Return location for error or %NULL.
|
* @error: Return location for error or %NULL.
|
||||||
*
|
*
|
||||||
@@ -438,7 +434,6 @@ mm_modem_messaging_create (MMModemMessaging *self,
|
|||||||
MMSms *
|
MMSms *
|
||||||
mm_modem_messaging_create_sync (MMModemMessaging *self,
|
mm_modem_messaging_create_sync (MMModemMessaging *self,
|
||||||
MMSmsProperties *properties,
|
MMSmsProperties *properties,
|
||||||
gboolean send,
|
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GError **error)
|
GError **error)
|
||||||
{
|
{
|
||||||
@@ -452,7 +447,6 @@ mm_modem_messaging_create_sync (MMModemMessaging *self,
|
|||||||
MM_COMMON_SMS_PROPERTIES (properties)));
|
MM_COMMON_SMS_PROPERTIES (properties)));
|
||||||
mm_gdbus_modem_messaging_call_create_sync (self,
|
mm_gdbus_modem_messaging_call_create_sync (self,
|
||||||
dictionary,
|
dictionary,
|
||||||
send,
|
|
||||||
&sms_path,
|
&sms_path,
|
||||||
cancellable,
|
cancellable,
|
||||||
error);
|
error);
|
||||||
|
@@ -41,7 +41,6 @@ gchar *mm_modem_messaging_dup_path (MMModemMessaging *self);
|
|||||||
|
|
||||||
void mm_modem_messaging_create (MMModemMessaging *self,
|
void mm_modem_messaging_create (MMModemMessaging *self,
|
||||||
MMSmsProperties *properties,
|
MMSmsProperties *properties,
|
||||||
gboolean send,
|
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GAsyncReadyCallback callback,
|
GAsyncReadyCallback callback,
|
||||||
gpointer user_data);
|
gpointer user_data);
|
||||||
@@ -50,7 +49,6 @@ MMSms *mm_modem_messaging_create_finish (MMModemMessaging *self,
|
|||||||
GError **error);
|
GError **error);
|
||||||
MMSms *mm_modem_messaging_create_sync (MMModemMessaging *self,
|
MMSms *mm_modem_messaging_create_sync (MMModemMessaging *self,
|
||||||
MMSmsProperties *properties,
|
MMSmsProperties *properties,
|
||||||
gboolean send,
|
|
||||||
GCancellable *cancellable,
|
GCancellable *cancellable,
|
||||||
GError **error);
|
GError **error);
|
||||||
|
|
||||||
|
@@ -49,12 +49,11 @@
|
|||||||
<!--
|
<!--
|
||||||
Create:
|
Create:
|
||||||
@properties: Message properties from the <link linkend="gdbus-org.freedesktop.ModemManager1.Sms">SMS D-Bus interface</link>.
|
@properties: Message properties from the <link linkend="gdbus-org.freedesktop.ModemManager1.Sms">SMS D-Bus interface</link>.
|
||||||
@send: If %TRUE, queue the message for immediate delivery.
|
|
||||||
@path: The object path of the new message object.
|
@path: The object path of the new message object.
|
||||||
|
|
||||||
Creates a new message object and optionally queues it for delivery.
|
Creates a new message object.
|
||||||
|
|
||||||
The '<link linkend="gdbus-property-org-freedesktop-ModemManager1-Sms.To">To</link>'
|
The '<link linkend="gdbus-property-org-freedesktop-ModemManager1-Sms.Number">Number</link>'
|
||||||
and
|
and
|
||||||
'<link linkend="gdbus-property-org-freedesktop-ModemManager1-Sms.Text">Text</link>'
|
'<link linkend="gdbus-property-org-freedesktop-ModemManager1-Sms.Text">Text</link>'
|
||||||
properties are mandatory, others are optional.
|
properties are mandatory, others are optional.
|
||||||
@@ -64,7 +63,6 @@
|
|||||||
-->
|
-->
|
||||||
<method name="Create">
|
<method name="Create">
|
||||||
<arg name="properties" type="a{sv}" direction="in" />
|
<arg name="properties" type="a{sv}" direction="in" />
|
||||||
<arg name="send" type="b" direction="in" />
|
|
||||||
<arg name="path" type="o" direction="out" />
|
<arg name="path" type="o" direction="out" />
|
||||||
</method>
|
</method>
|
||||||
|
|
||||||
|
@@ -128,7 +128,6 @@ static gboolean
|
|||||||
handle_create (MmGdbusModemMessaging *skeleton,
|
handle_create (MmGdbusModemMessaging *skeleton,
|
||||||
GDBusMethodInvocation *invocation,
|
GDBusMethodInvocation *invocation,
|
||||||
GVariant *dictionary,
|
GVariant *dictionary,
|
||||||
gboolean send,
|
|
||||||
MMIfaceModemMessaging *self)
|
MMIfaceModemMessaging *self)
|
||||||
{
|
{
|
||||||
GError *error = NULL;
|
GError *error = NULL;
|
||||||
|
Reference in New Issue
Block a user