(&self)
| 6954 | } |
| 6955 | |
| 6956 | pub fn get_scroll_offset(&self) -> Vector2 { |
| 6957 | let open_idx = self.get_open_layout_element(); |
| 6958 | let elem_id = self.layout_elements[open_idx].id; |
| 6959 | for scd in &self.scroll_container_datas { |
| 6960 | if scd.element_id == elem_id { |
| 6961 | return scd.scroll_position; |
| 6962 | } |
| 6963 | } |
| 6964 | Vector2::default() |
| 6965 | } |
| 6966 | |
| 6967 | pub fn set_scroll_position(&mut self, id: Id, position: Vector2) { |
| 6968 | for scd in &mut self.scroll_container_datas { |
no test coverage detected