Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/space_graph/graph_buttons.c
| Show First 20 Lines • Show All 587 Lines • ▼ Show 20 Lines | if (bezt->ipo == BEZT_IPO_BEZ) { | ||||
| NULL); | NULL); | ||||
| UI_but_func_set(but, graphedit_activekey_right_handle_coord_cb, fcu, bezt); | UI_but_func_set(but, graphedit_activekey_right_handle_coord_cb, fcu, bezt); | ||||
| UI_but_unit_type_set(but, unit); | UI_but_unit_type_set(but, unit); | ||||
| } | } | ||||
| } | } | ||||
| else { | else { | ||||
| if ((fcu->bezt == NULL) && (fcu->modifiers.first)) { | if ((fcu->bezt == NULL) && (fcu->modifiers.first)) { | ||||
| /* modifiers only - so no keyframes to be active */ | /* modifiers only - so no keyframes to be active */ | ||||
| uiItemL(layout, IFACE_("F-Curve only has F-Modifiers"), ICON_NONE); | uiItemL(layout, TIP_("F-Curve only has F-Modifiers"), ICON_NONE); | ||||
| uiItemL(layout, IFACE_("See Modifiers panel below"), ICON_INFO); | uiItemL(layout, TIP_("See Modifiers panel below"), ICON_INFO); | ||||
| } | } | ||||
| else if (fcu->fpt) { | else if (fcu->fpt) { | ||||
| /* samples only */ | /* samples only */ | ||||
| uiItemL(layout, | uiItemL(layout, | ||||
| IFACE_("F-Curve doesn't have any keyframes as it only contains sampled points"), | TIP_("F-Curve doesn't have any keyframes as it only contains sampled points"), | ||||
| ICON_NONE); | ICON_NONE); | ||||
| } | } | ||||
| else { | else { | ||||
| uiItemL(layout, IFACE_("No active keyframe on F-Curve"), ICON_NONE); | uiItemL(layout, TIP_("No active keyframe on F-Curve"), ICON_NONE); | ||||
| } | } | ||||
| } | } | ||||
| MEM_freeN(ale); | MEM_freeN(ale); | ||||
| } | } | ||||
| /* ******************* drivers ******************************** */ | /* ******************* drivers ******************************** */ | ||||
| ▲ Show 20 Lines • Show All 68 Lines • ▼ Show 20 Lines | |||||
| { | { | ||||
| uiPopupMenu *pup = UI_popup_menu_begin( | uiPopupMenu *pup = UI_popup_menu_begin( | ||||
| C, CTX_IFACE_(BLT_I18NCONTEXT_OPERATOR_DEFAULT, "Invalid Variable Name"), ICON_NONE); | C, CTX_IFACE_(BLT_I18NCONTEXT_OPERATOR_DEFAULT, "Invalid Variable Name"), ICON_NONE); | ||||
| uiLayout *layout = UI_popup_menu_layout(pup); | uiLayout *layout = UI_popup_menu_layout(pup); | ||||
| DriverVar *dvar = (DriverVar *)dvar_v; | DriverVar *dvar = (DriverVar *)dvar_v; | ||||
| if (dvar->flag & DVAR_FLAG_INVALID_EMPTY) { | if (dvar->flag & DVAR_FLAG_INVALID_EMPTY) { | ||||
| uiItemL(layout, "It cannot be left blank", ICON_ERROR); | uiItemL(layout, TIP_("It cannot be left blank"), ICON_ERROR); | ||||
| } | } | ||||
| if (dvar->flag & DVAR_FLAG_INVALID_START_NUM) { | if (dvar->flag & DVAR_FLAG_INVALID_START_NUM) { | ||||
| uiItemL(layout, "It cannot start with a number", ICON_ERROR); | uiItemL(layout, TIP_("It cannot start with a number"), ICON_ERROR); | ||||
| } | } | ||||
| if (dvar->flag & DVAR_FLAG_INVALID_START_CHAR) { | if (dvar->flag & DVAR_FLAG_INVALID_START_CHAR) { | ||||
| uiItemL(layout, | uiItemL(layout, | ||||
| "It cannot start with a special character," | TIP_("It cannot start with a special character," | ||||
| " including '$', '@', '!', '~', '+', '-', '_', '.', or ' '", | " including '$', '@', '!', '~', '+', '-', '_', '.', or ' '"), | ||||
| ICON_NONE); | ICON_NONE); | ||||
| } | } | ||||
| if (dvar->flag & DVAR_FLAG_INVALID_HAS_SPACE) { | if (dvar->flag & DVAR_FLAG_INVALID_HAS_SPACE) { | ||||
| uiItemL(layout, "It cannot contain spaces (e.g. 'a space')", ICON_ERROR); | uiItemL(layout, TIP_("It cannot contain spaces (e.g. 'a space')"), ICON_ERROR); | ||||
| } | } | ||||
| if (dvar->flag & DVAR_FLAG_INVALID_HAS_DOT) { | if (dvar->flag & DVAR_FLAG_INVALID_HAS_DOT) { | ||||
| uiItemL(layout, "It cannot contain dots (e.g. 'a.dot')", ICON_ERROR); | uiItemL(layout, TIP_("It cannot contain dots (e.g. 'a.dot')"), ICON_ERROR); | ||||
| } | } | ||||
| if (dvar->flag & DVAR_FLAG_INVALID_HAS_SPECIAL) { | if (dvar->flag & DVAR_FLAG_INVALID_HAS_SPECIAL) { | ||||
| uiItemL(layout, "It cannot contain special (non-alphabetical/numeric) characters", ICON_ERROR); | uiItemL(layout, | ||||
| TIP_("It cannot contain special (non-alphabetical/numeric) characters"), | |||||
| ICON_ERROR); | |||||
| } | } | ||||
| if (dvar->flag & DVAR_FLAG_INVALID_PY_KEYWORD) { | if (dvar->flag & DVAR_FLAG_INVALID_PY_KEYWORD) { | ||||
| uiItemL(layout, "It cannot be a reserved keyword in Python", ICON_INFO); | uiItemL(layout, TIP_("It cannot be a reserved keyword in Python"), ICON_INFO); | ||||
| } | } | ||||
| UI_popup_menu_end(C, pup); | UI_popup_menu_end(C, pup); | ||||
| } | } | ||||
| /* callback to reset the driver's flags */ | /* callback to reset the driver's flags */ | ||||
| static void driver_update_flags_cb(bContext *UNUSED(C), void *fcu_v, void *UNUSED(arg)) | static void driver_update_flags_cb(bContext *UNUSED(C), void *fcu_v, void *UNUSED(arg)) | ||||
| { | { | ||||
| ▲ Show 20 Lines • Show All 736 Lines • Show Last 20 Lines | |||||