From b810fd75a489f71b5d94b334df8343b4ea5ebdaf Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 24 Jun 2023 18:56:25 +1000 Subject: [PATCH] Cleanup: use _exec suffix for operator callbacks This was already the case for all but a few places. --- source/blender/editors/io/io_ply_ops.cc | 4 ++-- source/blender/editors/io/io_stl_ops.cc | 4 ++-- source/blender/editors/object/object_bake_simulation.cc | 6 +++--- source/blender/makesrna/intern/rna_wm.c | 4 ++-- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/source/blender/editors/io/io_ply_ops.cc b/source/blender/editors/io/io_ply_ops.cc index dd24a0af083..1c61443e6cd 100644 --- a/source/blender/editors/io/io_ply_ops.cc +++ b/source/blender/editors/io/io_ply_ops.cc @@ -230,7 +230,7 @@ static int wm_ply_import_invoke(bContext *C, wmOperator *op, const wmEvent *even return WM_operator_filesel(C, op, event); } -static int wm_ply_import_execute(bContext *C, wmOperator *op) +static int wm_ply_import_exec(bContext *C, wmOperator *op) { PLYImportParams params{}; params.forward_axis = eIOAxis(RNA_enum_get(op->ptr, "forward_axis")); @@ -283,7 +283,7 @@ void WM_OT_ply_import(wmOperatorType *ot) ot->idname = "WM_OT_ply_import"; ot->invoke = wm_ply_import_invoke; - ot->exec = wm_ply_import_execute; + ot->exec = wm_ply_import_exec; ot->poll = WM_operator_winactive; ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO | OPTYPE_PRESET; diff --git a/source/blender/editors/io/io_stl_ops.cc b/source/blender/editors/io/io_stl_ops.cc index c99ef8daaed..1f44c4304b2 100644 --- a/source/blender/editors/io/io_stl_ops.cc +++ b/source/blender/editors/io/io_stl_ops.cc @@ -29,7 +29,7 @@ static int wm_stl_import_invoke(bContext *C, wmOperator *op, const wmEvent *even return WM_operator_filesel(C, op, event); } -static int wm_stl_import_execute(bContext *C, wmOperator *op) +static int wm_stl_import_exec(bContext *C, wmOperator *op) { STLImportParams params{}; params.forward_axis = eIOAxis(RNA_enum_get(op->ptr, "forward_axis")); @@ -95,7 +95,7 @@ void WM_OT_stl_import(wmOperatorType *ot) ot->idname = "WM_OT_stl_import"; ot->invoke = wm_stl_import_invoke; - ot->exec = wm_stl_import_execute; + ot->exec = wm_stl_import_exec; ot->poll = WM_operator_winactive; ot->check = wm_stl_import_check; ot->flag = OPTYPE_REGISTER | OPTYPE_UNDO | OPTYPE_PRESET; diff --git a/source/blender/editors/object/object_bake_simulation.cc b/source/blender/editors/object/object_bake_simulation.cc index 803937bcef3..5ff75ee08f3 100644 --- a/source/blender/editors/object/object_bake_simulation.cc +++ b/source/blender/editors/object/object_bake_simulation.cc @@ -362,7 +362,7 @@ static void bake_simulation_job_endjob(void *customdata) WM_main_add_notifier(NC_OBJECT | ND_MODIFIER, nullptr); } -static int bake_simulation_execute(bContext *C, wmOperator *op) +static int bake_simulation_exec(bContext *C, wmOperator *op) { wmWindowManager *wm = CTX_wm_manager(C); Scene *scene = CTX_data_scene(C); @@ -556,7 +556,7 @@ static int bake_simulation_invoke(bContext *C, wmOperator *op, const wmEvent * / if (has_existing_bake_data) { return WM_operator_confirm_message(C, op, "Overwrite existing bake data"); } - return bake_simulation_execute(C, op); + return bake_simulation_exec(C, op); } static int bake_simulation_modal(bContext *C, wmOperator * /*op*/, const wmEvent * /*event*/) @@ -647,7 +647,7 @@ void OBJECT_OT_simulation_nodes_cache_bake(wmOperatorType *ot) ot->description = "Bake simulations in geometry nodes modifiers"; ot->idname = __func__; - ot->exec = bake_simulation_execute; + ot->exec = bake_simulation_exec; ot->invoke = bake_simulation_invoke; ot->modal = bake_simulation_modal; ot->poll = bake_simulation_poll; diff --git a/source/blender/makesrna/intern/rna_wm.c b/source/blender/makesrna/intern/rna_wm.c index 3eaa9f4f973..b26e2361184 100644 --- a/source/blender/makesrna/intern/rna_wm.c +++ b/source/blender/makesrna/intern/rna_wm.c @@ -1306,7 +1306,7 @@ static bool rna_operator_poll_cb(bContext *C, wmOperatorType *ot) return visible; } -static int rna_operator_execute_cb(bContext *C, wmOperator *op) +static int rna_operator_exec_cb(bContext *C, wmOperator *op) { extern FunctionRNA rna_Operator_execute_func; @@ -1600,7 +1600,7 @@ static StructRNA *rna_Operator_register(Main *bmain, dummy_ot.rna_ext.free = free; dummy_ot.pyop_poll = (have_function[0]) ? rna_operator_poll_cb : NULL; - dummy_ot.exec = (have_function[1]) ? rna_operator_execute_cb : NULL; + dummy_ot.exec = (have_function[1]) ? rna_operator_exec_cb : NULL; dummy_ot.check = (have_function[2]) ? rna_operator_check_cb : NULL; dummy_ot.invoke = (have_function[3]) ? rna_operator_invoke_cb : NULL; dummy_ot.modal = (have_function[4]) ? rna_operator_modal_cb : NULL;