From 93a46f7d08970ea4359ce289552ca5fed6b73259 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebasti=C3=A1n=20Barschkis?= Date: Tue, 4 Feb 2020 21:36:18 +0100 Subject: Fluid: Improved baking progress bar UI The baking progress bar now uses the entire notification space in the UI. Before, old reports could still be visible when a bake job got started. This had the disadvantage that those message got frozen too with the bake UI freeze. --- source/blender/editors/physics/physics_fluid.c | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'source/blender/editors/physics') diff --git a/source/blender/editors/physics/physics_fluid.c b/source/blender/editors/physics/physics_fluid.c index 63979e247bf..af77d966c9d 100644 --- a/source/blender/editors/physics/physics_fluid.c +++ b/source/blender/editors/physics/physics_fluid.c @@ -537,6 +537,8 @@ static int fluid_bake_exec(struct bContext *C, struct wmOperator *op) if (!fluid_validatepaths(job, op->reports)) { return OPERATOR_CANCELLED; } + WM_report_banners_cancel(job->bmain); + fluid_bake_startjob(job, NULL, NULL, NULL); fluid_bake_endjob(job); fluid_bake_free(job); @@ -564,6 +566,9 @@ static int fluid_bake_invoke(struct bContext *C, return OPERATOR_CANCELLED; } + /* Clear existing banners so that the upcoming progress bar from this job has more room. */ + WM_report_banners_cancel(job->bmain); + wmJob *wm_job = WM_jobs_get(CTX_wm_manager(C), CTX_wm_window(C), scene, @@ -638,6 +643,9 @@ static int fluid_free_exec(struct bContext *C, struct wmOperator *op) return OPERATOR_CANCELLED; } + /* Clear existing banners so that the upcoming progress bar from this job has more room. */ + WM_report_banners_cancel(job->bmain); + wmJob *wm_job = WM_jobs_get(CTX_wm_manager(C), CTX_wm_window(C), scene, -- cgit v1.2.3