[empathy] Use its own ListStore of contacts instead of borrowing the Contact
- From: Pierre-Luc Beaudoin <plbeaudoin src gnome org>
- To: svn-commits-list gnome org
- Subject: [empathy] Use its own ListStore of contacts instead of borrowing the Contact
- Date: Wed, 27 May 2009 12:55:31 -0400 (EDT)
commit 4152e6dc08ea55434558e4b0105ec1df3628c4f8
Author: Pierre-Luc Beaudoin <pierre-luc pierlux com>
Date: Tue Apr 7 17:41:23 2009 -0400
Use its own ListStore of contacts instead of borrowing the Contact
List's
---
src/empathy-main-window.c | 2 +-
src/empathy-map-view.c | 8 +++++++-
src/empathy-map-view.h | 2 +-
3 files changed, 9 insertions(+), 3 deletions(-)
diff --git a/src/empathy-main-window.c b/src/empathy-main-window.c
index b214648..0ff054f 100644
--- a/src/empathy-main-window.c
+++ b/src/empathy-main-window.c
@@ -720,7 +720,7 @@ static void
main_window_view_show_map_cb (GtkCheckMenuItem *item,
EmpathyMainWindow *window)
{
- empathy_map_view_show (window->list_store);
+ empathy_map_view_show ();
}
#endif
diff --git a/src/empathy-map-view.c b/src/empathy-map-view.c
index a0ca3f5..dd9f00f 100644
--- a/src/empathy-map-view.c
+++ b/src/empathy-map-view.c
@@ -89,7 +89,7 @@ static gchar * get_dup_string (GHashTable *location, gchar *key);
// FIXME: Make it so that only one window can be shown
GtkWidget *
-empathy_map_view_show (EmpathyContactListStore *list_store)
+empathy_map_view_show ()
{
static EmpathyMapView *window = NULL;
GtkBuilder *gui;
@@ -97,6 +97,8 @@ empathy_map_view_show (EmpathyContactListStore *list_store)
GtkWidget *embed;
gchar *filename;
GtkTreeModel *model;
+ EmpathyContactList *list_iface;
+ EmpathyContactListStore *list_store;
/*
if (window)
@@ -121,6 +123,10 @@ empathy_map_view_show (EmpathyContactListStore *list_store)
g_object_unref (gui);
+ list_iface = EMPATHY_CONTACT_LIST (empathy_contact_manager_dup_singleton ());
+ list_store = empathy_contact_list_store_new (list_iface);
+ g_object_unref (list_iface);
+
window->list_store = list_store;
/* Set up map view */
diff --git a/src/empathy-map-view.h b/src/empathy-map-view.h
index bad93da..45ecbdd 100644
--- a/src/empathy-map-view.h
+++ b/src/empathy-map-view.h
@@ -26,7 +26,7 @@
G_BEGIN_DECLS
-GtkWidget *empathy_map_view_show (EmpathyContactListStore *list_store);
+GtkWidget *empathy_map_view_show (void);
G_END_DECLS
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]