From c46722660643c38fda6e3261d835a93499ae7d1e Mon Sep 17 00:00:00 2001 From: Matt Birkholz Date: Sun, 19 Oct 2014 10:49:02 -0700 Subject: [PATCH] gtk: Fix load-option/suppress-loading-message?. The implementation in 56128b0 (a year ago!) was silly; it only suppressed half a notification, producing an unbalanced "... done". --- src/runtime/option.scm | 25 +++++++++++-------------- 1 file changed, 11 insertions(+), 14 deletions(-) diff --git a/src/runtime/option.scm b/src/runtime/option.scm index e2eff9432..73b1d3fa8 100644 --- a/src/runtime/option.scm +++ b/src/runtime/option.scm @@ -40,21 +40,18 @@ USA. ((not no-error?) (error "Unknown option name:" name)) (else #f))) - (define (notifier option) - (named-lambda (notify port) - (if (not (fluid load-option/suppress-loading-message?)) - (begin - (write-string "Loading " port) - (write-string (symbol-name option) port) - (write-string " option" port))))) - (define (load-entry entry) - (with-notification - (notifier name) - (lambda () - (let-fluid load/suppress-loading-message? #t - (lambda () - (for-each (lambda (thunk) (thunk)) (cdr entry)))))) + (let-fluid load/suppress-loading-message? #t + (lambda () + (if load-option/suppress-loading-message? + (for-each (lambda (thunk) (thunk)) (cdr entry)) + (with-notification + (named-lambda (load-optoin-notify port) + (write-string "Loading " port) + (write-string (symbol-name name) port) + (write-string " option" port)) + (lambda () + (for-each (lambda (thunk) (thunk)) (cdr entry))))))) (set! loaded-options (cons name loaded-options)) name) -- 2.25.1