13
0

fix erroneous start of autoscroll when mouse pointer is left or above the left/upper scrolling boundary but we're already scrolled to zero on the relevant axes

This commit is contained in:
Paul Davis 2014-06-13 18:43:16 -04:00
parent f7844f4893
commit 23b1c59630

View File

@ -528,8 +528,8 @@ Editor::maybe_autoscroll (bool allow_horiz, bool allow_vert, bool from_headers)
get_window()->get_pointer (x, y, mask);
if ((allow_horiz && (x < scrolling_boundary.x0 || x >= scrolling_boundary.x1)) ||
(allow_vert && (y < scrolling_boundary.y0 || y >= scrolling_boundary.y1))) {
if ((allow_horiz && ((x < scrolling_boundary.x0 && leftmost_frame > 0) || x >= scrolling_boundary.x1)) ||
(allow_vert && ((y < scrolling_boundary.y0 && vertical_adjustment.get_value() > 0)|| y >= scrolling_boundary.y1))) {
start_canvas_autoscroll (allow_horiz, allow_vert, scrolling_boundary);
}
}