Remove luaA_pushscreen
It's just an alias for luaA_object_push(). Signed-off-by: Uli Schlachter <psychon@znc.in>
This commit is contained in:
parent
5ccdb933bf
commit
611cd7c2d8
6
mouse.c
6
mouse.c
|
@ -133,13 +133,13 @@ luaA_mouse_index(lua_State *L)
|
||||||
* having lots of lua errors in this case.
|
* having lots of lua errors in this case.
|
||||||
*/
|
*/
|
||||||
if (globalconf.focus.client)
|
if (globalconf.focus.client)
|
||||||
luaA_pushscreen(L, globalconf.focus.client->screen);
|
luaA_object_push(L, globalconf.focus.client->screen);
|
||||||
else
|
else
|
||||||
luaA_pushscreen(L, screen_get_primary());
|
luaA_object_push(L, screen_get_primary());
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
luaA_pushscreen(L, screen_getbycoord(mouse_x, mouse_y));
|
luaA_object_push(L, screen_getbycoord(mouse_x, mouse_y));
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -2296,7 +2296,7 @@ luaA_client_get_screen(lua_State *L, client_t *c)
|
||||||
{
|
{
|
||||||
if(!c->screen)
|
if(!c->screen)
|
||||||
return 0;
|
return 0;
|
||||||
luaA_pushscreen(L, c->screen);
|
luaA_object_push(L, c->screen);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -99,12 +99,6 @@ screen_wipe(screen_t *s)
|
||||||
screen_output_array_wipe(&s->outputs);
|
screen_output_array_wipe(&s->outputs);
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
|
||||||
luaA_pushscreen(lua_State *L, screen_t *s)
|
|
||||||
{
|
|
||||||
luaA_object_push(L, s);
|
|
||||||
}
|
|
||||||
|
|
||||||
/** Get a screen argument from the lua stack */
|
/** Get a screen argument from the lua stack */
|
||||||
screen_t *
|
screen_t *
|
||||||
luaA_checkscreen(lua_State *L, int sidx)
|
luaA_checkscreen(lua_State *L, int sidx)
|
||||||
|
@ -501,7 +495,7 @@ screen_client_moveto(client_t *c, screen_t *new_screen, bool doresize)
|
||||||
{
|
{
|
||||||
luaA_object_push(L, c);
|
luaA_object_push(L, c);
|
||||||
if(old_screen != NULL)
|
if(old_screen != NULL)
|
||||||
luaA_pushscreen(L, old_screen);
|
luaA_object_push(L, old_screen);
|
||||||
else
|
else
|
||||||
lua_pushnil(L);
|
lua_pushnil(L);
|
||||||
luaA_object_emit_signal(L, -2, "property::screen", 1);
|
luaA_object_emit_signal(L, -2, "property::screen", 1);
|
||||||
|
@ -540,7 +534,7 @@ screen_client_moveto(client_t *c, screen_t *new_screen, bool doresize)
|
||||||
{
|
{
|
||||||
luaA_object_push(L, c);
|
luaA_object_push(L, c);
|
||||||
if(old_screen != NULL)
|
if(old_screen != NULL)
|
||||||
luaA_pushscreen(L, old_screen);
|
luaA_object_push(L, old_screen);
|
||||||
else
|
else
|
||||||
lua_pushnil(L);
|
lua_pushnil(L);
|
||||||
luaA_object_emit_signal(L, -2, "property::screen", 1);
|
luaA_object_emit_signal(L, -2, "property::screen", 1);
|
||||||
|
@ -658,7 +652,7 @@ luaA_screen_module_call(lua_State *L)
|
||||||
idx = screen_get_index(luaA_checkscreen(L, 3));
|
idx = screen_get_index(luaA_checkscreen(L, 3));
|
||||||
if (idx >= 0 && idx < globalconf.screens.len)
|
if (idx >= 0 && idx < globalconf.screens.len)
|
||||||
/* No +1 needed, index starts at 1, C array at 0 */
|
/* No +1 needed, index starts at 1, C array at 0 */
|
||||||
luaA_pushscreen(L, globalconf.screens.tab[idx]);
|
luaA_object_push(L, globalconf.screens.tab[idx]);
|
||||||
else
|
else
|
||||||
lua_pushnil(L);
|
lua_pushnil(L);
|
||||||
return 1;
|
return 1;
|
||||||
|
|
|
@ -50,7 +50,6 @@ void screen_client_moveto(client_t *, screen_t *, bool);
|
||||||
void screen_update_primary(void);
|
void screen_update_primary(void);
|
||||||
screen_t *screen_get_primary(void);
|
screen_t *screen_get_primary(void);
|
||||||
|
|
||||||
void luaA_pushscreen(lua_State *, screen_t *);
|
|
||||||
screen_t *luaA_checkscreen(lua_State *, int);
|
screen_t *luaA_checkscreen(lua_State *, int);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue