mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-12 10:49:06 +01:00
Extend BlogActivity to also show individual posts
This allows for swiping left/right to read other posts by using a ViewPager. This hasn't been done as a separate activity, but with fragments, so both can share the `BlogPersistentData` without needing to reload it. Closes #428
This commit is contained in:
@@ -0,0 +1,29 @@
|
||||
package org.briarproject.android.blogs;
|
||||
|
||||
import android.support.annotation.Nullable;
|
||||
|
||||
import org.briarproject.android.controller.ActivityLifecycleController;
|
||||
import org.briarproject.android.controller.handler.UiResultHandler;
|
||||
import org.briarproject.api.sync.GroupId;
|
||||
import org.briarproject.api.sync.MessageId;
|
||||
|
||||
import java.util.TreeSet;
|
||||
|
||||
public interface BlogController extends ActivityLifecycleController {
|
||||
|
||||
void loadBlog(final GroupId groupId, final boolean reload,
|
||||
final UiResultHandler<Boolean> resultHandler);
|
||||
|
||||
TreeSet<BlogPostItem> getBlogPosts();
|
||||
|
||||
@Nullable
|
||||
BlogPostItem getBlogPost(MessageId postId);
|
||||
|
||||
@Nullable
|
||||
MessageId getBlogPostId(int position);
|
||||
|
||||
interface BlogPostListener {
|
||||
void onBlogPostAdded(final BlogPostItem post, final boolean local);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user