Fix immersive interface UI issues in LoginActivity and CustomFontPreferenceFragmentCompat.

This commit is contained in:
Docile-Alligator 2025-07-08 18:01:02 -04:00
parent 613992a6ca
commit 6a2e59e255
5 changed files with 5 additions and 4 deletions

View File

@ -114,6 +114,7 @@ public class LoginActivity extends BaseActivity {
Insets allInsets = insets.getInsets(
WindowInsetsCompat.Type.systemBars()
| WindowInsetsCompat.Type.displayCutout()
| WindowInsetsCompat.Type.ime()
);
setMargins(binding.toolbarLoginActivity,

View File

@ -129,7 +129,7 @@ public class CustomThemeWrapper {
public int getFilledCardViewBackgroundColor() {
return getThemeSharedPreferences().getInt(CustomThemeSharedPreferencesUtils.FILLED_CARD_VIEW_BACKGROUND_COLOR,
getDefaultColor("#E6F4FF", "#242424", "#000000"));
getDefaultColor("#EDF6FD", "#242424", "#000000"));
}
public int getReadPostFilledCardViewBackgroundColor() {

View File

@ -53,7 +53,7 @@ public abstract class CustomFontPreferenceFragmentCompat extends PreferenceFragm
WindowInsetsCompat.Type.systemBars()
| WindowInsetsCompat.Type.displayCutout()
);
recyclerView.setPadding(0, 0, 0, allInsets.bottom);
recyclerView.setPadding(allInsets.left, 0, allInsets.right, allInsets.bottom);
return WindowInsetsCompat.CONSUMED;
}
});

View File

@ -176,7 +176,7 @@ public class NsfwAndSpoilerFragment extends Fragment {
.setTitle(getString(R.string.warning))
.setView(messageTextView)
.setPositiveButton(R.string.agree, (dialogInterface, i) -> dialogInterface.dismiss())
.setNegativeButton(R.string.do_not_agree, (dialogInterface, i) -> activity.onBackPressed())
.setNegativeButton(R.string.do_not_agree, (dialogInterface, i) -> activity.triggerBackPress())
.setCancelable(false)
.show();

View File

@ -94,7 +94,7 @@ public class SecurityPreferenceFragment extends CustomFontPreferenceFragmentComp
@Override
public void onAuthenticationError(int errorCode, @NonNull CharSequence errString) {
activity.onBackPressed();
activity.triggerBackPress();
}
});