diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2014-01-21 13:01:32 +0400 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2014-01-21 13:01:32 +0400 |
commit | 2a7665697637810515fb3620dad19c72f1c13e13 (patch) | |
tree | f1cfc667757e53456b6f2bd0a02a506b0f03ce77 /source/blender/editors/screen/screen_edit.c | |
parent | e27dcc3423d5cb9781074f5eb0afc00496759e36 (diff) |
Fix T38295: Crash when changing screen with different visible layers
The issue was caused by missing object update for the curve object
before going to new screen. And that new screen had different visible
layers due to disabled lock_camera_and_layers option.
Solved by calling DAG_on_visible_update() in ED_screen_set() even
in cases scene doesn't change. This ensures all the objects which
weren't visible before are correctly updated.
Diffstat (limited to 'source/blender/editors/screen/screen_edit.c')
-rw-r--r-- | source/blender/editors/screen/screen_edit.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/source/blender/editors/screen/screen_edit.c b/source/blender/editors/screen/screen_edit.c index c10cb3313de..30337e81890 100644 --- a/source/blender/editors/screen/screen_edit.c +++ b/source/blender/editors/screen/screen_edit.c @@ -1545,8 +1545,13 @@ void ED_screen_set(bContext *C, bScreen *sc) */ if (oldscene != sc->scene) { BKE_scene_set_background(bmain, sc->scene); - DAG_on_visible_update(bmain, FALSE); } + + /* Always do visible update since it's possible new screen will + * have different layers visible in 3D viewpots. This is possible + * because of view3d.lock_camera_and_layers option. + */ + DAG_on_visible_update(bmain, FALSE); } } |