diff options
author | Ton Roosendaal <ton@blender.org> | 2007-11-29 16:05:38 +0300 |
---|---|---|
committer | Ton Roosendaal <ton@blender.org> | 2007-11-29 16:05:38 +0300 |
commit | 231b160a568e72f3c821e05f6330394b93bce82a (patch) | |
tree | 0fe38976cb86f0804f7acc54b50bc5b761e5ccce /source/blender/src/editmesh_mods.c | |
parent | 742ef6746c3bd1dfbc2ecd705d4af255e919d7ae (diff) |
With faceselecting merged in editmode, we should also allow the active
material slot ("index") to update in the UI when you select a single face.
Works nice!
Diffstat (limited to 'source/blender/src/editmesh_mods.c')
-rw-r--r-- | source/blender/src/editmesh_mods.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/source/blender/src/editmesh_mods.c b/source/blender/src/editmesh_mods.c index ae10cef0879..a74bd851aeb 100644 --- a/source/blender/src/editmesh_mods.c +++ b/source/blender/src/editmesh_mods.c @@ -82,6 +82,7 @@ editmesh_mods.c, UI level access, no geometry changes #include "BIF_interface.h" #include "BIF_meshtools.h" #include "BIF_mywindow.h" +#include "BIF_previewrender.h" #include "BIF_resources.h" #include "BIF_screen.h" #include "BIF_space.h" @@ -2126,6 +2127,12 @@ void mouse_mesh(void) allqueue(REDRAWIMAGE, 0); allqueue(REDRAWBUTSEDIT, 0); /* for the texture face panel */ } + if (efa && efa->mat_nr != G.obedit->actcol-1) { + G.obedit->actcol= efa->mat_nr+1; + allqueue(REDRAWBUTSEDIT, 0); + allqueue(REDRAWBUTSSHADING, 0); + BIF_preview_changed(ID_MA); + } } rightmouse_transform(); |