X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Fscreens.c;h=35a6729f85787a01e26195a6476189b664dbc4a3;hb=621b6a2c4781c9c3e2f5849f9c184a906e0ce5b6;hp=e4be131820d7614a5c4d3b19d385393dc6178d5c;hpb=ab9b68feafe2cf6012533e5ad0581e6b9d423959;p=rocksndiamonds.git diff --git a/src/screens.c b/src/screens.c index e4be1318..35a6729f 100644 --- a/src/screens.c +++ b/src/screens.c @@ -11,15 +11,14 @@ * screens.c * ***********************************************************/ +#include "libgame/libgame.h" + #include "screens.h" #include "events.h" -#include "sound.h" #include "game.h" #include "tools.h" #include "editor.h" -#include "misc.h" #include "files.h" -#include "buttons.h" #include "tape.h" #include "joystick.h" #include "cartoons.h" @@ -85,7 +84,7 @@ void DrawMainMenu() UndrawSpecialEditorDoor(); /* needed if last screen was the setup screen and fullscreen state changed */ - ChangeVideoModeIfNeeded(); + setup.fullscreen = ChangeVideoModeIfNeeded(setup.fullscreen); #ifdef TARGET_SDL SetDrawtoField(DRAW_BACKBUFFER); #endif @@ -262,9 +261,9 @@ void HandleMainMenu(int mx, int my, int dx, int dy, int button) level_nr = new_level_nr; - DrawTextExt(drawto, gc, SX + 11 * 32, SY + 3 * 32, + DrawTextExt(drawto, SX + 11 * 32, SY + 3 * 32, int2str(level_nr, 3), FS_BIG, font_color); - DrawTextExt(window, gc, SX + 11 * 32, SY + 3 * 32, + DrawTextExt(window, SX + 11 * 32, SY + 3 * 32, int2str(level_nr, 3), FS_BIG, font_color); LoadLevel(level_nr); @@ -617,7 +616,7 @@ void DrawHelpScreenElAction(int start) } j++; - DrawGraphicExt(drawto, gc, xstart, ystart+(i-start)*ystep, graphic+frame); + DrawGraphicExt(drawto, xstart, ystart+(i-start)*ystep, graphic+frame); i++; } @@ -842,9 +841,9 @@ void HandleTypeName(int newxpos, Key key) setup.player_name[xpos] = ascii; setup.player_name[xpos + 1] = 0; xpos++; - DrawTextExt(drawto, gc, SX + 6*32, SY + ypos*32, + DrawTextExt(drawto, SX + 6*32, SY + ypos*32, setup.player_name, FS_BIG, FC_YELLOW); - DrawTextExt(window, gc, SX + 6*32, SY + ypos*32, + DrawTextExt(window, SX + 6*32, SY + ypos*32, setup.player_name, FS_BIG, FC_YELLOW); DrawGraphic(xpos + 6, ypos, GFX_KUGEL_ROT); } @@ -1500,7 +1499,7 @@ void HandleSetupScreen(int mx, int my, int dx, int dy, int button) setup.fading = !setup.fading; } #endif - else if (y == 8 && fullscreen_available) + else if (y == 8 && video.fullscreen_available) { if (setup.fullscreen) DrawText(SX+14*32, SY+yy*32,"off",FS_BIG,FC_BLUE);