aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorPierre-Luc Beaudoin <pierre-luc@pierlux.com>2009-05-27 08:44:25 +0800
committerPierre-Luc Beaudoin <pierre-luc@pierlux.com>2009-05-28 00:52:10 +0800
commita6727eb14a19681c1839e9aacf9abcb139ceb268 (patch)
treeed51d19eac51aafd793b3b70165faf0bd06b84a5 /src
parentd13ba3658eded1649daff133cb04c76f6e3a906b (diff)
downloadgsoc2013-empathy-a6727eb14a19681c1839e9aacf9abcb139ceb268.tar
gsoc2013-empathy-a6727eb14a19681c1839e9aacf9abcb139ceb268.tar.gz
gsoc2013-empathy-a6727eb14a19681c1839e9aacf9abcb139ceb268.tar.bz2
gsoc2013-empathy-a6727eb14a19681c1839e9aacf9abcb139ceb268.tar.lz
gsoc2013-empathy-a6727eb14a19681c1839e9aacf9abcb139ceb268.tar.xz
gsoc2013-empathy-a6727eb14a19681c1839e9aacf9abcb139ceb268.tar.zst
gsoc2013-empathy-a6727eb14a19681c1839e9aacf9abcb139ceb268.zip
Use the layer to list the markers
There was no need to add an extra list as the layer already has a list of the markers.
Diffstat (limited to 'src')
-rw-r--r--src/empathy-map-view.c10
1 files changed, 3 insertions, 7 deletions
diff --git a/src/empathy-map-view.c b/src/empathy-map-view.c
index c55e5c73a..b8a32885c 100644
--- a/src/empathy-map-view.c
+++ b/src/empathy-map-view.c
@@ -52,7 +52,6 @@ typedef struct {
GtkWidget *zoom_out;
ChamplainView *map_view;
ChamplainLayer *layer;
- GSList *notify_handles;
} EmpathyMapView;
static void map_view_destroy_cb (GtkWidget *widget,
@@ -144,9 +143,9 @@ static void
map_view_destroy_cb (GtkWidget *widget,
EmpathyMapView *window)
{
- GSList *item;
+ GList *item;
- item = window->notify_handles;
+ item = clutter_container_get_children (window->layer);
while (item != NULL)
{
EmpathyContact *contact;
@@ -155,9 +154,8 @@ map_view_destroy_cb (GtkWidget *widget,
marker = CHAMPLAIN_MARKER (item->data);
contact = g_object_get_data (G_OBJECT (marker), "contact");
g_signal_handlers_disconnect_by_func (contact, map_view_contact_location_notify, marker);
- g_object_unref (marker);
- item = g_slist_next (item);
+ item = g_list_next (item);
}
g_object_unref (window->list_store);
@@ -276,8 +274,6 @@ map_view_contacts_foreach (GtkTreeModel *model,
g_signal_connect (contact, "notify::location",
G_CALLBACK (map_view_contact_location_notify), marker);
g_object_set_data_full (G_OBJECT (marker), "contact", g_object_ref (contact), g_object_unref);
- window->notify_handles = g_slist_append (window->notify_handles,
- g_object_ref (marker));
map_view_marker_update_position (CHAMPLAIN_MARKER (marker), contact);