From 2078c60477842d7cf6991148e23979565737a8b5 Mon Sep 17 00:00:00 2001 From: Akshay Nair Date: Sat, 26 Jul 2025 11:59:38 +0530 Subject: Refactor heavy + extras.tabline module (incomplete) --- src/events/NotificationReceivedEvent.hpp | 3 +-- src/events/PermissionRequestedEvent.hpp | 3 +-- src/events/UrlChangedEvent.hpp | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) (limited to 'src/events') diff --git a/src/events/NotificationReceivedEvent.hpp b/src/events/NotificationReceivedEvent.hpp index ade2132..fd5a554 100644 --- a/src/events/NotificationReceivedEvent.hpp +++ b/src/events/NotificationReceivedEvent.hpp @@ -16,8 +16,7 @@ public: } void lua_push(lua_State *state) const override { - lua_newtable(state); - SET_FIELD("type", string, kind.toStdString().c_str()) + Event::lua_push(state); SET_FIELD("title", string, notification->title().toStdString().c_str()) SET_FIELD("message", string, notification->message().toStdString().c_str()) SET_FIELD("tag", string, notification->tag().toStdString().c_str()) diff --git a/src/events/PermissionRequestedEvent.hpp b/src/events/PermissionRequestedEvent.hpp index ec03ea5..f6c102a 100644 --- a/src/events/PermissionRequestedEvent.hpp +++ b/src/events/PermissionRequestedEvent.hpp @@ -40,8 +40,7 @@ public: } void lua_push(lua_State *state) const override { - lua_newtable(state); - SET_FIELD("type", string, kind.toStdString().c_str()) + Event::lua_push(state); SET_FIELD("permission_type", string, permission_type()) SET_FIELD("view_id", integer, webview_id) SET_FIELD("win_id", integer, win_id) diff --git a/src/events/UrlChangedEvent.hpp b/src/events/UrlChangedEvent.hpp index ec3980b..29547f2 100644 --- a/src/events/UrlChangedEvent.hpp +++ b/src/events/UrlChangedEvent.hpp @@ -3,9 +3,9 @@ #include #include +#include "WebViewData.hpp" #include "events/Event.hpp" #include "widgets/BrowserWindow.hpp" -#include "widgets/WebViewStack.hpp" class UrlChangedEvent : public Event { public: -- cgit v1.3.1