diff options
author | Xavier Claessens <xclaesse@gmail.com> | 2007-06-04 04:49:53 +0800 |
---|---|---|
committer | Xavier Claessens <xclaesse@src.gnome.org> | 2007-06-04 04:49:53 +0800 |
commit | c982f4d2eb903359a5083e9466669413d5eaf938 (patch) | |
tree | bb3cae88434dfd209e95094e9396846c5d8782b1 | |
parent | 42a7605e5c217a051e83294e2ce732b45b0db8d2 (diff) | |
download | gsoc2013-empathy-c982f4d2eb903359a5083e9466669413d5eaf938.tar gsoc2013-empathy-c982f4d2eb903359a5083e9466669413d5eaf938.tar.gz gsoc2013-empathy-c982f4d2eb903359a5083e9466669413d5eaf938.tar.bz2 gsoc2013-empathy-c982f4d2eb903359a5083e9466669413d5eaf938.tar.lz gsoc2013-empathy-c982f4d2eb903359a5083e9466669413d5eaf938.tar.xz gsoc2013-empathy-c982f4d2eb903359a5083e9466669413d5eaf938.tar.zst gsoc2013-empathy-c982f4d2eb903359a5083e9466669413d5eaf938.zip |
Set use_stock for button_connect to False, to avoid a crasher when opening
2007-06-03 Xavier Claessens <xclaesse@gmail.com>
* libempathy-gtk/gossip-accounts-dialog.glade: Set use_stock for
button_connect to False, to avoid a crasher when opening the accounts
window with GTK+ trunk. Fixes bug #439931.
* libempathy-gtk/gossip-chat.c: Do not add backlog for chatrooms and
do not log backlog from jabber server.
svn path=/trunk/; revision=122
-rw-r--r-- | ChangeLog | 8 | ||||
-rw-r--r-- | libempathy-gtk/gossip-accounts-dialog.glade | 2 | ||||
-rw-r--r-- | libempathy-gtk/gossip-chat.c | 18 |
3 files changed, 24 insertions, 4 deletions
@@ -1,5 +1,13 @@ 2007-06-03 Xavier Claessens <xclaesse@gmail.com> + * libempathy-gtk/gossip-accounts-dialog.glade: Set use_stock for + button_connect to False, to avoid a crasher when opening the accounts + window with GTK+ trunk. Fixes bug #439931. + * libempathy-gtk/gossip-chat.c: Do not add backlog for chatrooms and + do not log backlog from jabber server. + +2007-06-03 Xavier Claessens <xclaesse@gmail.com> + * libempathy-gtk/gossip-ui-utils.c * libempathy-gtk/gossip-accounts-dialog.c * libempathy-gtk/Makefile.am diff --git a/libempathy-gtk/gossip-accounts-dialog.glade b/libempathy-gtk/gossip-accounts-dialog.glade index 58c94e694..05ba64f80 100644 --- a/libempathy-gtk/gossip-accounts-dialog.glade +++ b/libempathy-gtk/gossip-accounts-dialog.glade @@ -107,7 +107,7 @@ <property name="visible">True</property> <property name="can_focus">True</property> <property name="label">gtk-connect</property> - <property name="use_stock">True</property> + <property name="use_stock">False</property> <property name="relief">GTK_RELIEF_NORMAL</property> <property name="focus_on_click">True</property> </widget> diff --git a/libempathy-gtk/gossip-chat.c b/libempathy-gtk/gossip-chat.c index 5492edfbf..9658f56b8 100644 --- a/libempathy-gtk/gossip-chat.c +++ b/libempathy-gtk/gossip-chat.c @@ -77,6 +77,7 @@ struct _GossipChatPriv { GList *compositors; guint scroll_idle_id; gboolean first_tp_chat; + GossipTime time_joined; /* Used to automatically shrink a window that has temporarily * grown due to long input. */ @@ -401,6 +402,7 @@ chat_message_received_cb (EmpathyTpChat *tp_chat, { GossipChatPriv *priv; GossipContact *sender; + GossipTime timestamp; priv = GET_PRIV (chat); @@ -408,9 +410,13 @@ chat_message_received_cb (EmpathyTpChat *tp_chat, gossip_debug (DEBUG_DOMAIN, "Appending message ('%s')", gossip_contact_get_name (sender)); - empathy_log_manager_add_message (priv->log_manager, - gossip_chat_get_id (chat), - message); + /* Log the message only if it's not backlog */ + timestamp = gossip_message_get_timestamp (message); + if (timestamp >= priv->time_joined) { + empathy_log_manager_add_message (priv->log_manager, + gossip_chat_get_id (chat), + message); + } gossip_chat_view_append_message (chat->view, message); @@ -1095,6 +1101,11 @@ chat_add_logs (GossipChat *chat) priv = GET_PRIV (chat); + /* Do not display backlog for chatrooms */ + if (gossip_chat_is_group_chat (chat)) { + return; + } + /* Turn off scrolling temporarily */ gossip_chat_view_scroll (chat->view, FALSE); @@ -1308,6 +1319,7 @@ gossip_chat_set_tp_chat (GossipChat *chat, g_free (priv->id); priv->tp_chat = g_object_ref (tp_chat); priv->id = g_strdup (empathy_tp_chat_get_id (tp_chat)); + priv->time_joined = gossip_time_get_current (); if (priv->first_tp_chat) { chat_add_logs (chat); |