Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add «Always expand description» in appearance settings, closes #1113 #2998

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -974,6 +974,11 @@ private void setHeightThumbnail() {

private void showContent() {
contentRootLayoutHiding.setVisibility(View.VISIBLE);
final boolean showDescriptionOnLoad = PreferenceManager.getDefaultSharedPreferences(activity)
.getBoolean(getString(R.string.always_expand_description_key), false);
if (showDescriptionOnLoad) {
toggleTitleAndDescription();
}
}

protected void setInitialData(int serviceId, String url, String name) {
Expand Down
2 changes: 1 addition & 1 deletion app/src/main/res/values/settings_keys.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1125,5 +1125,5 @@
<item>@string/list</item>
<item>@string/grid</item>
</string-array>

<string name="always_expand_description_key" translatable="false">always_expand_description</string>
</resources>
3 changes: 2 additions & 1 deletion app/src/main/res/values/strings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -644,4 +644,5 @@
<string name="feed_use_dedicated_fetch_method_enable_button">Enable fast mode</string>
<string name="feed_use_dedicated_fetch_method_disable_button">Disable fast mode</string>
<string name="feed_use_dedicated_fetch_method_help_text">Do you think feed loading is too slow? If so, try enabling fast loading (you can change it in settings or by pressing the button below).\n\nNewPipe offers two feed loading strategies:\n• Fetching the whole subscription channel, which is slow but complete.\n• Using a dedicated service endpoint, which is fast but usually not complete.\n\nThe difference between the two is that the fast one usually lacks some information, like the item\'s duration or type (can\'t distinguish between live videos and normal ones) and it may return less items.\n\nYouTube is an example of a service that offers this fast method with its RSS feed.\n\nSo the choice boils down to what you prefer: speed or precise information.</string>
</resources>
<string name="always_expand_description">Always expand description</string>
</resources>
5 changes: 5 additions & 0 deletions app/src/main/res/xml/appearance_settings.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,9 @@
android:title="@string/caption_setting_title"
android:summary="@string/caption_setting_description"/>

<SwitchPreference
app:iconSpaceReserved="false"
android:defaultValue="false"
android:key="@string/always_expand_description_key"
android:title="@string/always_expand_description"/>
</PreferenceScreen>