Browse Source

Layout fixes (mostly for tablets), rolled back recyclable

pull/24/head
Ezerous 8 years ago
parent
commit
cb0b6e1540
  1. 2
      app/src/main/java/gr/thmmy/mthmmy/activities/topic/TopicAdapter.java
  2. 34
      app/src/main/res/layout-sw600dp/activity_main.xml
  3. 2
      app/src/main/res/layout/activity_about.xml
  4. 4
      app/src/main/res/layout/activity_bookmark.xml
  5. 2
      app/src/main/res/layout/activity_downloads.xml
  6. 5
      app/src/main/res/layout/activity_topic.xml
  7. 2
      app/src/main/res/menu/topic_menu.xml

2
app/src/main/java/gr/thmmy/mthmmy/activities/topic/TopicAdapter.java

@ -178,8 +178,6 @@ class TopicAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder> {
final Post currentPost = postsList.get(position);
final PostViewHolder holder = (PostViewHolder) currentHolder;
holder.setIsRecyclable(false);
//Post's WebView parameters
holder.post.setClickable(true);
holder.post.setWebViewClient(new LinkLauncher());

34
app/src/main/res/layout-sw600dp/activity_main.xml

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="utf-8"?>
<android.support.design.widget.CoordinatorLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/main_content"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:fitsSystemWindows="true"
tools:context=".activities.main.MainActivity">
<android.support.design.widget.AppBarLayout
android:id="@+id/appbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:theme="@style/ToolbarTheme">
<android.support.design.widget.TabLayout
android:id="@+id/tabs"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:tabMaxWidth="0dp"
app:tabGravity="fill"
app:tabMode="fixed"
app:tabSelectedTextColor="@color/accent"
app:tabTextColor="@color/white"/>
</android.support.design.widget.AppBarLayout>
<android.support.v4.view.ViewPager
android:id="@+id/container"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior"/>
</android.support.design.widget.CoordinatorLayout>

2
app/src/main/res/layout/activity_about.xml

@ -30,7 +30,7 @@
android:id="@+id/scrollview"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="64dp"
app:layout_behavior="@string/appbar_scrolling_view_behavior"
android:background="@color/background">
<RelativeLayout

4
app/src/main/res/layout/activity_bookmark.xml

@ -30,9 +30,9 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="top|start"
android:layout_marginTop="64dp"
android:background="@color/background"
android:scrollbars="none">
android:scrollbars="none"
app:layout_behavior="@string/appbar_scrolling_view_behavior">
<LinearLayout
android:id="@+id/bookmarks_container"

2
app/src/main/res/layout/activity_downloads.xml

@ -30,9 +30,9 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="top|start"
android:layout_marginTop="64dp"
android:background="@color/background"
android:scrollbars="none"
app:layout_behavior="@string/appbar_scrolling_view_behavior"
tools:context="gr.thmmy.mthmmy.activities.downloads.DownloadsActivity">
</android.support.v7.widget.RecyclerView>

5
app/src/main/res/layout/activity_topic.xml

@ -37,12 +37,13 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_gravity="top|start"
android:layout_marginTop="64dp"
android:background="@color/background"
android:paddingTop="4dp"
android:paddingBottom="54dp"
android:clipToPadding="false"
android:scrollbars="none"
tools:context="gr.thmmy.mthmmy.activities.topic.TopicActivity">
tools:context="gr.thmmy.mthmmy.activities.topic.TopicActivity"
app:layout_behavior="@string/appbar_scrolling_view_behavior">
</android.support.v7.widget.RecyclerView>
<LinearLayout

2
app/src/main/res/menu/topic_menu.xml

@ -10,7 +10,7 @@
<item
android:id="@+id/menu_info"
android:icon="@drawable/ic_info"
app:showAsAction="ifRoom|withText"
app:showAsAction="ifRoom"
android:title="@string/info">
</item>
</menu>
Loading…
Cancel
Save