2019-04-03 18:30:22 -07:00
|
|
|
//! Map editor interface.
|
|
|
|
|
|
|
|
use super::glib::*;
|
|
|
|
use gobject_sys::*;
|
|
|
|
use gtk_sys::*;
|
2019-05-13 19:03:09 -07:00
|
|
|
use maraiah::{durandal::ffi, marathon::map};
|
|
|
|
use std::cell::RefCell;
|
2019-04-03 18:30:22 -07:00
|
|
|
|
2019-05-13 19:03:09 -07:00
|
|
|
impl EditorModel
|
2019-04-03 18:30:22 -07:00
|
|
|
{
|
2019-05-13 19:03:09 -07:00
|
|
|
pub fn new(view: EditorView) -> Self
|
2019-04-03 18:30:22 -07:00
|
|
|
{
|
2019-05-13 19:03:09 -07:00
|
|
|
Self{view}
|
2019-04-03 18:30:22 -07:00
|
|
|
}
|
|
|
|
|
2019-05-13 19:03:09 -07:00
|
|
|
pub fn open_new(&mut self)
|
2019-04-03 18:30:22 -07:00
|
|
|
{
|
2019-05-13 19:03:09 -07:00
|
|
|
eprintln!("open_new");
|
2019-04-03 18:30:22 -07:00
|
|
|
}
|
|
|
|
|
2019-05-13 19:03:09 -07:00
|
|
|
pub fn open_buf(&mut self, b: &[u8])
|
2019-04-03 18:30:22 -07:00
|
|
|
{
|
2019-05-13 19:03:09 -07:00
|
|
|
eprintln!("open_buf");
|
2019-04-03 18:30:22 -07:00
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2019-05-13 19:03:09 -07:00
|
|
|
pub struct EditorPresenter
|
2019-04-03 18:30:22 -07:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2019-05-13 19:03:09 -07:00
|
|
|
pub struct EditorView
|
2019-04-03 18:30:22 -07:00
|
|
|
{
|
2019-05-13 19:03:09 -07:00
|
|
|
pub prop: PropertiesWindow,
|
2019-04-03 18:30:22 -07:00
|
|
|
}
|
|
|
|
|
2019-05-13 19:03:09 -07:00
|
|
|
pub struct PropertiesWindow
|
2019-04-03 18:30:22 -07:00
|
|
|
{
|
2019-05-13 19:03:09 -07:00
|
|
|
pub flg_ent: Vec<Refc<'static, GtkToggleButton>>,
|
|
|
|
pub flg_env: Vec<Refc<'static, GtkToggleButton>>,
|
|
|
|
pub flg_msn: Vec<Refc<'static, GtkToggleButton>>,
|
2019-04-03 18:30:22 -07:00
|
|
|
}
|
|
|
|
|
2019-05-13 19:03:09 -07:00
|
|
|
pub struct EditorModel
|
2019-04-03 18:30:22 -07:00
|
|
|
{
|
|
|
|
}
|
|
|
|
|
2019-05-13 19:03:09 -07:00
|
|
|
pub type EditorRef = std::cell::RefCell<EditorModel>;
|
2019-04-03 18:30:22 -07:00
|
|
|
|
|
|
|
// EOF
|