chore(merge-upstream): still 21 things to do
This commit is contained in:
@@ -50,6 +50,7 @@ public class AccountLocalPreferences{
|
|||||||
public ShowEmojiReactions showEmojiReactions;
|
public ShowEmojiReactions showEmojiReactions;
|
||||||
public ColorPreference color;
|
public ColorPreference color;
|
||||||
public ArrayList<Emoji> recentCustomEmoji;
|
public ArrayList<Emoji> recentCustomEmoji;
|
||||||
|
public boolean preReplySheet;
|
||||||
|
|
||||||
private final static Type recentLanguagesType=new TypeToken<ArrayList<String>>() {}.getType();
|
private final static Type recentLanguagesType=new TypeToken<ArrayList<String>>() {}.getType();
|
||||||
private final static Type timelinesType=new TypeToken<ArrayList<TimelineDefinition>>() {}.getType();
|
private final static Type timelinesType=new TypeToken<ArrayList<TimelineDefinition>>() {}.getType();
|
||||||
@@ -68,6 +69,7 @@ public class AccountLocalPreferences{
|
|||||||
revealCWs=prefs.getBoolean("revealCWs", false);
|
revealCWs=prefs.getBoolean("revealCWs", false);
|
||||||
hideSensitiveMedia=prefs.getBoolean("hideSensitive", true);
|
hideSensitiveMedia=prefs.getBoolean("hideSensitive", true);
|
||||||
serverSideFiltersSupported=prefs.getBoolean("serverSideFilters", false);
|
serverSideFiltersSupported=prefs.getBoolean("serverSideFilters", false);
|
||||||
|
// preReplySheet=prefs.getBoolean("preReplySheet", false);
|
||||||
|
|
||||||
// MEGALODON
|
// MEGALODON
|
||||||
showReplies=prefs.getBoolean("showReplies", true);
|
showReplies=prefs.getBoolean("showReplies", true);
|
||||||
@@ -112,6 +114,9 @@ public class AccountLocalPreferences{
|
|||||||
.putBoolean("hideSensitive", hideSensitiveMedia)
|
.putBoolean("hideSensitive", hideSensitiveMedia)
|
||||||
.putBoolean("serverSideFilters", serverSideFiltersSupported)
|
.putBoolean("serverSideFilters", serverSideFiltersSupported)
|
||||||
|
|
||||||
|
//TODO figure this stuff out
|
||||||
|
// .putBoolean("preReplySheet", preReplySheet)
|
||||||
|
|
||||||
// MEGALODON
|
// MEGALODON
|
||||||
.putBoolean("showReplies", showReplies)
|
.putBoolean("showReplies", showReplies)
|
||||||
.putBoolean("showBoosts", showBoosts)
|
.putBoolean("showBoosts", showBoosts)
|
||||||
@@ -169,4 +174,9 @@ public class AccountLocalPreferences{
|
|||||||
ONLY_OPENED,
|
ONLY_OPENED,
|
||||||
ALWAYS
|
ALWAYS
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// public enum PreReplySheetType{
|
||||||
|
// OLD_POST,
|
||||||
|
// NON_MUTUAL
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1079,23 +1079,27 @@ public abstract class BaseStatusListFragment<T extends DisplayItemsParent> exten
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void maybeShowPreReplySheet(Status status, Runnable proceed){
|
public void maybeShowPreReplySheet(Status status, Runnable proceed){
|
||||||
Relationship rel=getRelationship(status.account.id);
|
// TODO: figure this stuff out
|
||||||
if(!GlobalUserPreferences.isOptedOutOfPreReplySheet(GlobalUserPreferences.PreReplySheetType.NON_MUTUAL, status.account, accountID) &&
|
// Relationship rel=getRelationship(status.account.id);
|
||||||
!status.account.id.equals(AccountSessionManager.get(accountID).self.id) && rel!=null && !rel.followedBy && status.account.followingCount>=1){
|
// if(!GlobalUserPreferences.isOptedOutOfPreReplySheet(GlobalUserPreferences.PreReplySheetType.NON_MUTUAL, status.account, accountID) &&
|
||||||
new NonMutualPreReplySheet(getActivity(), notAgain->{
|
// !status.account.id.equals(AccountSessionManager.get(accountID).self.id) && rel!=null && !rel.followedBy && status.account.followingCount>=1){
|
||||||
GlobalUserPreferences.optOutOfPreReplySheet(GlobalUserPreferences.PreReplySheetType.NON_MUTUAL, notAgain ? null : status.account, accountID);
|
// new NonMutualPreReplySheet(getActivity(), notAgain->{
|
||||||
|
// GlobalUserPreferences.optOutOfPreReplySheet(GlobalUserPreferences.PreReplySheetType.NON_MUTUAL, notAgain ? null : status.account, accountID);
|
||||||
|
// proceed.run();
|
||||||
|
// }, status.account, accountID).show();
|
||||||
|
// }else if(!GlobalUserPreferences.isOptedOutOfPreReplySheet(GlobalUserPreferences.PreReplySheetType.OLD_POST, null, null) &&
|
||||||
|
// status.createdAt.isBefore(Instant.now().minus(90, ChronoUnit.DAYS))){
|
||||||
|
// new OldPostPreReplySheet(getActivity(), notAgain->{
|
||||||
|
// if(notAgain)
|
||||||
|
// GlobalUserPreferences.optOutOfPreReplySheet(GlobalUserPreferences.PreReplySheetType.OLD_POST, null, null);
|
||||||
|
// proceed.run();
|
||||||
|
// }, status).show();
|
||||||
|
// }else{
|
||||||
|
// proceed.run();
|
||||||
|
// }
|
||||||
|
|
||||||
|
|
||||||
proceed.run();
|
proceed.run();
|
||||||
}, status.account, accountID).show();
|
|
||||||
}else if(!GlobalUserPreferences.isOptedOutOfPreReplySheet(GlobalUserPreferences.PreReplySheetType.OLD_POST, null, null) &&
|
|
||||||
status.createdAt.isBefore(Instant.now().minus(90, ChronoUnit.DAYS))){
|
|
||||||
new OldPostPreReplySheet(getActivity(), notAgain->{
|
|
||||||
if(notAgain)
|
|
||||||
GlobalUserPreferences.optOutOfPreReplySheet(GlobalUserPreferences.PreReplySheetType.OLD_POST, null, null);
|
|
||||||
proceed.run();
|
|
||||||
}, status).show();
|
|
||||||
}else{
|
|
||||||
proceed.run();
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected void onModifyItemViewHolder(BindableViewHolder<StatusDisplayItem> holder){}
|
protected void onModifyItemViewHolder(BindableViewHolder<StatusDisplayItem> holder){}
|
||||||
|
|||||||
@@ -147,7 +147,7 @@ public class PhotoViewerInfoSheet extends BottomSheet{
|
|||||||
statusID=status.id;
|
statusID=status.id;
|
||||||
boostBtn.setCompoundDrawablesWithIntrinsicBounds(0, switch(status.visibility){
|
boostBtn.setCompoundDrawablesWithIntrinsicBounds(0, switch(status.visibility){
|
||||||
case DIRECT -> R.drawable.ic_boost_disabled_24px;
|
case DIRECT -> R.drawable.ic_boost_disabled_24px;
|
||||||
case PUBLIC, UNLISTED -> R.drawable.ic_boost;
|
case PUBLIC, UNLISTED, LOCAL -> R.drawable.ic_boost;
|
||||||
case PRIVATE -> R.drawable.ic_boost_private;
|
case PRIVATE -> R.drawable.ic_boost_private;
|
||||||
}, 0, 0);
|
}, 0, 0);
|
||||||
boostBtn.setEnabled(status.visibility!=StatusPrivacy.DIRECT);
|
boostBtn.setEnabled(status.visibility!=StatusPrivacy.DIRECT);
|
||||||
|
|||||||
@@ -115,8 +115,8 @@ public class ComposeLanguageAlertViewController{
|
|||||||
int i=0;
|
int i=0;
|
||||||
boolean found=false;
|
boolean found=false;
|
||||||
for(SpecialLocaleInfo li:specialLocales){
|
for(SpecialLocaleInfo li:specialLocales){
|
||||||
if(null!=li.locale&&li.locale.equals(previouslySelected.locale)){
|
if(null!=li.language&&li.language.equals(previouslySelected.language)){
|
||||||
selectedLocale=li.locale;
|
selectedLocale=li.language;
|
||||||
selectedIndex=i;
|
selectedIndex=i;
|
||||||
found=true;
|
found=true;
|
||||||
break;
|
break;
|
||||||
|
|||||||
Reference in New Issue
Block a user