Changeset View
Standalone View
source/blender/editors/animation/drivers.c
| Show First 20 Lines • Show All 1,120 Lines • ▼ Show 20 Lines | |||||
| } | } | ||||
| void ANIM_OT_driver_button_remove(wmOperatorType *ot) | void ANIM_OT_driver_button_remove(wmOperatorType *ot) | ||||
| { | { | ||||
| /* identifiers */ | /* identifiers */ | ||||
| ot->name = "Remove Driver"; | ot->name = "Remove Driver"; | ||||
| ot->idname = "ANIM_OT_driver_button_remove"; | ot->idname = "ANIM_OT_driver_button_remove"; | ||||
| ot->description = | ot->description = | ||||
| "Remove the driver(s) for the property(s) connected represented by the highlighted button"; | "Remove the driver(s) for the connected property(s) represented by the highlighted button"; | ||||
| /* callbacks */ | /* callbacks */ | ||||
| ot->exec = remove_driver_button_exec; | ot->exec = remove_driver_button_exec; | ||||
| /* TODO: `op->poll` need to have some driver to be able to do this. */ | /* TODO: `op->poll` need to have some driver to be able to do this. */ | ||||
| /* flags */ | /* flags */ | ||||
| ot->flag = OPTYPE_UNDO | OPTYPE_INTERNAL; | ot->flag = OPTYPE_UNDO | OPTYPE_INTERNAL; | ||||
| Show All 20 Lines | |||||
| } | } | ||||
| void ANIM_OT_driver_button_edit(wmOperatorType *ot) | void ANIM_OT_driver_button_edit(wmOperatorType *ot) | ||||
| { | { | ||||
| /* identifiers */ | /* identifiers */ | ||||
| ot->name = "Edit Driver"; | ot->name = "Edit Driver"; | ||||
| ot->idname = "ANIM_OT_driver_button_edit"; | ot->idname = "ANIM_OT_driver_button_edit"; | ||||
| ot->description = | ot->description = | ||||
| "Edit the drivers for the property connected represented by the highlighted button"; | "Edit the drivers for the connected property represented by the highlighted button"; | ||||
| /* callbacks */ | /* callbacks */ | ||||
| ot->exec = edit_driver_button_exec; | ot->exec = edit_driver_button_exec; | ||||
| /* TODO: `op->poll` need to have some driver to be able to do this. */ | /* TODO: `op->poll` need to have some driver to be able to do this. */ | ||||
| /* flags */ | /* flags */ | ||||
| ot->flag = OPTYPE_UNDO | OPTYPE_INTERNAL; | ot->flag = OPTYPE_UNDO | OPTYPE_INTERNAL; | ||||
| } | } | ||||
| ▲ Show 20 Lines • Show All 77 Lines • ▼ Show 20 Lines | static int paste_driver_button_exec(bContext *C, wmOperator *op) | ||||
| return (changed) ? OPERATOR_FINISHED : OPERATOR_CANCELLED; | return (changed) ? OPERATOR_FINISHED : OPERATOR_CANCELLED; | ||||
| } | } | ||||
| void ANIM_OT_paste_driver_button(wmOperatorType *ot) | void ANIM_OT_paste_driver_button(wmOperatorType *ot) | ||||
| { | { | ||||
| /* identifiers */ | /* identifiers */ | ||||
| ot->name = "Paste Driver"; | ot->name = "Paste Driver"; | ||||
| ot->idname = "ANIM_OT_paste_driver_button"; | ot->idname = "ANIM_OT_paste_driver_button"; | ||||
| ot->description = "Paste the driver in the copy/paste buffer for the highlighted button"; | ot->description = "Paste the driver in the clipboard to the highlighted button"; | ||||
sybren: I don't think we should do this change. Not all "copy/paste buffers" of Blender actually use… | |||||
devpalestrinaAuthorUnsubmitted Not Done Inline ActionsFirst time replying to a revision comment so let me know if I just talked back to the president and need to sit back down. I disagree because technically what you're saying makes sense but for a user the word buffer is practically gibberish. The only context they might be aware of it in is in buffering of a video. (Obviously more technical users immediately understand) I'm wondering if it runs afoul of this guideline: Do not use implementation specific language. Use "data-block", not "ID". Do not use terms like "flag", "string", "RNA", "DNA". There is also an error message at 744 that uses clipboard. I can update both if we decide to use copy/paste buffer. if (BLI_listbase_is_empty(&driver_vars_copybuf)) {
BKE_report(reports, RPT_ERROR, "No driver variables in clipboard to paste");
return false;devpalestrina: First time replying to a revision comment so let me know if I just talked back to the president… | |||||
sybrenUnsubmitted Not Done Inline Actions
Haha love it :) And by all means stand up for your ideas. Everybody can be wrong, me definitely included. Having a clear discussion with clear points of view / perspectives / opinions only helps.
I agree with you here. Let's keep things as they are now (i.e. as committed). sybren: > First time replying to a revision comment so let me know if I just talked back to the… | |||||
| /* callbacks */ | /* callbacks */ | ||||
| ot->exec = paste_driver_button_exec; | ot->exec = paste_driver_button_exec; | ||||
| /* TODO: `op->poll` need to have some driver to be able to do this. */ | /* TODO: `op->poll` need to have some driver to be able to do this. */ | ||||
| /* flags */ | /* flags */ | ||||
| ot->flag = OPTYPE_UNDO | OPTYPE_INTERNAL; | ot->flag = OPTYPE_UNDO | OPTYPE_INTERNAL; | ||||
| } | } | ||||
| /* ************************************************** */ | /* ************************************************** */ | ||||
I don't think we should do this change. Not all "copy/paste buffers" of Blender actually use the system clipboard. For example, when copy-pasting an object between blend files, nothing actually gets stored on the clipboard -- "copy" just saves the object to a file in a specific location, and "paste" loads that file.