diff --git a/basis/ui/gadgets/gadgets.factor b/basis/ui/gadgets/gadgets.factor index e38f56c7f1..a4bedf1ef7 100644 --- a/basis/ui/gadgets/gadgets.factor +++ b/basis/ui/gadgets/gadgets.factor @@ -135,7 +135,9 @@ SYMBOL: ui-notify-flag : forget-pref-dim ( gadget -- ) f >>pref-dim drop ; -: layout-queue ( -- queue ) \ layout-queue get ; +: ui-state ( symbol -- value ) get [ "UI not running" throw ] unless* ; + +: layout-queue ( -- queue ) \ layout-queue ui-state ; : layout-later ( gadget -- ) #! When unit testing gadgets without the UI running, the @@ -214,7 +216,7 @@ M: gadget ungraft* drop ; > graft-queue delete-node ]