Skip to content

Commit

Permalink
remove: field graph
Browse files Browse the repository at this point in the history
  • Loading branch information
mrchantey committed Feb 5, 2024
1 parent 633427d commit a927c1a
Show file tree
Hide file tree
Showing 6 changed files with 2 additions and 52 deletions.
12 changes: 0 additions & 12 deletions crates/gamai/src/action/action_graph.rs
Original file line number Diff line number Diff line change
Expand Up @@ -86,15 +86,3 @@ impl<T: ActionSuper> ActionGraph<T> {
EntityGraph(entity_graph)
}
}

impl<T: ActionSuper + IntoFieldUi> ActionGraph<T> {
pub fn into_field_graph(&self) -> FieldGraph<T> {
self.0.into_field_graph()
}
}
#[extend::ext(name=ActionTreeExt2)]
pub impl<T: ActionSuper + IntoFieldUi> ActionTree<T> {
fn into_field_graph(self) -> FieldGraph<T> {
self.into_action_graph().into_field_graph()
}
}
3 changes: 2 additions & 1 deletion crates/gamai/src/ui/field_reflect.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,8 @@ impl<T: Clone> FieldValue for T {}
pub type GetFunc<T> = Rc<Box<dyn Fn() -> T>>;
pub type SetFunc<T> = Rc<Box<dyn Fn(T)>>;


// TODO we should consider higher order functions for set, ie update_cb
// It may mean field reflect needs to know parent type
#[derive(Clone)]
pub struct FieldReflect<T: FieldValue> {
pub field_name: String,
Expand Down
22 changes: 0 additions & 22 deletions crates/gamai/src/ui/graph_ui.rs

This file was deleted.

3 changes: 0 additions & 3 deletions crates/gamai/src/ui/mod.rs
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
pub mod group_field;
#[allow(unused_imports)]
pub use self::group_field::*;
pub mod graph_ui;
#[allow(unused_imports)]
pub use self::graph_ui::*;
pub mod number_field;
#[allow(unused_imports)]
pub use self::number_field::*;
Expand Down
11 changes: 0 additions & 11 deletions crates/gamai/test/ui/graph_ui.rs

This file was deleted.

3 changes: 0 additions & 3 deletions crates/gamai/test/ui/mod.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
pub mod graph_ui;
#[allow(unused_imports)]
pub use self::graph_ui::*;
pub mod field_ui;
#[allow(unused_imports)]
pub use self::field_ui::*;
Expand Down

0 comments on commit a927c1a

Please sign in to comment.