add show / hide implementations

This commit is contained in:
Corwin Kuiper 2021-05-29 12:24:04 +01:00
parent 9adbfbe275
commit 300aafd665

View file

@ -37,6 +37,12 @@ impl ObjectStandard {
pub fn set_hflip(&mut self, hflip: bool) { pub fn set_hflip(&mut self, hflip: bool) {
self.attributes.set_hflip(hflip) self.attributes.set_hflip(hflip)
} }
pub fn show(&mut self) {
self.attributes.set_mode(Mode::Normal)
}
pub fn hide(&mut self) {
self.attributes.set_mode(Mode::Hidden)
}
} }
pub struct ObjectAttributeStandard { pub struct ObjectAttributeStandard {