PageRenderTime 8ms CodeModel.GetById 1ms app.highlight 2ms RepoModel.GetById 1ms app.codeStats 0ms

/tutorial/vision/opengl/NeHe/lesson01/lesson01.e

http://github.com/tybor/Liberty
Specman e | 38 lines | 27 code | 9 blank | 2 comment | 0 complexity | 9c33ab306692467f1935de9b391863a7 MD5 | raw file
 1class LESSON01
 2
 3inherit
 4	GRAPHIC
 5	
 6creation
 7	make
 8
 9feature{ANY}
10	
11	-- WORLD is a sample GL_WIDGET.
12	-- It corresponds to the common OpenGL setup in these tutorials
13	world : WORLD
14
15	make is
16		local
17			win: TOPLEVEL_WINDOW
18			exit : BUTTON
19		do
20			create win.default_create
21			win.set_title("Lesson 01")
22			win.set_background_color(white_color)
23			win.map
24
25			create world.make(win)
26
27			create exit.with_label(win, U"Exit")
28			exit.when_left_clicked(agent finish_program)
29			win.when_close_requested(agent finish_program)
30
31			vision.start
32		end
33
34	finish_program is
35		do
36			vision.loop_stack.break
37		end
38end