use crate::system::*;

mod platform;
mod xinput;

pub struct Internal {
    supervisor:Sender<Query>,
    sys_window:Option<Sender<Query>>,
}
impl Internal {
    pub fn thread(supervisor:Sender<Query>, _tx:Sender<Query>, rx:Receiver<Query>)
    {
        let _sv = Internal {
            supervisor,
            sys_window:None,
        };

        // Request interested subsystem status.


        // Handle messages.
        while let Ok(msg) = rx.recv() {
            match msg.data {
                QueryData::Supervisor(request) => match request {
                    SupervisorQuery::Stop {
                        system: _,
                    } => {

                        // Perform shutdown operations and terminate thread.
                        return;
                    }

                    _ => { }
                }

                QueryData::Window(request) => match request {
                    _ => { }
                }

                _ => { }
            }
        }
    }
}

