add option to always expand content warnings (#1422)
This commit is contained in:
parent
588775ff9b
commit
8834c22120
13 changed files with 742 additions and 210 deletions
|
|
@ -166,6 +166,7 @@ public class TimelineFragment extends SFragment implements
|
|||
|
||||
private boolean didLoadEverythingBottom;
|
||||
private boolean alwaysShowSensitiveMedia;
|
||||
private boolean alwaysOpenSpoiler;
|
||||
private boolean initialUpdateFailed = false;
|
||||
|
||||
private PairedList<Either<Placeholder, Status>, StatusViewData> statuses =
|
||||
|
|
@ -176,7 +177,8 @@ public class TimelineFragment extends SFragment implements
|
|||
if (status != null) {
|
||||
return ViewDataUtils.statusToViewData(
|
||||
status,
|
||||
alwaysShowSensitiveMedia
|
||||
alwaysShowSensitiveMedia,
|
||||
alwaysOpenSpoiler
|
||||
);
|
||||
} else {
|
||||
Placeholder placeholder = input.asLeft();
|
||||
|
|
@ -340,6 +342,7 @@ public class TimelineFragment extends SFragment implements
|
|||
private void setupTimelinePreferences() {
|
||||
SharedPreferences preferences = PreferenceManager.getDefaultSharedPreferences(getActivity());
|
||||
alwaysShowSensitiveMedia = accountManager.getActiveAccount().getAlwaysShowSensitiveMedia();
|
||||
alwaysOpenSpoiler = accountManager.getActiveAccount().getAlwaysOpenSpoiler();
|
||||
boolean mediaPreviewEnabled = accountManager.getActiveAccount().getMediaPreviewEnabled();
|
||||
adapter.setMediaPreviewEnabled(mediaPreviewEnabled);
|
||||
boolean useAbsoluteTime = preferences.getBoolean("absoluteTimeView", false);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue