diff options
author | Dalai Felinto <dfelinto@gmail.com> | 2017-11-09 18:23:01 +0300 |
---|---|---|
committer | Dalai Felinto <dfelinto@gmail.com> | 2017-11-09 18:35:46 +0300 |
commit | cec7f1215acffcd31e591fce83d78268aff6e72a (patch) | |
tree | feb2b640e627b0f74cc57d6639f505e90889a383 /source/blender/editors/space_outliner | |
parent | c35f1d05eaa13348d4f33cdb44f6fb62f68e1ba3 (diff) |
Rename Scene macros back to their original _NEW less names
Diffstat (limited to 'source/blender/editors/space_outliner')
4 files changed, 21 insertions, 21 deletions
diff --git a/source/blender/editors/space_outliner/outliner_draw.c b/source/blender/editors/space_outliner/outliner_draw.c index 62eda7d5128..8a2c2594790 100644 --- a/source/blender/editors/space_outliner/outliner_draw.c +++ b/source/blender/editors/space_outliner/outliner_draw.c @@ -362,7 +362,7 @@ static void namebutton_cb(bContext *C, void *tsep, char *oldname) BLI_strncpy(newname, ebone->name, sizeof(ebone->name)); BLI_strncpy(ebone->name, oldname, sizeof(ebone->name)); ED_armature_bone_rename(obedit->data, oldname, newname); - WM_event_add_notifier(C, NC_OBJECT | ND_POSE, OBACT_NEW(sl)); + WM_event_add_notifier(C, NC_OBJECT | ND_POSE, OBACT(sl)); } break; } @@ -375,7 +375,7 @@ static void namebutton_cb(bContext *C, void *tsep, char *oldname) /* always make current object active */ tree_element_active(C, scene, sl, soops, te, OL_SETSEL_NORMAL, true); - ob = OBACT_NEW(sl); + ob = OBACT(sl); /* restore bone name */ BLI_strncpy(newname, bone->name, sizeof(bone->name)); @@ -392,7 +392,7 @@ static void namebutton_cb(bContext *C, void *tsep, char *oldname) /* always make current pose-bone active */ tree_element_active(C, scene, sl, soops, te, OL_SETSEL_NORMAL, true); - ob = OBACT_NEW(sl); + ob = OBACT(sl); BLI_assert(ob->type == OB_ARMATURE); @@ -1257,7 +1257,7 @@ static void outliner_draw_iconrow(bContext *C, uiBlock *block, Scene *scene, Sce /* active blocks get white circle */ if (tselem->type == 0) { if (te->idcode == ID_OB) { - active = (OBACT_NEW(sl) == (Object *)tselem->id) ? OL_DRAWSEL_NORMAL : OL_DRAWSEL_NONE; + active = (OBACT(sl) == (Object *)tselem->id) ? OL_DRAWSEL_NORMAL : OL_DRAWSEL_NONE; } else if (scene->obedit && scene->obedit->data == tselem->id) { active = OL_DRAWSEL_NORMAL; @@ -1363,13 +1363,13 @@ static void outliner_draw_tree_element( else if (te->idcode == ID_OB) { Object *ob = (Object *)tselem->id; - if (ob == OBACT_NEW(sl) || (ob->flag & SELECT)) { + if (ob == OBACT(sl) || (ob->flag & SELECT)) { char col[4] = {0, 0, 0, 0}; /* outliner active ob: always white text, circle color now similar to view3d */ active = OL_DRAWSEL_ACTIVE; - if (ob == OBACT_NEW(sl)) { + if (ob == OBACT(sl)) { if (ob->flag & SELECT) { UI_GetThemeColorType4ubv(TH_ACTIVE, SPACE_VIEW3D, col); col[3] = alpha; diff --git a/source/blender/editors/space_outliner/outliner_edit.c b/source/blender/editors/space_outliner/outliner_edit.c index 4e0686146fb..5d0befece0d 100644 --- a/source/blender/editors/space_outliner/outliner_edit.c +++ b/source/blender/editors/space_outliner/outliner_edit.c @@ -985,7 +985,7 @@ static int outliner_show_active_exec(bContext *C, wmOperator *UNUSED(op)) TreeElement *te; int xdelta, ytop; - Object *obact = OBACT_NEW(sl); + Object *obact = OBACT(sl); if (!obact) return OPERATOR_CANCELLED; diff --git a/source/blender/editors/space_outliner/outliner_select.c b/source/blender/editors/space_outliner/outliner_select.c index 0ef39fc4c92..606cc2fd14a 100644 --- a/source/blender/editors/space_outliner/outliner_select.c +++ b/source/blender/editors/space_outliner/outliner_select.c @@ -103,7 +103,7 @@ static void do_outliner_object_select_recursive(SceneLayer *sl, Object *ob_paren { Base *base; - for (base = FIRSTBASE_NEW(sl); base; base = base->next) { + for (base = FIRSTBASE(sl); base; base = base->next) { Object *ob = base->object; if ((((base->flag & BASE_VISIBLED) == 0) && BKE_object_is_child_recursive(ob_parent, ob))) { ED_object_base_select(base, select ? BA_SELECT : BA_DESELECT); @@ -151,7 +151,7 @@ static eOLDrawState tree_element_set_active_object( } else { ob = (Object *)outliner_search_back(soops, te, ID_OB); - if (ob == OBACT_NEW(sl)) { + if (ob == OBACT(sl)) { return OL_DRAWSEL_NONE; } } @@ -209,7 +209,7 @@ static eOLDrawState tree_element_active_material( /* we search for the object parent */ ob = (Object *)outliner_search_back(soops, te, ID_OB); // note: ob->matbits can be NULL when a local object points to a library mesh. - if (ob == NULL || ob != OBACT_NEW(sl) || ob->matbits == NULL) { + if (ob == NULL || ob != OBACT(sl) || ob->matbits == NULL) { return OL_DRAWSEL_NONE; /* just paranoia */ } @@ -258,7 +258,7 @@ static eOLDrawState tree_element_active_texture( { TreeElement *tep; TreeStoreElem /* *tselem,*/ *tselemp; - Object *ob = OBACT_NEW(sl); + Object *ob = OBACT(sl); SpaceButs *sbuts = NULL; if (ob == NULL) { @@ -347,7 +347,7 @@ static eOLDrawState tree_element_active_lamp( /* we search for the object parent */ ob = (Object *)outliner_search_back(soops, te, ID_OB); - if (ob == NULL || ob != OBACT_NEW(sl)) { + if (ob == NULL || ob != OBACT(sl)) { /* just paranoia */ return OL_DRAWSEL_NONE; } @@ -423,7 +423,7 @@ static eOLDrawState tree_element_active_defgroup( WM_event_add_notifier(C, NC_OBJECT | ND_TRANSFORM, ob); } else { - if (ob == OBACT_NEW(sl)) + if (ob == OBACT(sl)) if (ob->actdef == te->index + 1) { return OL_DRAWSEL_NORMAL; } @@ -443,7 +443,7 @@ static eOLDrawState tree_element_active_posegroup( } } else { - if (ob == OBACT_NEW(sl) && ob->pose) { + if (ob == OBACT(sl) && ob->pose) { if (ob->pose->active_group == te->index + 1) { return OL_DRAWSEL_NORMAL; } @@ -487,7 +487,7 @@ static eOLDrawState tree_element_active_posechannel( } } else { - if (ob == OBACT_NEW(sl) && ob->pose) { + if (ob == OBACT(sl) && ob->pose) { if (pchan->bone->flag & BONE_SELECTED) { return OL_DRAWSEL_NORMAL; } @@ -504,7 +504,7 @@ static eOLDrawState tree_element_active_bone( if (set != OL_SETSEL_NONE) { if (!(bone->flag & BONE_HIDDEN_P)) { - Object *ob = OBACT_NEW(sl); + Object *ob = OBACT(sl); if (ob) { if (set != OL_SETSEL_EXTEND) { /* single select forces all other bones to get unselected */ @@ -533,7 +533,7 @@ static eOLDrawState tree_element_active_bone( } } else { - Object *ob = OBACT_NEW(sl); + Object *ob = OBACT(sl); if (ob && ob->data == arm) { if (bone->flag & BONE_SELECTED) { @@ -842,7 +842,7 @@ eOLDrawState tree_element_type_active( if (set != OL_SETSEL_NONE) { tree_element_set_active_object(C, scene, sl, soops, te, set, false); } - else if (tselem->id == (ID *)OBACT_NEW(sl)) { + else if (tselem->id == (ID *)OBACT(sl)) { return OL_DRAWSEL_NORMAL; } break; diff --git a/source/blender/editors/space_outliner/outliner_tree.c b/source/blender/editors/space_outliner/outliner_tree.c index 88c5aa431c9..f843c474f98 100644 --- a/source/blender/editors/space_outliner/outliner_tree.c +++ b/source/blender/editors/space_outliner/outliner_tree.c @@ -1873,7 +1873,7 @@ void outliner_build_tree(Main *mainvar, Scene *scene, SceneLayer *sl, SpaceOops } } else if (soops->outlinevis == SO_SAME_TYPE) { - Object *ob_active = OBACT_NEW(sl); + Object *ob_active = OBACT(sl); if (ob_active) { FOREACH_SCENE_OBJECT(scene, ob) { @@ -1952,8 +1952,8 @@ void outliner_build_tree(Main *mainvar, Scene *scene, SceneLayer *sl, SpaceOops outliner_add_collections_master(soops, scene); } else { - ten = outliner_add_element(soops, &soops->tree, OBACT_NEW(sl), NULL, 0, 0); - ten->directdata = BASACT_NEW(sl); + ten = outliner_add_element(soops, &soops->tree, OBACT(sl), NULL, 0, 0); + ten->directdata = BASACT(sl); } if ((soops->flag & SO_SKIP_SORT_ALPHA) == 0) { |