diff options
author | Xavier Claessens <xavier.claessens@collabora.co.uk> | 2013-11-08 14:53:37 -0500 |
---|---|---|
committer | Xavier Claessens <xavier.claessens@collabora.co.uk> | 2013-11-11 10:59:58 -0500 |
commit | 8171d9e5bc8d4f47a36844afab0a6063b1958004 (patch) | |
tree | 866b6fdf6bcbad7de21fa32ecfd91909b1d8f16c /mission-control-plugins | |
parent | e9a9dd37bd193d8ac16729671d2296a4aa96139c (diff) |
Remove unused code
Diffstat (limited to 'mission-control-plugins')
-rw-r--r-- | mission-control-plugins/account.c | 109 | ||||
-rw-r--r-- | mission-control-plugins/account.h | 19 | ||||
-rw-r--r-- | mission-control-plugins/implementation.h | 16 |
3 files changed, 0 insertions, 144 deletions
diff --git a/mission-control-plugins/account.c b/mission-control-plugins/account.c index 493a34c0..c9859d70 100644 --- a/mission-control-plugins/account.c +++ b/mission-control-plugins/account.c @@ -191,31 +191,6 @@ mcp_account_manager_list_keys (const McpAccountManager *mcpa, } /** - * mcp_account_manager_get_value: - * @mcpa: an #McpAccountManager instance - * @account: the unique name of an account - * @key: the setting whose value we wish to fetch: either an attribute - * like "DisplayName", or "param-" plus a parameter like "account" - * - * Fetch a copy of the current value of an account setting held by - * the account manager. - * - * Returns: (transfer full): the value of @key - */ -gchar * -mcp_account_manager_get_value (const McpAccountManager *mcpa, - const gchar *account, - const gchar *key) -{ - McpAccountManagerIface *iface = MCP_ACCOUNT_MANAGER_GET_IFACE (mcpa); - - g_return_val_if_fail (iface != NULL, NULL); - g_return_val_if_fail (iface->set_value != NULL, NULL); - - return iface->get_value (mcpa, account, key); -} - -/** * mcp_account_manager_get_unique_name: * @mcpa: an #McpAccountManager instance * @manager: the name of the manager @@ -292,34 +267,6 @@ mcp_account_manager_identify_account_finish (McpAccountManager *mcpa, } /** - * mcp_account_manager_escape_value_from_keyfile: - * @mcpa: a #McpAccountManager - * @value: a value with a supported #GType - * - * Escape @value so it could be passed to g_key_file_set_value(). - * For instance, escaping the boolean value TRUE returns "true", - * and escaping the string value containing one space returns "\s". - * - * It is a programming error to use an unsupported type. - * The supported types are currently %G_TYPE_STRING, %G_TYPE_BOOLEAN, - * %G_TYPE_INT, %G_TYPE_UINT, %G_TYPE_INT64, %G_TYPE_UINT64, %G_TYPE_UCHAR, - * %G_TYPE_STRV, %DBUS_TYPE_G_OBJECT_PATH and %TP_ARRAY_TYPE_OBJECT_PATH_LIST. - * - * Returns: the escaped form of @value - */ -gchar * -mcp_account_manager_escape_value_for_keyfile (const McpAccountManager *mcpa, - const GValue *value) -{ - McpAccountManagerIface *iface = MCP_ACCOUNT_MANAGER_GET_IFACE (mcpa); - - g_return_val_if_fail (iface != NULL, NULL); - g_return_val_if_fail (iface->escape_value_for_keyfile != NULL, NULL); - - return iface->escape_value_for_keyfile (mcpa, value); -} - -/** * mcp_account_manager_escape_variant_for_keyfile: * @mcpa: a #McpAccountManager * @variant: a #GVariant with a supported #GVariantType @@ -348,59 +295,3 @@ mcp_account_manager_escape_variant_for_keyfile (const McpAccountManager *mcpa, return iface->escape_variant_for_keyfile (mcpa, variant); } - -/** - * mcp_account_manager_unescape_value_from_keyfile: - * @mcpa: a #McpAccountManager - * @escaped: an escaped string as returned by g_key_file_get_value() - * @value: a value to populate, with a supported #GType - * @error: used to raise an error if %FALSE is returned - * - * Attempt to interpret @escaped as a value of @value's type. - * If successful, put it in @value and return %TRUE. - * - * It is a programming error to try to escape an unsupported type. - * The supported types are currently %G_TYPE_STRING, %G_TYPE_BOOLEAN, - * %G_TYPE_INT, %G_TYPE_UINT, %G_TYPE_INT64, %G_TYPE_UINT64, %G_TYPE_UCHAR, - * %G_TYPE_STRV, %DBUS_TYPE_G_OBJECT_PATH and %TP_ARRAY_TYPE_OBJECT_PATH_LIST. - * - * Returns: %TRUE if @value was filled in - */ -gboolean -mcp_account_manager_unescape_value_from_keyfile (const McpAccountManager *mcpa, - const gchar *escaped, - GValue *value, - GError **error) -{ - McpAccountManagerIface *iface = MCP_ACCOUNT_MANAGER_GET_IFACE (mcpa); - - g_return_val_if_fail (iface != NULL, FALSE); - g_return_val_if_fail (iface->unescape_value_from_keyfile != NULL, FALSE); - - return iface->unescape_value_from_keyfile (mcpa, escaped, value, error); -} - -/** - * mcp_account_manager_init_value_for_attribute: - * @mcpa: a #McpAccountManager - * @value: a zero-filled value to initialize - * @attribute: a supported Mission Control attribute - * - * If @attribute is a known Mission Control attribute, initialize @value - * with an appropriate type for @attribute and return %TRUE. Otherwise, - * return %FALSE. - * - * Returns: %TRUE if @value was initialized - */ -gboolean -mcp_account_manager_init_value_for_attribute (const McpAccountManager *mcpa, - GValue *value, - const gchar *attribute) -{ - McpAccountManagerIface *iface = MCP_ACCOUNT_MANAGER_GET_IFACE (mcpa); - - g_return_val_if_fail (iface != NULL, FALSE); - g_return_val_if_fail (iface->init_value_for_attribute != NULL, FALSE); - - return iface->init_value_for_attribute (mcpa, value, attribute); -} diff --git a/mission-control-plugins/account.h b/mission-control-plugins/account.h index c283ef99..4356b3c0 100644 --- a/mission-control-plugins/account.h +++ b/mission-control-plugins/account.h @@ -62,10 +62,6 @@ void mcp_account_manager_set_parameter (const McpAccountManager *mcpa, GVariant *value, McpParameterFlags flags); -gchar * mcp_account_manager_get_value (const McpAccountManager *mcpa, - const gchar *account, - const gchar *key); - gchar * mcp_account_manager_get_unique_name (McpAccountManager *mcpa, const gchar *manager, const gchar *protocol, @@ -74,25 +70,10 @@ gchar * mcp_account_manager_get_unique_name (McpAccountManager *mcpa, GStrv mcp_account_manager_list_keys (const McpAccountManager *mcpa, const gchar *account); -gchar *mcp_account_manager_escape_value_for_keyfile ( - const McpAccountManager *mcpa, - const GValue *value); - gchar *mcp_account_manager_escape_variant_for_keyfile ( const McpAccountManager *mcpa, GVariant *variant); -gboolean mcp_account_manager_unescape_value_from_keyfile ( - const McpAccountManager *mcpa, - const gchar *escaped, - GValue *value, - GError **error); - -gboolean mcp_account_manager_init_value_for_attribute ( - const McpAccountManager *mcpa, - GValue *value, - const gchar *attribute); - void mcp_account_manager_identify_account_async (McpAccountManager *mcpa, const gchar *manager, const gchar *protocol, diff --git a/mission-control-plugins/implementation.h b/mission-control-plugins/implementation.h index 9cc04b4e..9d44b3bb 100644 --- a/mission-control-plugins/implementation.h +++ b/mission-control-plugins/implementation.h @@ -82,10 +82,6 @@ struct _McpAccountManagerIface { const gchar *key, const gchar *value); - gchar * (*get_value) (const McpAccountManager *ma, - const gchar *acct, - const gchar *key); - gchar * (* unique_name) (const McpAccountManager *ma, const gchar *manager, const gchar *protocol, @@ -94,18 +90,6 @@ struct _McpAccountManagerIface { GStrv (* list_keys) (const McpAccountManager *ma, const gchar *acct); - gchar * (* escape_value_for_keyfile) (const McpAccountManager *mcpa, - const GValue *value); - - gboolean (* unescape_value_from_keyfile) (const McpAccountManager *mcpa, - const gchar *escaped, - GValue *value, - GError **error); - - gboolean (* init_value_for_attribute) (const McpAccountManager *mcpa, - GValue *value, - const gchar *attribute); - gchar * (* escape_variant_for_keyfile) (const McpAccountManager *mcpa, GVariant *variant); |