Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/curve/editcurve_select.c
| Show First 20 Lines • Show All 397 Lines • ▼ Show 20 Lines | else { | ||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| static int de_select_first_exec(bContext *C, wmOperator *UNUSED(op)) | static int de_select_first_exec(bContext *C, wmOperator *UNUSED(op)) | ||||
| { | { | ||||
| Object *obedit = CTX_data_edit_object(C); | ViewLayer *view_layer = CTX_data_view_layer(C); | ||||
| uint objects_len = 0; | |||||
| Object **objects = BKE_view_layer_array_from_objects_in_edit_mode_unique_data(view_layer, &objects_len); | |||||
| for (uint ob_index = 0; ob_index < objects_len; ob_index++) { | |||||
| Object *obedit = objects[ob_index]; | |||||
| selectend_nurb(obedit, FIRST, true, DESELECT); | selectend_nurb(obedit, FIRST, true, DESELECT); | ||||
| DEG_id_tag_update(obedit->data, DEG_TAG_SELECT_UPDATE); | DEG_id_tag_update(obedit->data, DEG_TAG_SELECT_UPDATE); | ||||
| WM_event_add_notifier(C, NC_GEOM | ND_SELECT, obedit->data); | WM_event_add_notifier(C, NC_GEOM | ND_SELECT, obedit->data); | ||||
| BKE_curve_nurb_vert_active_validate(obedit->data); | BKE_curve_nurb_vert_active_validate(obedit->data); | ||||
| } | |||||
| return OPERATOR_FINISHED; | return OPERATOR_FINISHED; | ||||
| } | } | ||||
| void CURVE_OT_de_select_first(wmOperatorType *ot) | void CURVE_OT_de_select_first(wmOperatorType *ot) | ||||
| { | { | ||||
| /* identifiers */ | /* identifiers */ | ||||
| ot->name = "(De)select First"; | ot->name = "(De)select First"; | ||||
| ot->idname = "CURVE_OT_de_select_first"; | ot->idname = "CURVE_OT_de_select_first"; | ||||
| ▲ Show 20 Lines • Show All 1,375 Lines • Show Last 20 Lines | |||||