*/
#include "config.h"
-
-#include <string.h>
-#include <stdlib.h>
+#include "empathy-log-window.h"
#include <glib/gi18n-lib.h>
-#include <gtk/gtk.h>
-#include <webkit/webkit.h>
-
-#include <telepathy-glib/telepathy-glib.h>
#include <telepathy-glib/proxy-subclass.h>
-#include <telepathy-logger/telepathy-logger.h>
-
-#include <extensions/extensions.h>
-
-#include <libempathy/action-chain-internal.h>
-#include <libempathy/empathy-camera-monitor.h>
-#include <libempathy/empathy-chatroom-manager.h>
-#include <libempathy/empathy-chatroom.h>
-#include <libempathy/empathy-gsettings.h>
-#include <libempathy/empathy-message.h>
-#include <libempathy/empathy-request-util.h>
-#include <libempathy/empathy-utils.h>
-#include <libempathy/empathy-time.h>
-
-#include "empathy-log-window.h"
+#include "action-chain-internal.h"
#include "empathy-account-chooser.h"
#include "empathy-call-utils.h"
-#include "empathy-individual-information-dialog.h"
+#include "empathy-camera-monitor.h"
+#include "empathy-geometry.h"
+#include "empathy-gsettings.h"
#include "empathy-images.h"
+#include "empathy-individual-information-dialog.h"
+#include "empathy-request-util.h"
#include "empathy-theme-manager.h"
#include "empathy-ui-utils.h"
+#include "empathy-utils.h"
#include "empathy-webkit-utils.h"
-#include "empathy-geometry.h"
+#include "extensions.h"
#define DEBUG_FLAG EMPATHY_DEBUG_OTHER
-#include <libempathy/empathy-debug.h>
+#include "empathy-debug.h"
#define EMPATHY_NS "http://live.gnome.org/Empathy"
GtkTreeStore *store = log_window->priv->store_events;
GtkTreeIter iter, parent;
gchar *pretty_date, *alias, *body;
+ gchar *msg_escaped;
GDateTime *date;
EmpathyStringParser *parsers;
GString *msg;
empathy_string_parser_substr (empathy_message_get_body (message), -1,
parsers, msg);
+ msg_escaped = g_strescape (msg->str, NULL);
+
if (tpl_text_event_get_message_type (TPL_TEXT_EVENT (event))
== TP_CHANNEL_TEXT_MESSAGE_TYPE_ACTION)
{
/* Translators: this is an emote: '* Danielle waves' */
- body = g_strdup_printf (_("<i>* %s %s</i>"), alias, msg->str);
+ body = g_strdup_printf (_("<i>* %s %s</i>"), alias, msg_escaped);
}
else
{
/* Translators: this is a message: 'Danielle: hello'
* The string in bold is the sender's name */
- body = g_strdup_printf (_("<b>%s:</b> %s"), alias, msg->str);
+ body = g_strdup_printf (_("<b>%s:</b> %s"), alias, msg_escaped);
}
+ g_free (msg_escaped);
+
gtk_tree_store_append (store, &iter, &parent);
gtk_tree_store_set (store, &iter,
COL_EVENTS_TS, tpl_event_get_timestamp (event),
GList *accounts, *l;
manager = empathy_account_chooser_get_account_manager (account_chooser);
- accounts = tp_account_manager_get_valid_accounts (manager);
+ accounts = tp_account_manager_dup_valid_accounts (manager);
for (l = accounts; l != NULL; l = l->next)
{
get_entities_for_account, ctx);
}
- g_list_free (accounts);
+ g_list_free_full (accounts, g_object_unref);
}
_tpl_action_chain_append (self->priv->chain, select_first_entity, self);
_tpl_action_chain_start (self->priv->chain);