mirror of
https://github.com/RGBCube/serenity
synced 2025-05-20 18:15:07 +00:00
LibGUI: Convert Vector<OwnPtr> to NonnullOwnPtrVector.
This is turning out really nice so far. :^)
This commit is contained in:
parent
90ea4918d6
commit
2196f17c10
7 changed files with 46 additions and 47 deletions
|
@ -10,7 +10,7 @@ GMenuBar::~GMenuBar()
|
|||
unrealize_menubar();
|
||||
}
|
||||
|
||||
void GMenuBar::add_menu(OwnPtr<GMenu>&& menu)
|
||||
void GMenuBar::add_menu(NonnullOwnPtr<GMenu>&& menu)
|
||||
{
|
||||
m_menus.append(move(menu));
|
||||
}
|
||||
|
@ -40,8 +40,7 @@ void GMenuBar::notify_added_to_application(Badge<GApplication>)
|
|||
m_menubar_id = realize_menubar();
|
||||
ASSERT(m_menubar_id != -1);
|
||||
for (auto& menu : m_menus) {
|
||||
ASSERT(menu);
|
||||
int menu_id = menu->realize_menu();
|
||||
int menu_id = menu.realize_menu();
|
||||
ASSERT(menu_id != -1);
|
||||
WSAPI_ClientMessage request;
|
||||
request.type = WSAPI_ClientMessage::Type::AddMenuToMenubar;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue