LibGUI: Add Window::constrain_to_desktop() helper

And a center_within(IntRect const&) overload
This commit is contained in:
thankyouverycool 2023-05-13 05:06:46 -04:00 committed by Andreas Kling
commit dfe06096c7
Notes: sideshowbarker 2024-07-17 05:41:34 +09:00
2 changed files with 25 additions and 0 deletions

View file

@ -129,7 +129,10 @@ public:
void resize(Gfx::IntSize size) { set_rect({ position(), size }); }
void center_on_screen();
void constrain_to_desktop();
void center_within(Window const&);
void center_within(Gfx::IntRect const&);
virtual void event(Core::Event&) override;