diff options
author | Julian Eisel <eiseljulian@gmail.com> | 2019-09-07 17:00:19 +0300 |
---|---|---|
committer | Julian Eisel <eiseljulian@gmail.com> | 2019-09-07 17:08:56 +0300 |
commit | ab823176d31dc155645de733f1cd4fbd6ad74592 (patch) | |
tree | 10f45f4e88d0e5fb93f5a97291c5857c109386f3 /source/blender/windowmanager/wm_event_system.h | |
parent | fa7ee622f0fb2f7482dbae94df194a3b33a73a98 (diff) |
Fix saving images from temp Image Editor failing
Steps to reproduce were:
* Ensure //Render//->//Display Mode// is //New Window//
* F12
* In the opened Image Editor, Alt+S to save the image
* Save the image
The saving would fail silently.
Issue was that wm_handler_op_context() would fail to find the correct
area to activate, as the wrong window was active in context. So allow
overriding this window and do so when creating the file-select handler.
Diffstat (limited to 'source/blender/windowmanager/wm_event_system.h')
-rw-r--r-- | source/blender/windowmanager/wm_event_system.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/windowmanager/wm_event_system.h b/source/blender/windowmanager/wm_event_system.h index 53b25a80dce..c53ccda170a 100644 --- a/source/blender/windowmanager/wm_event_system.h +++ b/source/blender/windowmanager/wm_event_system.h @@ -116,6 +116,10 @@ typedef struct wmEventHandler_Op { /** Store context for this handler for derived/modal handlers. */ struct { + /* To override the window, and hence the screen. Set for few cases only, usually window/screen + * can be taken from current context. */ + struct wmWindow *win; + struct ScrArea *area; struct ARegion *region; short region_type; |