mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-10-02 06:09:51 +00:00
LibGUI: Make Widget::HitTestResult::widget a WeakPtr
This commit is contained in:
parent
c17fa67f51
commit
094b47971b
Notes:
sideshowbarker
2024-07-19 00:01:44 +09:00
Author: https://github.com/awesomekling
Commit: 094b47971b
1 changed files with 5 additions and 3 deletions
|
@ -184,10 +184,12 @@ public:
|
||||||
void set_focus_policy(FocusPolicy policy);
|
void set_focus_policy(FocusPolicy policy);
|
||||||
FocusPolicy focus_policy() const;
|
FocusPolicy focus_policy() const;
|
||||||
|
|
||||||
enum class ShouldRespectGreediness { No = 0,
|
enum class ShouldRespectGreediness {
|
||||||
Yes };
|
No = 0,
|
||||||
|
Yes
|
||||||
|
};
|
||||||
struct HitTestResult {
|
struct HitTestResult {
|
||||||
Widget* widget { nullptr };
|
WeakPtr<Widget> widget;
|
||||||
Gfx::IntPoint local_position;
|
Gfx::IntPoint local_position;
|
||||||
};
|
};
|
||||||
HitTestResult hit_test(const Gfx::IntPoint&, ShouldRespectGreediness = ShouldRespectGreediness::Yes);
|
HitTestResult hit_test(const Gfx::IntPoint&, ShouldRespectGreediness = ShouldRespectGreediness::Yes);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue