1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 04:07:44 +00:00

Taskbar: More bringup work. We now see a basic window list.

This commit is contained in:
Andreas Kling 2019-04-04 01:44:35 +02:00
parent ea801a99dc
commit 96104b5524
20 changed files with 339 additions and 12 deletions

View file

@ -0,0 +1,17 @@
#include "WindowList.h"
Window& WindowList::ensure_window(const WindowIdentifier& identifier)
{
auto it = m_windows.find(identifier);
if (it != m_windows.end())
return *it->value;
auto window = make<Window>(identifier);
auto& window_ref = *window;
m_windows.set(identifier, move(window));
return window_ref;
}
void WindowList::remove_window(const WindowIdentifier& identifier)
{
m_windows.remove(identifier);
}