diff options
| author | Akshay Nair <phenax5@gmail.com> | 2025-08-17 14:25:45 +0530 |
|---|---|---|
| committer | Akshay Nair <phenax5@gmail.com> | 2025-08-17 14:25:45 +0530 |
| commit | 98f3281256e6ff435c67d83c6895fff5841b70be (patch) | |
| tree | 6b05a448b8d049de130ac7dbe24baef0e7a1fc81 /src/WindowActionRouter.hpp | |
| parent | b16d38df05cd80aac209f42bfcb47971c62227e6 (diff) | |
| download | null-browser-98f3281256e6ff435c67d83c6895fff5841b70be.tar.gz null-browser-98f3281256e6ff435c67d83c6895fff5841b70be.zip | |
Use view for filtering window actions + window action router spec
Diffstat (limited to 'src/WindowActionRouter.hpp')
| -rw-r--r-- | src/WindowActionRouter.hpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/WindowActionRouter.hpp b/src/WindowActionRouter.hpp index efc54ca..7982667 100644 --- a/src/WindowActionRouter.hpp +++ b/src/WindowActionRouter.hpp @@ -34,7 +34,7 @@ public: void initialize(Configuration *config); void add_window(BrowserWindow *window); - const WindowMap &windows(); + const WindowMap &windows() { return window_map; } WebViewId fetch_current_view_id(WindowId win_id = 0); QList<WebViewData> fetch_webview_data_list(WindowId win_id = 0); @@ -49,12 +49,14 @@ public: DELEGATE(&event_queue, dispatch_event, dispatch_event) DELEGATE(&event_queue, register_event, register_event) -private: +protected: WindowActionRouter() = default; void add_keymap(const QString &mode_string, const QString &keyseq, std::function<void()> action); void find_current_search_text(WebViewId webview_id, bool forward); - std::vector<BrowserWindow *> get_relevant_windows(std::optional<WindowId> win_id); + std::vector<BrowserWindow *> + get_relevant_windows(std::optional<WindowId> win_id = std::nullopt, + std::optional<WebViewId> view_id = std::nullopt); signals: void new_window_requested(const QUrl &url); |
