error in last commit, also skip getting vars for wm_operator_reports() when there...
authorCampbell Barton <ideasman42@gmail.com>
Fri, 14 Jan 2011 21:45:49 +0000 (21:45 +0000)
committerCampbell Barton <ideasman42@gmail.com>
Fri, 14 Jan 2011 21:45:49 +0000 (21:45 +0000)
source/blender/blenkernel/intern/seqeffects.c
source/blender/windowmanager/intern/wm_event_system.c

index 36f618d04a978893ad209b5f439b9ca79c9952f1..11075fe402e7c1569b05d65867ab257226c1f79d 100644 (file)
@@ -2730,8 +2730,8 @@ static struct ImBuf * do_solid_color(
 
        unsigned char *rect;
        float *rect_float;
-       /*int x = context.rectx;*/ /*UNUSED*/
-       /*int y = context.recty;*/ /*UNUSED*/
+       int x; /*= context.rectx;*/ /*UNUSED*/
+       int y; /*= context.recty;*/ /*UNUSED*/
 
        if (out->rect) {
                unsigned char col0[3];
index 7d5cdb8a10c0c0663f37db558fc7508c6cdb7ce7..be6700f2ea1ef9a54ea3e4ca3529c1a92926a230 100644 (file)
@@ -423,10 +423,6 @@ static void wm_operator_print(bContext *C, wmOperator *op)
 
 static void wm_operator_reports(bContext *C, wmOperator *op, int retval, int popup)
 {
-       wmWindowManager *wm = CTX_wm_manager(C);
-       ReportList *reports = CTX_wm_reports(C);
-       char *buf;
-       
        if(popup)
                if(op->reports->list.first)
                        uiPupMenuReports(C, op->reports);
@@ -437,26 +433,29 @@ static void wm_operator_reports(bContext *C, wmOperator *op, int retval, int pop
                
                if (op->type->flag & OPTYPE_REGISTER) {
                        /* Report the python string representation of the operator */
-                       buf = WM_operator_pystring(C, op->type, op->ptr, 1);
+                       char *buf = WM_operator_pystring(C, op->type, op->ptr, 1);
                        BKE_report(CTX_wm_reports(C), RPT_OPERATOR, buf);
                        MEM_freeN(buf);
                }
        }
 
        if (op->reports->list.first) {
+
+               wmWindowManager *wm = CTX_wm_manager(C);
+               ReportList *wm_reports= CTX_wm_reports(C);
                ReportTimerInfo *rti;
-               
+
                /* add reports to the global list, otherwise they are not seen */
-               BLI_movelisttolist(&CTX_wm_reports(C)->list, &op->reports->list);
+               BLI_movelisttolist(&wm_reports->list, &op->reports->list);
                
                /* After adding reports to the global list, reset the report timer. */
-               WM_event_remove_timer(wm, NULL, reports->reporttimer);
+               WM_event_remove_timer(wm, NULL, wm_reports->reporttimer);
                
                /* Records time since last report was added */
-               reports->reporttimer= WM_event_add_timer(wm, CTX_wm_window(C), TIMER, 0.05);
+               wm_reports->reporttimer= WM_event_add_timer(wm, CTX_wm_window(C), TIMER, 0.05);
                
                rti = MEM_callocN(sizeof(ReportTimerInfo), "ReportTimerInfo");
-               reports->reporttimer->customdata = rti;
+               wm_reports->reporttimer->customdata = rti;
        }
 }