diff options
author | Philipp Oeser <info@graphics-engineer.com> | 2021-05-14 14:21:10 +0300 |
---|---|---|
committer | Philipp Oeser <info@graphics-engineer.com> | 2021-05-14 18:16:05 +0300 |
commit | c3e13d5a2b8e9ada467850b4629dc4f228a2b2b8 (patch) | |
tree | 44fe7f7515615020fbe0fb936f30131f5d9103a3 /source/blender/editors/include/ED_gpencil.h | |
parent | d19d79c5a644914564902c685f32e94e1b6449bb (diff) |
GPencil: fix separate points/strokes freezing with empty selection
Code would still create an object (without setting up materials), code
for removing unused material slots would then freeze.
Now return/cancel early in case of empty selection.
This came up in T88269 [which is still not fully fixed, transforming
curve edit points clear their GP_STROKE_SELECT flag which now results in
the early exit, should be looked at separately]
Maniphest Tasks: T88269
Differential Revision: https://developer.blender.org/D11252
Diffstat (limited to 'source/blender/editors/include/ED_gpencil.h')
-rw-r--r-- | source/blender/editors/include/ED_gpencil.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/editors/include/ED_gpencil.h b/source/blender/editors/include/ED_gpencil.h index e9ac21f60cf..d4ff374dc38 100644 --- a/source/blender/editors/include/ED_gpencil.h +++ b/source/blender/editors/include/ED_gpencil.h @@ -144,6 +144,8 @@ bool ED_gpencil_data_owner_is_annotation(struct PointerRNA *owner_ptr); bool ED_gpencil_has_keyframe_v3d(struct Scene *scene, struct Object *ob, int cfra); /* ----------- Stroke Editing Utilities ---------------- */ +bool ED_gpencil_frame_has_selected_stroke(const struct bGPDframe *gpf); +bool ED_gpencil_layer_has_selected_stroke(const struct bGPDlayer *gpl, const bool is_multiedit); bool ED_gpencil_stroke_can_use_direct(const struct ScrArea *area, const struct bGPDstroke *gps); bool ED_gpencil_stroke_can_use(const struct bContext *C, const struct bGPDstroke *gps); |