Skip to content
Snippets Groups Projects
Commit 9440a492 authored by deuce's avatar deuce
Browse files

Add the mode palette to screen save/restore.

parent d7d223fd
No related branches found
No related tags found
No related merge requests found
......@@ -1854,6 +1854,7 @@ CIOLIBEXPORT struct ciolib_screen * CIOLIBCALL ciolib_savescreen(void)
for (i=0; i<5; i++)
ret->fonts[i] = ciolib_getfont(i);
ret->flags = ciolib_getvideoflags();
ciolib_get_modepalette(ret->palette);
return ret;
}
......@@ -1881,6 +1882,7 @@ CIOLIBEXPORT int CIOLIBCALL ciolib_restorescreen(struct ciolib_screen *scrn)
if (ti.currmode != scrn->text_info.currmode)
ciolib_textmode(scrn->text_info.currmode);
ciolib_set_modepalette(ret->palette);
ciolib_vmem_puttext(1, 1, scrn->text_info.screenwidth, scrn->text_info.screenheight, scrn->vmem);
ciolib_textcolor(scrn->text_info.attribute);
ciolib_window(scrn->text_info.winleft, scrn->text_info.wintop, scrn->text_info.winright, scrn->text_info.winbottom);
......
......@@ -274,6 +274,7 @@ struct ciolib_screen {
struct ciolib_pixels *pixels;
struct vmem_cell *vmem;
struct text_info text_info;
uint32_t palette[16];
};
#define CONIO_FIRST_FREE_FONT 43
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment