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:
authorHans Goudey <h.goudey@me.com>2022-02-18 18:50:29 +0300
committerHans Goudey <h.goudey@me.com>2022-02-18 18:50:29 +0300
commitddf189892c596d939228cc531b775bfd6708bb2d (patch)
treecb3b28527696ef5a6a3eec581a55e6141c2e686d /source/blender/editors/object/object_edit.c
parent48b17da1d9fe4d559c5b0fa58029df05a45d3960 (diff)
Cleanup: Rename original curve object type enum
This commit renames enums related the "Curve" object type and ID type to add `_LEGACY` to the end. The idea is to make our aspirations clearer in the code and to avoid ambiguities between `CURVE` and `CURVES`. Ref T95355 To summarize for the record, the plans are: - In the short/medium term, replace the `Curve` object data type with `Curves` - In the longer term (no immediate plans), use a proper data block for 3D text and surfaces. Differential Revision: https://developer.blender.org/D14114
Diffstat (limited to 'source/blender/editors/object/object_edit.c')
-rw-r--r--source/blender/editors/object/object_edit.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/editors/object/object_edit.c b/source/blender/editors/object/object_edit.c
index e4a026d3205..58594affc05 100644
--- a/source/blender/editors/object/object_edit.c
+++ b/source/blender/editors/object/object_edit.c
@@ -568,7 +568,7 @@ static bool ED_object_editmode_load_free_ex(Main *bmain,
*/
DEG_relations_tag_update(bmain);
}
- else if (ELEM(obedit->type, OB_CURVE, OB_SURF)) {
+ else if (ELEM(obedit->type, OB_CURVES_LEGACY, OB_SURF)) {
const Curve *cu = obedit->data;
if (cu->editnurb == NULL) {
return false;
@@ -799,7 +799,7 @@ bool ED_object_editmode_enter_ex(Main *bmain, Scene *scene, Object *ob, int flag
WM_main_add_notifier(NC_SCENE | ND_MODE | NS_EDITMODE_LATTICE, scene);
}
- else if (ELEM(ob->type, OB_SURF, OB_CURVE)) {
+ else if (ELEM(ob->type, OB_SURF, OB_CURVES_LEGACY)) {
ok = true;
ED_curve_editnurb_make(ob);
@@ -1023,7 +1023,7 @@ void ED_object_check_force_modifiers(Main *bmain, Scene *scene, Object *object)
if (!md) {
if (pd && (pd->shape == PFIELD_SHAPE_SURFACE) &&
!ELEM(pd->forcefield, 0, PFIELD_GUIDE, PFIELD_TEXTURE)) {
- if (ELEM(object->type, OB_MESH, OB_SURF, OB_FONT, OB_CURVE)) {
+ if (ELEM(object->type, OB_MESH, OB_SURF, OB_FONT, OB_CURVES_LEGACY)) {
ED_object_modifier_add(NULL, bmain, scene, object, NULL, eModifierType_Surface);
}
}
@@ -1552,7 +1552,7 @@ static int shade_smooth_exec(bContext *C, wmOperator *op)
BKE_mesh_batch_cache_dirty_tag(ob->data, BKE_MESH_BATCH_DIRTY_ALL);
changed = true;
}
- else if (ELEM(ob->type, OB_SURF, OB_CURVE)) {
+ else if (ELEM(ob->type, OB_SURF, OB_CURVES_LEGACY)) {
BKE_curve_smooth_flag_set(ob->data, use_smooth);
changed = true;
}