impl<'a, TOption> super::Navigation where TOption: Clone + PartialEq + 'a, { pub fn find

(&self, pred: P) -> Option where P: Fn(&TOption) -> bool, { self.options_before_active .iter() .find(|o| pred(o)) .cloned() .or_else(|| self.active_option.clone().filter(|o| pred(o))) .or_else(|| self.options_after_active.iter().find(|o| pred(o)).cloned()) } }