indexing description: "[ Base class for EiffelMedia events. Only used for propagating constants to the child classes at the moment. ]" date: "$Date$" revision: "$Revision$" class EM_EVENT inherit EM_CONSTANTS export {NONE} all {ANY} is_equal, clone, copy, out, twin, Default_pointer end feature {NONE} -- Initialization make (a_pointer: POINTER) is -- Create an event to wrap an SDL_Event -- referenced by `a_pointer'. require a_pointer_not_null: a_pointer /= Default_pointer do create sdl_event.make_shared (a_pointer) end feature -- Queries type: INTEGER is -- Event type -- (see EM_CONSTANTS for possible values). do Result := sdl_event.type end feature -- Status report caught: BOOLEAN -- Has `Current' event already been caught? -- This means that somebody handled the event -- and it should not be published any further. feature -- Status setting set_caught (a_bool: BOOLEAN) is -- Set `caught' to `a_bool'. -- One should call `set_caught' with `True' -- when `Current' should not be published any further. do caught := a_bool ensure caught_set: caught = a_bool end feature {NONE} -- Implementation sdl_event: SDL_EVENT_UNION -- Wrapped union containing the event informations. invariant sdl_event_not_void: sdl_event /= Void end