Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/space_view3d/view3d_select.c
| Context not available. | |||||
| return data.is_changed; | return data.is_changed; | ||||
| } | } | ||||
| static void do_lasso_select_curve__doSelect(void *userData, | static void do_lasso_select_curve__doSelect(struct ViewContext* UNUSED(vc), | ||||
| void *userData, | |||||
| Nurb *UNUSED(nu), | Nurb *UNUSED(nu), | ||||
| BPoint *bp, | BPoint *bp, | ||||
| BezTriple *bezt, | BezTriple *bezt, | ||||
| Context not available. | |||||
| bool toggle = RNA_boolean_get(op->ptr, "toggle"); | bool toggle = RNA_boolean_get(op->ptr, "toggle"); | ||||
| bool center = RNA_boolean_get(op->ptr, "center"); | bool center = RNA_boolean_get(op->ptr, "center"); | ||||
| bool enumerate = RNA_boolean_get(op->ptr, "enumerate"); | bool enumerate = RNA_boolean_get(op->ptr, "enumerate"); | ||||
| /* Only force object select for edit-mode to support vertex parenting, | bool alt = RNA_int_get(op->ptr, "alt"); | ||||
| * or paint-select to allow pose bone select with vert/face select. */ | /* only force object select for editmode to support vertex parenting, | ||||
| * or paint-select to allow pose bone select with vert/face select */ | |||||
| bool object = (RNA_boolean_get(op->ptr, "object") && | bool object = (RNA_boolean_get(op->ptr, "object") && | ||||
| (obedit || BKE_paint_select_elem_test(obact) || | (obedit || BKE_paint_select_elem_test(obact) || | ||||
| /* so its possible to select bones in weight-paint mode (LMB select) */ | /* so its possible to select bones in weight-paint mode (LMB select) */ | ||||
| Context not available. | |||||
| } | } | ||||
| } | } | ||||
| else if (ELEM(obedit->type, OB_CURVE, OB_SURF)) { | else if (ELEM(obedit->type, OB_CURVE, OB_SURF)) { | ||||
| retval = ED_curve_editnurb_select_pick(C, location, extend, deselect, toggle); | retval = ED_curve_editnurb_select_pick(C, location, extend, deselect, toggle,alt); | ||||
| if (!retval && deselect_all) { | if (!retval && deselect_all) { | ||||
| retval = ED_curve_deselect_all_multi(C); | retval = ED_curve_deselect_all_multi(C); | ||||
| } | } | ||||
| Context not available. | |||||
| static int view3d_select_invoke(bContext *C, wmOperator *op, const wmEvent *event) | static int view3d_select_invoke(bContext *C, wmOperator *op, const wmEvent *event) | ||||
| { | { | ||||
| RNA_int_set_array(op->ptr, "location", event->mval); | RNA_int_set_array(op->ptr, "location", event->mval); | ||||
| RNA_int_set(op->ptr, "alt", event->alt); | |||||
| return view3d_select_exec(C, op); | return view3d_select_exec(C, op); | ||||
| } | } | ||||
| Context not available. | |||||
| RNA_def_property_flag(prop, PROP_SKIP_SAVE); | RNA_def_property_flag(prop, PROP_SKIP_SAVE); | ||||
| prop = RNA_def_boolean(ot->srna, "object", 0, "Object", "Use object selection (edit-mode only)"); | prop = RNA_def_boolean(ot->srna, "object", 0, "Object", "Use object selection (edit-mode only)"); | ||||
| RNA_def_property_flag(prop, PROP_SKIP_SAVE); | RNA_def_property_flag(prop, PROP_SKIP_SAVE); | ||||
| RNA_def_int(ot->srna, "alt", 0, 0, 10, "AltKey", "Invoked with Alt pressed (loop select mode)", 0, 10); | |||||
| RNA_def_property_flag(prop, PROP_SKIP_SAVE); | |||||
| prop = RNA_def_int_vector(ot->srna, | prop = RNA_def_int_vector(ot->srna, | ||||
| "location", | "location", | ||||
| Context not available. | |||||
| return changed; | return changed; | ||||
| } | } | ||||
| static void do_nurbs_box_select__doSelect(void *userData, | static void do_nurbs_box_select__doSelect(struct ViewContext* UNUSED(vc), | ||||
| void *userData, | |||||
| Nurb *UNUSED(nu), | Nurb *UNUSED(nu), | ||||
| BPoint *bp, | BPoint *bp, | ||||
| BezTriple *bezt, | BezTriple *bezt, | ||||
| Context not available. | |||||
| return changed; | return changed; | ||||
| } | } | ||||
| static void nurbscurve_circle_doSelect(void *userData, | static void nurbscurve_circle_doSelect(struct ViewContext* UNUSED(vc), | ||||
| void *userData, | |||||
| Nurb *UNUSED(nu), | Nurb *UNUSED(nu), | ||||
| BPoint *bp, | BPoint *bp, | ||||
| BezTriple *bezt, | BezTriple *bezt, | ||||
| Context not available. | |||||