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>2020-10-10 14:40:38 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-10-10 14:43:11 +0300
commit4427a67c86450a704bd35b0f7539c0adf152fea2 (patch)
tree60c1f2751e2e34774bab744724defae6166a1cfc /source/blender/blenloader/intern/versioning_legacy.c
parent5336555c31b3716f68e4c74f6a047c03c066049c (diff)
Cleanup: use macro for comparing file versions
Already done in most of the versioning code.
Diffstat (limited to 'source/blender/blenloader/intern/versioning_legacy.c')
-rw-r--r--source/blender/blenloader/intern/versioning_legacy.c30
1 files changed, 15 insertions, 15 deletions
diff --git a/source/blender/blenloader/intern/versioning_legacy.c b/source/blender/blenloader/intern/versioning_legacy.c
index b8d9b92a75d..666806479b2 100644
--- a/source/blender/blenloader/intern/versioning_legacy.c
+++ b/source/blender/blenloader/intern/versioning_legacy.c
@@ -2150,7 +2150,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if ((bmain->versionfile < 245) || (bmain->versionfile == 245 && bmain->subversionfile < 2)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 245, 2)) {
Image *ima;
/* initialize 1:1 Aspect */
@@ -2159,7 +2159,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if ((bmain->versionfile < 245) || (bmain->versionfile == 245 && bmain->subversionfile < 4)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 245, 4)) {
bArmature *arm;
ModifierData *md;
Object *ob;
@@ -2177,7 +2177,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if ((bmain->versionfile < 245) || (bmain->versionfile == 245 && bmain->subversionfile < 5)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 245, 5)) {
/* foreground color needs to be something other then black */
Scene *sce;
for (sce = bmain->scenes.first; sce; sce = sce->id.next) {
@@ -2187,7 +2187,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if ((bmain->versionfile < 245) || (bmain->versionfile == 245 && bmain->subversionfile < 6)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 245, 6)) {
Scene *sce;
/* fix frs_sec_base */
for (sce = bmain->scenes.first; sce; sce = sce->id.next) {
@@ -2197,7 +2197,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if ((bmain->versionfile < 245) || (bmain->versionfile == 245 && bmain->subversionfile < 7)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 245, 7)) {
Object *ob;
bPoseChannel *pchan;
@@ -2227,7 +2227,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if ((bmain->versionfile < 245) || (bmain->versionfile == 245 && bmain->subversionfile < 8)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 245, 8)) {
Scene *sce;
Object *ob;
PartEff *paf = NULL;
@@ -2394,7 +2394,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if ((bmain->versionfile < 245) || (bmain->versionfile == 245 && bmain->subversionfile < 10)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 245, 10)) {
Object *ob;
/* dupliface scale */
@@ -2403,7 +2403,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if ((bmain->versionfile < 245) || (bmain->versionfile == 245 && bmain->subversionfile < 11)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 245, 11)) {
Object *ob;
bActionStrip *strip;
@@ -2437,7 +2437,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if ((bmain->versionfile < 245) || (bmain->versionfile == 245 && bmain->subversionfile < 14)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 245, 14)) {
Scene *sce;
Sequence *seq;
@@ -2452,7 +2452,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
/* fix broken group lengths in id properties */
- if ((bmain->versionfile < 245) || (bmain->versionfile == 245 && bmain->subversionfile < 15)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 245, 15)) {
idproperties_fix_group_lengths(bmain->scenes);
idproperties_fix_group_lengths(bmain->libraries);
idproperties_fix_group_lengths(bmain->objects);
@@ -2481,7 +2481,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
/* convert fluids to modifier */
- if (bmain->versionfile < 246 || (bmain->versionfile == 246 && bmain->subversionfile < 1)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 246, 1)) {
Object *ob;
for (ob = bmain->objects.first; ob; ob = ob->id.next) {
@@ -2502,7 +2502,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if (bmain->versionfile < 246 || (bmain->versionfile == 246 && bmain->subversionfile < 1)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 246, 1)) {
Object *ob;
for (ob = bmain->objects.first; ob; ob = ob->id.next) {
if (ob->pd && (ob->pd->forcefield == PFIELD_WIND)) {
@@ -2512,7 +2512,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
/* set the curve radius interpolation to 2.47 default - easy */
- if (bmain->versionfile < 247 || (bmain->versionfile == 247 && bmain->subversionfile < 6)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 247, 6)) {
Curve *cu;
Nurb *nu;
@@ -2532,7 +2532,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if (bmain->versionfile < 248 || (bmain->versionfile == 248 && bmain->subversionfile < 2)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 248, 2)) {
Scene *sce;
/* Note, these will need to be added for painting */
@@ -2542,7 +2542,7 @@ void blo_do_versions_pre250(FileData *fd, Library *lib, Main *bmain)
}
}
- if (bmain->versionfile < 248 || (bmain->versionfile == 248 && bmain->subversionfile < 3)) {
+ if (!MAIN_VERSION_ATLEAST(bmain, 248, 3)) {
bScreen *screen;
/* adjust default settings for Animation Editors */