- https://www.afonde.com/
-
Research Engineer at the animation studio Les Fées Spéciales. Occasional contributor to Grease Pencil.
- Joined on
2022-01-17
Maybe here we could check if the layer is nullptr
, and return false in that case.
Hey, the patch looks good to me. I think it would be even better if this PR included a new grease_pencil->is_layer_active
function that we could use everywhere. I was planning to do this after…
Oh, yes, sorry I forgot about that. Well, forget about the first part of my comment then.
We can still use grease_pencil->set_active_layer
though.
Thanks for the patch. I think it would be nice if we use the API a little more to manipulate the layers' data, I've left a few comments in that direction. (Actually, this could have been in my review of the previous PR, sorry.)
if ((layer->is_selected()) && (selectmode != SELECT_EXTEND_RANGE))
Better to use grease_pencil->get_active_layer() == ale->data;