Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/interface/interface.c
| Show First 20 Lines • Show All 6,476 Lines • ▼ Show 20 Lines | if (properties) { | ||||
| PointerRNA *ptr = UI_but_operator_ptr_get(but); | PointerRNA *ptr = UI_but_operator_ptr_get(but); | ||||
| /* Copy idproperties. */ | /* Copy idproperties. */ | ||||
| ptr->data = IDP_CopyProperty(properties); | ptr->data = IDP_CopyProperty(properties); | ||||
| } | } | ||||
| return but; | return but; | ||||
| } | } | ||||
| void UI_but_node_link_set(uiBut *but, bNodeSocket *socket, const float draw_color[4]) | |||||
| { | |||||
| but->flag |= UI_BUT_NODE_LINK; | |||||
| but->custom_data = socket; | |||||
| rgba_float_to_uchar(but->col, draw_color); | |||||
| } | |||||
| /** | /** | ||||
| * push a new event onto event queue to activate the given button | * push a new event onto event queue to activate the given button | ||||
| * (usually a text-field) upon entering a popup | * (usually a text-field) upon entering a popup | ||||
| */ | */ | ||||
| void UI_but_focus_on_enter_event(wmWindow *win, uiBut *but) | void UI_but_focus_on_enter_event(wmWindow *win, uiBut *but) | ||||
| { | { | ||||
| wmEvent event; | wmEvent event; | ||||
| ▲ Show 20 Lines • Show All 279 Lines • Show Last 20 Lines | |||||