1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-27 00:27:45 +00:00

Browser: Use CommonActions where possible and various fixes

This replaces some actions with CommonActions and also adds '...' to
menu items that require user input.
This commit is contained in:
Marcus Nilsson 2021-08-03 17:02:10 +02:00 committed by Andreas Kling
parent 3b9e8ec597
commit 578318ca0f
5 changed files with 17 additions and 11 deletions

View file

@ -324,10 +324,10 @@ Tab::Tab(BrowserWindow& window)
};
m_tab_context_menu = GUI::Menu::construct();
m_tab_context_menu->add_action(GUI::Action::create("&Reload Tab", [this](auto&) {
m_tab_context_menu->add_action(GUI::CommonActions::make_reload_action([this](auto&) {
this->window().reload_action().activate();
}));
m_tab_context_menu->add_action(GUI::Action::create("&Close Tab", [this](auto&) {
m_tab_context_menu->add_action(GUI::CommonActions::make_close_tab_action([this](auto&) {
on_tab_close_request(*this);
}));
m_tab_context_menu->add_action(GUI::Action::create("&Duplicate Tab", [this](auto&) {