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:
authorCampbell Barton <ideasman42@gmail.com>2018-08-31 06:36:14 +0300
committerCampbell Barton <ideasman42@gmail.com>2018-08-31 06:36:46 +0300
commit18d135d05c53885eb7460e1c95cc8ebbdb771102 (patch)
tree9a4bbe8b2d67ccc572c2e6058f3627c0a249aa78 /source/blender/editors/sculpt_paint/paint_ops.c
parent94ea566b5a185bd99c57eeaad974253896e0041c (diff)
Cleanup: rename WM_keymap_find -> WM_keymap_ensure
Diffstat (limited to 'source/blender/editors/sculpt_paint/paint_ops.c')
-rw-r--r--source/blender/editors/sculpt_paint/paint_ops.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_ops.c b/source/blender/editors/sculpt_paint/paint_ops.c
index b42a825ad7c..74984d090f8 100644
--- a/source/blender/editors/sculpt_paint/paint_ops.c
+++ b/source/blender/editors/sculpt_paint/paint_ops.c
@@ -1255,13 +1255,13 @@ void ED_keymap_paint(wmKeyConfig *keyconf)
wmKeyMapItem *kmi;
int i;
- keymap = WM_keymap_find(keyconf, "Paint Curve", 0, 0);
+ keymap = WM_keymap_ensure(keyconf, "Paint Curve", 0, 0);
keymap->poll = paint_curve_poll;
paint_keymap_curve(keymap);
/* Sculpt mode */
- keymap = WM_keymap_find(keyconf, "Sculpt", 0, 0);
+ keymap = WM_keymap_ensure(keyconf, "Sculpt", 0, 0);
keymap->poll = sculpt_mode_poll;
RNA_enum_set(WM_keymap_add_item(keymap, "SCULPT_OT_brush_stroke", LEFTMOUSE, KM_PRESS, 0, 0)->ptr, "mode", BRUSH_STROKE_NORMAL);
@@ -1337,7 +1337,7 @@ void ED_keymap_paint(wmKeyConfig *keyconf)
WM_keymap_add_menu(keymap, "VIEW3D_MT_angle_control", RKEY, KM_PRESS, 0, 0);
/* Vertex Paint mode */
- keymap = WM_keymap_find(keyconf, "Vertex Paint", 0, 0);
+ keymap = WM_keymap_ensure(keyconf, "Vertex Paint", 0, 0);
keymap->poll = vertex_paint_mode_poll;
WM_keymap_verify_item(keymap, "PAINT_OT_vertex_paint", LEFTMOUSE, KM_PRESS, 0, 0);
@@ -1364,7 +1364,7 @@ void ED_keymap_paint(wmKeyConfig *keyconf)
RNA_string_set(kmi->ptr, "data_path", "tool_settings.vertex_paint.brush.stroke_method");
/* Weight Paint mode */
- keymap = WM_keymap_find(keyconf, "Weight Paint", 0, 0);
+ keymap = WM_keymap_ensure(keyconf, "Weight Paint", 0, 0);
keymap->poll = weight_paint_mode_poll;
WM_keymap_verify_item(keymap, "PAINT_OT_weight_paint", LEFTMOUSE, KM_PRESS, 0, 0);
@@ -1396,7 +1396,7 @@ void ED_keymap_paint(wmKeyConfig *keyconf)
RNA_string_set(kmi->ptr, "data_path", "tool_settings.weight_paint.brush.use_smooth_stroke");
/*Weight paint's Vertex Selection Mode */
- keymap = WM_keymap_find(keyconf, "Weight Paint Vertex Selection", 0, 0);
+ keymap = WM_keymap_ensure(keyconf, "Weight Paint Vertex Selection", 0, 0);
keymap->poll = vert_paint_poll;
kmi = WM_keymap_add_item(keymap, "PAINT_OT_vert_select_all", AKEY, KM_PRESS, 0, 0);
RNA_enum_set(kmi->ptr, "action", SEL_TOGGLE);
@@ -1410,7 +1410,7 @@ void ED_keymap_paint(wmKeyConfig *keyconf)
WM_keymap_add_item(keymap, "VIEW3D_OT_select_circle", CKEY, KM_PRESS, 0, 0);
/* Image/Texture Paint mode */
- keymap = WM_keymap_find(keyconf, "Image Paint", 0, 0);
+ keymap = WM_keymap_ensure(keyconf, "Image Paint", 0, 0);
keymap->poll = image_texture_paint_poll;
RNA_enum_set(WM_keymap_add_item(keymap, "PAINT_OT_image_paint", LEFTMOUSE, KM_PRESS, 0, 0)->ptr, "mode", BRUSH_STROKE_NORMAL);
@@ -1439,7 +1439,7 @@ void ED_keymap_paint(wmKeyConfig *keyconf)
RNA_string_set(kmi->ptr, "data_path", "tool_settings.image_paint.brush.stroke_method");
/* face-mask mode */
- keymap = WM_keymap_find(keyconf, "Face Mask", 0, 0);
+ keymap = WM_keymap_ensure(keyconf, "Face Mask", 0, 0);
keymap->poll = facemask_paint_poll;
kmi = WM_keymap_add_item(keymap, "PAINT_OT_face_select_all", AKEY, KM_PRESS, 0, 0);
@@ -1458,7 +1458,7 @@ void ED_keymap_paint(wmKeyConfig *keyconf)
kmi = WM_keymap_add_item(keymap, "PAINT_OT_face_select_linked_pick", LKEY, KM_PRESS, KM_SHIFT, 0);
RNA_boolean_set(kmi->ptr, "deselect", true);
- keymap = WM_keymap_find(keyconf, "UV Sculpt", 0, 0);
+ keymap = WM_keymap_ensure(keyconf, "UV Sculpt", 0, 0);
keymap->poll = uv_sculpt_keymap_poll;
kmi = WM_keymap_add_item(keymap, "WM_OT_context_toggle", QKEY, KM_PRESS, 0, 0);