UI: Removal of GRAPH_OT_keys_to_samples Confirmation
Removal of the dialog that pops up to confirm this operator. The Animation & Rigging module feels this isn't needed since this action is quite visual and hard to miss. This operator is also not often used and might get removed in future as unnecessary. Pull Request: https://projects.blender.org/blender/blender/pulls/120074
This commit is contained in:
committed by
Harley Acheson
parent
d2d810f11a
commit
7226b52728
@@ -980,20 +980,6 @@ static int graphkeys_keys_to_samples_exec(bContext *C, wmOperator * /*op*/)
|
||||
return OPERATOR_FINISHED;
|
||||
}
|
||||
|
||||
static int graphkeys_keys_to_samples_invoke(bContext *C, wmOperator *op, const wmEvent * /*event*/)
|
||||
{
|
||||
if (RNA_boolean_get(op->ptr, "confirm")) {
|
||||
return WM_operator_confirm_ex(C,
|
||||
op,
|
||||
IFACE_("Convert selected keys to samples?"),
|
||||
nullptr,
|
||||
IFACE_("Convert"),
|
||||
ALERT_ICON_NONE,
|
||||
false);
|
||||
}
|
||||
return graphkeys_keys_to_samples_exec(C, op);
|
||||
}
|
||||
|
||||
void GRAPH_OT_keys_to_samples(wmOperatorType *ot)
|
||||
{
|
||||
/* Identifiers */
|
||||
@@ -1003,13 +989,11 @@ void GRAPH_OT_keys_to_samples(wmOperatorType *ot)
|
||||
"Convert selected channels to an uneditable set of samples to save storage space";
|
||||
|
||||
/* API callbacks */
|
||||
ot->invoke = graphkeys_keys_to_samples_invoke;
|
||||
ot->exec = graphkeys_keys_to_samples_exec;
|
||||
ot->poll = graphop_selected_fcurve_poll;
|
||||
|
||||
/* Flags */
|
||||
ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO;
|
||||
WM_operator_properties_confirm_or_exec(ot);
|
||||
|
||||
/* TODO: add props for start/end frames (Joshua Leung 2009) */
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user