|
|
@ -11,6 +11,9 @@ use winit::event::Event;
|
|
|
|
use crate::util::tr_event::{TrEvent, TrUIEvent};
|
|
|
|
use crate::util::tr_event::{TrEvent, TrUIEvent};
|
|
|
|
use crate::drawables::sprite::{Velocity, Geometry};
|
|
|
|
use crate::drawables::sprite::{Velocity, Geometry};
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
enum CustomEvent {
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
/// Trait which may be inherited by objects that wish to be drawn to the screen
|
|
|
|
/// Trait which may be inherited by objects that wish to be drawn to the screen
|
|
|
|
pub trait Drawable {
|
|
|
|
pub trait Drawable {
|
|
|
|
|
|
|
|
|
|
|
@ -31,7 +34,7 @@ pub trait Drawable {
|
|
|
|
// Notify is where custom events created in other parts of the system will be ingested. It
|
|
|
|
// Notify is where custom events created in other parts of the system will be ingested. It
|
|
|
|
// might be a good idea in the future to have some of pre-function-call filtering so we
|
|
|
|
// might be a good idea in the future to have some of pre-function-call filtering so we
|
|
|
|
// don't have as many notifies that just immediately reject.
|
|
|
|
// don't have as many notifies that just immediately reject.
|
|
|
|
fn notify<Y, T>(&self, tr_event : Vec<TrEvent<Y>>, ui_events: Vec<TrUIEvent<T>>) -> Vec<TrUIEvent<T>>;
|
|
|
|
fn notify<Y: 'static, T: 'static>(&self, tr_event : Vec<TrEvent<Y>>, ui_events: Vec<TrUIEvent<T>>) -> Vec<TrUIEvent<T>>;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|