Add classic configuration to wizard button

pull/201/head
M66B 3 years ago
parent 0958c9f349
commit 65b63104fd

@ -133,13 +133,17 @@ public class FragmentBase extends Fragment {
scroll.post(new Runnable() {
@Override
public void run() {
Rect rect = new Rect();
child.getDrawingRect(rect);
scroll.offsetDescendantRectToMyCoords(child, rect);
int y = rect.top - scroll.getPaddingTop() + dy;
if (y < 0)
y = 0;
scroll.scrollTo(0, y);
try {
Rect rect = new Rect();
child.getDrawingRect(rect);
scroll.offsetDescendantRectToMyCoords(child, rect);
int y = rect.top - scroll.getPaddingTop() + dy;
if (y < 0)
y = 0;
scroll.scrollTo(0, y);
} catch (Throwable ex) {
Log.e(ex);
}
}
});
}

@ -212,6 +212,10 @@ public class FragmentSetup extends FragmentBase {
menu.add(Menu.NONE, R.string.title_setup_other, order++, R.string.title_setup_other)
.setIcon(R.drawable.twotone_auto_fix_high_24);
menu.add(Menu.NONE, R.string.title_setup_classic, order++, R.string.title_setup_classic)
.setIcon(R.drawable.twotone_settings_24)
.setVisible(BuildConfig.DEBUG);
SpannableString ss = new SpannableString(getString(R.string.title_setup_pop3));
ss.setSpan(new RelativeSizeSpan(0.9f), 0, ss.length(), 0);
menu.add(Menu.NONE, R.string.title_setup_pop3, order++, ss);
@ -247,6 +251,22 @@ public class FragmentSetup extends FragmentBase {
} else if (itemId == R.string.title_setup_other) {
lbm.sendBroadcast(new Intent(ActivitySetup.ACTION_QUICK_SETUP));
return true;
} else if (itemId == R.string.title_setup_classic) {
ibManual.setPressed(true);
ibManual.setPressed(false);
manual = true;
updateManual();
view.post(new Runnable() {
@Override
public void run() {
try {
scrollTo(R.id.ibManual, 0);
} catch (Throwable ex) {
Log.e(ex);
}
}
});
return true;
} else if (itemId == R.string.title_setup_pop3) {
lbm.sendBroadcast(new Intent(ActivitySetup.ACTION_QUICK_POP3));
return true;

Loading…
Cancel
Save