Fix wrong usage of FONT_NONE. It was not meant to be set in
scp->font_size in the first place. It is redundant now and is removed. Found by: bde
This commit is contained in:
parent
3f681c0c41
commit
acdf858c9b
@ -879,7 +879,7 @@ sc_mouse_ioctl(struct tty *tp, u_long cmd, caddr_t data, int flag,
|
||||
s = spltty();
|
||||
sc_remove_all_mouse(scp->sc);
|
||||
#ifndef SC_NO_FONT_LOADING
|
||||
if (ISTEXTSC(cur_scp) && (cur_scp->font_size != FONT_NONE))
|
||||
if (ISTEXTSC(cur_scp) && (cur_scp->font != NULL))
|
||||
sc_load_font(cur_scp, 0, cur_scp->font_size, cur_scp->font,
|
||||
cur_scp->sc->mouse_char, 4);
|
||||
#endif
|
||||
|
@ -273,7 +273,7 @@ sc_set_graphics_mode(scr_stat *scp, struct tty *tp, int mode)
|
||||
scp->xpixel = info.vi_width;
|
||||
scp->ypixel = info.vi_height;
|
||||
scp->font = NULL;
|
||||
scp->font_size = FONT_NONE;
|
||||
scp->font_size = 0;
|
||||
#ifndef SC_NO_SYSMOUSE
|
||||
/* move the mouse cursor at the center of the screen */
|
||||
sc_mouse_move(scp, scp->xpixel / 2, scp->ypixel / 2);
|
||||
@ -316,7 +316,7 @@ sc_set_pixel_mode(scr_stat *scp, struct tty *tp, int xsize, int ysize,
|
||||
return ENODEV; /* this shouldn't happen */
|
||||
|
||||
/* adjust argument values */
|
||||
if ((fontsize <= 0) || (fontsize == FONT_NONE))
|
||||
if (fontsize <= 0)
|
||||
fontsize = info.vi_cheight;
|
||||
if (fontsize < 14) {
|
||||
fontsize = 8;
|
||||
|
@ -2802,7 +2802,7 @@ init_scp(sc_softc_t *sc, int vty, scr_stat *scp)
|
||||
scp->ypixel = info.vi_height;
|
||||
scp->xsize = info.vi_width/8;
|
||||
scp->ysize = info.vi_height/info.vi_cheight;
|
||||
scp->font_size = FONT_NONE;
|
||||
scp->font_size = 0;
|
||||
scp->font = NULL;
|
||||
} else {
|
||||
scp->xsize = info.vi_width;
|
||||
|
@ -196,7 +196,6 @@ typedef struct sc_softc {
|
||||
|
||||
#ifndef SC_NO_FONT_LOADING
|
||||
int fonts_loaded;
|
||||
#define FONT_NONE 1
|
||||
#define FONT_8 2
|
||||
#define FONT_14 4
|
||||
#define FONT_16 8
|
||||
|
Loading…
x
Reference in New Issue
Block a user