forked from bartvdbraak/blender
remove unused code from object convert and indent.
This commit is contained in:
parent
e2ece45fec
commit
09aadea2cc
@ -2624,10 +2624,6 @@ void txt_indent(Text *text)
|
||||
return;
|
||||
}
|
||||
|
||||
if (!text) return;
|
||||
if (!text->curl) return;
|
||||
if (!text->sell) return;
|
||||
|
||||
/* insert spaces rather than tabs */
|
||||
if (text->flags & TXT_TABSTOSPACES) {
|
||||
add = tab_to_spaces;
|
||||
@ -2687,9 +2683,9 @@ void txt_unindent(Text *text)
|
||||
/* hardcoded: TXT_TABSIZE = 4 spaces: */
|
||||
int spaceslen = TXT_TABSIZE;
|
||||
|
||||
if (!text) return;
|
||||
if (!text->curl) return;
|
||||
if (!text->sell) return;
|
||||
if (ELEM3(NULL, text, text->curl, text->sell)) {
|
||||
return;
|
||||
}
|
||||
|
||||
/* insert spaces rather than tabs */
|
||||
if (text->flags & TXT_TABSTOSPACES) {
|
||||
|
@ -1431,7 +1431,7 @@ static int convert_exec(bContext *C, wmOperator *op)
|
||||
{
|
||||
Main *bmain = CTX_data_main(C);
|
||||
Scene *scene = CTX_data_scene(C);
|
||||
Base *basen = NULL, *basact = NULL, *basedel = NULL;
|
||||
Base *basen = NULL, *basact = NULL;
|
||||
Object *ob, *ob1, *newob, *obact = CTX_data_active_object(C);
|
||||
DerivedMesh *dm;
|
||||
Curve *cu;
|
||||
@ -1687,14 +1687,6 @@ static int convert_exec(bContext *C, wmOperator *op)
|
||||
DAG_id_tag_update(&ob->id, OB_RECALC_DATA);
|
||||
((ID *)ob->data)->flag &= ~LIB_DOIT; /* flag not to convert this datablock again */
|
||||
}
|
||||
|
||||
/* delete original if needed */
|
||||
if (basedel) {
|
||||
if (!keep_original)
|
||||
ED_base_object_free_and_unlink(bmain, scene, basedel);
|
||||
|
||||
basedel = NULL;
|
||||
}
|
||||
}
|
||||
CTX_DATA_END;
|
||||
|
||||
|
@ -1140,7 +1140,7 @@ static int need_add_seq_dup(Sequence *seq)
|
||||
*/
|
||||
p = seq->prev;
|
||||
while (p) {
|
||||
if ((!p->strip) || (!p->strip->stripdata) || (!p->strip->stripdata->name)) {
|
||||
if ((!p->strip) || (!p->strip->stripdata)) {
|
||||
p = p->prev;
|
||||
continue;
|
||||
}
|
||||
@ -1152,7 +1152,7 @@ static int need_add_seq_dup(Sequence *seq)
|
||||
|
||||
p = seq->next;
|
||||
while (p) {
|
||||
if ((!p->strip) || (!p->strip->stripdata) || (!p->strip->stripdata->name)) {
|
||||
if ((!p->strip) || (!p->strip->stripdata)) {
|
||||
p = p->next;
|
||||
continue;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user