pub struct SearchFieldsState {
pub focussed_section: FocussedSection,
pub search_state: Option<SearchState>,
pub search_debounce_timer: Option<JoinHandle<()>>,
pub preview_update_state: Option<PreviewUpdateStatus>,
pub last_scheduled_key: Option<Box<SearchKey>>,
/* private fields */
}Fields§
§focussed_section: FocussedSection§search_state: Option<SearchState>§search_debounce_timer: Option<JoinHandle<()>>§preview_update_state: Option<PreviewUpdateStatus>§last_scheduled_key: Option<Box<SearchKey>>Key of the most recently scheduled/run search. Cleared whenever
search_state is cleared (e.g. on empty text) so that re-typing the
same query runs the search again. Boxed to keep the Screen enum
compact.
Implementations§
Source§impl SearchFieldsState
impl SearchFieldsState
pub fn replacements_in_progress(&self) -> Option<(usize, usize)>
pub fn cancel_preview_updates(&mut self)
pub fn abort_search_debounce(&mut self)
Sourcepub fn cancel_pending_async_work(&mut self)
pub fn cancel_pending_async_work(&mut self)
Cancel both async refresh paths owned by this state: any pending
preview-replacement update and any pending debounced search. Does
not signal an in-flight search task to stop — that’s
App::cancel_search / SearchState::cancel.
pub fn next_search_generation(&mut self) -> u64
Trait Implementations§
Source§impl Debug for SearchFieldsState
impl Debug for SearchFieldsState
Auto Trait Implementations§
impl Freeze for SearchFieldsState
impl RefUnwindSafe for SearchFieldsState
impl Send for SearchFieldsState
impl Sync for SearchFieldsState
impl Unpin for SearchFieldsState
impl UnsafeUnpin for SearchFieldsState
impl UnwindSafe for SearchFieldsState
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more