Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/space_node/node_group.c
| Show First 20 Lines • Show All 556 Lines • ▼ Show 20 Lines | static int node_group_separate_exec(bContext *C, wmOperator *op) | ||||
| snode_notify(C, snode); | snode_notify(C, snode); | ||||
| snode_dag_update(C, snode); | snode_dag_update(C, snode); | ||||
| return OPERATOR_FINISHED; | return OPERATOR_FINISHED; | ||||
| } | } | ||||
| static int node_group_separate_invoke(bContext *C, wmOperator *UNUSED(op), const wmEvent *UNUSED(event)) | static int node_group_separate_invoke(bContext *C, wmOperator *UNUSED(op), const wmEvent *UNUSED(event)) | ||||
| { | { | ||||
| uiPopupMenu *pup = uiPupMenuBegin(C, CTX_IFACE_(BLF_I18NCONTEXT_OPERATOR_DEFAULT, "Separate"), ICON_NONE); | uiPopupMenu *pup = UI_popup_menu_begin(C, CTX_IFACE_(BLF_I18NCONTEXT_OPERATOR_DEFAULT, "Separate"), ICON_NONE); | ||||
| uiLayout *layout = uiPupMenuLayout(pup); | uiLayout *layout = UI_popup_menu_layout(pup); | ||||
| uiLayoutSetOperatorContext(layout, WM_OP_EXEC_DEFAULT); | uiLayoutSetOperatorContext(layout, WM_OP_EXEC_DEFAULT); | ||||
| uiItemEnumO(layout, "NODE_OT_group_separate", NULL, 0, "type", NODE_GS_COPY); | uiItemEnumO(layout, "NODE_OT_group_separate", NULL, 0, "type", NODE_GS_COPY); | ||||
| uiItemEnumO(layout, "NODE_OT_group_separate", NULL, 0, "type", NODE_GS_MOVE); | uiItemEnumO(layout, "NODE_OT_group_separate", NULL, 0, "type", NODE_GS_MOVE); | ||||
| uiPupMenuEnd(C, pup); | UI_popup_menu_end(C, pup); | ||||
| return OPERATOR_INTERFACE; | return OPERATOR_INTERFACE; | ||||
| } | } | ||||
| void NODE_OT_group_separate(wmOperatorType *ot) | void NODE_OT_group_separate(wmOperatorType *ot) | ||||
| { | { | ||||
| /* identifiers */ | /* identifiers */ | ||||
| ot->name = "Separate"; | ot->name = "Separate"; | ||||
| ▲ Show 20 Lines • Show All 427 Lines • Show Last 20 Lines | |||||