Add operator to close a window
[blender-staging.git] / source / blender / windowmanager / intern / wm_window.c
index 51feea55654c3e24f3994cce24f83753206eefb8..d8e6671afdab0c0d3db1582b755da6631d6af22b 100644 (file)
@@ -712,6 +712,14 @@ wmWindow *WM_window_open_temp(bContext *C, const rcti *rect_init, int type)
 
 /* ****************** Operators ****************** */
 
+int wm_window_close_exec(bContext *C, wmOperator *UNUSED(op))
+{
+       wmWindowManager *wm = CTX_wm_manager(C);
+       wmWindow *win = CTX_wm_window(C);
+       wm_window_close(C, wm, win);
+       return OPERATOR_FINISHED;
+}
+
 /* operator callback */
 int wm_window_duplicate_exec(bContext *C, wmOperator *UNUSED(op))
 {