- /* This method has no arguments. */
-
- /* printf(" debug: to=%s\n", idle_data->to); */
+static gint
+on_dbus_method_dump (DBusConnection *con, DBusMessage *message)
+{
+ gchar *str;
+ gchar *op_queue_str;
+ DBusMessage *reply;
+ dbus_uint32_t serial = 0;
+
+ op_queue_str = modest_mail_operation_queue_to_string
+ (modest_runtime_get_mail_operation_queue ());
+
+ str = g_strdup_printf ("\nmodest debug dump\n=================\n%s\n",
+ op_queue_str);
+ g_free (op_queue_str);
+
+ g_printerr (str);
+
+ reply = dbus_message_new_method_return (message);
+ if (reply) {
+ dbus_message_append_args (reply,
+ DBUS_TYPE_STRING, &str,
+ DBUS_TYPE_INVALID);
+ dbus_connection_send (con, reply, &serial);
+ dbus_connection_flush (con);
+ dbus_message_unref (reply);
+ }
+
+ g_free (str);
+ return OSSO_OK;
+}
+
+
+static gint
+on_send_receive(GArray *arguments, gpointer data, osso_rpc_t * retval)
+{
+ /* Use g_idle to context-switch into the application's thread: */