[next] telepathy-glib: remove tp_dbus_tube_channel_get_parameters
Guillaume Desmottes
gdesmott at kemper.freedesktop.org
Thu Feb 27 06:07:35 PST 2014
Module: telepathy-glib
Branch: next
Commit: 18086fb09d32e0bfc3e1e3b505b0ed353ed77c18
URL: http://cgit.freedesktop.org/telepathy/telepathy-glib/commit/?id=18086fb09d32e0bfc3e1e3b505b0ed353ed77c18
Author: Guillaume Desmottes <guillaume.desmottes at collabora.co.uk>
Date: Tue Feb 18 18:14:29 2014 +0100
remove tp_dbus_tube_channel_get_parameters
---
.../telepathy-glib/telepathy-glib-sections.txt | 1 -
telepathy-glib/dbus-tube-channel.c | 17 -------------
telepathy-glib/dbus-tube-channel.h | 3 ---
tests/dbus/dbus-tube.c | 26 ++++----------------
4 files changed, 5 insertions(+), 42 deletions(-)
diff --git a/docs/reference/telepathy-glib/telepathy-glib-sections.txt b/docs/reference/telepathy-glib/telepathy-glib-sections.txt
index d0ab07d..28c4a38 100644
--- a/docs/reference/telepathy-glib/telepathy-glib-sections.txt
+++ b/docs/reference/telepathy-glib/telepathy-glib-sections.txt
@@ -5192,7 +5192,6 @@ TpStreamTubeConnectionPrivate
TpDBusTubeChannel
TpDBusTubeChannelClass
TP_DBUS_TUBE_CHANNEL_FEATURE_CORE
-tp_dbus_tube_channel_get_parameters
tp_dbus_tube_channel_dup_parameters_vardict
tp_dbus_tube_channel_get_service_name
tp_dbus_tube_channel_offer_async
diff --git a/telepathy-glib/dbus-tube-channel.c b/telepathy-glib/dbus-tube-channel.c
index ea25bd8..f53c2f9 100644
--- a/telepathy-glib/dbus-tube-channel.c
+++ b/telepathy-glib/dbus-tube-channel.c
@@ -522,23 +522,6 @@ tp_dbus_tube_channel_get_service_name (TpDBusTubeChannel *self)
}
/**
- * tp_dbus_tube_channel_get_parameters: (skip)
- * @self: a #TpDBusTubeChannel
- *
- * Return the #TpDBusTubeChannel:parameters property
- *
- * Returns: (transfer none) (element-type utf8 GObject.Value):
- * the value of #TpDBusTubeChannel:parameters
- *
- * Since: 0.18.0
- */
-GHashTable *
-tp_dbus_tube_channel_get_parameters (TpDBusTubeChannel *self)
-{
- return self->priv->parameters;
-}
-
-/**
* tp_dbus_tube_channel_dup_parameters_vardict:
* @self: a #TpDBusTubeChannel
*
diff --git a/telepathy-glib/dbus-tube-channel.h b/telepathy-glib/dbus-tube-channel.h
index 998499f..814ed55 100644
--- a/telepathy-glib/dbus-tube-channel.h
+++ b/telepathy-glib/dbus-tube-channel.h
@@ -66,9 +66,6 @@ GType tp_dbus_tube_channel_get_type (void);
_TP_AVAILABLE_IN_0_18
const gchar * tp_dbus_tube_channel_get_service_name (TpDBusTubeChannel *self);
-_TP_AVAILABLE_IN_0_18
-GHashTable * tp_dbus_tube_channel_get_parameters (TpDBusTubeChannel *self);
-
_TP_AVAILABLE_IN_0_20
GVariant * tp_dbus_tube_channel_dup_parameters_vardict (TpDBusTubeChannel *self);
diff --git a/tests/dbus/dbus-tube.c b/tests/dbus/dbus-tube.c
index 9e46ca0..b29c1f3 100644
--- a/tests/dbus/dbus-tube.c
+++ b/tests/dbus/dbus-tube.c
@@ -166,15 +166,6 @@ test_creation (Test *test,
}
static void
-check_parameters (GHashTable *parameters)
-{
- g_assert (parameters != NULL);
-
- g_assert_cmpuint (g_hash_table_size (parameters), ==, 1);
- g_assert_cmpuint (tp_asv_get_uint32 (parameters, "badger", NULL), ==, 42);
-}
-
-static void
check_parameters_vardict (GVariant *parameters_vardict)
{
guint32 badger_value;
@@ -191,7 +182,6 @@ test_properties (Test *test,
gconstpointer data G_GNUC_UNUSED)
{
gchar *service;
- GHashTable *parameters;
GVariant *parameters_vardict;
/* Outgoing tube */
@@ -205,29 +195,19 @@ test_properties (Test *test,
g_free (service);
/* Parameters */
- parameters = tp_dbus_tube_channel_get_parameters (test->tube);
parameters_vardict = tp_dbus_tube_channel_dup_parameters_vardict (
test->tube);
/* NULL as the tube has not be offered yet */
- g_assert (parameters == NULL);
- g_object_get (test->tube, "parameters", ¶meters, NULL);
- g_assert (parameters == NULL);
g_assert (parameters_vardict == NULL);
/* Incoming tube */
create_tube_service (test, FALSE, FALSE);
/* Parameters */
- parameters = tp_dbus_tube_channel_get_parameters (test->tube);
- check_parameters (parameters);
- g_object_get (test->tube, "parameters", ¶meters, NULL);
- check_parameters (parameters);
-
parameters_vardict = tp_dbus_tube_channel_dup_parameters_vardict (
test->tube);
check_parameters_vardict (parameters_vardict);
- g_hash_table_unref (parameters);
g_variant_unref (parameters_vardict);
g_object_get (test->tube,
@@ -370,6 +350,7 @@ test_offer (Test *test,
{
const TpTestsDBusTubeChannelOpenMode open_mode = GPOINTER_TO_UINT (data);
GHashTable *params;
+ GVariant *variant;
/* Outgoing tube */
create_tube_service (test, TRUE, TRUE);
@@ -381,12 +362,15 @@ test_offer (Test *test,
G_CALLBACK (new_connection_cb), test);
tp_dbus_tube_channel_offer_async (test->tube, params, tube_offer_cb, test);
+ g_hash_table_unref (params);
test->wait = 2;
g_main_loop_run (test->mainloop);
g_assert_no_error (test->error);
- check_parameters (tp_dbus_tube_channel_get_parameters (test->tube));
+ variant = tp_dbus_tube_channel_dup_parameters_vardict (test->tube);
+ check_parameters_vardict (variant);
+ g_variant_unref (variant);
g_assert (G_IS_DBUS_CONNECTION (test->tube_conn));
g_assert (G_IS_DBUS_CONNECTION (test->cm_conn));
More information about the telepathy-commits
mailing list