diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-06-26 06:57:05 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-06-26 06:57:05 +0400 |
commit | 28e14794e7d6d41ab2ab5c8b1fff97bdb9d52507 (patch) | |
tree | 877103cce22e123d4f8b7f2fec4a4566ae685a5a /source/blender/editors | |
parent | a7858767f46d25d8b7d95b37a3e66aaf552d67c8 (diff) |
fix for vert/face mask modes using last used select option when using the select-all key shortcut.
Diffstat (limited to 'source/blender/editors')
-rw-r--r-- | source/blender/editors/sculpt_paint/paint_ops.c | 6 | ||||
-rw-r--r-- | source/blender/editors/space_view3d/view3d_buttons.c | 2 |
2 files changed, 5 insertions, 3 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_ops.c b/source/blender/editors/sculpt_paint/paint_ops.c index df1978c49f6..2c7824d4a0d 100644 --- a/source/blender/editors/sculpt_paint/paint_ops.c +++ b/source/blender/editors/sculpt_paint/paint_ops.c @@ -1242,7 +1242,8 @@ void ED_keymap_paint(wmKeyConfig *keyconf) /*Weight paint's Vertex Selection Mode */ keymap = WM_keymap_find(keyconf, "Weight Paint Vertex Selection", 0, 0); keymap->poll = vert_paint_poll; - WM_keymap_add_item(keymap, "PAINT_OT_vert_select_all", AKEY, KM_PRESS, 0, 0); + kmi = WM_keymap_add_item(keymap, "PAINT_OT_vert_select_all", AKEY, KM_PRESS, 0, 0); + RNA_enum_set(kmi->ptr, "action", SEL_TOGGLE); kmi = WM_keymap_add_item(keymap, "PAINT_OT_vert_select_all", IKEY, KM_PRESS, KM_CTRL, 0); RNA_enum_set(kmi->ptr, "action", SEL_INVERT); WM_keymap_add_item(keymap, "VIEW3D_OT_select_border", BKEY, KM_PRESS, 0, 0); @@ -1283,7 +1284,8 @@ void ED_keymap_paint(wmKeyConfig *keyconf) keymap = WM_keymap_find(keyconf, "Face Mask", 0, 0); keymap->poll = facemask_paint_poll; - WM_keymap_add_item(keymap, "PAINT_OT_face_select_all", AKEY, KM_PRESS, 0, 0); + kmi = WM_keymap_add_item(keymap, "PAINT_OT_face_select_all", AKEY, KM_PRESS, 0, 0); + RNA_enum_set(kmi->ptr, "action", SEL_TOGGLE); kmi = WM_keymap_add_item(keymap, "PAINT_OT_face_select_all", IKEY, KM_PRESS, KM_CTRL, 0); RNA_enum_set(kmi->ptr, "action", SEL_INVERT); kmi = WM_keymap_add_item(keymap, "PAINT_OT_face_select_hide", HKEY, KM_PRESS, 0, 0); diff --git a/source/blender/editors/space_view3d/view3d_buttons.c b/source/blender/editors/space_view3d/view3d_buttons.c index 57088bcc315..860807946a0 100644 --- a/source/blender/editors/space_view3d/view3d_buttons.c +++ b/source/blender/editors/space_view3d/view3d_buttons.c @@ -914,7 +914,7 @@ static void view3d_panel_vgroup(const bContext *C, Panel *pa) but = uiDefButO_ptr(block, BUT, ot, WM_OP_EXEC_DEFAULT, "Normalize", 0, yco, UI_UNIT_X * 5, UI_UNIT_Y, TIP_("Normalize weights of active vertex (if affected groups are unlocked")); - if(locked) { + if (locked) { uiButSetFlag(but, UI_BUT_DISABLED); } |