mirror of
https://git.savannah.gnu.org/git/emacs.git
synced 2025-01-18 18:05:07 +00:00
Fix EMACS_INT/int conversion in scroll.c.
This commit is contained in:
parent
f5c7fc2739
commit
f0812d352e
@ -1,5 +1,9 @@
|
||||
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
|
||||
|
18
src/scroll.c
18
src/scroll.c
@ -94,7 +94,7 @@ calculate_scrolling (FRAME_PTR frame,
|
||||
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;
|
||||
|
||||
@ -115,7 +115,7 @@ calculate_scrolling (FRAME_PTR frame,
|
||||
/* 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;
|
||||
@ -428,7 +428,7 @@ calculate_direct_scrolling (FRAME_PTR frame,
|
||||
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;
|
||||
|
||||
@ -448,7 +448,7 @@ calculate_direct_scrolling (FRAME_PTR frame,
|
||||
/* 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;
|
||||
@ -886,9 +886,9 @@ scroll_cost (FRAME_PTR frame, int from, int to, int amount)
|
||||
{
|
||||
/* 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;
|
||||
@ -921,8 +921,8 @@ scroll_cost (FRAME_PTR frame, int from, int to, int amount)
|
||||
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;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user