aboutsummaryrefslogtreecommitdiff
path: root/src/LuaRuntimeApi.hpp
diff options
context:
space:
mode:
authorAkshay Nair <phenax5@gmail.com>2025-04-20 17:40:09 +0530
committerAkshay Nair <phenax5@gmail.com>2025-05-02 16:15:41 +0530
commit31872258b18e81d5f973080e5130ebf49db3271f (patch)
tree6b70d71d2f9d845ffa2798df89010f347040d381 /src/LuaRuntimeApi.hpp
parentb4b6a646b3a7a7f6c7e990c67f208b76f4b5f748 (diff)
downloadnull-browser-31872258b18e81d5f973080e5130ebf49db3271f.tar.gz
null-browser-31872258b18e81d5f973080e5130ebf49db3271f.zip
Some more lua api specs
Diffstat (limited to 'src/LuaRuntimeApi.hpp')
-rw-r--r--src/LuaRuntimeApi.hpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/LuaRuntimeApi.hpp b/src/LuaRuntimeApi.hpp
index 80e8bc2..4767134 100644
--- a/src/LuaRuntimeApi.hpp
+++ b/src/LuaRuntimeApi.hpp
@@ -4,7 +4,6 @@
#include "LuaRuntime.hpp"
#include "WindowActionRouter.hpp"
-#include "lua.h"
int lua_api_view_set_url(lua_State *state) {
const char *url = lua_tostring(state, 1);
@@ -190,7 +189,7 @@ int lua_event_register(lua_State *state) {
int lua_api_search_set_text(lua_State *state) {
const char *text = lua_tostring(state, 1);
- WebViewId view_id = lua_isnoneornil(state, 1) ? 0 : lua_tointeger(state, 1);
+ WebViewId view_id = lua_isnoneornil(state, 2) ? 0 : lua_tointeger(state, 2);
auto &runtime = LuaRuntime::instance();
emit runtime.search_requested(text, view_id);
return 1;