Editing the InstanceRulesFragment for allowing a more coherent color scheme

This commit is contained in:
LucasGGamerM 2022-12-30 19:42:16 -03:00
parent 16c0866f7f
commit dccd9dcb97
4 changed files with 6 additions and 5 deletions

View File

@ -2,6 +2,7 @@ package org.joinmastodon.android.fragments.onboarding;
import android.annotation.SuppressLint; import android.annotation.SuppressLint;
import android.app.Activity; import android.app.Activity;
import android.content.res.Resources;
import android.os.Build; import android.os.Build;
import android.os.Bundle; import android.os.Bundle;
import android.view.LayoutInflater; import android.view.LayoutInflater;
@ -65,7 +66,7 @@ public class InstanceRulesFragment extends ToolbarFragment{
adapter.addAdapter(new SingleViewRecyclerAdapter(headerView)); adapter.addAdapter(new SingleViewRecyclerAdapter(headerView));
adapter.addAdapter(new ItemsAdapter()); adapter.addAdapter(new ItemsAdapter());
list.setAdapter(adapter); list.setAdapter(adapter);
list.addItemDecoration(new DividerItemDecoration(getActivity(), R.attr.colorM3SurfaceVariant, 1, 56, 0, DividerItemDecoration.NOT_FIRST)); list.addItemDecoration(new DividerItemDecoration(getActivity(), R.attr.colorPollVoted, 1, 56, 0, DividerItemDecoration.NOT_FIRST));
btn=view.findViewById(R.id.btn_next); btn=view.findViewById(R.id.btn_next);
btn.setOnClickListener(v->onButtonClick()); btn.setOnClickListener(v->onButtonClick());
@ -77,8 +78,8 @@ public class InstanceRulesFragment extends ToolbarFragment{
@Override @Override
public void onViewCreated(View view, Bundle savedInstanceState){ public void onViewCreated(View view, Bundle savedInstanceState){
super.onViewCreated(view, savedInstanceState); super.onViewCreated(view, savedInstanceState);
setStatusBarColor(UiUtils.getThemeColor(getActivity(), R.attr.colorM3Background)); // setStatusBarColor(UiUtils.getThemeColor(getActivity(), R.attr.colorM3Background));
view.setBackgroundColor(UiUtils.getThemeColor(getActivity(), R.attr.colorM3Background)); // view.setBackgroundColor(UiUtils.getThemeColor(getActivity(), R.attr.colorM3Background));
} }
// @Override // @Override

View File

@ -26,6 +26,7 @@
android:layout_marginBottom="16dp" android:layout_marginBottom="16dp"
android:minWidth="145dp" android:minWidth="145dp"
style="@style/Widget.Mastodon.M3.Button.Filled" style="@style/Widget.Mastodon.M3.Button.Filled"
android:visibility="gone"
android:text="@string/i_agree" /> android:text="@string/i_agree" />
</LinearLayout> </LinearLayout>

View File

@ -4,7 +4,6 @@
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:textAppearance="@style/m3_body_large" android:textAppearance="@style/m3_body_large"
android:textColor="?colorM3OnSurface"
android:paddingStart="56dp" android:paddingStart="56dp"
android:paddingTop="12dp" android:paddingTop="12dp"
android:paddingEnd="24dp" android:paddingEnd="24dp"

View File

@ -15,7 +15,7 @@
android:layout_width="24dp" android:layout_width="24dp"
android:layout_height="24dp" android:layout_height="24dp"
android:layout_marginEnd="16dp" android:layout_marginEnd="16dp"
android:textColor="?colorM3Primary" android:textColor="?android:colorAccent"
android:fontFamily="sans-serif-condensed" android:fontFamily="sans-serif-condensed"
android:textStyle="bold" android:textStyle="bold"
android:textSize="22dp" android:textSize="22dp"