WindowServer: Make hit test results richer

Instead of just answering hit/no-hit when hit testing windows, we now
return a HitTestResult object which tells you which window was hit,
where it was hit, and whether you hit the frame or the content.
This commit is contained in:
Andreas Kling 2021-06-18 00:47:38 +02:00
commit 4133caba78
Notes: sideshowbarker 2024-07-18 12:04:59 +09:00
6 changed files with 91 additions and 45 deletions

View file

@ -6,6 +6,7 @@
#pragma once
#include "HitTestResult.h"
#include <AK/Forward.h>
#include <AK/NonnullOwnPtrVector.h>
#include <AK/RefPtr.h>
@ -78,7 +79,7 @@ public:
void theme_changed();
bool hit_test(const Gfx::IntPoint&) const;
Optional<HitTestResult> hit_test(Gfx::IntPoint const&) const;
void open_menubar_menu(Menu&);