diff options
Diffstat (limited to 'Userland/Services/WindowServer')
22 files changed, 14 insertions, 54 deletions
diff --git a/Userland/Services/WindowServer/AppletManager.cpp b/Userland/Services/WindowServer/AppletManager.cpp index 607ed20816..c4a6c74e56 100644 --- a/Userland/Services/WindowServer/AppletManager.cpp +++ b/Userland/Services/WindowServer/AppletManager.cpp @@ -25,10 +25,6 @@ AppletManager::AppletManager() order_vector = order.split(','); } -AppletManager::~AppletManager() -{ -} - AppletManager& AppletManager::the() { VERIFY(s_the); diff --git a/Userland/Services/WindowServer/AppletManager.h b/Userland/Services/WindowServer/AppletManager.h index f92fe9979a..3fabbd4506 100644 --- a/Userland/Services/WindowServer/AppletManager.h +++ b/Userland/Services/WindowServer/AppletManager.h @@ -14,7 +14,7 @@ namespace WindowServer { class AppletManager : public Core::Object { C_OBJECT(AppletManager) public: - ~AppletManager(); + ~AppletManager() = default; static AppletManager& the(); diff --git a/Userland/Services/WindowServer/Button.cpp b/Userland/Services/WindowServer/Button.cpp index a7feb11d4c..128d72aefc 100644 --- a/Userland/Services/WindowServer/Button.cpp +++ b/Userland/Services/WindowServer/Button.cpp @@ -20,9 +20,7 @@ Button::Button(WindowFrame& frame, Function<void(Button&)>&& on_click_handler) { } -Button::~Button() -{ -} +Button::~Button() = default; void Button::paint(Screen& screen, Gfx::Painter& painter) { diff --git a/Userland/Services/WindowServer/Cursor.h b/Userland/Services/WindowServer/Cursor.h index 5a414029d6..8991432dce 100644 --- a/Userland/Services/WindowServer/Cursor.h +++ b/Userland/Services/WindowServer/Cursor.h @@ -46,7 +46,7 @@ public: Gfx::IntSize size() const { return m_rect.size(); } private: - Cursor() { } + Cursor() = default; Cursor(NonnullRefPtr<Gfx::Bitmap>&&, int, const Gfx::CursorParams&); bool load(StringView, StringView); diff --git a/Userland/Services/WindowServer/Event.h b/Userland/Services/WindowServer/Event.h index 18aaf0af5d..ff2a95f697 100644 --- a/Userland/Services/WindowServer/Event.h +++ b/Userland/Services/WindowServer/Event.h @@ -37,12 +37,12 @@ public: WindowResized, }; - Event() { } + Event() = default; explicit Event(Type type) : Core::Event(type) { } - virtual ~Event() { } + virtual ~Event() = default; bool is_mouse_event() const { return type() == MouseMove || type() == MouseDown || type() == MouseDoubleClick || type() == MouseUp || type() == MouseWheel; } bool is_key_event() const { return type() == KeyUp || type() == KeyDown; } diff --git a/Userland/Services/WindowServer/EventLoop.cpp b/Userland/Services/WindowServer/EventLoop.cpp index d7621fc241..1da51d8558 100644 --- a/Userland/Services/WindowServer/EventLoop.cpp +++ b/Userland/Services/WindowServer/EventLoop.cpp @@ -41,10 +41,6 @@ EventLoop::EventLoop() } } -EventLoop::~EventLoop() -{ -} - void EventLoop::drain_mouse() { auto& screen_input = ScreenInput::the(); diff --git a/Userland/Services/WindowServer/EventLoop.h b/Userland/Services/WindowServer/EventLoop.h index 8d9b1b6394..f0125bc119 100644 --- a/Userland/Services/WindowServer/EventLoop.h +++ b/Userland/Services/WindowServer/EventLoop.h @@ -20,7 +20,7 @@ class ConnectionFromClient; class EventLoop { public: EventLoop(); - virtual ~EventLoop(); + virtual ~EventLoop() = default; int exec() { return m_event_loop.exec(); } diff --git a/Userland/Services/WindowServer/KeymapSwitcher.cpp b/Userland/Services/WindowServer/KeymapSwitcher.cpp index ac47e2473b..2781dd7145 100644 --- a/Userland/Services/WindowServer/KeymapSwitcher.cpp +++ b/Userland/Services/WindowServer/KeymapSwitcher.cpp @@ -26,10 +26,6 @@ KeymapSwitcher::KeymapSwitcher() refresh(); } -KeymapSwitcher::~KeymapSwitcher() -{ -} - void KeymapSwitcher::refresh() { m_keymaps.clear(); diff --git a/Userland/Services/WindowServer/KeymapSwitcher.h b/Userland/Services/WindowServer/KeymapSwitcher.h index a2d0ddf235..bbae14c1a3 100644 --- a/Userland/Services/WindowServer/KeymapSwitcher.h +++ b/Userland/Services/WindowServer/KeymapSwitcher.h @@ -19,7 +19,7 @@ namespace WindowServer { class KeymapSwitcher final : public Core::Object { C_OBJECT(KeymapSwitcher) public: - virtual ~KeymapSwitcher() override; + virtual ~KeymapSwitcher() override = default; void next_keymap(); diff --git a/Userland/Services/WindowServer/Menu.cpp b/Userland/Services/WindowServer/Menu.cpp index 7112cb0808..98e77aaa8e 100644 --- a/Userland/Services/WindowServer/Menu.cpp +++ b/Userland/Services/WindowServer/Menu.cpp @@ -47,10 +47,6 @@ Menu::Menu(ConnectionFromClient* client, int menu_id, String name) m_alt_shortcut_character = find_ampersand_shortcut_character(m_name); } -Menu::~Menu() -{ -} - const Gfx::Font& Menu::font() const { return Gfx::FontDatabase::default_font(); diff --git a/Userland/Services/WindowServer/Menu.h b/Userland/Services/WindowServer/Menu.h index 348b58436e..8b1b40abf6 100644 --- a/Userland/Services/WindowServer/Menu.h +++ b/Userland/Services/WindowServer/Menu.h @@ -28,7 +28,7 @@ class Menu final : public Core::Object { C_OBJECT(Menu); public: - virtual ~Menu() override; + virtual ~Menu() override = default; ConnectionFromClient* client() { return m_client; } const ConnectionFromClient* client() const { return m_client; } diff --git a/Userland/Services/WindowServer/MenuItem.cpp b/Userland/Services/WindowServer/MenuItem.cpp index 14dde1545d..707a365327 100644 --- a/Userland/Services/WindowServer/MenuItem.cpp +++ b/Userland/Services/WindowServer/MenuItem.cpp @@ -31,10 +31,6 @@ MenuItem::MenuItem(Menu& menu, Type type) { } -MenuItem::~MenuItem() -{ -} - void MenuItem::set_enabled(bool enabled) { if (m_enabled == enabled) diff --git a/Userland/Services/WindowServer/MenuItem.h b/Userland/Services/WindowServer/MenuItem.h index 310e574274..cb9d640dff 100644 --- a/Userland/Services/WindowServer/MenuItem.h +++ b/Userland/Services/WindowServer/MenuItem.h @@ -25,7 +25,7 @@ public: MenuItem(Menu&, unsigned identifier, const String& text, const String& shortcut_text = {}, bool enabled = true, bool checkable = false, bool checked = false, const Gfx::Bitmap* icon = nullptr); MenuItem(Menu&, Type); - ~MenuItem(); + ~MenuItem() = default; Type type() const { return m_type; } diff --git a/Userland/Services/WindowServer/MenuManager.cpp b/Userland/Services/WindowServer/MenuManager.cpp index 3b0e631b30..e511befaf4 100644 --- a/Userland/Services/WindowServer/MenuManager.cpp +++ b/Userland/Services/WindowServer/MenuManager.cpp @@ -26,10 +26,6 @@ MenuManager::MenuManager() s_the = this; } -MenuManager::~MenuManager() -{ -} - bool MenuManager::is_open(const Menu& menu) const { for (size_t i = 0; i < m_open_menu_stack.size(); ++i) { diff --git a/Userland/Services/WindowServer/MenuManager.h b/Userland/Services/WindowServer/MenuManager.h index e9aa03a44f..c5177073f7 100644 --- a/Userland/Services/WindowServer/MenuManager.h +++ b/Userland/Services/WindowServer/MenuManager.h @@ -20,7 +20,7 @@ class MenuManager final : public Core::Object { public: static MenuManager& the(); - virtual ~MenuManager() override; + virtual ~MenuManager() override = default; bool is_open(const Menu&) const; bool has_open_menu() const { return !m_open_menu_stack.is_empty(); } diff --git a/Userland/Services/WindowServer/WindowFrame.cpp b/Userland/Services/WindowServer/WindowFrame.cpp index 97c7b44cc4..7c44578d27 100644 --- a/Userland/Services/WindowServer/WindowFrame.cpp +++ b/Userland/Services/WindowServer/WindowFrame.cpp @@ -112,9 +112,7 @@ void WindowFrame::window_was_constructed(Badge<Window>) m_has_alpha_channel = Gfx::WindowTheme::current().frame_uses_alpha(window_state_for_theme(), WindowManager::the().palette()); } -WindowFrame::~WindowFrame() -{ -} +WindowFrame::~WindowFrame() = default; void WindowFrame::set_button_icons() { diff --git a/Userland/Services/WindowServer/WindowManager.cpp b/Userland/Services/WindowServer/WindowManager.cpp index 152d023108..31dc9d56d2 100644 --- a/Userland/Services/WindowServer/WindowManager.cpp +++ b/Userland/Services/WindowServer/WindowManager.cpp @@ -68,10 +68,6 @@ WindowManager::WindowManager(Gfx::PaletteImpl const& palette) Compositor::the().did_construct_window_manager({}); } -WindowManager::~WindowManager() -{ -} - void WindowManager::reload_config() { m_config = Core::ConfigFile::open("/etc/WindowServer.ini", Core::ConfigFile::AllowWriting::Yes).release_value_but_fixme_should_propagate_errors(); diff --git a/Userland/Services/WindowServer/WindowManager.h b/Userland/Services/WindowServer/WindowManager.h index b6ec0885f8..ece88429df 100644 --- a/Userland/Services/WindowServer/WindowManager.h +++ b/Userland/Services/WindowServer/WindowManager.h @@ -69,7 +69,7 @@ public: static WindowManager& the(); - virtual ~WindowManager() override; + virtual ~WindowManager() override = default; Palette palette() const { return Palette(*m_palette); } diff --git a/Userland/Services/WindowServer/WindowStack.cpp b/Userland/Services/WindowServer/WindowStack.cpp index 7f307428e5..22f5233d05 100644 --- a/Userland/Services/WindowServer/WindowStack.cpp +++ b/Userland/Services/WindowServer/WindowStack.cpp @@ -15,10 +15,6 @@ WindowStack::WindowStack(unsigned row, unsigned column) { } -WindowStack::~WindowStack() -{ -} - void WindowStack::add(Window& window) { VERIFY(!window.is_on_any_window_stack({})); diff --git a/Userland/Services/WindowServer/WindowStack.h b/Userland/Services/WindowServer/WindowStack.h index 1fba705456..b95fc46a74 100644 --- a/Userland/Services/WindowServer/WindowStack.h +++ b/Userland/Services/WindowServer/WindowStack.h @@ -16,7 +16,7 @@ class Compositor; class WindowStack { public: WindowStack(unsigned row, unsigned column); - ~WindowStack(); + ~WindowStack() = default; bool is_empty() const { return m_windows.is_empty(); } void add(Window&); diff --git a/Userland/Services/WindowServer/WindowSwitcher.cpp b/Userland/Services/WindowServer/WindowSwitcher.cpp index f5b41727be..f359ffb998 100644 --- a/Userland/Services/WindowServer/WindowSwitcher.cpp +++ b/Userland/Services/WindowServer/WindowSwitcher.cpp @@ -28,10 +28,6 @@ WindowSwitcher::WindowSwitcher() s_the = this; } -WindowSwitcher::~WindowSwitcher() -{ -} - void WindowSwitcher::set_visible(bool visible) { if (m_visible == visible) diff --git a/Userland/Services/WindowServer/WindowSwitcher.h b/Userland/Services/WindowServer/WindowSwitcher.h index 0a5142087a..40ee72af9f 100644 --- a/Userland/Services/WindowServer/WindowSwitcher.h +++ b/Userland/Services/WindowServer/WindowSwitcher.h @@ -26,7 +26,7 @@ public: }; static WindowSwitcher& the(); - virtual ~WindowSwitcher() override; + virtual ~WindowSwitcher() override = default; bool is_visible() const { return m_visible; } void set_visible(bool); |