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 <eiseljulian@gmail.com>2019-09-06 17:46:36 +0300
committerJulian Eisel <eiseljulian@gmail.com>2019-09-06 17:49:59 +0300
commit83a7d98a325232bef85bd7c66dccf911248abf05 (patch)
tree7ae0ad53785f35c898a69de88ba3e3e2734baa3d
parent24d05b5ff9d6d85a7ff8f58b47bef31b5dbcec81 (diff)
Fix: File browser report popups not showing up
Popup would be closed immediately after creating, because of incorrect mouse coordinates stored in window (popup is set to close if mouse is some distance away from it). Completes fix for T69581.
-rw-r--r--source/blender/windowmanager/intern/wm_event_system.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/windowmanager/intern/wm_event_system.c b/source/blender/windowmanager/intern/wm_event_system.c
index 7216278c9f9..2e3abfd9944 100644
--- a/source/blender/windowmanager/intern/wm_event_system.c
+++ b/source/blender/windowmanager/intern/wm_event_system.c
@@ -2397,6 +2397,9 @@ static int wm_handler_fileselect_do(bContext *C,
CTX_wm_window_set(C, ctx_win); // wm_window_close() NULLs.
/* Some operators expect a drawable context (for EVT_FILESELECT_EXEC) */
wm_window_make_drawable(wm, ctx_win);
+ /* Ensure correct cursor positon, otherwise, popups may close immediately after
+ * opening (UI_BLOCK_MOVEMOUSE_QUIT) */
+ wm_get_cursor_position(ctx_win, &ctx_win->eventstate->x, &ctx_win->eventstate->y);
wm->winactive = ctx_win; /* Reports use this... */
}
else if (file_sa->full) {