From 50a8e0e49507b2f6400618bdcb19f4387ce4ee2c Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Mon, 29 Mar 2021 22:39:18 +0200 Subject: LibGUI+WindowServer: Keep canonical WindowType enum in WindowServer Having the same enum in two places was annoying. Let's just "using" the WindowServer::WindowType enum into the GUI namespace. --- Userland/Libraries/LibGUI/WindowType.h | 17 +++-------------- Userland/Services/WindowServer/WindowType.h | 5 ++++- 2 files changed, 7 insertions(+), 15 deletions(-) diff --git a/Userland/Libraries/LibGUI/WindowType.h b/Userland/Libraries/LibGUI/WindowType.h index a7fae0987b..c8568ed153 100644 --- a/Userland/Libraries/LibGUI/WindowType.h +++ b/Userland/Libraries/LibGUI/WindowType.h @@ -26,21 +26,10 @@ #pragma once +#include + namespace GUI { -// Keep this in sync with WindowServer::WindowType. -enum class WindowType { - Invalid = 0, - Normal, - Menu, - WindowSwitcher, - Taskbar, - Tooltip, - Menubar, - MenuApplet, - Notification, - Desktop, - ToolWindow, -}; +using WindowType = WindowServer::WindowType; } diff --git a/Userland/Services/WindowServer/WindowType.h b/Userland/Services/WindowServer/WindowType.h index 214aad9338..f260cc8937 100644 --- a/Userland/Services/WindowServer/WindowType.h +++ b/Userland/Services/WindowServer/WindowType.h @@ -26,7 +26,8 @@ #pragma once -// Keep this in sync with GUI::WindowType. +namespace WindowServer { + enum class WindowType { Invalid = 0, Normal, @@ -40,3 +41,5 @@ enum class WindowType { Desktop, ToolWindow, }; + +} -- cgit v1.2.3