peek original post before scrolling
This commit is contained in:
parent
4956543eac
commit
579794d7e0
|
@ -573,9 +573,10 @@ public class ComposeFragment extends MastodonToolbarFragment implements OnBackPr
|
|||
initiallyScrolled = true;
|
||||
scrollView.post(() -> {
|
||||
int bottom = scrollView.getChildAt(0).getBottom();
|
||||
int sy = scrollView.getScrollY();
|
||||
int sh = scrollView.getHeight();
|
||||
scrollView.scrollBy(0, bottom - (sy + sh));
|
||||
int delta = bottom - (scrollView.getScrollY() + scrollView.getHeight());
|
||||
int space = Math.min(V.dp(150), delta);
|
||||
scrollView.scrollBy(0, delta - space);
|
||||
scrollView.postDelayed(() -> scrollView.smoothScrollBy(0, space), 150);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue