Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/interface/interface.c
| Show First 20 Lines • Show All 1,210 Lines • ▼ Show 20 Lines | for (but = block->buttons.first; but; but = but->next) { | ||||
| } | } | ||||
| else if (ui_but_event_property_operator_string(C, but, buf, sizeof(buf))) { | else if (ui_but_event_property_operator_string(C, but, buf, sizeof(buf))) { | ||||
| ui_but_add_shortcut(but, buf, false); | ui_but_add_shortcut(but, buf, false); | ||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| void ui_but_override_flag(uiBut *but) | |||||
| { | |||||
| bool is_overridden; | |||||
| RNA_property_override_status(&but->rnapoin, but->rnaprop, but->rnaindex, NULL, &is_overridden, NULL, NULL); | |||||
| if (is_overridden) { | |||||
| but->flag |= UI_BUT_OVERRIDEN; | |||||
| } | |||||
| else { | |||||
| but->flag &= ~UI_BUT_OVERRIDEN; | |||||
| } | |||||
| } | |||||
| void UI_block_update_from_old(const bContext *C, uiBlock *block) | void UI_block_update_from_old(const bContext *C, uiBlock *block) | ||||
| { | { | ||||
| uiBut *but_old; | uiBut *but_old; | ||||
| uiBut *but; | uiBut *but; | ||||
| if (!block->oldblock) | if (!block->oldblock) | ||||
| return; | return; | ||||
| ▲ Show 20 Lines • Show All 48 Lines • ▼ Show 20 Lines | if (but->optype) { | ||||
| but->flag |= UI_BUT_DISABLED; | but->flag |= UI_BUT_DISABLED; | ||||
| } | } | ||||
| if (but->context) | if (but->context) | ||||
| CTX_store_set((bContext *)C, NULL); | CTX_store_set((bContext *)C, NULL); | ||||
| } | } | ||||
| ui_but_anim_flag(but, (scene) ? scene->r.cfra : 0.0f); | ui_but_anim_flag(but, (scene) ? scene->r.cfra : 0.0f); | ||||
| ui_but_override_flag(but); | |||||
| } | } | ||||
| /* handle pending stuff */ | /* handle pending stuff */ | ||||
| if (block->layouts.first) { | if (block->layouts.first) { | ||||
| UI_block_layout_resolve(block, NULL, NULL); | UI_block_layout_resolve(block, NULL, NULL); | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 3,478 Lines • Show Last 20 Lines | |||||