Merge pull request #22774 from kellams/master

Fix to scrolling, rounding error on max_v_scroll
This commit is contained in:
Rémi Verschelde 2018-10-06 12:36:17 +02:00 committed by GitHub
commit d2043fad67
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -3260,7 +3260,7 @@ void TextEdit::_scroll_down(real_t p_delta) {
}
if (smooth_scroll_enabled) {
int max_v_scroll = v_scroll->get_max() - v_scroll->get_page();
int max_v_scroll = round(v_scroll->get_max() - v_scroll->get_page());
if (target_v_scroll > max_v_scroll) {
target_v_scroll = max_v_scroll;
v_scroll->set_value(target_v_scroll);