Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
style: Fix two issues with themed widgets in high contrast mode.
There were two issues with the existing code that we use to determine whether a widget is styled or not. First, it was using `color == Color::transparent()` instead of `color.is_transparent()` to check for transparent backgrounds. That is not sound as `Color::transparent()` is the literal value `rgba(0, 0, 0, 0)`, not the `transparent` keyword, so the equality check would fail. The other issue is that this function was early-returning false if that check was returning false. It is a bug for this function to early-return false, as it makes the result of the function dependent of the order of the declarations. Differential Revision: https://phabricator.services.mozilla.com/D62060
- Loading branch information