Blender Git Commit Log

Git Commits -> Revision 063be8f

Revision 063be8f by Bastien Montagne (master)
June 26, 2013, 07:28 (GMT)
Fix [#35750] list items in properties editor (text colors not following list item theme).

Issue goes back since we stopped using LISTROW button to draw item's name (i.e. since we have custom buttons in list items!).

This commit:
* Adds a new flag to uiBlock, UI_BLOCK_LIST_ITEM, to mark blocks used for each list item.
* Adds a new button type, LISTLABEL, which basically behaves exactly as LABEL, but uses wcol_list_item color set.
* When uiItemL is called, it checks whether current block has UI_BLOCK_LIST_ITEM set, and if so, switch produced button to LISTLABEL type.
* Adds a new helper func, ui_layout_list_set_labels_active, called after the active list item has been "drawn", to set all LISTLABEL buttons as UI_SELECT.

Note custom widget_state_label() was removed, in interface_widgets.c, as it did nothing more than default widget_state().

Thanks to Brecht for the review and advices.

Commit Details:

Full Hash: 063be8fdc03e2fed9d2bec4fc80db6b55fec42c1
SVN Revision: 57760
Parent Commit: c0c9f53
Lines Changed: +57, -25

6 Modified Paths:

/source/blender/editors/include/UI_interface.h (+5, -2) (Diff)
/source/blender/editors/interface/interface_handlers.c (+6, -5) (Diff)
/source/blender/editors/interface/interface_intern.h (+3, -1) (Diff)
/source/blender/editors/interface/interface_layout.c (+19, -2) (Diff)
/source/blender/editors/interface/interface_templates.c (+14, -0) (Diff)
/source/blender/editors/interface/interface_widgets.c (+10, -15) (Diff)
By: Miika HämäläinenLast update: Nov-07-2014 14:18MiikaHweb | 2003-2021