From e2c858da3481213f7fd74ddfc9ed393bd47f608d Mon Sep 17 00:00:00 2001 From: Slava Pestov Date: Fri, 10 Apr 2009 06:20:23 -0500 Subject: [PATCH] Add better error check for 'window' word --- basis/ui/ui.factor | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/basis/ui/ui.factor b/basis/ui/ui.factor index dff7726d08..1de3912f28 100644 --- a/basis/ui/ui.factor +++ b/basis/ui/ui.factor @@ -12,7 +12,10 @@ IN: ui ! Assoc mapping aliens to gadgets SYMBOL: windows -: window ( handle -- world ) windows get-global at ; +ERROR: no-window handle ; + +: window ( handle -- world ) + windows get-global ?at [ no-window ] unless ; : window-focus ( handle -- gadget ) window world-focus ;