Perhaps doing ownership right?
This commit is contained in:
@@ -25,8 +25,8 @@ mod signalk;
|
|||||||
mod vesseldata;
|
mod vesseldata;
|
||||||
use vesseldata::VesselDataEventSource;
|
use vesseldata::VesselDataEventSource;
|
||||||
|
|
||||||
pub struct HelmsDisplay {
|
pub struct HelmsDisplay<'a> {
|
||||||
font: Font<'static>,
|
font: Font<'a>,
|
||||||
boat: forms::Form,
|
boat: forms::Form,
|
||||||
compassrose: forms::Form,
|
compassrose: forms::Form,
|
||||||
cog: forms::Form,
|
cog: forms::Form,
|
||||||
@@ -36,9 +36,9 @@ pub struct HelmsDisplay {
|
|||||||
course_screen: forms::Screen,
|
course_screen: forms::Screen,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl HelmsDisplay {
|
impl<'a> HelmsDisplay<'a> {
|
||||||
|
|
||||||
pub fn new() -> HelmsDisplay {
|
pub fn new() -> HelmsDisplay<'a> {
|
||||||
// in the future, this method should probably take some sort of
|
// in the future, this method should probably take some sort of
|
||||||
// configuration object.
|
// configuration object.
|
||||||
let mut loader = forms::Loader::new("/root/helms-display".to_string());
|
let mut loader = forms::Loader::new("/root/helms-display".to_string());
|
||||||
|
|||||||
Reference in New Issue
Block a user