feat(settings): invert post-divider setting
This commit is contained in:
@@ -31,7 +31,7 @@ public class GlobalUserPreferences{
|
||||
public static boolean alwaysExpandContentWarnings;
|
||||
public static boolean disableMarquee;
|
||||
public static boolean disableSwipe;
|
||||
public static boolean disableDividers;
|
||||
public static boolean showDividers;
|
||||
public static boolean voteButtonForSingleChoice;
|
||||
public static boolean uniformNotificationIcon;
|
||||
public static boolean enableDeleteNotifications;
|
||||
@@ -102,7 +102,7 @@ public class GlobalUserPreferences{
|
||||
alwaysExpandContentWarnings=prefs.getBoolean("alwaysExpandContentWarnings", false);
|
||||
disableMarquee=prefs.getBoolean("disableMarquee", false);
|
||||
disableSwipe=prefs.getBoolean("disableSwipe", false);
|
||||
disableDividers=prefs.getBoolean("disableDividers", true);
|
||||
showDividers =prefs.getBoolean("showDividers", true);
|
||||
relocatePublishButton=prefs.getBoolean("relocatePublishButton", true);
|
||||
voteButtonForSingleChoice=prefs.getBoolean("voteButtonForSingleChoice", true);
|
||||
enableDeleteNotifications=prefs.getBoolean("enableDeleteNotifications", false);
|
||||
@@ -163,7 +163,7 @@ public class GlobalUserPreferences{
|
||||
.putBoolean("alwaysExpandContentWarnings", alwaysExpandContentWarnings)
|
||||
.putBoolean("disableMarquee", disableMarquee)
|
||||
.putBoolean("disableSwipe", disableSwipe)
|
||||
.putBoolean("disableDividers", disableDividers)
|
||||
.putBoolean("showDividers", showDividers)
|
||||
.putBoolean("relocatePublishButton", relocatePublishButton)
|
||||
.putBoolean("uniformNotificationIcon", uniformNotificationIcon)
|
||||
.putBoolean("enableDeleteNotifications", enableDeleteNotifications)
|
||||
|
||||
@@ -763,7 +763,7 @@ public abstract class BaseStatusListFragment<T extends DisplayItemsParent> exten
|
||||
private int currentMediaHiddenLayoutsWidth=0;
|
||||
|
||||
{
|
||||
dividerPaint.setColor(UiUtils.getThemeColor(getActivity(), GlobalUserPreferences.disableDividers ? R.attr.colorWindowBackground : R.attr.colorPollVoted));
|
||||
dividerPaint.setColor(UiUtils.getThemeColor(getActivity(), GlobalUserPreferences.showDividers ? R.attr.colorPollVoted : R.attr.colorWindowBackground));
|
||||
dividerPaint.setStyle(Paint.Style.STROKE);
|
||||
dividerPaint.setStrokeWidth(V.dp(1));
|
||||
}
|
||||
|
||||
@@ -2,21 +2,14 @@ package org.joinmastodon.android.fragments.settings;
|
||||
|
||||
import android.view.Gravity;
|
||||
import android.view.MenuItem;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.Button;
|
||||
import android.widget.EditText;
|
||||
import android.widget.FrameLayout;
|
||||
import android.widget.PopupMenu;
|
||||
import android.widget.Toast;
|
||||
|
||||
import org.joinmastodon.android.GlobalUserPreferences;
|
||||
import org.joinmastodon.android.R;
|
||||
import org.joinmastodon.android.ui.M3AlertDialogBuilder;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import me.grishka.appkit.utils.V;
|
||||
|
||||
public class TimeLineFragment extends SettingsBaseFragment{
|
||||
|
||||
private SwitchItem showNewPostsButtonItem, compactReblogReplyLineItem;
|
||||
@@ -104,8 +97,8 @@ public class TimeLineFragment extends SettingsBaseFragment{
|
||||
GlobalUserPreferences.save();
|
||||
needAppRestart=true;
|
||||
}));
|
||||
items.add(new SwitchItem(R.string.mo_disable_dividers, R.drawable.ic_fluent_timeline_24_regular, GlobalUserPreferences.disableDividers, i->{
|
||||
GlobalUserPreferences.disableDividers=i.checked;
|
||||
items.add(new SwitchItem(R.string.mo_enable_dividers, R.drawable.ic_fluent_timeline_24_regular, GlobalUserPreferences.showDividers, i->{
|
||||
GlobalUserPreferences.showDividers =i.checked;
|
||||
GlobalUserPreferences.save();
|
||||
needAppRestart=true;
|
||||
}));
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
|
||||
<string name="mo_color_palette_nord">Nord</string>
|
||||
<string name="mo_app_username" translatable="false">\@moshidon</string>
|
||||
<string name="mo_disable_dividers">Disable post dividers</string>
|
||||
<string name="mo_enable_dividers">Show post dividers</string>
|
||||
<string name="mo_relocate_publish_button">Relocate publish button</string>
|
||||
<string name="mo_hide_compose_button_while_scrolling_setting">Hide compose button while scrolling</string>
|
||||
<string name="mo_welcome_text">To get started, please enter your home instance’s domain name below.</string>
|
||||
|
||||
Reference in New Issue
Block a user