diff --git a/common/luaobject.h b/common/luaobject.h index 86caa420..af75d1af 100644 --- a/common/luaobject.h +++ b/common/luaobject.h @@ -167,15 +167,6 @@ int luaA_object_emit_signal_simple(lua_State *); } \ \ static inline int \ - prefix##_push_item(lua_State *L, type *item, void *ref) \ - { \ - luaA_object_push(L, item); \ - luaA_object_push_item(L, -1, ref); \ - lua_remove(L, -2); \ - return 1; \ - } \ - \ - static inline int \ luaA_##prefix##_tostring(lua_State *L) \ { \ lua_pushfstring(L, lua_type ": %p", luaL_checkudata(L, 1, lua_type)); \ diff --git a/event.c b/event.c index 6633529c..64a4b73e 100644 --- a/event.c +++ b/event.c @@ -440,7 +440,9 @@ event_handle_leavenotify(void *data __attribute__ ((unused)), if(wibox->mouse_leave) { - wibox_push_item(globalconf.L, wibox, wibox->mouse_leave); + luaA_object_push(globalconf.L, wibox); + luaA_object_push_item(globalconf.L, -1, wibox->mouse_leave); + lua_remove(globalconf.L, -2); luaA_dofunction(globalconf.L, 0, 0); } } @@ -475,7 +477,9 @@ event_handle_enternotify(void *data __attribute__ ((unused)), if(wibox->mouse_enter) { - wibox_push_item(globalconf.L, wibox, wibox->mouse_enter); + luaA_object_push(globalconf.L, wibox); + luaA_object_push_item(globalconf.L, -1, wibox->mouse_enter); + lua_remove(globalconf.L, -2); luaA_dofunction(globalconf.L, 0, 0); } }