diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2013-03-15 23:56:29 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2013-03-15 23:56:29 +0400 |
commit | 88cf1a2bc73bbd2f2fbf2ba3d5b1e7d4a1db7a93 (patch) | |
tree | 0ff0b71ff27279f622be9ff872d100a64abc3aa4 /source/blender/windowmanager | |
parent | 433c82649e0eb7380dd8c6092e6b49cd1b84df26 (diff) |
Screen: add exit callback for area and region types, this gets called when
hiding or removing an area or region.
Diffstat (limited to 'source/blender/windowmanager')
-rw-r--r-- | source/blender/windowmanager/WM_api.h | 2 | ||||
-rw-r--r-- | source/blender/windowmanager/intern/wm_event_system.c | 7 |
2 files changed, 5 insertions, 4 deletions
diff --git a/source/blender/windowmanager/WM_api.h b/source/blender/windowmanager/WM_api.h index 6db310e44d1..4cac73b4cf6 100644 --- a/source/blender/windowmanager/WM_api.h +++ b/source/blender/windowmanager/WM_api.h @@ -306,7 +306,7 @@ void WM_gestures_remove(struct bContext *C); /* fileselecting support */ void WM_event_add_fileselect(struct bContext *C, struct wmOperator *op); -void WM_event_fileselect_event(struct bContext *C, void *ophandle, int eventval); +void WM_event_fileselect_event(struct wmWindowManager *wm, void *ophandle, int eventval); #ifndef NDEBUG void WM_event_print(const struct wmEvent *event); #endif diff --git a/source/blender/windowmanager/intern/wm_event_system.c b/source/blender/windowmanager/intern/wm_event_system.c index 5a24b371a98..b2647626f3a 100644 --- a/source/blender/windowmanager/intern/wm_event_system.c +++ b/source/blender/windowmanager/intern/wm_event_system.c @@ -2244,12 +2244,12 @@ void wm_event_do_handlers(bContext *C) /* ********** filesector handling ************ */ -void WM_event_fileselect_event(bContext *C, void *ophandle, int eventval) +void WM_event_fileselect_event(wmWindowManager *wm, void *ophandle, int eventval) { /* add to all windows! */ wmWindow *win; - for (win = CTX_wm_manager(C)->windows.first; win; win = win->next) { + for (win = wm->windows.first; win; win = win->next) { wmEvent event = *win->eventstate; event.type = EVT_FILESELECT; @@ -2271,6 +2271,7 @@ void WM_event_fileselect_event(bContext *C, void *ophandle, int eventval) void WM_event_add_fileselect(bContext *C, wmOperator *op) { wmEventHandler *handler, *handlernext; + wmWindowManager *wm = CTX_wm_manager(C); wmWindow *win = CTX_wm_window(C); int full = 1; // XXX preset? @@ -2302,7 +2303,7 @@ void WM_event_add_fileselect(bContext *C, wmOperator *op) op->type->check(C, op); /* ignore return value */ } - WM_event_fileselect_event(C, op, full ? EVT_FILESELECT_FULL_OPEN : EVT_FILESELECT_OPEN); + WM_event_fileselect_event(wm, op, full ? EVT_FILESELECT_FULL_OPEN : EVT_FILESELECT_OPEN); } #if 0 |