From 37a5533393d422729be76bc86a06e69a4874393b Mon Sep 17 00:00:00 2001 From: M66B Date: Thu, 13 May 2021 08:21:45 +0200 Subject: [PATCH] Scroll to debug settings --- .../main/java/eu/faircode/email/FragmentOptionsMisc.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/app/src/main/java/eu/faircode/email/FragmentOptionsMisc.java b/app/src/main/java/eu/faircode/email/FragmentOptionsMisc.java index 5a5b29d508..8d45fb860b 100644 --- a/app/src/main/java/eu/faircode/email/FragmentOptionsMisc.java +++ b/app/src/main/java/eu/faircode/email/FragmentOptionsMisc.java @@ -511,6 +511,13 @@ public class FragmentOptionsMisc extends FragmentBase implements SharedPreferenc public void onCheckedChanged(CompoundButton compoundButton, boolean checked) { prefs.edit().putBoolean("debug", checked).apply(); cardDebug.setVisibility(checked || BuildConfig.DEBUG ? View.VISIBLE : View.GONE); + if (checked) + view.post(new Runnable() { + @Override + public void run() { + view.scrollTo(0, swDebug.getTop()); + } + }); } });