2010-09-24 Lars Magne Ingebrigtsen <larsi@gnus.org>
+ * scroll.c (calculate_scrolling, line_ins_del)
+ (calculate_direct_scrolling, scroll_cost): Fix EMACS_INT/int
+ conversion.
+
* region-cache.c (move_cache_gap, set_cache_region, pp_cache)
(region_cache_backward, region_cache_forward)
(revalidate_region_cache, set_cache_region): FIX EMACS_INT/int
int free_at_end)
{
register int i, j;
- int frame_lines = FRAME_LINES (frame);
+ EMACS_INT frame_lines = FRAME_LINES (frame);
register struct matrix_elt *p, *p1;
register int cost, cost1;
/* Discourage long scrolls on fast lines.
Don't scroll nearly a full frame height unless it saves
at least 1/4 second. */
- int extra_cost = baud_rate / (10 * 4 * FRAME_LINES (frame));
+ int extra_cost = (int) (baud_rate / (10 * 4 * FRAME_LINES (frame)));
if (baud_rate <= 0)
extra_cost = 1;
int free_at_end)
{
register int i, j;
- int frame_lines = FRAME_LINES (frame);
+ EMACS_INT frame_lines = FRAME_LINES (frame);
register struct matrix_elt *p, *p1;
register int cost, cost1, delta;
/* Discourage long scrolls on fast lines.
Don't scroll nearly a full frame height unless it saves
at least 1/4 second. */
- int extra_cost = baud_rate / (10 * 4 * FRAME_LINES (frame));
+ int extra_cost = (int) (baud_rate / (10 * 4 * FRAME_LINES (frame)));
if (baud_rate <= 0)
extra_cost = 1;
{
/* Compute how many lines, at bottom of frame,
will not be involved in actual motion. */
- int limit = to;
- int offset;
- int height = FRAME_LINES (frame);
+ EMACS_INT limit = to;
+ EMACS_INT offset;
+ EMACS_INT height = FRAME_LINES (frame);
if (amount == 0)
return 0;
static void
line_ins_del (FRAME_PTR frame, int ov1, int pf1, int ovn, int pfn, register int *ov, register int *mf)
{
- register int i;
- register int frame_lines = FRAME_LINES (frame);
+ register EMACS_INT i;
+ register EMACS_INT frame_lines = FRAME_LINES (frame);
register int insert_overhead = ov1 * 10;
register int next_insert_cost = ovn * 10;