aboutsummaryrefslogtreecommitdiff
path: root/main/src
diff options
context:
space:
mode:
authorfiaxh <git@mx.ax.lt>2018-09-02 14:24:59 +0200
committerfiaxh <git@mx.ax.lt>2018-09-02 14:30:07 +0200
commit0f57191bea9e4bd44af36fafe22212e262ce8221 (patch)
tree568b8684d5b265955197bb1f0380752f32cbab9d /main/src
parentea7efd6399ec57bfaa9791fffc06e53a66cb2442 (diff)
downloaddino-0f57191bea9e4bd44af36fafe22212e262ce8221.tar.gz
dino-0f57191bea9e4bd44af36fafe22212e262ce8221.zip
Fix sent messages sometimes being displayed twice
Diffstat (limited to 'main/src')
-rw-r--r--main/src/ui/conversation_summary/content_populator.vala2
-rw-r--r--main/src/ui/global_search.vala6
2 files changed, 4 insertions, 4 deletions
diff --git a/main/src/ui/conversation_summary/content_populator.vala b/main/src/ui/conversation_summary/content_populator.vala
index 9ebb9159..c19d0d26 100644
--- a/main/src/ui/conversation_summary/content_populator.vala
+++ b/main/src/ui/conversation_summary/content_populator.vala
@@ -78,7 +78,7 @@ public class ContentMetaItem : Plugins.MetaConversationItem {
public ContentMetaItem(ContentItem content_item, ContentItemWidgetFactory widget_factory) {
this.jid = content_item.jid;
this.sort_time = content_item.sort_time;
- this.seccondary_sort_indicator = content_item.seccondary_sort_indicator;
+ this.seccondary_sort_indicator = content_item.id;
this.display_time = content_item.display_time;
this.encryption = content_item.encryption;
this.mark = content_item.mark;
diff --git a/main/src/ui/global_search.vala b/main/src/ui/global_search.vala
index eadf142c..82aac76a 100644
--- a/main/src/ui/global_search.vala
+++ b/main/src/ui/global_search.vala
@@ -160,7 +160,7 @@ class GlobalSearch : Overlay {
string display_name = Util.get_conversation_display_name(stream_interactor, item.conversation);
string title = item.message.type_ == Message.Type.GROUPCHAT ? _("In %s").printf(display_name) : _("With %s").printf(display_name);
- Box header_box = new Box(Orientation.HORIZONTAL, 10) { margin_left=7, visible=true };
+ Box header_box = new Box(Orientation.HORIZONTAL, 10) { margin_start=7, visible=true };
header_box.add(new Label(@"<b>$(Markup.escape_text(title))</b>") { ellipsize=EllipsizeMode.END, xalign=0, use_markup=true, visible=true });
header_box.add(date_label);
@@ -223,7 +223,7 @@ class GlobalSearch : Overlay {
private Grid get_context_message_widget(MessageItem item) {
Grid grid = get_skeleton(item);
- grid.margin_left = 7;
+ grid.margin_start = 7;
Label label = new Label(item.message.body.replace("\n", "").replace("\r", "")) { ellipsize=EllipsizeMode.MIDDLE, xalign=0, visible=true };
grid.attach(label, 1, 1, 1, 1);
grid.opacity = 0.55;
@@ -231,7 +231,7 @@ class GlobalSearch : Overlay {
}
private Grid get_skeleton(MessageItem item) {
- AvatarImage image = new AvatarImage() { height=32, width=32, margin_right=7, valign=Align.START, visible=true, allow_gray = false };
+ AvatarImage image = new AvatarImage() { height=32, width=32, margin_end=7, valign=Align.START, visible=true, allow_gray = false };
image.set_jid(stream_interactor, item.jid, item.message.account);
Grid grid = new Grid() { row_homogeneous=false, visible=true };
grid.attach(image, 0, 0, 1, 2);