add offline_sort_by_feed
This commit is contained in:
parent
b096bd3389
commit
efbcbe7b89
|
@ -1,8 +1,8 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
package="org.fox.ttrss"
|
package="org.fox.ttrss"
|
||||||
android:versionCode="422"
|
android:versionCode="423"
|
||||||
android:versionName="1.188" >
|
android:versionName="1.189" >
|
||||||
|
|
||||||
<uses-permission android:name="android.permission.INTERNET" />
|
<uses-permission android:name="android.permission.INTERNET" />
|
||||||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
||||||
|
|
|
@ -116,6 +116,10 @@ public class OfflineHeadlinesFragment extends Fragment implements OnItemClickLis
|
||||||
menu.findItem(R.id.article_set_note).setVisible(false);
|
menu.findItem(R.id.article_set_note).setVisible(false);
|
||||||
menu.findItem(R.id.headlines_article_unread).setVisible(false); // TODO: implement
|
menu.findItem(R.id.headlines_article_unread).setVisible(false); // TODO: implement
|
||||||
|
|
||||||
|
if (m_prefs.getBoolean("offline_sort_by_feed", false)) {
|
||||||
|
menu.findItem(R.id.catchup_above).setVisible(false);
|
||||||
|
}
|
||||||
|
|
||||||
super.onCreateContextMenu(menu, v, menuInfo);
|
super.onCreateContextMenu(menu, v, menuInfo);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -361,7 +365,11 @@ public class OfflineHeadlinesFragment extends Fragment implements OnItemClickLis
|
||||||
}
|
}
|
||||||
|
|
||||||
String orderBy = (m_prefs.getBoolean("offline_oldest_first", false)) ? "updated" : "updated DESC";
|
String orderBy = (m_prefs.getBoolean("offline_oldest_first", false)) ? "updated" : "updated DESC";
|
||||||
|
|
||||||
|
if (m_prefs.getBoolean("offline_sort_by_feed", false)) {
|
||||||
|
orderBy = "feed_title, " + orderBy;
|
||||||
|
}
|
||||||
|
|
||||||
if (m_searchQuery == null || m_searchQuery.equals("")) {
|
if (m_searchQuery == null || m_searchQuery.equals("")) {
|
||||||
return m_activity.getDatabase().query("articles LEFT JOIN feeds ON (feed_id = feeds."+BaseColumns._ID+")",
|
return m_activity.getDatabase().query("articles LEFT JOIN feeds ON (feed_id = feeds."+BaseColumns._ID+")",
|
||||||
new String[] { "articles.*", "feeds.title AS feed_title" }, feedClause,
|
new String[] { "articles.*", "feeds.title AS feed_title" }, feedClause,
|
||||||
|
|
|
@ -254,4 +254,5 @@
|
||||||
<string name="widget_background_transparent">Transparent</string>
|
<string name="widget_background_transparent">Transparent</string>
|
||||||
<string name="pref_widget_background">Background color</string>
|
<string name="pref_widget_background">Background color</string>
|
||||||
<string name="pref_widget_update_interval_summary">This interval is imprecise due to Android limitations</string>
|
<string name="pref_widget_update_interval_summary">This interval is imprecise due to Android limitations</string>
|
||||||
|
<string name="prefs_offline_sort_by_feed">Group headlines by feeds</string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|
|
@ -182,6 +182,11 @@
|
||||||
android:summary="@string/offline_articles_to_download_long"
|
android:summary="@string/offline_articles_to_download_long"
|
||||||
android:title="@string/offline_articles_to_download" />
|
android:title="@string/offline_articles_to_download" />
|
||||||
|
|
||||||
|
<org.fox.ttrss.util.LessBrokenSwitchPreference
|
||||||
|
android:defaultValue="false"
|
||||||
|
android:key="offline_sort_by_feed"
|
||||||
|
android:title="@string/prefs_offline_sort_by_feed" />
|
||||||
|
|
||||||
<org.fox.ttrss.util.LessBrokenSwitchPreference
|
<org.fox.ttrss.util.LessBrokenSwitchPreference
|
||||||
android:defaultValue="false"
|
android:defaultValue="false"
|
||||||
android:key="offline_image_cache_enabled"
|
android:key="offline_image_cache_enabled"
|
||||||
|
|
Loading…
Reference in New Issue
Block a user