| 737 | } |
| 738 | |
| 739 | int Plugin::lua_is_enabled(lua_State *state) |
| 740 | { |
| 741 | auto obj = (Plugin*)lua_touserdata(state, lua_upvalueindex(1)); |
| 742 | |
| 743 | RefAutoinc lock(obj->access); |
| 744 | if (obj->state == PS_LOADED && obj->plugin_is_enabled) |
| 745 | lua_pushboolean(state, obj->is_enabled()); |
| 746 | else |
| 747 | lua_pushnil(state); |
| 748 | |
| 749 | return 1; |
| 750 | } |
| 751 | |
| 752 | int Plugin::lua_set_enabled(lua_State *state) |
| 753 | { |
nothing calls this directly
no test coverage detected