mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-04-21 12:05:15 +00:00
Browser: Handle close event in WebContentView
This commit is contained in:
parent
59752807c4
commit
54a1ec2f10
Notes:
sideshowbarker
2024-07-16 23:19:20 +09:00
Author: https://github.com/kalenikaliaksandr Commit: https://github.com/SerenityOS/serenity/commit/54a1ec2f10 Pull-request: https://github.com/SerenityOS/serenity/pull/17742 Reviewed-by: https://github.com/linusg
1 changed files with 4 additions and 0 deletions
|
@ -468,6 +468,10 @@ Tab::Tab(BrowserWindow& window)
|
|||
go_forward();
|
||||
};
|
||||
|
||||
view().on_close = [this] {
|
||||
on_tab_close_request(*this);
|
||||
};
|
||||
|
||||
m_tab_context_menu = GUI::Menu::construct();
|
||||
m_tab_context_menu->add_action(GUI::CommonActions::make_reload_action([this](auto&) {
|
||||
reload();
|
||||
|
|
Loading…
Add table
Reference in a new issue