(&self, control: &dyn Element)
| 150 | //Internal |
| 151 | |
| 152 | pub fn apply_depth(&self, control: &dyn Element) { |
| 153 | let mut state = self.state.borrow_mut(); |
| 154 | control.set_depth(state.depth_idx + control.depth_offset()); |
| 155 | state.depth_idx += 1.0; |
| 156 | |
| 157 | // for child in control.as_ref().borrow().children.iter() { |
| 158 | // if let Some(widget) = child.widget() { |
| 159 | // self.apply_depth(widget.as_ref()); |
| 160 | // } |
| 161 | // } |
| 162 | } |
| 163 | |
| 164 | pub fn sync_depth(&self) { |
| 165 | self.state.borrow_mut().depth_idx = 0.0; |
no test coverage detected