Refactoring names to custom. Thank you @sk22 for this amazing piece of commit
This commit is contained in:
parent
bc3869b920
commit
f580ba7779
@ -16,7 +16,7 @@ import org.joinmastodon.android.fragments.HomeFragment;
|
||||
import org.joinmastodon.android.fragments.ProfileFragment;
|
||||
import org.joinmastodon.android.fragments.ThreadFragment;
|
||||
import org.joinmastodon.android.fragments.onboarding.AccountActivationFragment;
|
||||
import org.joinmastodon.android.fragments.onboarding.MoshidonLoginFragment;
|
||||
import org.joinmastodon.android.fragments.onboarding.CustomLoginFragment;
|
||||
import org.joinmastodon.android.model.Notification;
|
||||
import org.joinmastodon.android.ui.utils.UiUtils;
|
||||
import org.joinmastodon.android.updater.GithubSelfUpdater;
|
||||
@ -33,7 +33,7 @@ public class MainActivity extends FragmentStackActivity{
|
||||
|
||||
if(savedInstanceState==null){
|
||||
if(AccountSessionManager.getInstance().getLoggedInAccounts().isEmpty()){
|
||||
showFragmentClearingBackStack(new MoshidonLoginFragment());
|
||||
showFragmentClearingBackStack(new CustomLoginFragment());
|
||||
}else{
|
||||
AccountSessionManager.getInstance().maybeUpdateLocalInfo();
|
||||
AccountSession session;
|
||||
|
@ -36,11 +36,11 @@ import me.grishka.appkit.utils.SingleViewRecyclerAdapter;
|
||||
import me.grishka.appkit.utils.V;
|
||||
import me.grishka.appkit.views.UsableRecyclerView;
|
||||
|
||||
public class MoshidonLoginFragment extends InstanceCatalogFragment {
|
||||
public class CustomLoginFragment extends InstanceCatalogFragment {
|
||||
private View headerView;
|
||||
|
||||
public MoshidonLoginFragment() {
|
||||
super(R.layout.fragment_moshidon_welcome, 1);
|
||||
public CustomLoginFragment() {
|
||||
super(R.layout.fragment_welcome_custom, 1);
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -131,7 +131,7 @@ public class MoshidonLoginFragment extends InstanceCatalogFragment {
|
||||
|
||||
@Override
|
||||
protected RecyclerView.Adapter getAdapter(){
|
||||
headerView=getActivity().getLayoutInflater().inflate(R.layout.header_moshidon_welcome, list, false);
|
||||
headerView=getActivity().getLayoutInflater().inflate(R.layout.header_welcome_custom, list, false);
|
||||
searchEdit=headerView.findViewById(R.id.search_edit);
|
||||
searchEdit.setOnEditorActionListener(this::onSearchEnterPressed);
|
||||
|
||||
@ -203,7 +203,7 @@ public class MoshidonLoginFragment extends InstanceCatalogFragment {
|
||||
private final RadioButton radioButton;
|
||||
|
||||
public InstanceViewHolder(){
|
||||
super(getActivity(), R.layout.item_moshidon_instance, list);
|
||||
super(getActivity(), R.layout.item_instance_custom, list);
|
||||
|
||||
// itemView.setPadding(V.dp(16), V.dp(16), V.dp(16), V.dp(16));
|
||||
// TypedValue value = new TypedValue();
|
@ -23,7 +23,7 @@ import org.joinmastodon.android.R;
|
||||
import org.joinmastodon.android.api.requests.oauth.RevokeOauthToken;
|
||||
import org.joinmastodon.android.api.session.AccountSession;
|
||||
import org.joinmastodon.android.api.session.AccountSessionManager;
|
||||
import org.joinmastodon.android.fragments.onboarding.MoshidonLoginFragment;
|
||||
import org.joinmastodon.android.fragments.onboarding.CustomLoginFragment;
|
||||
import org.joinmastodon.android.ui.utils.UiUtils;
|
||||
|
||||
import java.util.List;
|
||||
@ -77,7 +77,7 @@ public class AccountSwitcherSheet extends BottomSheet{
|
||||
holder.avatar.setImageResource(R.drawable.ic_fluent_add_circle_24_filled);
|
||||
holder.avatar.setImageTintList(ColorStateList.valueOf(UiUtils.getThemeColor(activity, android.R.attr.textColorPrimary)));
|
||||
adapter.addAdapter(new ClickableSingleViewRecyclerAdapter(holder.itemView, ()->{
|
||||
Nav.go(activity, MoshidonLoginFragment.class, null);
|
||||
Nav.go(activity, CustomLoginFragment.class, null);
|
||||
dismiss();
|
||||
}));
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user