2022-11-13 20:57:43 +00:00
|
|
|
public class Tooth.API.Mention : Entity, Widgetizable {
|
2018-04-28 16:27:10 +00:00
|
|
|
|
2020-06-20 10:04:58 +00:00
|
|
|
public string id { get; construct set; }
|
2020-05-29 12:19:35 +00:00
|
|
|
public string username { get; construct set; }
|
|
|
|
public string acct { get; construct set; }
|
|
|
|
public string url { get; construct set; }
|
|
|
|
|
2020-09-05 08:02:42 +00:00
|
|
|
public string handle {
|
|
|
|
owned get {
|
|
|
|
return "@" + acct;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2020-06-20 10:04:58 +00:00
|
|
|
public Mention.from_account (API.Account account) {
|
2020-05-29 12:19:35 +00:00
|
|
|
Object (
|
|
|
|
id: account.id,
|
|
|
|
username: account.username,
|
|
|
|
acct: account.acct,
|
|
|
|
url: account.url
|
|
|
|
);
|
2018-04-28 16:27:10 +00:00
|
|
|
}
|
2019-03-11 14:14:37 +00:00
|
|
|
|
2020-08-01 15:40:56 +00:00
|
|
|
public override void open () {
|
|
|
|
Views.Profile.open_from_id (id);
|
|
|
|
}
|
|
|
|
|
2018-04-28 16:27:10 +00:00
|
|
|
}
|