diff --git a/basis/opengl/opengl.factor b/basis/opengl/opengl.factor index a56b72ada5..bb5847e734 100644 --- a/basis/opengl/opengl.factor +++ b/basis/opengl/opengl.factor @@ -154,7 +154,7 @@ MACRO: all-enabled-client-state ( seq quot -- ) :: with-vertex-array ( id quot -- ) id glBindVertexArray - quot [ binding 0 glBindVertexArray ] [ ] cleanup ; inline + quot [ 0 glBindVertexArray ] [ ] cleanup ; inline : ( target data hint -- id ) pick gen-gl-buffer [ diff --git a/basis/ui/gadgets/worlds/worlds.factor b/basis/ui/gadgets/worlds/worlds.factor index 1766abba97..ed21c85b19 100755 --- a/basis/ui/gadgets/worlds/worlds.factor +++ b/basis/ui/gadgets/worlds/worlds.factor @@ -89,13 +89,13 @@ SYMBOL: context-world : with-gl-context ( world quot -- ) '[ set-gl-context @ ] - [ flush-gl-context gl-error ] bi ; inline + [ handle>> flush-gl-context gl-error ] bi ; inline ERROR: no-world-found ; : find-gl-context ( gadget -- ) find-world dup - [ handle>> set-gl-context ] [ no-world-found ] if ; + [ set-gl-context ] [ no-world-found ] if ; : (request-focus) ( child world ? -- ) pick parent>> pick eq? [ @@ -164,8 +164,8 @@ M: world (>>dim) [ call-next-method ] [ dup handle>> - [ set-gl-context resize-world ] - [ drop ] if* + [ [ set-gl-context ] [ resize-world ] bi ] + [ drop ] if ] bi ; GENERIC: draw-world* ( world -- ) @@ -199,7 +199,7 @@ ui-error-hook [ [ rethrow ] ] initialize dup draw-world? [ dup world [ [ - dup handle>> [ draw-world* ] with-gl-context + dup [ draw-world* ] with-gl-context flush-layout-cache-hook get call( -- ) ] [ over ui-error diff --git a/basis/ui/ui.factor b/basis/ui/ui.factor index 9d1c40377f..8ac2cdd36f 100644 --- a/basis/ui/ui.factor +++ b/basis/ui/ui.factor @@ -61,7 +61,7 @@ SYMBOL: windows : set-up-window ( world -- ) { - [ handle>> set-gl-context ] + [ set-gl-context ] [ [ title>> ] keep set-title ] [ begin-world ] [ resize-world ] @@ -89,13 +89,13 @@ M: world graft* : (ungraft-world) ( world -- ) { - [ handle>> set-gl-context ] + [ set-gl-context ] [ text-handle>> [ dispose ] when* ] [ images>> [ dispose ] when* ] [ hand-clicked close-global ] [ hand-gadget close-global ] [ end-world ] - [ [ [ [ dispose ] when* ] each V{ } clone ] change-window-resources ] + [ [ [ [ dispose ] when* ] each V{ } clone ] change-window-resources drop ] } cleave ; M: world ungraft* diff --git a/extra/ui/gadgets/worlds/null/null.factor b/extra/ui/gadgets/worlds/null/null.factor index 26fc3e8a94..0f116f0d51 100644 --- a/extra/ui/gadgets/worlds/null/null.factor +++ b/extra/ui/gadgets/worlds/null/null.factor @@ -22,6 +22,6 @@ M: null-world pref-dim* drop { 512 512 } ; f swap open-window* ; : into-window ( world quot -- world ) - [ dup handle>> ] dip with-gl-context ; inline + [ dup ] dip with-gl-context ; inline