Improve posts appearance

This commit is contained in:
Pierre HUBERT 2018-08-27 18:24:26 +02:00
parent b95c040ff2
commit 2b999c63a8
3 changed files with 9 additions and 2 deletions

View File

@ -7,6 +7,7 @@ import android.content.DialogInterface;
import android.os.AsyncTask; import android.os.AsyncTask;
import android.os.Bundle; import android.os.Bundle;
import android.support.annotation.Nullable; import android.support.annotation.Nullable;
import android.support.v7.widget.DividerItemDecoration;
import android.support.v7.widget.LinearLayoutManager; import android.support.v7.widget.LinearLayoutManager;
import android.util.ArrayMap; import android.util.ArrayMap;
import android.util.Pair; import android.util.Pair;
@ -176,6 +177,8 @@ public class PostsListFragment extends Fragment
//Get the list view //Get the list view
mRecyclerView = view.findViewById(R.id.posts_list); mRecyclerView = view.findViewById(R.id.posts_list);
mRecyclerView.setOnScrollChangeDetectListener(this); mRecyclerView.setOnScrollChangeDetectListener(this);
mRecyclerView.addItemDecoration(new DividerItemDecoration(mRecyclerView.getContext(),
DividerItemDecoration.VERTICAL));
//Show the posts //Show the posts
show(); show();

View File

@ -56,6 +56,7 @@
style="@style/PostVisibility" style="@style/PostVisibility"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_gravity="top"
tools:text="Public" /> tools:text="Public" />
<ImageView <ImageView
@ -63,8 +64,8 @@
style="@style/PostActionsButton" style="@style/PostActionsButton"
android:layout_width="@dimen/post_options_btn_width" android:layout_width="@dimen/post_options_btn_width"
android:layout_height="@dimen/post_options_btn_height" android:layout_height="@dimen/post_options_btn_height"
android:contentDescription="@string/post_action_btn_description" android:layout_gravity="top"
android:src="@android:drawable/ic_menu_manage" /> android:contentDescription="@string/post_action_btn_description" />
</LinearLayout> </LinearLayout>

View File

@ -82,6 +82,9 @@
<style name="PostActionsButton"> <style name="PostActionsButton">
<item name="android:padding">2dp</item> <item name="android:padding">2dp</item>
<item name="android:layout_gravity">center</item> <item name="android:layout_gravity">center</item>
<item name="android:background">?selectableItemBackground</item>
<item name="android:src">@drawable/ic_more</item>
<item name="android:tint">@android:color/darker_gray</item>
</style> </style>
<!-- Post header --> <!-- Post header -->