mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-03 15:16:14 +00:00
WindowServer: Make it possible to launch a terminal from the system menu.
This commit is contained in:
@@ -193,6 +193,11 @@ WSWindowManager::WSWindowManager()
|
||||
m_system_menu->add_item(make<WSMenuItem>(WSMenuItem::Separator));
|
||||
m_system_menu->add_item(make<WSMenuItem>(4, "About..."));
|
||||
m_system_menu->on_item_activation = [] (WSMenuItem& item) {
|
||||
if (item.identifier() == 0) {
|
||||
int error;
|
||||
Process::create_user_process("/bin/Terminal", 100, 100, current->pid(), error);
|
||||
return;
|
||||
}
|
||||
kprintf("WSMenu 1 item activated: '%s'\n", item.text().characters());
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user