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>2020-03-31 17:39:59 +0300
committerJulian Eisel <julian@blender.org>2020-03-31 17:49:38 +0300
commitf149d5e4b21f372f779fdb28b39984355c9682a6 (patch)
treee9e943b80c4432070eda62e3364ee6426911fd7f /source/blender/windowmanager
parentafe707cc3a3d0185b3b750bc9e907838bbea8e0c (diff)
Fix VR session toggle not changing reliably on session start/end
The text and icon were supposed to change but didn't reliably, which was a race condition I think. It depended on how fast the OpenXR runtime would transition the session state. This also makes sure the correct notifier is sent on session exit.
Diffstat (limited to 'source/blender/windowmanager')
-rw-r--r--source/blender/windowmanager/intern/wm_operators.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/windowmanager/intern/wm_operators.c b/source/blender/windowmanager/intern/wm_operators.c
index e782b802729..c3446a016f1 100644
--- a/source/blender/windowmanager/intern/wm_operators.c
+++ b/source/blender/windowmanager/intern/wm_operators.c
@@ -3711,6 +3711,8 @@ static void wm_xr_session_update_screen(Main *bmain, const wmXrData *xr_data)
}
}
}
+
+ WM_main_add_notifier(NC_WM | ND_XR_DATA_CHANGED, NULL);
}
static void wm_xr_session_update_screen_on_exit_cb(const wmXrData *xr_data)