Cleanup: replace int with wmOperatorStatus
Follow up to adding wmOperatorStatus, these cases were missed as they didn't cause compiler warnings.
This commit is contained in:
@@ -1104,7 +1104,7 @@ bool ED_view3d_navigation_do(bContext *C,
|
||||
event = &event_tmp;
|
||||
}
|
||||
|
||||
int op_return = OPERATOR_CANCELLED;
|
||||
wmOperatorStatus op_return = OPERATOR_CANCELLED;
|
||||
|
||||
ViewOpsData_Utility *vod_intern = static_cast<ViewOpsData_Utility *>(vod);
|
||||
if (vod_intern->is_modal_event) {
|
||||
|
||||
@@ -132,7 +132,7 @@ static PyObject *pyop_call(PyObject * /*self*/, PyObject *args)
|
||||
wmOperatorType *ot;
|
||||
int error_val = 0;
|
||||
PointerRNA ptr;
|
||||
int operator_ret = OPERATOR_CANCELLED;
|
||||
wmOperatorStatus operator_ret = OPERATOR_CANCELLED;
|
||||
|
||||
const char *opname;
|
||||
const char *context_str = nullptr;
|
||||
@@ -301,7 +301,7 @@ static PyObject *pyop_call(PyObject * /*self*/, PyObject *args)
|
||||
BPY_modules_update();
|
||||
|
||||
/* return operator_ret as a bpy enum */
|
||||
return pyrna_enum_bitfield_as_set(rna_enum_operator_return_items, operator_ret);
|
||||
return pyrna_enum_bitfield_as_set(rna_enum_operator_return_items, int(operator_ret));
|
||||
}
|
||||
|
||||
static PyObject *pyop_as_string(PyObject * /*self*/, PyObject *args)
|
||||
|
||||
@@ -964,12 +964,12 @@ wmOperatorStatus WM_operator_name_call_with_properties(bContext *C,
|
||||
* - `poll()` must be called by python before this runs.
|
||||
* - reports can be passed to this function (so python can report them as exceptions).
|
||||
*/
|
||||
int WM_operator_call_py(bContext *C,
|
||||
wmOperatorType *ot,
|
||||
wmOperatorCallContext context,
|
||||
PointerRNA *properties,
|
||||
ReportList *reports,
|
||||
bool is_undo);
|
||||
wmOperatorStatus WM_operator_call_py(bContext *C,
|
||||
wmOperatorType *ot,
|
||||
wmOperatorCallContext context,
|
||||
PointerRNA *properties,
|
||||
ReportList *reports,
|
||||
bool is_undo);
|
||||
|
||||
void WM_operator_name_call_ptr_with_depends_on_cursor(bContext *C,
|
||||
wmOperatorType *ot,
|
||||
|
||||
@@ -1930,12 +1930,12 @@ void WM_menu_name_call(bContext *C, const char *menu_name, short context)
|
||||
WM_operator_properties_free(&ptr);
|
||||
}
|
||||
|
||||
int WM_operator_call_py(bContext *C,
|
||||
wmOperatorType *ot,
|
||||
wmOperatorCallContext context,
|
||||
PointerRNA *properties,
|
||||
ReportList *reports,
|
||||
const bool is_undo)
|
||||
wmOperatorStatus WM_operator_call_py(bContext *C,
|
||||
wmOperatorType *ot,
|
||||
wmOperatorCallContext context,
|
||||
PointerRNA *properties,
|
||||
ReportList *reports,
|
||||
const bool is_undo)
|
||||
{
|
||||
wmOperatorStatus retval = OPERATOR_CANCELLED;
|
||||
/* Not especially nice using undo depth here. It's used so Python never
|
||||
@@ -2562,7 +2562,7 @@ static eHandlerActionFlag wm_handler_operator_call(bContext *C,
|
||||
PointerRNA *properties,
|
||||
const char *kmi_idname)
|
||||
{
|
||||
int retval = OPERATOR_PASS_THROUGH;
|
||||
wmOperatorStatus retval = OPERATOR_PASS_THROUGH;
|
||||
|
||||
/* Derived, modal or blocking operator. */
|
||||
if ((handler_base->type == WM_HANDLER_TYPE_OP) &&
|
||||
|
||||
Reference in New Issue
Block a user