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
diff options
context:
space:
mode:
authorJulian Eisel <julian@blender.org>2021-03-11 20:40:42 +0300
committerJulian Eisel <julian@blender.org>2021-03-11 20:47:14 +0300
commit8c6337e587bd2d738398474ce6068a748bd1b85b (patch)
treeb0d2cd6555100e768b4cc7efbe93a5bdf393c1fe /source/blender/windowmanager/intern/wm_event_system.c
parent1b1f8da5dde04f301c779e9426138b5cb76dc32a (diff)
Fix missing UI updates, caused by own earlier commit
Caused by 46aa70cb486d. RNA would send property update notifiers with the owner ID as `reference` data. Since above's commit we'd only send the notifiers to editors if the reference data address matches the space's address. So editors wouldn't get the notifiers at all. The owner ID for space properties is always the screen AFAIK. So allow notifiers with the screen as reference to be passed to editors as well, think this is reasonable to do either way. For example, steps to reproduce were: * Open Asset Browser * Mark some data-blocks of different types as assets (e.g. object & its material) * Switch between the categories in the Asset Browser. The asset list wouldn't be updated.
Diffstat (limited to 'source/blender/windowmanager/intern/wm_event_system.c')
-rw-r--r--source/blender/windowmanager/intern/wm_event_system.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/source/blender/windowmanager/intern/wm_event_system.c b/source/blender/windowmanager/intern/wm_event_system.c
index 33ba27c849c..646aa71025c 100644
--- a/source/blender/windowmanager/intern/wm_event_system.c
+++ b/source/blender/windowmanager/intern/wm_event_system.c
@@ -577,9 +577,12 @@ void wm_event_do_notifiers(bContext *C)
}
ED_screen_areas_iter (win, screen, area) {
- if ((note->category == NC_SPACE) && note->reference &&
- (note->reference != area->spacedata.first)) {
- continue;
+ if ((note->category == NC_SPACE) && note->reference) {
+ /* Filter out notifiers sent to other spaces. RNA sets the reference to the owning ID
+ * though, the screen, so let notifiers through that reference the entire screen. */
+ if ((note->reference != area->spacedata.first) && (note->reference != screen)) {
+ continue;
+ }
}
wmSpaceTypeListenerParams area_params = {
.window = win,