remove drawer in headlines_articles on phones

This commit is contained in:
Andrew Dolgov 2014-11-01 09:23:20 +03:00
parent 66906beace
commit 081b98e9c0
4 changed files with 16 additions and 34 deletions

View File

@ -1,8 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.fox.ttrss"
android:versionCode="254"
android:versionName="1.51" >
android:versionCode="255"
android:versionName="1.52" >
<uses-sdk
android:minSdkVersion="9"

View File

@ -768,7 +768,7 @@ public class HeadlinesFragment extends Fragment implements OnItemClickListener,
String articleContent = article.content != null ? article.content : "";
if (holder.excerptView != null) {
if ((m_compactLayoutMode && m_activity.isSmallScreen()) || !m_prefs.getBoolean("headlines_show_content", true)) {
if (!m_prefs.getBoolean("headlines_show_content", true)) {
holder.excerptView.setVisibility(View.GONE);
} else {
String excerpt = Jsoup.parse(articleContent).text();
@ -966,12 +966,6 @@ public class HeadlinesFragment extends Fragment implements OnItemClickListener,
});
}
if (m_compactLayoutMode && m_activity.isSmallScreen()) {
if (holder.headlineFooter != null) {
holder.headlineFooter.setVisibility(View.GONE);
}
}
return v;
}

View File

@ -592,7 +592,7 @@ public class OfflineHeadlinesFragment extends Fragment implements OnItemClickLis
TextView te = (TextView)v.findViewById(R.id.excerpt);
if (te != null) {
if ((m_compactLayoutMode && m_activity.isSmallScreen()) || !m_prefs.getBoolean("headlines_show_content", true)) {
if (!m_prefs.getBoolean("headlines_show_content", true)) {
te.setVisibility(View.GONE);
} else {
String excerpt = Jsoup.parse(article.getString(article.getColumnIndex("content"))).text();
@ -684,12 +684,6 @@ public class OfflineHeadlinesFragment extends Fragment implements OnItemClickLis
});
}
View headlineFooter = v.findViewById(R.id.headline_footer);
if (headlineFooter != null && m_compactLayoutMode && m_activity.isSmallScreen()) {
headlineFooter.setVisibility(View.GONE);
}
return v;
}

View File

@ -4,25 +4,19 @@
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<android.support.v4.widget.DrawerLayout
android:id="@+id/headlines_drawer"
<FrameLayout
android:id="@+id/article_fragment"
android:layout_width="match_parent"
android:layout_height="match_parent">
android:layout_height="match_parent"
android:background="?articleBackground">
</FrameLayout>
<FrameLayout
android:id="@+id/article_fragment"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="?articleBackground">
</FrameLayout>
<FrameLayout
android:id="@+id/headlines_fragment"
android:layout_height="match_parent"
android:layout_width="240dp"
android:layout_gravity="start"
android:background="?headlinesBackgroundSolid">
</FrameLayout>
</android.support.v4.widget.DrawerLayout>
<FrameLayout
android:id="@+id/headlines_fragment"
android:visibility="gone"
android:layout_height="0dp"
android:layout_width="0dp"
android:background="?headlinesBackgroundSolid">
</FrameLayout>
</FrameLayout>