aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy-gtk/empathy-contact-chooser.c
diff options
context:
space:
mode:
authorGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2011-08-05 18:08:20 +0800
committerGuillaume Desmottes <guillaume.desmottes@collabora.co.uk>2011-08-05 21:04:05 +0800
commit8e839c45aea812bef072cc3365c58f366adc104e (patch)
tree4c38fd62505913c011a8824321424a62be6345f6 /libempathy-gtk/empathy-contact-chooser.c
parent508d001793fdcb91dc6305c547a9b2f205acdad1 (diff)
downloadgsoc2013-empathy-8e839c45aea812bef072cc3365c58f366adc104e.tar
gsoc2013-empathy-8e839c45aea812bef072cc3365c58f366adc104e.tar.gz
gsoc2013-empathy-8e839c45aea812bef072cc3365c58f366adc104e.tar.bz2
gsoc2013-empathy-8e839c45aea812bef072cc3365c58f366adc104e.tar.lz
gsoc2013-empathy-8e839c45aea812bef072cc3365c58f366adc104e.tar.xz
gsoc2013-empathy-8e839c45aea812bef072cc3365c58f366adc104e.tar.zst
gsoc2013-empathy-8e839c45aea812bef072cc3365c58f366adc104e.zip
EmpathyContactChooser: remove EmpathyTpChat property
It's not used any more and a generic widget shouldn't need it. https://bugzilla.gnome.org/show_bug.cgi?id=656020
Diffstat (limited to 'libempathy-gtk/empathy-contact-chooser.c')
-rw-r--r--libempathy-gtk/empathy-contact-chooser.c61
1 files changed, 1 insertions, 60 deletions
diff --git a/libempathy-gtk/empathy-contact-chooser.c b/libempathy-gtk/empathy-contact-chooser.c
index f6fa59d3b..a4a0aad1d 100644
--- a/libempathy-gtk/empathy-contact-chooser.c
+++ b/libempathy-gtk/empathy-contact-chooser.c
@@ -20,11 +20,6 @@
G_DEFINE_TYPE (EmpathyContactChooser,
empathy_contact_chooser, GTK_TYPE_BOX);
-enum
-{
- PROP_TP_CHAT = 1
-};
-
enum {
SIG_SELECTION_CHANGED,
LAST_SIGNAL
@@ -36,7 +31,6 @@ typedef struct _AddTemporaryIndividualCtx AddTemporaryIndividualCtx;
struct _EmpathyContactChooserPrivate
{
- EmpathyTpChat *tp_chat;
TpAccountManager *account_mgr;
EmpathyIndividualStore *store;
@@ -53,47 +47,6 @@ struct _EmpathyContactChooserPrivate
gpointer filter_data;
};
-static void
-contact_chooser_get_property (GObject *object,
- guint param_id,
- GValue *value,
- GParamSpec *pspec)
-{
- EmpathyContactChooser *self = (EmpathyContactChooser *)
- object;
-
- switch (param_id)
- {
- case PROP_TP_CHAT:
- g_value_set_object (value, self->priv->tp_chat);
- break;
- default:
- G_OBJECT_WARN_INVALID_PROPERTY_ID (object, param_id, pspec);
- break;
- };
-}
-
-static void
-contact_chooser_set_property (GObject *object,
- guint param_id,
- const GValue *value,
- GParamSpec *pspec)
-{
- EmpathyContactChooser *self = (EmpathyContactChooser *)
- object;
-
- switch (param_id)
- {
- case PROP_TP_CHAT:
- g_assert (self->priv->tp_chat == NULL); /* construct-only */
- self->priv->tp_chat = g_value_dup_object (value);
- break;
- default:
- G_OBJECT_WARN_INVALID_PROPERTY_ID (object, param_id, pspec);
- break;
- };
-}
-
struct _AddTemporaryIndividualCtx
{
EmpathyContactChooser *self;
@@ -139,7 +92,6 @@ contact_chooser_dispose (GObject *object)
tp_clear_pointer (&self->priv->add_temp_ctx,
add_temporary_individual_ctx_free);
- tp_clear_object (&self->priv->tp_chat);
tp_clear_object (&self->priv->store);
tp_clear_pointer (&self->priv->search_words, g_ptr_array_unref);
tp_clear_pointer (&self->priv->search_str, g_free);
@@ -156,19 +108,11 @@ empathy_contact_chooser_class_init (
{
GObjectClass *object_class = G_OBJECT_CLASS (klass);
- object_class->get_property = contact_chooser_get_property;
- object_class->set_property = contact_chooser_set_property;
object_class->dispose = contact_chooser_dispose;
g_type_class_add_private (object_class,
sizeof (EmpathyContactChooserPrivate));
- g_object_class_install_property (object_class,
- PROP_TP_CHAT,
- g_param_spec_object ("tp-chat", "EmpathyTpChat", "EmpathyTpChat",
- EMPATHY_TYPE_TP_CHAT,
- G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY | G_PARAM_STATIC_STRINGS));
-
signals[SIG_SELECTION_CHANGED] = g_signal_new ("selection-changed",
G_TYPE_FROM_CLASS (klass),
G_SIGNAL_RUN_LAST,
@@ -395,13 +339,10 @@ empathy_contact_chooser_init (EmpathyContactChooser *self)
}
GtkWidget *
-empathy_contact_chooser_new (EmpathyTpChat *tp_chat)
+empathy_contact_chooser_new (void)
{
- g_return_val_if_fail (EMPATHY_IS_TP_CHAT (tp_chat), NULL);
-
return g_object_new (EMPATHY_TYPE_CONTACT_CHOOSER,
"orientation", GTK_ORIENTATION_VERTICAL,
- "tp-chat", tp_chat,
NULL);
}