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:
Diffstat (limited to 'source/blender/src/butspace.c')
-rw-r--r--source/blender/src/butspace.c30
1 files changed, 24 insertions, 6 deletions
diff --git a/source/blender/src/butspace.c b/source/blender/src/butspace.c
index bb6dc671e14..752e831c2b4 100644
--- a/source/blender/src/butspace.c
+++ b/source/blender/src/butspace.c
@@ -107,7 +107,7 @@ void test_scriptpoin_but(char *name, ID **idpp)
}
id= id->next;
}
- *idpp= 0;
+ *idpp= NULL;
}
void test_actionpoin_but(char *name, ID **idpp)
@@ -122,7 +122,7 @@ void test_actionpoin_but(char *name, ID **idpp)
}
id= id->next;
}
- *idpp= 0;
+ *idpp= NULL;
}
@@ -144,7 +144,7 @@ void test_obpoin_but(char *name, ID **idpp)
}
id= id->next;
}
- *idpp= 0;
+ *idpp= NULL;
}
void test_meshpoin_but(char *name, ID **idpp)
@@ -162,7 +162,7 @@ void test_meshpoin_but(char *name, ID **idpp)
}
id= id->next;
}
- *idpp= 0;
+ *idpp= NULL;
}
void test_matpoin_but(char *name, ID **idpp)
@@ -180,7 +180,7 @@ void test_matpoin_but(char *name, ID **idpp)
}
id= id->next;
}
- *idpp= 0;
+ *idpp= NULL;
}
void test_scenepoin_but(char *name, ID **idpp)
@@ -198,7 +198,25 @@ void test_scenepoin_but(char *name, ID **idpp)
}
id= id->next;
}
- *idpp= 0;
+ *idpp= NULL;
+}
+
+void test_grouppoin_but(char *name, ID **idpp)
+{
+ ID *id;
+
+ if( *idpp ) (*idpp)->us--;
+
+ id= G.main->group.first;
+ while(id) {
+ if( strcmp(name, id->name+2)==0 ) {
+ *idpp= id;
+ id_us_plus(id);
+ return;
+ }
+ id= id->next;
+ }
+ *idpp= NULL;
}