diff options
author | bobufa <bobufa@users.noreply.github.com> | 2018-06-23 11:59:21 +0200 |
---|---|---|
committer | bobufa <bobufa@users.noreply.github.com> | 2018-08-13 22:05:04 +0200 |
commit | 760fd4cb26340165fb85c2e3aee8390e46dc8b63 (patch) | |
tree | e68f93a234680b4d84fd79b02cd27c6f1b058077 /main/src/ui/conversation_summary/content_populator.vala | |
parent | 443e7ee49da305a9ae8052c5b7a73412d03ce75f (diff) | |
download | dino-760fd4cb26340165fb85c2e3aee8390e46dc8b63.tar.gz dino-760fd4cb26340165fb85c2e3aee8390e46dc8b63.zip |
load+display later messages when scrolling down
Diffstat (limited to 'main/src/ui/conversation_summary/content_populator.vala')
-rw-r--r-- | main/src/ui/conversation_summary/content_populator.vala | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/main/src/ui/conversation_summary/content_populator.vala b/main/src/ui/conversation_summary/content_populator.vala index 9fb83419..cec54c7b 100644 --- a/main/src/ui/conversation_summary/content_populator.vala +++ b/main/src/ui/conversation_summary/content_populator.vala @@ -53,6 +53,18 @@ public class ContentProvider : ContentItemCollection, Object { } return ret; } + + public Gee.List<ContentMetaItem> populate_after(Conversation conversation, Plugins.MetaConversationItem before_item, int n) { + Gee.List<ContentMetaItem> ret = new ArrayList<ContentMetaItem>(); + ContentMetaItem? content_meta_item = before_item as ContentMetaItem; + if (content_meta_item != null) { + Gee.List<ContentItem> items = stream_interactor.get_module(ContentItemAccumulator.IDENTITY).populate_after(this, conversation, content_meta_item.content_item, n); + foreach (ContentItem item in items) { + ret.add(new ContentMetaItem(item, widget_factory)); + } + } + return ret; + } } public class ContentMetaItem : Plugins.MetaConversationItem { |