diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2011-12-08 15:37:04 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2011-12-08 15:37:04 +0400 |
commit | 5fbc3b57d44b17a49f62253817812d560625b00c (patch) | |
tree | 6e68fcf8842055a00cf85b07b889e28612aac915 | |
parent | 36e7a22fcc3c7ad3b66f5798c6c9a3ad9e0972ea (diff) |
Fix #29546: missing 3d view redraw after game exit with overlap draw mode,
when launching game from properties editor. Also fix popup/menu still
showing during game when starting from the top menu.
-rw-r--r-- | source/blender/editors/space_view3d/view3d_view.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/source/blender/editors/space_view3d/view3d_view.c b/source/blender/editors/space_view3d/view3d_view.c index 90f617513a5..89f859d0976 100644 --- a/source/blender/editors/space_view3d/view3d_view.c +++ b/source/blender/editors/space_view3d/view3d_view.c @@ -1715,6 +1715,10 @@ static int game_engine_exec(bContext *C, wmOperator *op) if(!ED_view3d_context_activate(C)) return OPERATOR_CANCELLED; + /* redraw to hide any menus/popups, we don't go back to + the window manager until after this operator exits */ + WM_redraw_windows(C); + rv3d= CTX_wm_region_view3d(C); /* sa= CTX_wm_area(C); */ /* UNUSED */ ar= CTX_wm_region(C); @@ -1750,6 +1754,8 @@ static int game_engine_exec(bContext *C, wmOperator *op) CTX_wm_window_set(C, NULL); } + ED_area_tag_redraw(CTX_wm_area(C)); + if(prevwin) { /* restore context, in case it changed in the meantime, for example by working in another window or closing it */ @@ -1763,8 +1769,6 @@ static int game_engine_exec(bContext *C, wmOperator *op) //XXX restore_all_scene_cfra(scene_cfra_store); set_scene_bg(CTX_data_main(C), startscene); //XXX scene_update_for_newframe(bmain, scene, scene->lay); - - ED_area_tag_redraw(CTX_wm_area(C)); return OPERATOR_FINISHED; #else |