Make usage of SDL renderer optional
This commit is contained in:
+2
-2
@@ -109,7 +109,7 @@ top:
|
||||
|
||||
case SDL_WINDOWEVENT:
|
||||
if (e.window.event == SDL_WINDOWEVENT_RESIZED) {
|
||||
ren_setup_renderer();
|
||||
ren_resize_window();
|
||||
lua_pushstring(L, "resized");
|
||||
/* The size below will be in points. */
|
||||
lua_pushnumber(L, e.window.data1);
|
||||
@@ -318,7 +318,7 @@ static int f_set_window_size(lua_State *L) {
|
||||
double y = luaL_checknumber(L, 4);
|
||||
SDL_SetWindowSize(window, w, h);
|
||||
SDL_SetWindowPosition(window, x, y);
|
||||
ren_setup_renderer();
|
||||
ren_resize_window();
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user