diff options
author | Hans Goudey <h.goudey@me.com> | 2020-06-29 22:00:25 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2020-06-29 22:00:25 +0300 |
commit | 1fa40c9f8a81036476d5051b09ff15e27b628012 (patch) | |
tree | 37a5fa840d8eae820b5aff81fbe4e3e36599aab3 /source/blender/editors/interface/interface_layout.c | |
parent | 4f8a881715ca71599c1f4ee82b76cbce0a02b4d9 (diff) |
UI: Add shortcuts for modifier panels
The shortcuts act on the modifier with its panel under the mouse.
The following shortcuts are enabled by default:
- Remove modifier: X, Delete
- Apply modifier: Ctrl A
- Duplicate modifier: Shift D
More shortcuts can be added in the keymap.
Each panel can now store a custom data RNA pointer, and a new
function is added to get the custom data for the panel under the
cursor. This custom data could be used to refactor the "List Panel
System" to generalize it and integrate it further with RNA.
The same functionality will be added in further commits where it
applies to constraints, grease pencil modifiers, and effects.
Differential Revision: https://developer.blender.org/D8031
Diffstat (limited to 'source/blender/editors/interface/interface_layout.c')
-rw-r--r-- | source/blender/editors/interface/interface_layout.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/editors/interface/interface_layout.c b/source/blender/editors/interface/interface_layout.c index 6aefef197df..771e9383b8a 100644 --- a/source/blender/editors/interface/interface_layout.c +++ b/source/blender/editors/interface/interface_layout.c @@ -5576,6 +5576,7 @@ static void ui_paneltype_draw_impl(bContext *C, PanelType *pt, uiLayout *layout, panel->layout = layout; pt->draw(C, panel); panel->layout = NULL; + BLI_assert(panel->runtime.custom_data_ptr = NULL); MEM_freeN(panel); |