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:
authorTon Roosendaal <ton@blender.org>2006-06-22 18:00:05 +0400
committerTon Roosendaal <ton@blender.org>2006-06-22 18:00:05 +0400
commit8be0682ea2e012ee7f89dac8ff820c1b919c42b0 (patch)
tree05141c2a7a7c748abfc07a410c2805a2772f9ec0 /source/blender/src/editmesh_mods.c
parent7cb459b95d25e15706cb42e04cfedc98c8258af7 (diff)
Bugfix #3773
Option SHIFT+CTRL+5, "select all non-tria/quad" didnt work at all.
Diffstat (limited to 'source/blender/src/editmesh_mods.c')
-rw-r--r--source/blender/src/editmesh_mods.c19
1 files changed, 9 insertions, 10 deletions
diff --git a/source/blender/src/editmesh_mods.c b/source/blender/src/editmesh_mods.c
index b92906e261e..4f62a278c77 100644
--- a/source/blender/src/editmesh_mods.c
+++ b/source/blender/src/editmesh_mods.c
@@ -1853,26 +1853,25 @@ void select_faces_by_numverts(int numverts)
EditMesh *em = G.editMesh;
EditFace *efa;
- /* Selects isolated verts, and edges that do not have 2 neighboring
+ /* Selects trias/qiads or isolated verts, and edges that do not have 2 neighboring
* faces
*/
-
- if(G.scene->selectmode!=SCE_SELECT_FACE) {
+
+ /* for loose vertices/edges, we first select all, loop below will deselect */
+ if(numverts==5)
+ EM_set_flag_all(SELECT);
+ else if(G.scene->selectmode!=SCE_SELECT_FACE) {
error("Only works in face selection mode");
return;
}
-
- efa= em->faces.first;
- while(efa) {
+
+ for(efa= em->faces.first; efa; efa= efa->next) {
if (efa->e4) {
EM_select_face(efa, (numverts==4) );
}
- else if (efa->e3) {
+ else {
EM_select_face(efa, (numverts==3) );
}
- else
- EM_select_face(efa, (numverts!=3) && (numverts!=4) );
- efa= efa->next;
}
countall();