Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorJulian Eisel <julian@blender.org>2020-08-04 15:50:16 +0300
committerJulian Eisel <julian@blender.org>2020-08-04 16:05:24 +0300
commite1a10b5e537f802344207761bbd24c13aadadc6b (patch)
treec38c5dee56e1837274c68b4974c9c014e36509e7 /source
parent701a9d39175e0d3e5e2f776821f1251b8a7a5f78 (diff)
Fix T79234: Material preview does not update
When changing the material while the properties editor temporarily isn't visible (e.g. because another editor is in full-screen or a different workspace is active), the preview wouldn't be updated on changes. Always trigger a material preview update on screen layout or editor type changes.
Diffstat (limited to 'source')
-rw-r--r--source/blender/editors/space_buttons/space_buttons.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/source/blender/editors/space_buttons/space_buttons.c b/source/blender/editors/space_buttons/space_buttons.c
index 88c2c6e82b6..ac59bb245f3 100644
--- a/source/blender/editors/space_buttons/space_buttons.c
+++ b/source/blender/editors/space_buttons/space_buttons.c
@@ -493,6 +493,10 @@ static void buttons_area_listener(wmWindow *UNUSED(win),
if (wmn->data == ND_SPACE_PROPERTIES) {
ED_area_tag_redraw(area);
}
+ else if (wmn->data == ND_SPACE_CHANGED) {
+ ED_area_tag_redraw(area);
+ sbuts->preview = 1;
+ }
break;
case NC_ID:
if (wmn->action == NA_RENAME) {
@@ -533,6 +537,12 @@ static void buttons_area_listener(wmWindow *UNUSED(win),
sbuts->preview = 1;
}
break;
+ case NC_SCREEN:
+ if (wmn->data == ND_LAYOUTSET) {
+ ED_area_tag_redraw(area);
+ sbuts->preview = 1;
+ }
+ break;
#ifdef WITH_FREESTYLE
case NC_LINESTYLE:
ED_area_tag_redraw(area);