Ampersands no longer break everything
This commit is contained in:
parent
d20ce27a5d
commit
5ea88fd8c9
|
@ -25,5 +25,9 @@ public class Tootle.Utils{
|
|||
|
||||
return simplified;
|
||||
}
|
||||
|
||||
public static string escape_entities (string content) {
|
||||
return content.replace ("&", "&");
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -138,7 +138,7 @@ public class Tootle.AccountView : TimelineView {
|
|||
}
|
||||
|
||||
public void rebind (){
|
||||
display_name.label = "<b>%s</b>".printf (account.display_name);
|
||||
display_name.label = "<b>%s</b>".printf (Utils.escape_entities(account.display_name));
|
||||
username.label = "@" + account.acct;
|
||||
note.label = Utils.simplify_html (account.note);
|
||||
button_follow.visible = !account.is_self ();
|
||||
|
|
|
@ -192,7 +192,7 @@ public class Tootle.StatusWidget : Gtk.EventBox {
|
|||
public void rebind () {
|
||||
var formal = status.get_formal ();
|
||||
|
||||
title_user.label = "<b>%s</b>".printf (formal.account.display_name);
|
||||
title_user.label = "<b>%s</b>".printf (Utils.escape_entities (formal.account.display_name));
|
||||
title_acct.label = "@" + formal.account.acct;
|
||||
content_label.label = formal.content;
|
||||
content_label.mentions = formal.mentions;
|
||||
|
@ -224,10 +224,10 @@ public class Tootle.StatusWidget : Gtk.EventBox {
|
|||
}
|
||||
|
||||
private GLib.DateTime? parse_date_iso8601 (string date) {
|
||||
var timeval = GLib.TimeVal();
|
||||
if (timeval.from_iso8601 (date)) {
|
||||
var timeval = GLib.TimeVal ();
|
||||
if (timeval.from_iso8601 (date))
|
||||
return new GLib.DateTime.from_timeval_local (timeval);
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue