mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 06:47:35 +00:00
WindowManager: Allow disabling window hit testing altogether
This allows us to disable hit testing for transparent windows that don't use alpha channels.
This commit is contained in:
parent
7269e0f751
commit
7e9c265cc0
2 changed files with 7 additions and 0 deletions
|
@ -949,6 +949,8 @@ bool Window::hit_test(const Gfx::IntPoint& point, bool include_frame) const
|
|||
return frame().hit_test(point);
|
||||
return false;
|
||||
}
|
||||
if (!m_hit_testing_enabled)
|
||||
return false;
|
||||
u8 threshold = alpha_hit_threshold() * 255;
|
||||
if (threshold == 0 || !m_backing_store || !m_backing_store->has_alpha_channel())
|
||||
return true;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue