indexing description: "[ Objects that represents the credits menu ]" date: "$Date$" revision: "$Revision$" class CREDITS inherit MENU redefine initialize_scene, redraw end create make_scene feature -- Initialization initialize_scene is -- Initialize the scene local i: INTEGER str: EM_STRING font: EM_FONT lines: EM_DRAWABLE_CONTAINER [EM_STRING] cursor: DS_LINKED_LIST_CURSOR [EM_STRING] do Precursor -- build the menu entries create menu_entries.make (1, 1) menu_entries.put (create {EM_STRING}.make ("Back", normal_font), 1) menu_entries.item (1).set_x_y (512 - menu_entries.item (1).width // 2, 650) font := standard_bmp_fonts.medium_font create lines.make create str.make ("Created with", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("EiffelMedia", font) lines.extend (str) create str.make ("eiffelmedia.origo.ethz.ch", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("Programmer:", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("Patrick", font) lines.extend (str) create str.make ("Ruckstuhl", font) lines.extend (str) create str.make ("rupatric@student.ethz.ch", font) lines.extend (str) create str.make ("Thanks to:", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("Till", font) lines.extend (str) create str.make ("For a cool", font) lines.extend (str) create str.make ("Semesterthesis", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("and", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("Bertrand Meyer", font) lines.extend (str) create str.make ("For a cool", font) lines.extend (str) create str.make ("Programminglanguage", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("Andreas Leitner", font) lines.extend (str) create str.make ("For the", font) lines.extend (str) create str.make ("Eiffel Wrapper Generator", font) lines.extend (str) create str.make ("ewg.sf.net", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("and", font) lines.extend (str) create str.make ("All the testers", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("", font) lines.extend (str) create str.make ("12.03.2005", font) lines.extend (str) create cursor.make (lines) from cursor.start i := 0 until cursor.off loop cursor.item.set_x_y (406 - cursor.item.width // 2, 330 + i * 40) cursor.forth i := i + 1 end create scroll.make (lines) scroll.set_x_y (100, 300) scroll.set_speed (40) start_animating (scroll) selected_nr := 1 menu_entries.item (selected_nr).set_font (select_font) end feature {NONE} -- Event handler on_select is -- Set the `next_scene' according to `selected_nr' here do if selected_nr = 1 then -- back next_scene := create {START}.make_scene end end redraw is -- Handle the outside event. do screen.clear scene.draw (screen) draw_menu_entries scroll.draw_part (create {EM_RECT}.make (0, 0, 812, 330), screen) screen.redraw end feature {NONE} -- Implementation scroll: EM_NEVER_ENDING_BACKGROUND_VERTICAL end