Changes to allow python to do redraws through the timer operator, a reliable way...
[blender.git] / source / blender / windowmanager / intern / wm_event_system.c
index 503eb5a1b9a79180a771607c4f07e14655699b39..03e13329bbd656499bd304cd106e4bf093c573c7 100644 (file)
@@ -415,7 +415,9 @@ static int wm_operator_invoke(bContext *C, wmOperatorType *ot, wmEvent *event, P
                else
                        printf("invalid operator call %s\n", ot->idname); /* debug, important to leave a while, should never happen */
 
                else
                        printf("invalid operator call %s\n", ot->idname); /* debug, important to leave a while, should never happen */
 
-               if(!(retval & OPERATOR_RUNNING_MODAL)) {
+               /* Note, if the report is given as an argument then assume the caller will deal with displaying them
+                * currently python only uses this */
+               if(!(retval & OPERATOR_RUNNING_MODAL) && reports==NULL) {
                        if(op->reports->list.first) /* only show the report if the report list was not given in the function */
                                uiPupMenuReports(C, op->reports);
                
                        if(op->reports->list.first) /* only show the report if the report list was not given in the function */
                                uiPupMenuReports(C, op->reports);