diff options
author | Campbell Barton <ideasman42@gmail.com> | 2013-09-30 13:04:17 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2013-09-30 13:04:17 +0400 |
commit | 65233bc49e021e0d4609c61242a4005ed0aa133c (patch) | |
tree | 155632c6fc235c2392e96e245c1989af98be7c18 /source/blender/editors/sculpt_paint/paint_image.c | |
parent | 8064989e7ba076dd978ef4d6befd579791a95307 (diff) |
revert r36440, own commit, no longer needed because of changes to the keymap.
resolves [#36860] sampling color in face select mask
Diffstat (limited to 'source/blender/editors/sculpt_paint/paint_image.c')
-rw-r--r-- | source/blender/editors/sculpt_paint/paint_image.c | 22 |
1 files changed, 1 insertions, 21 deletions
diff --git a/source/blender/editors/sculpt_paint/paint_image.c b/source/blender/editors/sculpt_paint/paint_image.c index feff02fa121..a32293ab12b 100644 --- a/source/blender/editors/sculpt_paint/paint_image.c +++ b/source/blender/editors/sculpt_paint/paint_image.c @@ -963,26 +963,6 @@ static int sample_color_modal(bContext *C, wmOperator *op, const wmEvent *event) return OPERATOR_RUNNING_MODAL; } -/* same as image_paint_poll but fail when face mask mode is enabled */ -static int image_paint_sample_color_poll(bContext *C) -{ - if (image_paint_poll(C)) { - if (CTX_wm_view3d(C)) { - Object *obact = CTX_data_active_object(C); - if (obact && obact->mode & OB_MODE_TEXTURE_PAINT) { - Mesh *me = BKE_mesh_from_object(obact); - if (me) { - return !(me->editflag & ME_EDIT_PAINT_FACE_SEL); - } - } - } - - return 1; - } - - return 0; -} - void PAINT_OT_sample_color(wmOperatorType *ot) { /* identifiers */ @@ -994,7 +974,7 @@ void PAINT_OT_sample_color(wmOperatorType *ot) ot->exec = sample_color_exec; ot->invoke = sample_color_invoke; ot->modal = sample_color_modal; - ot->poll = image_paint_sample_color_poll; + ot->poll = image_paint_poll; /* flags */ ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO; |