diff options
author | Tamito Kajiyama <rd6t-kjym@asahi-net.or.jp> | 2011-09-15 04:06:49 +0400 |
---|---|---|
committer | Tamito Kajiyama <rd6t-kjym@asahi-net.or.jp> | 2011-09-15 04:06:49 +0400 |
commit | f24255b5a03f68a2ef4e09eb55d93dc21a1f44c0 (patch) | |
tree | 55e57ce12ac10b554c39001b84abe0de89a4e075 /source/blender/freestyle/intern/blender_interface/FRS_freestyle.cpp | |
parent | 7ae9a81323cf7a12356831e4a2ed4df06f924581 (diff) |
Fix for the Link/Append commands not working when scenes had line styles.
The problem was reported by mato.sus304, thank you!
Diffstat (limited to 'source/blender/freestyle/intern/blender_interface/FRS_freestyle.cpp')
-rw-r--r-- | source/blender/freestyle/intern/blender_interface/FRS_freestyle.cpp | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/source/blender/freestyle/intern/blender_interface/FRS_freestyle.cpp b/source/blender/freestyle/intern/blender_interface/FRS_freestyle.cpp index 2a82f4ab812..ec3bd9f5c5b 100644 --- a/source/blender/freestyle/intern/blender_interface/FRS_freestyle.cpp +++ b/source/blender/freestyle/intern/blender_interface/FRS_freestyle.cpp @@ -16,6 +16,7 @@ extern "C" { #include "DNA_camera_types.h" #include "DNA_text_types.h" +#include "DNA_group_types.h" #include "DNA_freestyle_types.h" #include "BKE_global.h" @@ -418,6 +419,10 @@ extern "C" { FreestyleLineSet *lineset; for(lineset=(FreestyleLineSet *)srl->freestyleConfig.linesets.first; lineset; lineset=lineset->next) { + if (lineset->group) { + lineset->group->id.us--; + lineset->group = NULL; + } lineset->linestyle->id.us--; lineset->linestyle = NULL; } @@ -479,6 +484,10 @@ extern "C" { FreestyleLineSet *lineset = FRS_get_active_lineset(config); if (lineset) { + if (lineset->group) { + lineset->group->id.us--; + lineset->group = NULL; + } lineset->linestyle->id.us--; lineset->linestyle = NULL; BLI_remlink(&config->linesets, lineset); |