SaveFilePickerAction
struct · ferroui-xaml-interactions · v0.5.0
struct SaveFilePickerAction
An action that will open a save file picker dialog.
The picked file (StorageFileRef) is given to the handlers of pick and,
unless a handler handled it, to the command.
Deviation (DEVIATIONS.md, Behaviors): the Pick event is an event of the Rust API (a handler
list), not declared to markup.
Members
TYPEto_refon_pickdefault_extension_propertyfile_type_choices_propertyshow_overwrite_prompt_propertyconstructnewpickdefault_extensionset_default_extensionfile_type_choicesset_file_type_choicesshow_overwrite_promptset_show_overwrite_prompt
TYPE
const TYPE: &'static $crate::TypeInfo
The runtime type of this class.
to_ref
fn to_ref(self: &Self) -> $crate::Ref<SaveFilePickerAction>
Returns a strong reference to this object.
on_pick
fn on_pick(self: &Self, args: &SaveFilePickerEventArgs)
Raises the pick event.
default_extension_property
fn default_extension_property() -> &'static StyledProperty<Option<String>>
Identifies the DefaultExtension property.
file_type_choices_property
fn file_type_choices_property() -> &'static StyledProperty<Option<String>>
Identifies the FileTypeChoices property.
show_overwrite_prompt_property
fn show_overwrite_prompt_property() -> &'static StyledProperty<Option<bool>>
Identifies the ShowOverwritePrompt property.
construct
fn construct() -> Self
Creates the class data; see ferroui_base::FerroObject::construct.
new
fn new() -> Ref<Self>
Creates an action.
pick
fn pick(self: &Self, handler: impl Fn(&SaveFilePickerEventArgs) -> () + 'static) -> Rc<dyn IDisposable>
Occurs after the save file picker successfully returns a file. Disposing the returned handle removes the handler.
default_extension
fn default_extension(self: &Self) -> Option<String>
Gets or sets the default extension to be used to save the file. This is a property of the object model.
set_default_extension
fn set_default_extension(self: &Self, value: Option<String>)
file_type_choices
fn file_type_choices(self: &Self) -> Option<String>
Gets or sets the file types that the user can choose to assign to a file, as a filter
(Description|*.ext;*.other|..). This is a property of the object model.
set_file_type_choices
fn set_file_type_choices(self: &Self, value: Option<String>)
show_overwrite_prompt
fn show_overwrite_prompt(self: &Self) -> Option<bool>
Gets or sets a value indicating whether the picker displays a warning if the user specifies the name of a file that already exists. This is a property of the object model.
set_show_overwrite_prompt
fn set_show_overwrite_prompt(self: &Self, value: Option<bool>)
Trait implementations
SendSyncFreezeUnsafeUnpinUnpinUnwindSafeRefUnwindSafeSaveFilePickerActionImplExtBorrow<T>BorrowMut<T>Into<U>From<T>TryInto<U>TryFrom<U>ReceiverAnyFerroObjectImplExtStyledElementImplExtClassDefaultsErasedDestructorIntoEitherStyledElementActionImplExtDerefUpcast<T>Upcast<SaveFilePickerAction>StaticTypeObjectTypeSubclassable<T>DefaultConstructibleStyledElementImplFerroObjectImplStyledElementActionImplSaveFilePickerActionImpl
Availability
Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.