Remove unused code and strings

This commit is contained in:
Grishka 2023-04-12 18:34:28 +03:00
parent d93d66f702
commit eef33266fc
2 changed files with 0 additions and 63 deletions

View File

@ -177,61 +177,4 @@ public class SplashFragment extends AppKitFragment{
super.onHidden(); super.onHidden();
motionEffect.deactivate(); motionEffect.deactivate();
} }
private class PagerAdapter extends RecyclerView.Adapter<PagerViewHolder>{
@NonNull
@Override
public PagerViewHolder onCreateViewHolder(@NonNull ViewGroup parent, int viewType){
return new PagerViewHolder(viewType);
}
@Override
public void onBindViewHolder(@NonNull PagerViewHolder holder, int position){}
@Override
public int getItemCount(){
return 3;
}
@Override
public int getItemViewType(int position){
return position;
}
}
private class PagerViewHolder extends RecyclerView.ViewHolder{
public PagerViewHolder(int page){
super(new LinearLayout(getActivity()));
LinearLayout ll=(LinearLayout) itemView;
ll.setOrientation(LinearLayout.VERTICAL);
int pad=V.dp(16);
ll.setPadding(pad, pad, pad, pad);
ll.setLayoutParams(new RecyclerView.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.MATCH_PARENT));
TextView title=new TextView(getActivity());
title.setTextAppearance(R.style.m3_headline_medium);
title.setText(switch(page){
case 0 -> getString(R.string.welcome_page1_title);
case 1 -> getString(R.string.welcome_page2_title);
case 2 -> getString(R.string.welcome_page3_title);
default -> throw new IllegalStateException("Unexpected value: "+page);
});
title.setTextColor(0xFF17063B);
LinearLayout.LayoutParams lp=new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, V.dp(page==0 ? 46 : 36));
lp.bottomMargin=V.dp(page==0 ? 4 : 14);
ll.addView(title, lp);
TextView text=new TextView(getActivity());
text.setTextAppearance(R.style.m3_body_medium);
text.setText(switch(page){
case 0 -> R.string.welcome_page1_text;
case 1 -> R.string.welcome_page2_text;
case 2 -> R.string.welcome_page3_text;
default -> throw new IllegalStateException("Unexpected value: "+page);
});
text.setTextColor(0xFF17063B);
ll.addView(text, new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT));
}
}
} }

View File

@ -402,12 +402,6 @@
<string name="login_title">Welcome Back</string> <string name="login_title">Welcome Back</string>
<string name="login_subtitle">Log in with the server where you created your account.</string> <string name="login_subtitle">Log in with the server where you created your account.</string>
<string name="server_url">Server URL</string> <string name="server_url">Server URL</string>
<string name="welcome_page1_title">What is Mastodon?</string>
<string name="welcome_page1_text">Imagine you have an email address that ends with @example.com.\n\nYou can still send and receive emails from anyone, even if their email ends in @gmail.com or @icloud.com or @example.com.</string>
<string name="welcome_page2_title">Mastodon is like that.</string>
<string name="welcome_page2_text">Your handle might be @gothgirl654@example.social, but you can still follow, boost, and chat with @fallout5ever@example.online.</string>
<string name="welcome_page3_title">How do I pick a server?</string>
<string name="welcome_page3_text">Different people choose different servers for any number of reasons. art.example is a great place for artists, while glasgow.example might be a good pick for Scots.\n\nYou cant go wrong with any of our recommend servers, so regardless of which one you pick (or if you enter your own in the server search bar), youll never miss a beat anywhere.</string>
<string name="signup_random_server_explain">We\'ll pick a server based on your language if you continue without making a selection.</string> <string name="signup_random_server_explain">We\'ll pick a server based on your language if you continue without making a selection.</string>
<string name="server_filter_any_language">Any Language</string> <string name="server_filter_any_language">Any Language</string>
<string name="server_filter_instant_signup">Instant Sign-up</string> <string name="server_filter_instant_signup">Instant Sign-up</string>