Skip to content

Commit

Permalink
Merge pull request #23 from mgerhardy/fixes
Browse files Browse the repository at this point in the history
Fixed warnings and removed unused methods and global vars
keharriso authored Apr 30, 2018
2 parents 36b788c + 4b844d6 commit c09651b
Showing 1 changed file with 2 additions and 25 deletions.
27 changes: 2 additions & 25 deletions src/nuklear_love.c
Original file line number Diff line number Diff line change
@@ -45,7 +45,6 @@ static struct nk_user_font *fonts;
static int font_count;
static char *edit_buffer;
static const char **combobox_items;
static struct nk_cursor cursors[NK_CURSOR_COUNT];
static float *floats;
static int layout_ratio_count;

@@ -363,28 +362,6 @@ static void nk_love_draw_rect_multi_color(int x, int y, unsigned int w,
lua_pop(L, 2);
}

static void nk_love_clear(struct nk_color col)
{
lua_getglobal(L, "love");
lua_getfield(L, -1, "graphics");
lua_getfield(L, -1, "clear");
lua_pushnumber(L, col.r / 255.0);
lua_pushnumber(L, col.g / 255.0);
lua_pushnumber(L, col.b / 255.0);
lua_pushnumber(L, col.a / 255.0);
lua_call(L, 4, 0);
lua_pop(L, 2);
}

static void nk_love_blit()
{
lua_getglobal(L, "love");
lua_getfield(L, -1, "graphics");
lua_getfield(L, -1, "present");
lua_call(L, 0, 0);
lua_pop(L, 2);
}

static void nk_love_draw_image(int x, int y, unsigned int w, unsigned int h,
struct nk_image image, struct nk_color color)
{
@@ -3437,12 +3414,12 @@ static int nk_love_input_is_mouse(int down)

static int nk_love_input_is_mouse_pressed(lua_State *L)
{
nk_love_input_is_mouse(nk_true);
return nk_love_input_is_mouse(nk_true);
}

static int nk_love_input_is_mouse_released(lua_State *L)
{
nk_love_input_is_mouse(nk_false);
return nk_love_input_is_mouse(nk_false);
}

static int nk_love_input_was_hovered(lua_State *L)

0 comments on commit c09651b

Please sign in to comment.