diff options
author | Andreas Kling <kling@serenityos.org> | 2020-02-06 13:32:14 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2020-02-06 13:32:14 +0100 |
commit | f8b00aa29010cc3a99b285d0afd88314c40be079 (patch) | |
tree | 578b042c504966843609d9c6260093d859e67306 /Servers | |
parent | 9b87843af169b08f1b852da96f696004866783fe (diff) | |
download | serenity-f8b00aa29010cc3a99b285d0afd88314c40be079.zip |
LibGfx: Unpublish Gfx::Size from the global namespace
Diffstat (limited to 'Servers')
-rw-r--r-- | Servers/WindowServer/WSCursor.h | 2 | ||||
-rw-r--r-- | Servers/WindowServer/WSScreen.h | 2 | ||||
-rw-r--r-- | Servers/WindowServer/WSWindow.h | 6 | ||||
-rw-r--r-- | Servers/WindowServer/WSWindowManager.cpp | 4 |
4 files changed, 7 insertions, 7 deletions
diff --git a/Servers/WindowServer/WSCursor.h b/Servers/WindowServer/WSCursor.h index 4f42de6ffd..881cd8d282 100644 --- a/Servers/WindowServer/WSCursor.h +++ b/Servers/WindowServer/WSCursor.h @@ -51,7 +51,7 @@ public: const Gfx::Bitmap& bitmap() const { return *m_bitmap; } Gfx::Rect rect() const { return m_bitmap->rect(); } - Size size() const { return m_bitmap->size(); } + Gfx::Size size() const { return m_bitmap->size(); } private: WSCursor(NonnullRefPtr<Gfx::Bitmap>&&, const Gfx::Point&); diff --git a/Servers/WindowServer/WSScreen.h b/Servers/WindowServer/WSScreen.h index 28e486e10a..cee4700c66 100644 --- a/Servers/WindowServer/WSScreen.h +++ b/Servers/WindowServer/WSScreen.h @@ -49,7 +49,7 @@ public: static WSScreen& the(); - Size size() const { return { width(), height() }; } + Gfx::Size size() const { return { width(), height() }; } Gfx::Rect rect() const { return { 0, 0, width(), height() }; } Gfx::Point cursor_location() const { return m_cursor_location; } diff --git a/Servers/WindowServer/WSWindow.h b/Servers/WindowServer/WSWindow.h index 75976f397e..215cfdc177 100644 --- a/Servers/WindowServer/WSWindow.h +++ b/Servers/WindowServer/WSWindow.h @@ -159,7 +159,7 @@ public: void set_position(const Gfx::Point& position) { set_rect({ position.x(), position.y(), width(), height() }); } void set_position_without_repaint(const Gfx::Point& position) { set_rect_without_repaint({ position.x(), position.y(), width(), height() }); } - Size size() const { return m_rect.size(); } + Gfx::Size size() const { return m_rect.size(); } void invalidate(); void invalidate(const Gfx::Rect&); @@ -193,10 +193,10 @@ public: bool has_alpha_channel() const { return m_has_alpha_channel; } void set_has_alpha_channel(bool value) { m_has_alpha_channel = value; } - Size size_increment() const { return m_size_increment; } + Gfx::Size size_increment() const { return m_size_increment; } void set_size_increment(const Gfx::Size& increment) { m_size_increment = increment; } - Size base_size() const { return m_base_size; } + Gfx::Size base_size() const { return m_base_size; } void set_base_size(const Gfx::Size& size) { m_base_size = size; } const Gfx::Bitmap& icon() const { return *m_icon; } diff --git a/Servers/WindowServer/WSWindowManager.cpp b/Servers/WindowServer/WSWindowManager.cpp index 24502b4a7d..3b97e297c9 100644 --- a/Servers/WindowServer/WSWindowManager.cpp +++ b/Servers/WindowServer/WSWindowManager.cpp @@ -146,7 +146,7 @@ void WSWindowManager::set_resolution(int width, int height) client.notify_about_new_screen_rect(WSScreen::the().rect()); }); if (m_wm_config) { - dbg() << "Saving resolution: " << Size(width, height) << " to config file at " << m_wm_config->file_name(); + dbg() << "Saving resolution: " << Gfx::Size(width, height) << " to config file at " << m_wm_config->file_name(); m_wm_config->write_num_entry("Screen", "Width", width); m_wm_config->write_num_entry("Screen", "Height", height); m_wm_config->sync(); @@ -542,7 +542,7 @@ bool WSWindowManager::process_ongoing_window_resize(const WSMouseEvent& event, W auto new_rect = m_resize_window_original_rect; // First, size the new rect. - Size minimum_size { 50, 50 }; + Gfx::Size minimum_size { 50, 50 }; new_rect.set_width(max(minimum_size.width(), new_rect.width() + change_w)); new_rect.set_height(max(minimum_size.height(), new_rect.height() + change_h)); |