diff --git a/egui_node_graph/src/traits.rs b/egui_node_graph/src/traits.rs index 7665346..376d870 100644 --- a/egui_node_graph/src/traits.rs +++ b/egui_node_graph/src/traits.rs @@ -5,6 +5,10 @@ use super::*; /// types of the node graph. pub trait WidgetValueTrait { type Response; + /// This method will be called for each input parameter with a widget. The + /// return value is a vector of custom response objects which can be used + /// to implement handling of side effects. If unsure, the response Vec can + /// be empty. fn value_widget(&mut self, param_name: &str, ui: &mut egui::Ui) -> Vec; } diff --git a/egui_node_graph_example/src/app.rs b/egui_node_graph_example/src/app.rs index 147b7ca..1c2c812 100644 --- a/egui_node_graph_example/src/app.rs +++ b/egui_node_graph_example/src/app.rs @@ -271,7 +271,7 @@ impl WidgetValueTrait for MyValueType { }); } } - // This allows you to retorn your responses from the inline widgets. + // This allows you to return your responses from the inline widgets. Vec::new() } }