diff options
author | Hans Goudey <h.goudey@me.com> | 2020-10-02 21:10:21 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2020-10-02 21:10:21 +0300 |
commit | 933bf62a611f61bd61e3e7745ce6dea58f571e72 (patch) | |
tree | 671de906d3acbea69f32428899bbeb64a009d45c /source/blender/editors/interface/interface_intern.h | |
parent | 6f96dd85766a8159d5ffb761cbb4dbd20b7cad00 (diff) |
Property Search: Differentiate search filtered and inactive buttons
Currently there's no way to know if a button is inactive when it doesn't
match the search results, because they use the same 50% gray level.
This isn't a huge problem, but it could lead to confusion. This commit
uses a subtle solution, a 25% opacity when the button is inactive and
also filtered by search.
This requires flipping the meaning of the UI_SEARCH_FILTER_MATCHES
flag in the code, and also adding a widget_alpha_factor utility in
the widget code.
Differential Revision: https://developer.blender.org/D8975
Diffstat (limited to 'source/blender/editors/interface/interface_intern.h')
-rw-r--r-- | source/blender/editors/interface/interface_intern.h | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/source/blender/editors/interface/interface_intern.h b/source/blender/editors/interface/interface_intern.h index 91a71b0ca28..7ac6ca4577e 100644 --- a/source/blender/editors/interface/interface_intern.h +++ b/source/blender/editors/interface/interface_intern.h @@ -81,11 +81,8 @@ enum { UI_HAS_ICON = (1 << 3), UI_HIDDEN = (1 << 4), UI_SELECT_DRAW = (1 << 5), /* Display selected, doesn't impact interaction. */ - /** - * The button matches the search filter. When property search is active, this - * is used to determine which items to keep enabled and which to disable. - */ - UI_SEARCH_FILTER_MATCHES = (1 << 12), + /** Property search filter is active and the button does not match. */ + UI_SEARCH_FILTER_NO_MATCH = (1 << 12), /* warn: rest of uiBut->flag in UI_interface.h */ }; |