]> git.0d.be Git - empathy.git/blobdiff - libempathy-gtk/empathy-chat.c
Merge branch 'people-nearby-fake-group-613558'
[empathy.git] / libempathy-gtk / empathy-chat.c
index edb2aabc36abd89731ad0c51b9636914afb65b28..36b4136ee40154d667c9c80c54c455b97c82fb79 100644 (file)
@@ -56,6 +56,7 @@
 #include "empathy-theme-manager.h"
 #include "empathy-smiley-manager.h"
 #include "empathy-ui-utils.h"
+#include "empathy-string-parser.h"
 
 #define DEBUG_FLAG EMPATHY_DEBUG_CHAT
 #include <libempathy/empathy-debug.h>
@@ -1212,7 +1213,12 @@ chat_property_changed_cb (EmpathyTpChat *tp_chat,
                if (EMP_STR_EMPTY (priv->subject)) {
                        gtk_widget_hide (priv->hbox_topic);
                } else {
-                       gtk_label_set_text (GTK_LABEL (priv->label_topic), priv->subject);
+                       gchar *markup_text;
+
+                       markup_text = empathy_add_link_markup (priv->subject);
+                       gtk_label_set_markup (GTK_LABEL (priv->label_topic), markup_text);
+                       g_free (markup_text);
+
                        gtk_widget_show (priv->hbox_topic);
                }
                if (priv->block_events_timeout_id == 0) {
@@ -1238,13 +1244,10 @@ static void
 chat_input_text_buffer_changed_cb (GtkTextBuffer *buffer,
                                    EmpathyChat    *chat)
 {
-       EmpathyChatPriv *priv;
        GtkTextIter     start, end;
        gchar          *str;
        gboolean        spell_checker = FALSE;
 
-       priv = GET_PRIV (chat);
-
        if (gtk_text_buffer_get_char_count (buffer) == 0) {
                chat_composing_stop (chat);
        } else {
@@ -1815,7 +1818,7 @@ got_filtered_messages_cb (GObject *manager,
        EmpathyChatPriv *priv = GET_PRIV (chat);
        GError *error = NULL;
 
-       messages = tpl_log_manager_async_operation_finish (result, &error);
+       messages = tpl_log_manager_get_filtered_messages_async_finish (result, &error);
 
        if (error != NULL) {
                DEBUG ("%s. Aborting.", error->message);
@@ -2249,9 +2252,9 @@ chat_create_ui (EmpathyChat *chat)
                          G_CALLBACK (chat_input_populate_popup_cb),
                          chat);
        buffer = gtk_text_view_get_buffer (GTK_TEXT_VIEW (chat->input_text_view));
-       g_signal_connect (buffer, "changed",
+       empathy_signal_connect_weak  (buffer, "changed",
                          G_CALLBACK (chat_input_text_buffer_changed_cb),
-                         chat);
+                         G_OBJECT (chat));
        gtk_text_buffer_create_tag (buffer, "misspelled",
                                    "underline", PANGO_UNDERLINE_ERROR,
                                    NULL);