From 728b6f19e54af36e176e2ba69bcf89b33dfa1142 Mon Sep 17 00:00:00 2001 From: Joe Groff Date: Sat, 16 Jan 2010 11:44:58 -0800 Subject: [PATCH] use world-attributes pref-dim instead of world pref-dim* method where applicable --- extra/spheres/spheres.factor | 4 +--- extra/ui/gadgets/worlds/null/null.factor | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/extra/spheres/spheres.factor b/extra/spheres/spheres.factor index de969e47b6..819dbe892e 100644 --- a/extra/spheres/spheres.factor +++ b/extra/spheres/spheres.factor @@ -196,9 +196,6 @@ M: spheres-world end-world [ plane-program>> [ delete-gl-program ] when* ] } cleave ; -M: spheres-world pref-dim* - drop { 640 480 } ; - :: (draw-sphere) ( program center radius -- ) program "center" glGetAttribLocation center first3 glVertexAttrib3f program "radius" glGetAttribLocation radius glVertexAttrib1f @@ -307,4 +304,5 @@ MAIN-WINDOW: spheres-window { double-buffered T{ depth-bits { value 16 } } } } + { pref-dim { 640 480 } } } ; diff --git a/extra/ui/gadgets/worlds/null/null.factor b/extra/ui/gadgets/worlds/null/null.factor index 0f116f0d51..eb0e1c1d5c 100644 --- a/extra/ui/gadgets/worlds/null/null.factor +++ b/extra/ui/gadgets/worlds/null/null.factor @@ -7,7 +7,6 @@ M: null-world begin-world drop ; M: null-world end-world drop ; M: null-world draw-world* drop ; M: null-world resize-world drop ; -M: null-world pref-dim* drop { 512 512 } ; : null-window ( title -- world ) @@ -19,6 +18,7 @@ M: null-world pref-dim* drop { 512 512 } ; backing-store T{ depth-bits f 24 } } >>pixel-format-attributes + { 512 512 } >>pref-dim f swap open-window* ; : into-window ( world quot -- world )