From 541e14f7ef5688c95240d40be4ce0f47ea59efdd Mon Sep 17 00:00:00 2001 From: Lauri Tulmin Date: Fri, 25 Feb 2005 16:51:13 +0000 Subject: [PATCH] Make sure that last line is at the bottom of the edit control. --- dlls/user/edit.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/user/edit.c b/dlls/user/edit.c index 501eb0b1e07..37568c55842 100644 --- a/dlls/user/edit.c +++ b/dlls/user/edit.c @@ -3278,12 +3278,12 @@ static void EDIT_EM_ScrollCaret(EDITSTATE *es) dx = x - es->format_rect.left - ww / HSCROLL_FRACTION / cw * cw; if (x > es->format_rect.right) dx = x - es->format_rect.left - (HSCROLL_FRACTION - 1) * ww / HSCROLL_FRACTION / cw * cw; - if (dy || dx) + if (dy || dx || (es->y_offset && (es->line_count - es->y_offset < vlc))) { /* check if we are going to move too far */ if(es->x_offset + dx + ww > es->text_width) dx = es->text_width - ww - es->x_offset; - if(dx || dy) + if(dx || dy || (es->y_offset && (es->line_count - es->y_offset < vlc))) EDIT_EM_LineScroll_internal(es, dx, dy); } } else {