Add event handler methods to the engine structure
This commit is contained in:
parent
c32a452f17
commit
9905ffd26b
5 changed files with 29 additions and 25 deletions
|
|
@ -66,6 +66,10 @@ impl<E: EngineTrait> Platform<E> for GliumPlatform<E> {
|
|||
.systems
|
||||
.values_mut()
|
||||
.for_each(|system| system.handle_event(&mut self.window, event.clone()));
|
||||
|
||||
let mut ctx2 = ctx.clone();
|
||||
ctx2.current_event = event.clone();
|
||||
self.engine.handle_event(ctx2);
|
||||
|
||||
match event {
|
||||
Event::WindowEvent { event, .. } => match event {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue