]> gitweb.factorcode.org Git - factor.git/commitdiff
ui.gadgets.worlds: dispose of the handle after ungrabbing input
authorSlava Pestov <slava@factorcode.org>
Sat, 17 Jul 2010 20:08:36 +0000 (16:08 -0400)
committerSlava Pestov <slava@factorcode.org>
Sat, 17 Jul 2010 20:08:36 +0000 (16:08 -0400)
basis/ui/gadgets/worlds/worlds.factor
basis/ui/ui.factor

index e713b0f99959b0c0abf00dc86af12565ecea2dbe..7e064ee76b30095a04b7f374a31c02deeea08a9c 100644 (file)
@@ -129,6 +129,7 @@ M: world request-focus-on ( child gadget -- )
     [ T{ rgba f 1.0 1.0 1.0 1.0 } ] if ;
 
 GENERIC# apply-world-attributes 1 ( world attributes -- world )
+
 M: world apply-world-attributes
     {
         [ title>> >>title ]
@@ -166,15 +167,11 @@ flush-layout-cache-hook [ [ ] ] initialize
 
 GENERIC: begin-world ( world -- )
 GENERIC: end-world ( world -- )
-
 GENERIC: resize-world ( world -- )
 
-M: world begin-world
-    drop ;
-M: world end-world
-    drop ;
-M: world resize-world
-    drop ;
+M: world begin-world drop ;
+M: world end-world drop ;
+M: world resize-world drop ;
 
 M: world dim<<
     [ call-next-method ]
index d65f4725a9e59258e5c640770c7a2b7a9f99bddc..fad774cbcc9b9cfe7a85e944591ad757821d8f05 100644 (file)
@@ -90,8 +90,8 @@ M: world ungraft*
         [ hand-gadget close-global ]
         [ end-world ]
         [ [ <reversed> [ [ dispose ] when* ] each V{ } clone ] change-window-resources drop ]
-        [ [ (close-window) f ] change-handle drop ]
         [ unfocus-world ]
+        [ [ (close-window) f ] change-handle drop ]
         [ promise>> t swap fulfill ]
     } cleave ;