Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2012-01-17 06:20:23 +0400
committerCampbell Barton <ideasman42@gmail.com>2012-01-17 06:20:23 +0400
commitbbe69705a52386ca5b6552d7187b0492b4b2b378 (patch)
tree48fb3e4b70c78b2a31f1c6a0a02e33b09b0113f5 /source/blender/blenloader
parent0e0d88605f0ce7422f278c399b913d394bc7f3ca (diff)
parent67b2985cceaf789e1b77d4f70864bf67ee9375c3 (diff)
svn merge ^/trunk/blender -r43420:43436
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/readfile.c44
1 files changed, 44 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index 7e1634d6eca..978cb4d00e3 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -137,6 +137,7 @@
#include "BKE_scene.h"
#include "BKE_screen.h"
#include "BKE_sequencer.h"
+#include "BKE_text.h" // for txt_extended_ascii_as_utf8
#include "BKE_texture.h" // for open_plugin_tex
#include "BKE_tracking.h"
#include "BKE_utildefines.h" // SWITCH_INT DATA ENDB DNA1 O_BINARY GLOB USER TEST REND
@@ -13052,6 +13053,49 @@ static void do_versions(FileData *fd, Library *lib, Main *main)
}
}
}
+
+ if (main->versionfile < 261 || (main->versionfile == 261 && main->subversionfile < 3))
+ {
+ {
+ /* convert extended ascii to utf-8 for text editor */
+ Text *text;
+ for (text= main->text.first; text; text= text->id.next)
+ if(!(text->flags & TXT_ISEXT)) {
+ TextLine *tl;
+
+ for (tl= text->lines.first; tl; tl= tl->next) {
+ int added= txt_extended_ascii_as_utf8(&tl->line);
+ tl->len+= added;
+
+ /* reset cursor position if line was changed */
+ if (added && tl == text->curl)
+ text->curc = 0;
+ }
+ }
+ }
+ {
+ /* set new dynamic paint values */
+ Object *ob;
+ for(ob = main->object.first; ob; ob = ob->id.next) {
+ ModifierData *md;
+ for(md= ob->modifiers.first; md; md= md->next) {
+ if (md->type == eModifierType_DynamicPaint) {
+ DynamicPaintModifierData *pmd = (DynamicPaintModifierData *)md;
+ if(pmd->canvas)
+ {
+ DynamicPaintSurface *surface = pmd->canvas->surfaces.first;
+ for (; surface; surface=surface->next) {
+ surface->color_dry_threshold = 1.0f;
+ surface->influence_scale = 1.0f;
+ surface->radius_scale = 1.0f;
+ surface->flags |= MOD_DPAINT_USE_DRYING;
+ }
+ }
+ }
+ }
+ }
+ }
+ }
/* put compatibility code here until next subversion bump */
{