diff options
author | Antonioya <blendergit@gmail.com> | 2019-04-16 12:27:36 +0300 |
---|---|---|
committer | Antonioya <blendergit@gmail.com> | 2019-04-16 14:10:04 +0300 |
commit | 5494926ee564dcde052e875debb90e27c60cd6aa (patch) | |
tree | c7fa42b881c7940b93219a22ff30b4c5ca21bf38 /source/blender/editors/gpencil/gpencil_brush.c | |
parent | a8852ade8aa65cc591d1fa20d732bb766aefe60a (diff) |
GPencil: Add lock icon to Vertex Groups list
Also check this flag in operators.
Note: This is required for the development of the new Normalize All operator.
Diffstat (limited to 'source/blender/editors/gpencil/gpencil_brush.c')
-rw-r--r-- | source/blender/editors/gpencil/gpencil_brush.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/source/blender/editors/gpencil/gpencil_brush.c b/source/blender/editors/gpencil/gpencil_brush.c index e7e6d7a5f7f..8f64ec1c868 100644 --- a/source/blender/editors/gpencil/gpencil_brush.c +++ b/source/blender/editors/gpencil/gpencil_brush.c @@ -929,6 +929,12 @@ static bool gp_brush_weight_apply( gso->vrgroup = 0; } } + else { + bDeformGroup *defgroup = BLI_findlink(&gso->object->defbase, gso->vrgroup); + if (defgroup->flag & DG_LOCK_WEIGHT) { + return false; + } + } /* get current weight */ MDeformWeight *dw = defvert_verify_index(dvert, gso->vrgroup); float curweight = dw ? dw->weight : 0.0f; |