aboutsummaryrefslogtreecommitdiffstats
path: root/libempathy
diff options
context:
space:
mode:
authorXavier Claessens <xclaesse@gmail.com>2007-06-14 21:04:45 +0800
committerXavier Claessens <xclaesse@src.gnome.org>2007-06-14 21:04:45 +0800
commit9dc3fd8854b3f9255ba8ab5aceca30f6d12b61e4 (patch)
treea2a12eac4237cb0b5ee1d330f91a3e9458ba788e /libempathy
parent92b095154e6c804d2d7138689629f32856eddd15 (diff)
downloadgsoc2013-empathy-9dc3fd8854b3f9255ba8ab5aceca30f6d12b61e4.tar
gsoc2013-empathy-9dc3fd8854b3f9255ba8ab5aceca30f6d12b61e4.tar.gz
gsoc2013-empathy-9dc3fd8854b3f9255ba8ab5aceca30f6d12b61e4.tar.bz2
gsoc2013-empathy-9dc3fd8854b3f9255ba8ab5aceca30f6d12b61e4.tar.lz
gsoc2013-empathy-9dc3fd8854b3f9255ba8ab5aceca30f6d12b61e4.tar.xz
gsoc2013-empathy-9dc3fd8854b3f9255ba8ab5aceca30f6d12b61e4.tar.zst
gsoc2013-empathy-9dc3fd8854b3f9255ba8ab5aceca30f6d12b61e4.zip
Empathy is no more splitted into 2 processes. It makes debugging more
2007-06-14 Xavier Claessens <xclaesse@gmail.com> * src/org.gnome.Empathy.Chat.service.in: * src/empathy-accounts.c: * src/empathy-accounts-main.c: * src/empathy-chat-main.c: * src/empathy.c: * src/Makefile.am: * src/empathy-main.c: * libempathy/gossip-chatroom-manager.c: * autogen.sh: Empathy is no more splitted into 2 processes. It makes debugging more difficult when emmpathy-chat crashes. It's also more optimised like that since contact objects can be shared. svn path=/trunk/; revision=154
Diffstat (limited to 'libempathy')
-rw-r--r--libempathy/gossip-chatroom-manager.c52
1 files changed, 0 insertions, 52 deletions
diff --git a/libempathy/gossip-chatroom-manager.c b/libempathy/gossip-chatroom-manager.c
index f85d5407e..cc6aa81ad 100644
--- a/libempathy/gossip-chatroom-manager.c
+++ b/libempathy/gossip-chatroom-manager.c
@@ -31,8 +31,6 @@
#include <libxml/parser.h>
#include <libxml/tree.h>
-#include <libgnomevfs/gnome-vfs.h>
-
#include "gossip-debug.h"
#include "gossip-chatroom-manager.h"
#include "gossip-utils.h"
@@ -46,18 +44,12 @@
struct _GossipChatroomManagerPriv {
GList *chatrooms;
- GHashTable *monitors;
};
static void gossip_chatroom_manager_class_init (GossipChatroomManagerClass *klass);
static void gossip_chatroom_manager_init (GossipChatroomManager *manager);
static void chatroom_manager_finalize (GObject *object);
static gboolean chatroom_manager_get_all (GossipChatroomManager *manager);
-static void chatroom_manager_file_changed_cb (GnomeVFSMonitorHandle *handle,
- const gchar *monitor_uri,
- const gchar *info_uri,
- GnomeVFSMonitorEventType event_type,
- GossipChatroomManager *manager);
static gboolean chatroom_manager_file_parse (GossipChatroomManager *manager,
const gchar *filename);
static void chatroom_manager_parse_chatroom (GossipChatroomManager *manager,
@@ -110,11 +102,6 @@ gossip_chatroom_manager_init (GossipChatroomManager *manager)
GossipChatroomManagerPriv *priv;
priv = GET_PRIV (manager);
-
- priv->monitors = g_hash_table_new_full (g_str_hash,
- g_str_equal,
- (GDestroyNotify) g_free,
- (GDestroyNotify) gnome_vfs_monitor_cancel);
}
static void
@@ -126,7 +113,6 @@ chatroom_manager_finalize (GObject *object)
g_list_foreach (priv->chatrooms, (GFunc) g_object_unref, NULL);
g_list_free (priv->chatrooms);
- g_hash_table_destroy (priv->monitors);
(G_OBJECT_CLASS (gossip_chatroom_manager_parent_class)->finalize) (object);
}
@@ -340,31 +326,6 @@ chatroom_manager_get_all (GossipChatroomManager *manager)
return TRUE;
}
-static void
-chatroom_manager_file_changed_cb (GnomeVFSMonitorHandle *handle,
- const gchar *monitor_uri,
- const gchar *info_uri,
- GnomeVFSMonitorEventType event_type,
- GossipChatroomManager *manager)
-{
- GossipChatroomManagerPriv *priv;
- GList *l;
-
- priv = GET_PRIV (manager);
-
- gossip_debug (DEBUG_DOMAIN, "Reload file: %s", monitor_uri);
-
- /* FIXME: This is not optimised */
- for (l = priv->chatrooms; l; l = l->next) {
- g_signal_emit (manager, signals[CHATROOM_REMOVED], 0, l->data);
- g_object_unref (l->data);
- }
- g_list_free (priv->chatrooms);
- priv->chatrooms = NULL;
-
- chatroom_manager_get_all (manager);
-}
-
static gboolean
chatroom_manager_file_parse (GossipChatroomManager *manager,
const gchar *filename)
@@ -377,19 +338,6 @@ chatroom_manager_file_parse (GossipChatroomManager *manager,
priv = GET_PRIV (manager);
- /* Do not monitor this file twice if it's already monitored */
- if (!g_hash_table_lookup (priv->monitors, filename)) {
- GnomeVFSMonitorHandle *handle;
-
- gnome_vfs_monitor_add (&handle,
- filename,
- GNOME_VFS_MONITOR_FILE,
- (GnomeVFSMonitorCallback) chatroom_manager_file_changed_cb,
- manager);
-
- g_hash_table_insert (priv->monitors, g_strdup (filename), handle);
- }
-
gossip_debug (DEBUG_DOMAIN, "Attempting to parse file:'%s'...", filename);
ctxt = xmlNewParserCtxt ();