X-Git-Url: http://git.maemo.org/git/?p=modest;a=blobdiff_plain;f=libmodest-dbus-client%2Fsrc%2Flibmodest-dbus-client.c;h=7775f563f7b6d7ebf5c165b707c6c7933d8c8cb5;hp=43f5c9e06402ada77c5b441de8f937e0777db8e0;hb=527ab5d715bf2302443e229919b0f33cc6c03eed;hpb=cbcafcdc75d184aacc3df87e7a303c77dfc6263d diff --git a/libmodest-dbus-client/src/libmodest-dbus-client.c b/libmodest-dbus-client/src/libmodest-dbus-client.c index 43f5c9e..7775f56 100644 --- a/libmodest-dbus-client/src/libmodest-dbus-client.c +++ b/libmodest-dbus-client/src/libmodest-dbus-client.c @@ -205,6 +205,54 @@ libmodest_dbus_client_send_and_receive (osso_context_t *osso_context) } gboolean +libmodest_dbus_client_send_and_receive_full (osso_context_t *osso_context, + const gchar *account, + gboolean manual) +{ + osso_rpc_t retval = { 0 }; + const osso_return_t ret = osso_rpc_run_with_defaults(osso_context, + MODEST_DBUS_NAME, + MODEST_DBUS_METHOD_SEND_RECEIVE_FULL, &retval, + DBUS_TYPE_STRING, account, + DBUS_TYPE_BOOLEAN, manual, + DBUS_TYPE_INVALID); + + if (ret != OSSO_OK) { + printf("debug: %s: osso_rpc_run() failed.\n", __FUNCTION__); + return FALSE; + } else { + printf("debug: %s: osso_rpc_run() succeeded.\n", __FUNCTION__); + } + + osso_rpc_free_val(&retval); + + return TRUE; +} + +gboolean +libmodest_dbus_client_update_folder_counts (osso_context_t *osso_context, + const gchar *account) +{ + osso_rpc_t retval = { 0 }; + const osso_return_t ret = osso_rpc_run_with_defaults(osso_context, + MODEST_DBUS_NAME, + MODEST_DBUS_METHOD_UPDATE_FOLDER_COUNTS, &retval, + DBUS_TYPE_STRING, account, + DBUS_TYPE_INVALID); + + if (ret != OSSO_OK) { + printf("debug: %s: osso_rpc_run() failed.\n", __FUNCTION__); + return FALSE; + } else { + printf("debug: %s: osso_rpc_run() succeeded.\n", __FUNCTION__); + } + + osso_rpc_free_val(&retval); + + return TRUE; +} + +gboolean libmodest_dbus_client_open_default_inbox (osso_context_t *osso_context) { osso_rpc_t retval = { 0 }; @@ -249,6 +297,28 @@ libmodest_dbus_client_open_account (osso_context_t *osso_context, return TRUE; } +gboolean +libmodest_dbus_client_open_edit_accounts_dialog (osso_context_t *osso_context) +{ + osso_rpc_t retval = { 0 }; + const osso_return_t ret = + osso_rpc_run_with_defaults(osso_context, + MODEST_DBUS_NAME, + MODEST_DBUS_METHOD_OPEN_EDIT_ACCOUNTS_DIALOG, &retval, + DBUS_TYPE_INVALID); + + if (ret != OSSO_OK) { + printf("debug: %s: osso_rpc_run() failed.\n", __FUNCTION__); + return FALSE; + } else { + printf("debug: %s: osso_rpc_run() succeeded.\n", __FUNCTION__); + } + + osso_rpc_free_val(&retval); + + return TRUE; +} + /** * libmodest_dbus_client_delete_message: * @osso_context: a valid #osso_context_t object.