diff --git a/News-Android-App/src/main/java/de/luhmer/owncloudnewsreader/NewsReaderListActivity.java b/News-Android-App/src/main/java/de/luhmer/owncloudnewsreader/NewsReaderListActivity.java
index 3b2405803..945b45fd7 100644
--- a/News-Android-App/src/main/java/de/luhmer/owncloudnewsreader/NewsReaderListActivity.java
+++ b/News-Android-App/src/main/java/de/luhmer/owncloudnewsreader/NewsReaderListActivity.java
@@ -1189,7 +1189,13 @@ private void updateListView() {
@Override
public void onClick(RssItemViewHolder vh, int position) {
Feed feed = vh.getRssItem().getFeed();
- Long openIn = feed.getOpenIn();
+
+ // check @NewsReadListDialogFragment
+ // open feed in means:
+ // 1: openInDetailedView
+ // 2: openInBrowserCct
+ // 3: openInBrowserExternal
+ Long openIn = feed.getOpenIn();
Uri currentUrl = Uri.parse(vh.getRssItem().getLink());
@@ -1199,14 +1205,9 @@ public void onClick(RssItemViewHolder vh, int position) {
//Choose Browser based on user settings
//modified copy from NewsDetailFragment.java:loadUrl(String url)
int selectedBrowser = Integer.parseInt(mPrefs.getString(SettingsActivity.SP_DISPLAY_BROWSER, "0"));
- switch(selectedBrowser) {
- case 0:
- case 2:
- openRssItemInCustomTab(currentUrl);
- break;
- case 1:
- openRssItemInExternalBrowser(currentUrl);
- break;
+ switch (selectedBrowser) {
+ case 0, 2 -> openRssItemInCustomTab(currentUrl);
+ case 1 -> openRssItemInExternalBrowser(currentUrl);
}
((NewsListRecyclerAdapter) getNewsReaderDetailFragment().getRecyclerView().getAdapter()).changeReadStateOfItem(vh, true);
@@ -1215,17 +1216,11 @@ public void onClick(RssItemViewHolder vh, int position) {
}
} else {
switch (openIn.intValue()) {
- case 1:
- openRssItemInDetailedView(position);
- break;
- case 2:
- openRssItemInCustomTab(currentUrl);
- break;
- case 3:
- openRssItemInExternalBrowser(currentUrl);
- break;
- default:
- throw new RuntimeException("Unreachable: openIn has illegal value " + openIn);
+ case 1 -> openRssItemInDetailedView(position);
+ case 2 -> openRssItemInCustomTab(currentUrl);
+ case 3 -> openRssItemInExternalBrowser(currentUrl);
+ default ->
+ throw new RuntimeException("Unreachable: openIn has illegal value " + openIn);
}
}
}
diff --git a/News-Android-App/src/main/res/values/strings.xml b/News-Android-App/src/main/res/values/strings.xml
index f180a0252..bda5456c9 100644
--- a/News-Android-App/src/main/res/values/strings.xml
+++ b/News-Android-App/src/main/res/values/strings.xml
@@ -307,13 +307,13 @@
- @string/pref_display_browser_cct
- - @string/pref_display_browser_built_in
- @string/pref_display_browser_external
+ - @string/pref_display_browser_built_in
- 0
- - 2
- 1
+ - 2
Thumbnails (only Headlines)