return TRUE;
}
+gboolean
+libmodest_dbus_client_open_account (osso_context_t *osso_context,
+ const gchar *account_id)
+{
+ osso_rpc_t retval;
+ const osso_return_t ret =
+ osso_rpc_run_with_defaults(osso_context,
+ MODEST_DBUS_NAME,
+ MODEST_DBUS_METHOD_OPEN_ACCOUNT, &retval,
+ DBUS_TYPE_STRING, account_id,
+ 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.
* opens a new mail composer with the provided details filled in,
* based on a mailto: string. apart from the To:-field (the first arg),
* also, cc, bcc, subject and body are supported, ie. "mailto:foo@bar.cuu?subject=test"
- *
+ *
* Returns: TRUE upon success, FALSE otherwise
*/
gboolean libmodest_dbus_client_mail_to (osso_context_t *osso_context,
*
* opens an existing message based on its URI; these URIs are unique pointers
* to some message, and are retrieved from modest.
- *
+ *
* Returns: TRUE upon success, FALSE otherwise
*/
gboolean libmodest_dbus_client_open_message (osso_context_t *osso_context,
* @osso_context: a valid osso_context instance
*
* send/receive messages
- *
+ *
* Returns: TRUE upon success, FALSE otherwise
*/
gboolean libmodest_dbus_client_send_and_receive (osso_context_t *osso_context);
* @osso_context: a valid osso_context instance
*
* start modest, and open the inbox for the default account
- *
+ *
* Returns: TRUE upon success, FALSE otherwise
*/
gboolean libmodest_dbus_client_open_default_inbox (osso_context_t *osso_context);
+/**
+ * libmodest_dbus_client_open_account:
+ * @osso_context: a valid osso_context instance
+ * @account_id: the unique ID of one account
+ *
+ * Starts Modest showing the account that is specified as
+ * parametter. Note that this only makes sense when the folder view is
+ * showing just one account
+ *
+ * Returns: TRUE upon success, FALSE otherwise
+ */
+gboolean libmodest_dbus_client_open_account (osso_context_t *osso_context,
+ const gchar *account_id);
/*
MODEST_DBUS_OPEN_MESSAGE_ARGS_COUNT
};
+#define MODEST_DBUS_METHOD_OPEN_ACCOUNT "OpenAccount"
+enum ModestDbusOpenAccountArguments
+{
+ MODEST_DBUS_OPEN_ACCOUNT_ARG_ID,
+ MODEST_DBUS_OPEN_ACCOUNT_ARGS_COUNT
+};
+
#define MODEST_DBUS_METHOD_SEND_RECEIVE "SendReceive"
#define MODEST_DBUS_METHOD_COMPOSE_MAIL "ComposeMail"
gint modest_dbus_req_handler(const gchar * interface, const gchar * method,
GArray * arguments, gpointer data,
osso_rpc_t * retval);
-
+
void modest_osso_cb_hw_state_handler(osso_hw_state_t *state, gpointer data);
DBusHandlerResult modest_dbus_req_filter (DBusConnection *con,