pub struct FileDialogState {
pub core: FileDialogCore,
pub ui: FileDialogUiState,
}Expand description
Combined state for the in-UI file dialog.
Fields§
§core: FileDialogCoreCore state machine.
ui: FileDialogUiStateUI-only state.
Implementations§
Source§impl FileDialogState
impl FileDialogState
Sourcepub fn new(mode: DialogMode) -> Self
pub fn new(mode: DialogMode) -> Self
Creates a new dialog state for a mode.
Sourcepub fn open(&mut self)
pub fn open(&mut self)
Opens (or reopens) the dialog.
This mirrors IGFD’s OpenDialog step before Display.
Sourcepub fn reopen(&mut self)
pub fn reopen(&mut self)
Reopens the dialog.
Alias of FileDialogState::open.
Sourcepub fn scan_policy(&self) -> ScanPolicy
pub fn scan_policy(&self) -> ScanPolicy
Returns the active scan policy.
Sourcepub fn set_scan_policy(&mut self, policy: ScanPolicy)
pub fn set_scan_policy(&mut self, policy: ScanPolicy)
Sets scan policy for future directory refreshes.
Sourcepub fn scan_status(&self) -> &ScanStatus
pub fn scan_status(&self) -> &ScanStatus
Returns the latest scan status from core.
Sourcepub fn request_rescan(&mut self)
pub fn request_rescan(&mut self)
Requests a rescan on the next draw tick.
Sourcepub fn set_scan_hook<F>(&mut self, hook: F)
pub fn set_scan_hook<F>(&mut self, hook: F)
Installs a scan hook on the core listing pipeline.
The hook runs during directory scan and can mutate or drop entries.
Sourcepub fn clear_scan_hook(&mut self)
pub fn clear_scan_hook(&mut self)
Clears the scan hook and restores raw filesystem listing.
Sourcepub fn apply_igfd_classic_preset(&mut self)
pub fn apply_igfd_classic_preset(&mut self)
Applies an “IGFD classic” preset for both UI and core.
This is a convenience wrapper over FileDialogUiState::apply_igfd_classic_preset that
also tunes core defaults to match typical IGFD behavior.