Fix T79373: Forbid painting on linked image.
There is just no reason to support that kind of useless behavior. Some remote TODO could be to define a process based on liboverride and layers.
This commit is contained in:
parent
b8b60e132d
commit
d72b5785eb
Notes:
blender-bot
2023-02-14 11:28:39 +01:00
Referenced by issue #79373, Crash undo painting on linked image
|
@ -288,6 +288,9 @@ static bool image_paint_poll_ex(bContext *C, bool check_tool)
|
|||
SpaceImage *sima = CTX_wm_space_image(C);
|
||||
|
||||
if (sima) {
|
||||
if (sima->image != NULL && ID_IS_LINKED(sima->image)) {
|
||||
return false;
|
||||
}
|
||||
ARegion *region = CTX_wm_region(C);
|
||||
|
||||
if ((sima->mode == SI_MODE_PAINT) && region->regiontype == RGN_TYPE_WINDOW) {
|
||||
|
|
Loading…
Reference in New Issue