Fix operator execution resetting the cursor

Area and region are NULL in the context if the operator finishes.
This commit is contained in:
2018-05-18 11:42:58 +02:00
parent 1cf0930e89
commit 6e40b2de7a

View File

@@ -1958,7 +1958,7 @@ static int wm_handler_operator_call(bContext *C, ListBase *handlers, wmEventHand
/* set cursor back to the default for the region */
wmWindow *win = CTX_wm_window(C);
WM_cursor_grab_disable(win, NULL);
ED_region_cursor_set(win, CTX_wm_area(C), CTX_wm_region(C));
ED_region_cursor_set(win, area, region);
BLI_remlink(handlers, handler);
wm_event_free_handler(handler);